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_HASH_STYLE 727 OPENJDK_BUILD_LDFLAGS_CXX_JDK 728 OPENJDK_BUILD_JDKEXE_LIBS 729 OPENJDK_BUILD_JDKLIB_LIBS 730 OPENJDK_BUILD_LDFLAGS_JDKEXE 731 OPENJDK_BUILD_LDFLAGS_JDKLIB 732 OPENJDK_BUILD_CXXFLAGS_JDKEXE 733 OPENJDK_BUILD_CXXFLAGS_JDKLIB 734 OPENJDK_BUILD_CFLAGS_JDKEXE 735 OPENJDK_BUILD_CFLAGS_JDKLIB 736 OPENJDK_BUILD_CXXSTD_CXXFLAG 737 JVM_LIBS 738 JVM_ASFLAGS 739 JVM_LDFLAGS 740 JVM_CFLAGS 741 LDFLAGS_HASH_STYLE 742 LDFLAGS_CXX_JDK 743 JDKEXE_LIBS 744 JDKLIB_LIBS 745 LDFLAGS_JDKEXE 746 LDFLAGS_JDKLIB 747 CXXFLAGS_JDKEXE 748 CXXFLAGS_JDKLIB 749 CFLAGS_JDKEXE 750 CFLAGS_JDKLIB 751 MACOSX_VERSION_MAX 752 MACOSX_VERSION_MIN 753 CXXSTD_CXXFLAG 754 JDK_ARCH_ABI_PROP_NAME 755 CXX_O_FLAG_SIZE 756 CXX_O_FLAG_NONE 757 CXX_O_FLAG_DEBUG 758 CXX_O_FLAG_NORM 759 CXX_O_FLAG_HI 760 CXX_O_FLAG_HIGHEST 761 CXX_O_FLAG_HIGHEST_JVM 762 C_O_FLAG_SIZE 763 C_O_FLAG_NONE 764 C_O_FLAG_DEBUG 765 C_O_FLAG_NORM 766 C_O_FLAG_HI 767 C_O_FLAG_HIGHEST 768 C_O_FLAG_HIGHEST_JVM 769 JVM_CFLAGS_SYMBOLS 770 CXXFLAGS_DEBUG_SYMBOLS 771 CFLAGS_DEBUG_SYMBOLS 772 CXX_FLAG_DEPS 773 C_FLAG_DEPS 774 SHARED_LIBRARY_FLAGS 775 SET_SHARED_LIBRARY_MAPFILE 776 SET_SHARED_LIBRARY_NAME 777 SET_SHARED_LIBRARY_ORIGIN 778 SET_EXECUTABLE_ORIGIN 779 CXX_FLAG_REORDER 780 C_FLAG_REORDER 781 JVM_RCFLAGS 782 RC_FLAGS 783 AR_OUT_OPTION 784 LD_OUT_OPTION 785 EXE_OUT_OPTION 786 CC_OUT_OPTION 787 STRIPFLAGS 788 ARFLAGS 789 COMPILER_BINDCMD_FILE_FLAG 790 COMPILER_COMMAND_FILE_FLAG 791 COMPILER_TARGET_BITS_FLAG 792 JIB_JAR 793 JT_HOME 794 JTREGEXE 795 HOTSPOT_TOOLCHAIN_TYPE 796 USING_BROKEN_SUSE_LD 797 PACKAGE_PATH 798 BUILD_AS 799 BUILD_LDCXX 800 BUILD_LD 801 BUILD_STRIP 802 BUILD_OBJCOPY 803 BUILD_AR 804 BUILD_NM 805 BUILD_CXX 806 BUILD_CC 807 BUILD_SYSROOT_LDFLAGS 808 BUILD_SYSROOT_CFLAGS 809 ac_ct_OBJDUMP 810 OBJDUMP 811 ac_ct_OBJCOPY 812 OBJCOPY 813 ac_ct_NM 814 ac_ct_STRIP 815 GNM 816 NM 817 STRIP 818 MSBUILD 819 DUMPBIN 820 RC 821 MT 822 LIPO 823 ac_ct_AR 824 AR 825 AS 826 LDCXX 827 LD 828 CXXCPP 829 CPP 830 CXX_VERSION_NUMBER 831 CC_VERSION_NUMBER 832 ac_ct_CXX 833 CXXFLAGS 834 CXX 835 TOOLCHAIN_PATH_CXX 836 POTENTIAL_CXX 837 OBJEXT 838 EXEEXT 839 ac_ct_CC 840 CPPFLAGS 841 LDFLAGS 842 CFLAGS 843 CC 844 TOOLCHAIN_PATH_CC 845 POTENTIAL_CC 846 TOOLCHAIN_VERSION 847 VS_LIB 848 VS_INCLUDE 849 VS_PATH 850 CYGWIN_LINK 851 SYSROOT_LDFLAGS 852 SYSROOT_CFLAGS 853 EXTRA_LDFLAGS 854 EXTRA_CXXFLAGS 855 EXTRA_CFLAGS 856 EXE_SUFFIX 857 OBJ_SUFFIX 858 STATIC_LIBRARY 859 SHARED_LIBRARY 860 STATIC_LIBRARY_SUFFIX 861 SHARED_LIBRARY_SUFFIX 862 LIBRARY_PREFIX 863 TOOLCHAIN_TYPE 864 STATIC_BUILD 865 IMPORT_MODULES_MAKE 866 IMPORT_MODULES_SRC 867 IMPORT_MODULES_MAN 868 IMPORT_MODULES_LEGAL 869 IMPORT_MODULES_CONF 870 IMPORT_MODULES_LIBS 871 IMPORT_MODULES_CMDS 872 IMPORT_MODULES_CLASSES 873 BUILD_OUTPUT 874 EXTERNAL_BUILDJDK 875 BUILD_JDK 876 CREATE_BUILDJDK 877 JLINK 878 JMOD 879 JAVAC_FLAGS 880 BOOT_JDK_MODULAR 881 BOOT_JDK_SOURCETARGET 882 JARSIGNER 883 JAR 884 JAVAH 885 JAVAC 886 JAVA 887 BOOT_JDK 888 JAVA_CHECK 889 JAVAC_CHECK 890 VERSION_IS_GA 891 VERSION_SHORT 892 VERSION_STRING 893 VERSION_NUMBER_FOUR_POSITIONS 894 VERSION_NUMBER 895 VERSION_OPT 896 VERSION_BUILD 897 VERSION_PRE 898 VERSION_PATCH 899 VERSION_SECURITY 900 VERSION_MINOR 901 VERSION_MAJOR 902 MACOSX_BUNDLE_ID_BASE 903 MACOSX_BUNDLE_NAME_BASE 904 HOTSPOT_VM_DISTRO 905 COMPANY_NAME 906 JDK_RC_PLATFORM_NAME 907 PRODUCT_SUFFIX 908 PRODUCT_NAME 909 LAUNCHER_NAME 910 JLINK_KEEP_PACKAGED_MODULES 911 COPYRIGHT_YEAR 912 COMPRESS_JARS 913 INCLUDE_SA 914 UNLIMITED_CRYPTO 915 CACERTS_FILE 916 ENABLE_FULL_DOCS 917 ENABLE_HEADLESS_ONLY 918 DEFAULT_MAKE_TARGET 919 OS_VERSION_MICRO 920 OS_VERSION_MINOR 921 OS_VERSION_MAJOR 922 PKG_CONFIG 923 BASH_ARGS 924 SETFILE 925 CODESIGN 926 XATTR 927 DSYMUTIL 928 IS_GNU_TIME 929 PATCH 930 DTRACE 931 FLOCK 932 TIME 933 STAT 934 HG 935 DOT 936 READELF 937 OTOOL 938 LDD 939 ZIPEXE 940 UNZIP 941 TAR_SUPPORTS_TRANSFORM 942 TAR_INCLUDE_PARAM 943 TAR_CREATE_EXTRA_PARAM 944 TAR_TYPE 945 FIND_DELETE 946 OUTPUT_SYNC 947 OUTPUT_SYNC_SUPPORTED 948 CHECK_TOOLSDIR_MAKE 949 CHECK_TOOLSDIR_GMAKE 950 CHECK_MAKE 951 CHECK_GMAKE 952 MAKE 953 PKGHANDLER 954 CONFIGURESUPPORT_OUTPUTDIR 955 OUTPUT_ROOT 956 CONF_NAME 957 SPEC 958 SDKROOT 959 XCODEBUILD 960 JVM_VARIANT_MAIN 961 VALID_JVM_VARIANTS 962 JVM_VARIANTS 963 DEBUG_LEVEL 964 HOTSPOT_DEBUG_LEVEL 965 JDK_VARIANT 966 USERNAME 967 CANONICAL_TOPDIR 968 ORIGINAL_TOPDIR 969 TOPDIR 970 PATH_SEP 971 HOTSPOT_BUILD_CPU_DEFINE 972 HOTSPOT_BUILD_CPU_ARCH 973 HOTSPOT_BUILD_CPU 974 HOTSPOT_BUILD_OS_TYPE 975 HOTSPOT_BUILD_OS 976 OPENJDK_BUILD_BUNDLE_PLATFORM 977 OPENJDK_BUILD_OS_EXPORT_DIR 978 OPENJDK_BUILD_CPU_OSARCH 979 OPENJDK_BUILD_CPU_ISADIR 980 OPENJDK_BUILD_CPU_LEGACY_LIB 981 OPENJDK_BUILD_CPU_LEGACY 982 HOTSPOT_TARGET_CPU_DEFINE 983 HOTSPOT_TARGET_CPU_ARCH 984 HOTSPOT_TARGET_CPU 985 HOTSPOT_TARGET_OS_TYPE 986 HOTSPOT_TARGET_OS 987 DEFINE_CROSS_COMPILE_ARCH 988 OPENJDK_TARGET_BUNDLE_PLATFORM 989 OPENJDK_TARGET_OS_EXPORT_DIR 990 OPENJDK_TARGET_CPU_OSARCH 991 OPENJDK_TARGET_CPU_ISADIR 992 OPENJDK_TARGET_CPU_LEGACY_LIB 993 OPENJDK_TARGET_CPU_LEGACY 994 RELEASE_FILE_OS_ARCH 995 RELEASE_FILE_OS_NAME 996 OPENJDK_MODULE_TARGET_PLATFORM 997 COMPILE_TYPE 998 OPENJDK_TARGET_CPU_ENDIAN 999 OPENJDK_TARGET_CPU_BITS 1000 OPENJDK_TARGET_CPU_ARCH 1001 OPENJDK_TARGET_CPU 1002 OPENJDK_TARGET_OS_ENV 1003 OPENJDK_TARGET_OS_TYPE 1004 OPENJDK_TARGET_OS 1005 OPENJDK_BUILD_CPU_ENDIAN 1006 OPENJDK_BUILD_CPU_BITS 1007 OPENJDK_BUILD_CPU_ARCH 1008 OPENJDK_BUILD_CPU 1009 OPENJDK_BUILD_OS_ENV 1010 OPENJDK_BUILD_OS_TYPE 1011 OPENJDK_BUILD_OS 1012 OPENJDK_BUILD_AUTOCONF_NAME 1013 OPENJDK_TARGET_AUTOCONF_NAME 1014 target_os 1015 target_vendor 1016 target_cpu 1017 target 1018 host_os 1019 host_vendor 1020 host_cpu 1021 host 1022 build_os 1023 build_vendor 1024 build_cpu 1025 build 1026 PANDOC 1027 NICE 1028 CPIO 1029 DF 1030 READLINK 1031 CYGPATH 1032 SED 1033 FGREP 1034 EGREP 1035 GREP 1036 AWK 1037 XARGS 1038 WHICH 1039 WC 1040 UNIQ 1041 UNAME 1042 TR 1043 TOUCH 1044 TEE 1045 TAR 1046 TAIL 1047 SORT 1048 SH 1049 RMDIR 1050 RM 1051 PRINTF 1052 NAWK 1053 MV 1054 MKTEMP 1055 MKDIR 1056 LS 1057 LN 1058 GZIP 1059 GUNZIP 1060 HEAD 1061 FIND 1062 FILE 1063 EXPR 1064 ECHO 1065 DIRNAME 1066 DIFF 1067 DATE 1068 CUT 1069 CP 1070 COMM 1071 CMP 1072 CHMOD 1073 CAT 1074 BASH 1075 BASENAME 1076 DATE_WHEN_CONFIGURED 1077 ORIGINAL_PATH 1078 CONFIGURE_COMMAND_LINE 1079 target_alias 1080 host_alias 1081 build_alias 1082 LIBS 1083 ECHO_T 1084 ECHO_N 1085 ECHO_C 1086 DEFS 1087 mandir 1088 localedir 1089 libdir 1090 psdir 1091 pdfdir 1092 dvidir 1093 htmldir 1094 infodir 1095 docdir 1096 oldincludedir 1097 includedir 1098 localstatedir 1099 sharedstatedir 1100 sysconfdir 1101 datadir 1102 datarootdir 1103 libexecdir 1104 sbindir 1105 bindir 1106 program_transform_name 1107 prefix 1108 exec_prefix 1109 PACKAGE_URL 1110 PACKAGE_BUGREPORT 1111 PACKAGE_STRING 1112 PACKAGE_VERSION 1113 PACKAGE_TARNAME 1114 PACKAGE_NAME 1115 PATH_SEPARATOR 1116 SHELL' 1117 ac_subst_files='' 1118 ac_user_opts=' 1119 enable_option_checking 1120 with_target_bits 1121 enable_openjdk_only 1122 with_custom_make_dir 1123 with_jdk_variant 1124 enable_debug 1125 with_debug_level 1126 with_jvm_variants 1127 with_cpu_port 1128 with_devkit 1129 with_sys_root 1130 with_sysroot 1131 with_tools_dir 1132 with_toolchain_path 1133 with_extra_path 1134 with_sdk_name 1135 with_conf_name 1136 with_output_base_dir 1137 with_output_sync 1138 with_default_make_target 1139 enable_headless_only 1140 enable_full_docs 1141 with_cacerts_file 1142 enable_unlimited_crypto 1143 with_copyright_year 1144 enable_keep_packaged_modules 1145 with_milestone 1146 with_update_version 1147 with_user_release_suffix 1148 with_build_number 1149 with_version_string 1150 with_version_pre 1151 with_version_opt 1152 with_version_build 1153 with_version_major 1154 with_version_minor 1155 with_version_security 1156 with_version_patch 1157 with_boot_jdk 1158 with_build_jdk 1159 with_import_modules 1160 enable_static_build 1161 with_toolchain_type 1162 with_extra_cflags 1163 with_extra_cxxflags 1164 with_extra_ldflags 1165 with_toolchain_version 1166 with_build_devkit 1167 with_jtreg 1168 with_jib 1169 with_abi_profile 1170 with_macosx_version_max 1171 enable_warnings_as_errors 1172 with_native_debug_symbols 1173 enable_debug_symbols 1174 enable_zip_debug_info 1175 enable_native_coverage 1176 enable_dtrace 1177 enable_aot 1178 enable_cds 1179 enable_hotspot_gtest 1180 with_stdc__lib 1181 with_msvcr_dll 1182 with_msvcp_dll 1183 with_x 1184 with_cups 1185 with_cups_include 1186 with_freetype 1187 with_freetype_include 1188 with_freetype_lib 1189 with_freetype_src 1190 enable_freetype_bundling 1191 with_freetype_license 1192 with_alsa 1193 with_alsa_include 1194 with_alsa_lib 1195 with_libffi 1196 with_libffi_include 1197 with_libffi_lib 1198 enable_libffi_bundling 1199 with_libjpeg 1200 with_giflib 1201 with_libpng 1202 with_zlib 1203 with_lcms 1204 with_dxsdk 1205 with_dxsdk_lib 1206 with_dxsdk_include 1207 with_jvm_features 1208 with_jvm_interpreter 1209 enable_jtreg_failure_handler 1210 enable_generate_classlist 1211 with_num_cores 1212 with_memory_size 1213 with_jobs 1214 with_test_jobs 1215 with_boot_jdk_jvmargs 1216 with_sjavac_server_java 1217 enable_sjavac 1218 enable_javac_server 1219 enable_icecc 1220 enable_precompiled_headers 1221 enable_ccache 1222 with_ccache_dir 1223 ' 1224 ac_precious_vars='build_alias 1225 host_alias 1226 target_alias 1227 BASENAME 1228 BASH 1229 CAT 1230 CHMOD 1231 CMP 1232 COMM 1233 CP 1234 CUT 1235 DATE 1236 DIFF 1237 DIRNAME 1238 ECHO 1239 EXPR 1240 FILE 1241 FIND 1242 HEAD 1243 GUNZIP 1244 GZIP 1245 LN 1246 LS 1247 MKDIR 1248 MKTEMP 1249 MV 1250 NAWK 1251 PRINTF 1252 RM 1253 RMDIR 1254 SH 1255 SORT 1256 TAIL 1257 TAR 1258 TEE 1259 TOUCH 1260 TR 1261 UNAME 1262 UNIQ 1263 WC 1264 WHICH 1265 XARGS 1266 AWK 1267 GREP 1268 EGREP 1269 FGREP 1270 SED 1271 CYGPATH 1272 READLINK 1273 DF 1274 CPIO 1275 NICE 1276 PANDOC 1277 MAKE 1278 UNZIP 1279 ZIPEXE 1280 LDD 1281 OTOOL 1282 READELF 1283 DOT 1284 HG 1285 STAT 1286 TIME 1287 FLOCK 1288 DTRACE 1289 PATCH 1290 DSYMUTIL 1291 XATTR 1292 CODESIGN 1293 SETFILE 1294 PKG_CONFIG 1295 JAVA 1296 JAVAC 1297 JAVAH 1298 JAR 1299 JARSIGNER 1300 CC 1301 CFLAGS 1302 LDFLAGS 1303 LIBS 1304 CPPFLAGS 1305 CXX 1306 CXXFLAGS 1307 CCC 1308 CPP 1309 CXXCPP 1310 AS 1311 AR 1312 LIPO 1313 STRIP 1314 NM 1315 GNM 1316 OBJCOPY 1317 OBJDUMP 1318 BUILD_CC 1319 BUILD_CXX 1320 BUILD_NM 1321 BUILD_AR 1322 BUILD_OBJCOPY 1323 BUILD_STRIP 1324 JTREGEXE 1325 XMKMF 1326 FREETYPE_CFLAGS 1327 FREETYPE_LIBS 1328 ALSA_CFLAGS 1329 ALSA_LIBS 1330 LIBFFI_CFLAGS 1331 LIBFFI_LIBS 1332 PNG_CFLAGS 1333 PNG_LIBS 1334 LCMS_CFLAGS 1335 LCMS_LIBS 1336 ICECC_CMD 1337 ICECC_CREATE_ENV 1338 ICECC_WRAPPER 1339 CCACHE' 1340 1341 1342 # Initialize some variables set by options. 1343 ac_init_help= 1344 ac_init_version=false 1345 ac_unrecognized_opts= 1346 ac_unrecognized_sep= 1347 # The variables have the same names as the options, with 1348 # dashes changed to underlines. 1349 cache_file=/dev/null 1350 exec_prefix=NONE 1351 no_create= 1352 no_recursion= 1353 prefix=NONE 1354 program_prefix=NONE 1355 program_suffix=NONE 1356 program_transform_name=s,x,x, 1357 silent= 1358 site= 1359 srcdir= 1360 verbose= 1361 x_includes=NONE 1362 x_libraries=NONE 1363 1364 # Installation directory options. 1365 # These are left unexpanded so users can "make install exec_prefix=/foo" 1366 # and all the variables that are supposed to be based on exec_prefix 1367 # by default will actually change. 1368 # Use braces instead of parens because sh, perl, etc. also accept them. 1369 # (The list follows the same order as the GNU Coding Standards.) 1370 bindir='${exec_prefix}/bin' 1371 sbindir='${exec_prefix}/sbin' 1372 libexecdir='${exec_prefix}/libexec' 1373 datarootdir='${prefix}/share' 1374 datadir='${datarootdir}' 1375 sysconfdir='${prefix}/etc' 1376 sharedstatedir='${prefix}/com' 1377 localstatedir='${prefix}/var' 1378 includedir='${prefix}/include' 1379 oldincludedir='/usr/include' 1380 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1381 infodir='${datarootdir}/info' 1382 htmldir='${docdir}' 1383 dvidir='${docdir}' 1384 pdfdir='${docdir}' 1385 psdir='${docdir}' 1386 libdir='${exec_prefix}/lib' 1387 localedir='${datarootdir}/locale' 1388 mandir='${datarootdir}/man' 1389 1390 ac_prev= 1391 ac_dashdash= 1392 for ac_option 1393 do 1394 # If the previous option needs an argument, assign it. 1395 if test -n "$ac_prev"; then 1396 eval $ac_prev=\$ac_option 1397 ac_prev= 1398 continue 1399 fi 1400 1401 case $ac_option in 1402 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1403 *=) ac_optarg= ;; 1404 *) ac_optarg=yes ;; 1405 esac 1406 1407 # Accept the important Cygnus configure options, so we can diagnose typos. 1408 1409 case $ac_dashdash$ac_option in 1410 --) 1411 ac_dashdash=yes ;; 1412 1413 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1414 ac_prev=bindir ;; 1415 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1416 bindir=$ac_optarg ;; 1417 1418 -build | --build | --buil | --bui | --bu) 1419 ac_prev=build_alias ;; 1420 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1421 build_alias=$ac_optarg ;; 1422 1423 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1424 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1425 ac_prev=cache_file ;; 1426 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1427 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1428 cache_file=$ac_optarg ;; 1429 1430 --config-cache | -C) 1431 cache_file=config.cache ;; 1432 1433 -datadir | --datadir | --datadi | --datad) 1434 ac_prev=datadir ;; 1435 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1436 datadir=$ac_optarg ;; 1437 1438 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1439 | --dataroo | --dataro | --datar) 1440 ac_prev=datarootdir ;; 1441 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1442 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1443 datarootdir=$ac_optarg ;; 1444 1445 -disable-* | --disable-*) 1446 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1447 # Reject names that are not valid shell variable names. 1448 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1449 as_fn_error $? "invalid feature name: $ac_useropt" 1450 ac_useropt_orig=$ac_useropt 1451 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1452 case $ac_user_opts in 1453 *" 1454 "enable_$ac_useropt" 1455 "*) ;; 1456 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1457 ac_unrecognized_sep=', ';; 1458 esac 1459 eval enable_$ac_useropt=no ;; 1460 1461 -docdir | --docdir | --docdi | --doc | --do) 1462 ac_prev=docdir ;; 1463 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1464 docdir=$ac_optarg ;; 1465 1466 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1467 ac_prev=dvidir ;; 1468 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1469 dvidir=$ac_optarg ;; 1470 1471 -enable-* | --enable-*) 1472 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1473 # Reject names that are not valid shell variable names. 1474 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1475 as_fn_error $? "invalid feature name: $ac_useropt" 1476 ac_useropt_orig=$ac_useropt 1477 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1478 case $ac_user_opts in 1479 *" 1480 "enable_$ac_useropt" 1481 "*) ;; 1482 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1483 ac_unrecognized_sep=', ';; 1484 esac 1485 eval enable_$ac_useropt=\$ac_optarg ;; 1486 1487 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1488 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1489 | --exec | --exe | --ex) 1490 ac_prev=exec_prefix ;; 1491 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1492 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1493 | --exec=* | --exe=* | --ex=*) 1494 exec_prefix=$ac_optarg ;; 1495 1496 -gas | --gas | --ga | --g) 1497 # Obsolete; use --with-gas. 1498 with_gas=yes ;; 1499 1500 -help | --help | --hel | --he | -h) 1501 ac_init_help=long ;; 1502 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1503 ac_init_help=recursive ;; 1504 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1505 ac_init_help=short ;; 1506 1507 -host | --host | --hos | --ho) 1508 ac_prev=host_alias ;; 1509 -host=* | --host=* | --hos=* | --ho=*) 1510 host_alias=$ac_optarg ;; 1511 1512 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1513 ac_prev=htmldir ;; 1514 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1515 | --ht=*) 1516 htmldir=$ac_optarg ;; 1517 1518 -includedir | --includedir | --includedi | --included | --include \ 1519 | --includ | --inclu | --incl | --inc) 1520 ac_prev=includedir ;; 1521 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1522 | --includ=* | --inclu=* | --incl=* | --inc=*) 1523 includedir=$ac_optarg ;; 1524 1525 -infodir | --infodir | --infodi | --infod | --info | --inf) 1526 ac_prev=infodir ;; 1527 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1528 infodir=$ac_optarg ;; 1529 1530 -libdir | --libdir | --libdi | --libd) 1531 ac_prev=libdir ;; 1532 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1533 libdir=$ac_optarg ;; 1534 1535 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1536 | --libexe | --libex | --libe) 1537 ac_prev=libexecdir ;; 1538 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1539 | --libexe=* | --libex=* | --libe=*) 1540 libexecdir=$ac_optarg ;; 1541 1542 -localedir | --localedir | --localedi | --localed | --locale) 1543 ac_prev=localedir ;; 1544 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1545 localedir=$ac_optarg ;; 1546 1547 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1548 | --localstate | --localstat | --localsta | --localst | --locals) 1549 ac_prev=localstatedir ;; 1550 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1551 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1552 localstatedir=$ac_optarg ;; 1553 1554 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1555 ac_prev=mandir ;; 1556 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1557 mandir=$ac_optarg ;; 1558 1559 -nfp | --nfp | --nf) 1560 # Obsolete; use --without-fp. 1561 with_fp=no ;; 1562 1563 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1564 | --no-cr | --no-c | -n) 1565 no_create=yes ;; 1566 1567 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1568 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1569 no_recursion=yes ;; 1570 1571 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1572 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1573 | --oldin | --oldi | --old | --ol | --o) 1574 ac_prev=oldincludedir ;; 1575 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1576 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1577 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1578 oldincludedir=$ac_optarg ;; 1579 1580 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1581 ac_prev=prefix ;; 1582 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1583 prefix=$ac_optarg ;; 1584 1585 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1586 | --program-pre | --program-pr | --program-p) 1587 ac_prev=program_prefix ;; 1588 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1589 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1590 program_prefix=$ac_optarg ;; 1591 1592 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1593 | --program-suf | --program-su | --program-s) 1594 ac_prev=program_suffix ;; 1595 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1596 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1597 program_suffix=$ac_optarg ;; 1598 1599 -program-transform-name | --program-transform-name \ 1600 | --program-transform-nam | --program-transform-na \ 1601 | --program-transform-n | --program-transform- \ 1602 | --program-transform | --program-transfor \ 1603 | --program-transfo | --program-transf \ 1604 | --program-trans | --program-tran \ 1605 | --progr-tra | --program-tr | --program-t) 1606 ac_prev=program_transform_name ;; 1607 -program-transform-name=* | --program-transform-name=* \ 1608 | --program-transform-nam=* | --program-transform-na=* \ 1609 | --program-transform-n=* | --program-transform-=* \ 1610 | --program-transform=* | --program-transfor=* \ 1611 | --program-transfo=* | --program-transf=* \ 1612 | --program-trans=* | --program-tran=* \ 1613 | --progr-tra=* | --program-tr=* | --program-t=*) 1614 program_transform_name=$ac_optarg ;; 1615 1616 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1617 ac_prev=pdfdir ;; 1618 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1619 pdfdir=$ac_optarg ;; 1620 1621 -psdir | --psdir | --psdi | --psd | --ps) 1622 ac_prev=psdir ;; 1623 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1624 psdir=$ac_optarg ;; 1625 1626 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1627 | -silent | --silent | --silen | --sile | --sil) 1628 silent=yes ;; 1629 1630 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1631 ac_prev=sbindir ;; 1632 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1633 | --sbi=* | --sb=*) 1634 sbindir=$ac_optarg ;; 1635 1636 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1637 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1638 | --sharedst | --shareds | --shared | --share | --shar \ 1639 | --sha | --sh) 1640 ac_prev=sharedstatedir ;; 1641 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1642 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1643 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1644 | --sha=* | --sh=*) 1645 sharedstatedir=$ac_optarg ;; 1646 1647 -site | --site | --sit) 1648 ac_prev=site ;; 1649 -site=* | --site=* | --sit=*) 1650 site=$ac_optarg ;; 1651 1652 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1653 ac_prev=srcdir ;; 1654 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1655 srcdir=$ac_optarg ;; 1656 1657 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1658 | --syscon | --sysco | --sysc | --sys | --sy) 1659 ac_prev=sysconfdir ;; 1660 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1661 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1662 sysconfdir=$ac_optarg ;; 1663 1664 -target | --target | --targe | --targ | --tar | --ta | --t) 1665 ac_prev=target_alias ;; 1666 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1667 target_alias=$ac_optarg ;; 1668 1669 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1670 verbose=yes ;; 1671 1672 -version | --version | --versio | --versi | --vers | -V) 1673 ac_init_version=: ;; 1674 1675 -with-* | --with-*) 1676 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1677 # Reject names that are not valid shell variable names. 1678 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1679 as_fn_error $? "invalid package name: $ac_useropt" 1680 ac_useropt_orig=$ac_useropt 1681 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1682 case $ac_user_opts in 1683 *" 1684 "with_$ac_useropt" 1685 "*) ;; 1686 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1687 ac_unrecognized_sep=', ';; 1688 esac 1689 eval with_$ac_useropt=\$ac_optarg ;; 1690 1691 -without-* | --without-*) 1692 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1693 # Reject names that are not valid shell variable names. 1694 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1695 as_fn_error $? "invalid package name: $ac_useropt" 1696 ac_useropt_orig=$ac_useropt 1697 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1698 case $ac_user_opts in 1699 *" 1700 "with_$ac_useropt" 1701 "*) ;; 1702 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1703 ac_unrecognized_sep=', ';; 1704 esac 1705 eval with_$ac_useropt=no ;; 1706 1707 --x) 1708 # Obsolete; use --with-x. 1709 with_x=yes ;; 1710 1711 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1712 | --x-incl | --x-inc | --x-in | --x-i) 1713 ac_prev=x_includes ;; 1714 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1715 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1716 x_includes=$ac_optarg ;; 1717 1718 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1719 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1720 ac_prev=x_libraries ;; 1721 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1722 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1723 x_libraries=$ac_optarg ;; 1724 1725 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1726 Try \`$0 --help' for more information" 1727 ;; 1728 1729 *=*) 1730 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1731 # Reject names that are not valid shell variable names. 1732 case $ac_envvar in #( 1733 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1734 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1735 esac 1736 eval $ac_envvar=\$ac_optarg 1737 export $ac_envvar ;; 1738 1739 *) 1740 # FIXME: should be removed in autoconf 3.0. 1741 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1742 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1743 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1744 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1745 ;; 1746 1747 esac 1748 done 1749 1750 if test -n "$ac_prev"; then 1751 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1752 as_fn_error $? "missing argument to $ac_option" 1753 fi 1754 1755 if test -n "$ac_unrecognized_opts"; then 1756 case $enable_option_checking in 1757 no) ;; 1758 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1759 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1760 esac 1761 fi 1762 1763 # Check all directory arguments for consistency. 1764 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1765 datadir sysconfdir sharedstatedir localstatedir includedir \ 1766 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1767 libdir localedir mandir 1768 do 1769 eval ac_val=\$$ac_var 1770 # Remove trailing slashes. 1771 case $ac_val in 1772 */ ) 1773 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1774 eval $ac_var=\$ac_val;; 1775 esac 1776 # Be sure to have absolute directory names. 1777 case $ac_val in 1778 [\\/$]* | ?:[\\/]* ) continue;; 1779 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1780 esac 1781 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1782 done 1783 1784 # There might be people who depend on the old broken behavior: `$host' 1785 # used to hold the argument of --host etc. 1786 # FIXME: To remove some day. 1787 build=$build_alias 1788 host=$host_alias 1789 target=$target_alias 1790 1791 # FIXME: To remove some day. 1792 if test "x$host_alias" != x; then 1793 if test "x$build_alias" = x; then 1794 cross_compiling=maybe 1795 elif test "x$build_alias" != "x$host_alias"; then 1796 cross_compiling=yes 1797 fi 1798 fi 1799 1800 ac_tool_prefix= 1801 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1802 1803 test "$silent" = yes && exec 6>/dev/null 1804 1805 1806 ac_pwd=`pwd` && test -n "$ac_pwd" && 1807 ac_ls_di=`ls -di .` && 1808 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1809 as_fn_error $? "working directory cannot be determined" 1810 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1811 as_fn_error $? "pwd does not report name of working directory" 1812 1813 1814 # Find the source files, if location was not specified. 1815 if test -z "$srcdir"; then 1816 ac_srcdir_defaulted=yes 1817 # Try the directory containing this script, then the parent directory. 1818 ac_confdir=`$as_dirname -- "$as_myself" || 1819 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1820 X"$as_myself" : 'X\(//\)[^/]' \| \ 1821 X"$as_myself" : 'X\(//\)$' \| \ 1822 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1823 $as_echo X"$as_myself" | 1824 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1825 s//\1/ 1826 q 1827 } 1828 /^X\(\/\/\)[^/].*/{ 1829 s//\1/ 1830 q 1831 } 1832 /^X\(\/\/\)$/{ 1833 s//\1/ 1834 q 1835 } 1836 /^X\(\/\).*/{ 1837 s//\1/ 1838 q 1839 } 1840 s/.*/./; q'` 1841 srcdir=$ac_confdir 1842 if test ! -r "$srcdir/$ac_unique_file"; then 1843 srcdir=.. 1844 fi 1845 else 1846 ac_srcdir_defaulted=no 1847 fi 1848 if test ! -r "$srcdir/$ac_unique_file"; then 1849 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1850 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1851 fi 1852 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1853 ac_abs_confdir=`( 1854 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1855 pwd)` 1856 # When building in place, set srcdir=. 1857 if test "$ac_abs_confdir" = "$ac_pwd"; then 1858 srcdir=. 1859 fi 1860 # Remove unnecessary trailing slashes from srcdir. 1861 # Double slashes in file names in object file debugging info 1862 # mess up M-x gdb in Emacs. 1863 case $srcdir in 1864 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1865 esac 1866 for ac_var in $ac_precious_vars; do 1867 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1868 eval ac_env_${ac_var}_value=\$${ac_var} 1869 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1870 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1871 done 1872 1873 # 1874 # Report the --help message. 1875 # 1876 if test "$ac_init_help" = "long"; then 1877 # Omit some internal or obsolete options to make the list less imposing. 1878 # This message is too long to be a string in the A/UX 3.1 sh. 1879 cat <<_ACEOF 1880 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1881 1882 Usage: $0 [OPTION]... [VAR=VALUE]... 1883 1884 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1885 VAR=VALUE. See below for descriptions of some of the useful variables. 1886 1887 Defaults for the options are specified in brackets. 1888 1889 Configuration: 1890 -h, --help display this help and exit 1891 --help=short display options specific to this package 1892 --help=recursive display the short help of all the included packages 1893 -V, --version display version information and exit 1894 -q, --quiet, --silent do not print \`checking ...' messages 1895 --cache-file=FILE cache test results in FILE [disabled] 1896 -C, --config-cache alias for \`--cache-file=config.cache' 1897 -n, --no-create do not create output files 1898 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1899 1900 Installation directories: 1901 --prefix=PREFIX install architecture-independent files in PREFIX 1902 [$ac_default_prefix] 1903 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1904 [PREFIX] 1905 1906 By default, \`make install' will install all the files in 1907 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1908 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1909 for instance \`--prefix=\$HOME'. 1910 1911 For better control, use the options below. 1912 1913 Fine tuning of the installation directories: 1914 --bindir=DIR user executables [EPREFIX/bin] 1915 --sbindir=DIR system admin executables [EPREFIX/sbin] 1916 --libexecdir=DIR program executables [EPREFIX/libexec] 1917 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1918 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1919 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1920 --libdir=DIR object code libraries [EPREFIX/lib] 1921 --includedir=DIR C header files [PREFIX/include] 1922 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1923 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1924 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1925 --infodir=DIR info documentation [DATAROOTDIR/info] 1926 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1927 --mandir=DIR man documentation [DATAROOTDIR/man] 1928 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1929 --htmldir=DIR html documentation [DOCDIR] 1930 --dvidir=DIR dvi documentation [DOCDIR] 1931 --pdfdir=DIR pdf documentation [DOCDIR] 1932 --psdir=DIR ps documentation [DOCDIR] 1933 _ACEOF 1934 1935 cat <<\_ACEOF 1936 1937 X features: 1938 --x-includes=DIR X include files are in DIR 1939 --x-libraries=DIR X library files are in DIR 1940 1941 System types: 1942 --build=BUILD configure for building on BUILD [guessed] 1943 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1944 --target=TARGET configure for building compilers for TARGET [HOST] 1945 _ACEOF 1946 fi 1947 1948 if test -n "$ac_init_help"; then 1949 case $ac_init_help in 1950 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1951 esac 1952 cat <<\_ACEOF 1953 1954 Optional Features: 1955 --disable-option-checking ignore unrecognized --enable/--with options 1956 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1957 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1958 --enable-openjdk-only suppress building custom source even if present 1959 [disabled] 1960 --enable-debug set the debug level to fastdebug (shorthand for 1961 --with-debug-level=fastdebug) [disabled] 1962 --enable-headless-only only build headless (no GUI) support [disabled] 1963 --enable-full-docs build complete documentation [enabled if all tools 1964 found] 1965 --disable-unlimited-crypto 1966 Disable unlimited crypto policy [enabled] 1967 --disable-keep-packaged-modules 1968 Do not keep packaged modules in jdk image [enable] 1969 --enable-static-build enable static library build [disabled] 1970 --disable-warnings-as-errors 1971 do not consider native warnings to be an error 1972 [enabled] 1973 --enable-debug-symbols Deprecated. Option is kept for backwards 1974 compatibility and is ignored 1975 --enable-zip-debug-info Deprecated. Option is kept for backwards 1976 compatibility and is ignored 1977 --enable-native-coverage 1978 enable native compilation with code coverage 1979 data[disabled] 1980 --enable-dtrace[=yes/no/auto] 1981 enable dtrace. Default is auto, where dtrace is 1982 enabled if all dependencies are present. 1983 --enable-aot[=yes/no/auto] 1984 enable ahead of time compilation feature. Default is 1985 auto, where aot is enabled if all dependencies are 1986 present. 1987 --enable-cds[=yes/no] enable class data sharing feature in non-minimal VM. 1988 Default is yes. 1989 --disable-hotspot-gtest Disables building of the Hotspot unit tests 1990 --disable-freetype-bundling 1991 disable bundling of the freetype library with the 1992 build result [enabled on Windows or when using 1993 --with-freetype, disabled otherwise] 1994 --enable-libffi-bundling 1995 enable bundling of libffi.so to make the built JDK 1996 runnable on more systems 1997 --enable-jtreg-failure-handler 1998 forces build of the jtreg failure handler to be 1999 enabled, missing dependencies become fatal errors. 2000 Default is auto, where the failure handler is built 2001 if all dependencies are present and otherwise just 2002 disabled. 2003 --disable-generate-classlist 2004 forces enabling or disabling of the generation of a 2005 CDS classlist at build time. Default is to generate 2006 it when either the server or client JVMs are built 2007 and enable-cds is true. 2008 --enable-sjavac use sjavac to do fast incremental compiles 2009 [disabled] 2010 --disable-javac-server disable javac server [enabled] 2011 --enable-icecc enable distribted compilation of native code using 2012 icecc/icecream [disabled] 2013 --disable-precompiled-headers 2014 disable using precompiled headers when compiling C++ 2015 [enabled] 2016 --enable-ccache enable using ccache to speed up recompilations 2017 [disabled] 2018 2019 Optional Packages: 2020 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2021 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2022 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2023 support it), e.g. --with-target-bits=32 [guessed] 2024 --with-custom-make-dir Deprecated. Option is kept for backwards 2025 compatibility and is ignored 2026 --with-jdk-variant JDK variant to build (normal) [normal] 2027 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2028 optimized) [release] 2029 --with-jvm-variants JVM variants (separated by commas) to build 2030 (server,client,minimal,core,zero,zeroshark,custom) 2031 [server] 2032 --with-cpu-port specify sources to use for Hotspot 64-bit ARM port 2033 (arm64,aarch64) [aarch64] 2034 --with-devkit use this devkit for compilers, tools and resources 2035 --with-sys-root alias for --with-sysroot for backwards compatability 2036 --with-sysroot use this directory as sysroot 2037 --with-tools-dir alias for --with-toolchain-path for backwards 2038 compatibility 2039 --with-toolchain-path prepend these directories when searching for 2040 toolchain binaries (compilers etc) 2041 --with-extra-path prepend these directories to the default path 2042 --with-sdk-name use the platform SDK of the given name. [macosx] 2043 --with-conf-name use this as the name of the configuration [generated 2044 from important configuration options] 2045 --with-output-base-dir override the default output base directory [./build] 2046 --with-output-sync set make output sync type if supported by make. 2047 [recurse] 2048 --with-default-make-target 2049 set the default make target [exploded-image] 2050 --with-cacerts-file specify alternative cacerts file 2051 --with-copyright-year Set copyright year value for build [current year] 2052 --with-milestone Deprecated. Option is kept for backwards 2053 compatibility and is ignored 2054 --with-update-version Deprecated. Option is kept for backwards 2055 compatibility and is ignored 2056 --with-user-release-suffix 2057 Deprecated. Option is kept for backwards 2058 compatibility and is ignored 2059 --with-build-number Deprecated. Option is kept for backwards 2060 compatibility and is ignored 2061 --with-version-string Set version string [calculated] 2062 --with-version-pre Set the base part of the version 'PRE' field 2063 (pre-release identifier) ['internal'] 2064 --with-version-opt Set version 'OPT' field (build metadata) 2065 [<timestamp>.<user>.<dirname>] 2066 --with-version-build Set version 'BUILD' field (build number) [not 2067 specified] 2068 --with-version-major Set version 'MAJOR' field (first number) [current 2069 source value] 2070 --with-version-minor Set version 'MINOR' field (second number) [current 2071 source value] 2072 --with-version-security Set version 'SECURITY' field (third number) [current 2073 source value] 2074 --with-version-patch Set version 'PATCH' field (fourth number) [not 2075 specified] 2076 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2077 --with-build-jdk path to JDK of same version as is being built[the 2078 newly built JDK] 2079 --with-import-modules import a set of prebuilt modules either as a zip 2080 file or an exploded directory 2081 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2082 to show possible values [platform dependent] 2083 --with-extra-cflags extra flags to be used when compiling jdk c-files 2084 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2085 --with-extra-ldflags extra flags to be used when linking jdk 2086 --with-toolchain-version 2087 the version of the toolchain to look for, use 2088 '--help' to show possible values [platform 2089 dependent] 2090 --with-build-devkit Devkit to use for the build platform toolchain 2091 --with-jtreg Regression Test Harness [probed] 2092 --with-jib Jib dependency management tool [not used] 2093 --with-abi-profile specify ABI profile for ARM builds 2094 (arm-vfp-sflt,arm-vfp-hflt,arm-sflt, 2095 armv5-vfp-sflt,armv6-vfp-hflt,arm64,aarch64) 2096 [toolchain dependent] 2097 --with-macosx-version-max 2098 error on use of newer functionality. [macosx] 2099 --with-native-debug-symbols 2100 set the native debug symbol configuration (none, 2101 internal, external, zipped) [varying] 2102 --with-stdc++lib=<static>,<dynamic>,<default> 2103 force linking of the C++ runtime on Linux to either 2104 static or dynamic, default is static with dynamic as 2105 fallback 2106 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2107 (Windows only) [probed] 2108 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2109 (Windows only) [probed] 2110 --with-x use the X Window System 2111 --with-cups specify prefix directory for the cups package 2112 (expecting the headers under PATH/include) 2113 --with-cups-include specify directory for the cups include files 2114 --with-freetype specify prefix directory for the freetype package 2115 (expecting the libraries under PATH/lib and the 2116 headers under PATH/include) 2117 --with-freetype-include specify directory for the freetype include files 2118 --with-freetype-lib specify directory for the freetype library 2119 --with-freetype-src specify directory with freetype sources to 2120 automatically build the library (experimental, 2121 Windows-only) 2122 --with-freetype-license if bundling freetype, also bundle this license file 2123 --with-alsa specify prefix directory for the alsa package 2124 (expecting the libraries under PATH/lib and the 2125 headers under PATH/include) 2126 --with-alsa-include specify directory for the alsa include files 2127 --with-alsa-lib specify directory for the alsa library 2128 --with-libffi specify prefix directory for the libffi package 2129 (expecting the libraries under PATH/lib and the 2130 headers under PATH/include) 2131 --with-libffi-include specify directory for the libffi include files 2132 --with-libffi-lib specify directory for the libffi library 2133 --with-libjpeg use libjpeg from build system or OpenJDK source 2134 (system, bundled) [bundled] 2135 --with-giflib use giflib from build system or OpenJDK source 2136 (system, bundled) [bundled] 2137 --with-libpng use libpng from build system or OpenJDK source 2138 (system, bundled) [bundled] 2139 --with-zlib use zlib from build system or OpenJDK source 2140 (system, bundled) [bundled] 2141 --with-lcms use lcms2 from build system or OpenJDK source 2142 (system, bundled) [bundled] 2143 --with-dxsdk Deprecated. Option is kept for backwards 2144 compatibility and is ignored 2145 --with-dxsdk-lib Deprecated. Option is kept for backwards 2146 compatibility and is ignored 2147 --with-dxsdk-include Deprecated. Option is kept for backwards 2148 compatibility and is ignored 2149 --with-jvm-features additional JVM features to enable (separated by 2150 comma), use '--help' to show possible values [none] 2151 --with-jvm-interpreter Deprecated. Option is kept for backwards 2152 compatibility and is ignored 2153 --with-num-cores number of cores in the build system, e.g. 2154 --with-num-cores=8 [probed] 2155 --with-memory-size memory (in MB) available in the build system, e.g. 2156 --with-memory-size=1024 [probed] 2157 --with-jobs number of parallel jobs to let make run [calculated 2158 based on cores and memory] 2159 --with-test-jobs number of parallel tests jobs to run [based on build 2160 jobs] 2161 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2162 invocations of boot JDK, overriding the default 2163 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2164 -enableassertions" 2165 --with-sjavac-server-java 2166 use this java binary for running the sjavac 2167 background server [Boot JDK java] 2168 --with-ccache-dir where to store ccache files [~/.ccache] 2169 2170 Some influential environment variables: 2171 BASENAME Override default value for BASENAME 2172 BASH Override default value for BASH 2173 CAT Override default value for CAT 2174 CHMOD Override default value for CHMOD 2175 CMP Override default value for CMP 2176 COMM Override default value for COMM 2177 CP Override default value for CP 2178 CUT Override default value for CUT 2179 DATE Override default value for DATE 2180 DIFF Override default value for DIFF 2181 DIRNAME Override default value for DIRNAME 2182 ECHO Override default value for ECHO 2183 EXPR Override default value for EXPR 2184 FILE Override default value for FILE 2185 FIND Override default value for FIND 2186 HEAD Override default value for HEAD 2187 GUNZIP Override default value for GUNZIP 2188 GZIP Override default value for GZIP 2189 LN Override default value for LN 2190 LS Override default value for LS 2191 MKDIR Override default value for MKDIR 2192 MKTEMP Override default value for MKTEMP 2193 MV Override default value for MV 2194 NAWK Override default value for NAWK 2195 PRINTF Override default value for PRINTF 2196 RM Override default value for RM 2197 RMDIR Override default value for RMDIR 2198 SH Override default value for SH 2199 SORT Override default value for SORT 2200 TAIL Override default value for TAIL 2201 TAR Override default value for TAR 2202 TEE Override default value for TEE 2203 TOUCH Override default value for TOUCH 2204 TR Override default value for TR 2205 UNAME Override default value for UNAME 2206 UNIQ Override default value for UNIQ 2207 WC Override default value for WC 2208 WHICH Override default value for WHICH 2209 XARGS Override default value for XARGS 2210 AWK Override default value for AWK 2211 GREP Override default value for GREP 2212 EGREP Override default value for EGREP 2213 FGREP Override default value for FGREP 2214 SED Override default value for SED 2215 CYGPATH Override default value for CYGPATH 2216 READLINK Override default value for READLINK 2217 DF Override default value for DF 2218 CPIO Override default value for CPIO 2219 NICE Override default value for NICE 2220 PANDOC Override default value for PANDOC 2221 MAKE Override default value for MAKE 2222 UNZIP Override default value for UNZIP 2223 ZIPEXE Override default value for ZIPEXE 2224 LDD Override default value for LDD 2225 OTOOL Override default value for OTOOL 2226 READELF Override default value for READELF 2227 DOT Override default value for DOT 2228 HG Override default value for HG 2229 STAT Override default value for STAT 2230 TIME Override default value for TIME 2231 FLOCK Override default value for FLOCK 2232 DTRACE Override default value for DTRACE 2233 PATCH Override default value for PATCH 2234 DSYMUTIL Override default value for DSYMUTIL 2235 XATTR Override default value for XATTR 2236 CODESIGN Override default value for CODESIGN 2237 SETFILE Override default value for SETFILE 2238 PKG_CONFIG path to pkg-config utility 2239 JAVA Override default value for JAVA 2240 JAVAC Override default value for JAVAC 2241 JAVAH Override default value for JAVAH 2242 JAR Override default value for JAR 2243 JARSIGNER Override default value for JARSIGNER 2244 CC C compiler command 2245 CFLAGS C compiler flags 2246 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2247 nonstandard directory <lib dir> 2248 LIBS libraries to pass to the linker, e.g. -l<library> 2249 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2250 you have headers in a nonstandard directory <include dir> 2251 CXX C++ compiler command 2252 CXXFLAGS C++ compiler flags 2253 CPP C preprocessor 2254 CXXCPP C++ preprocessor 2255 AS Override default value for AS 2256 AR Override default value for AR 2257 LIPO Override default value for LIPO 2258 STRIP Override default value for STRIP 2259 NM Override default value for NM 2260 GNM Override default value for GNM 2261 OBJCOPY Override default value for OBJCOPY 2262 OBJDUMP Override default value for OBJDUMP 2263 BUILD_CC Override default value for BUILD_CC 2264 BUILD_CXX Override default value for BUILD_CXX 2265 BUILD_NM Override default value for BUILD_NM 2266 BUILD_AR Override default value for BUILD_AR 2267 BUILD_OBJCOPY 2268 Override default value for BUILD_OBJCOPY 2269 BUILD_STRIP Override default value for BUILD_STRIP 2270 JTREGEXE Override default value for JTREGEXE 2271 XMKMF Path to xmkmf, Makefile generator for X Window System 2272 FREETYPE_CFLAGS 2273 C compiler flags for FREETYPE, overriding pkg-config 2274 FREETYPE_LIBS 2275 linker flags for FREETYPE, overriding pkg-config 2276 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2277 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2278 LIBFFI_CFLAGS 2279 C compiler flags for LIBFFI, overriding pkg-config 2280 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2281 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2282 PNG_LIBS linker flags for PNG, overriding pkg-config 2283 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2284 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2285 ICECC_CMD Override default value for ICECC_CMD 2286 ICECC_CREATE_ENV 2287 Override default value for ICECC_CREATE_ENV 2288 ICECC_WRAPPER 2289 Override default value for ICECC_WRAPPER 2290 CCACHE Override default value for CCACHE 2291 2292 Use these variables to override the choices made by `configure' or to help 2293 it to find libraries and programs with nonstandard names/locations. 2294 2295 Report bugs to <build-dev@openjdk.java.net>. 2296 OpenJDK home page: <http://openjdk.java.net>. 2297 _ACEOF 2298 ac_status=$? 2299 fi 2300 2301 if test "$ac_init_help" = "recursive"; then 2302 # If there are subdirs, report their specific --help. 2303 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2304 test -d "$ac_dir" || 2305 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2306 continue 2307 ac_builddir=. 2308 2309 case "$ac_dir" in 2310 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2311 *) 2312 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2313 # A ".." for each directory in $ac_dir_suffix. 2314 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2315 case $ac_top_builddir_sub in 2316 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2317 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2318 esac ;; 2319 esac 2320 ac_abs_top_builddir=$ac_pwd 2321 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2322 # for backward compatibility: 2323 ac_top_builddir=$ac_top_build_prefix 2324 2325 case $srcdir in 2326 .) # We are building in place. 2327 ac_srcdir=. 2328 ac_top_srcdir=$ac_top_builddir_sub 2329 ac_abs_top_srcdir=$ac_pwd ;; 2330 [\\/]* | ?:[\\/]* ) # Absolute name. 2331 ac_srcdir=$srcdir$ac_dir_suffix; 2332 ac_top_srcdir=$srcdir 2333 ac_abs_top_srcdir=$srcdir ;; 2334 *) # Relative name. 2335 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2336 ac_top_srcdir=$ac_top_build_prefix$srcdir 2337 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2338 esac 2339 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2340 2341 cd "$ac_dir" || { ac_status=$?; continue; } 2342 # Check for guested configure. 2343 if test -f "$ac_srcdir/configure.gnu"; then 2344 echo && 2345 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2346 elif test -f "$ac_srcdir/configure"; then 2347 echo && 2348 $SHELL "$ac_srcdir/configure" --help=recursive 2349 else 2350 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2351 fi || ac_status=$? 2352 cd "$ac_pwd" || { ac_status=$?; break; } 2353 done 2354 fi 2355 2356 test -n "$ac_init_help" && exit $ac_status 2357 if $ac_init_version; then 2358 cat <<\_ACEOF 2359 OpenJDK configure jdk9 2360 generated by GNU Autoconf 2.69 2361 2362 Copyright (C) 2012 Free Software Foundation, Inc. 2363 This configure script is free software; the Free Software Foundation 2364 gives unlimited permission to copy, distribute and modify it. 2365 _ACEOF 2366 exit 2367 fi 2368 2369 ## ------------------------ ## 2370 ## Autoconf initialization. ## 2371 ## ------------------------ ## 2372 2373 # ac_fn_c_try_compile LINENO 2374 # -------------------------- 2375 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2376 ac_fn_c_try_compile () 2377 { 2378 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2379 rm -f conftest.$ac_objext 2380 if { { ac_try="$ac_compile" 2381 case "(($ac_try" in 2382 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2383 *) ac_try_echo=$ac_try;; 2384 esac 2385 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2386 $as_echo "$ac_try_echo"; } >&5 2387 (eval "$ac_compile") 2>conftest.err 2388 ac_status=$? 2389 if test -s conftest.err; then 2390 grep -v '^ *+' conftest.err >conftest.er1 2391 cat conftest.er1 >&5 2392 mv -f conftest.er1 conftest.err 2393 fi 2394 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2395 test $ac_status = 0; } && { 2396 test -z "$ac_c_werror_flag" || 2397 test ! -s conftest.err 2398 } && test -s conftest.$ac_objext; then : 2399 ac_retval=0 2400 else 2401 $as_echo "$as_me: failed program was:" >&5 2402 sed 's/^/| /' conftest.$ac_ext >&5 2403 2404 ac_retval=1 2405 fi 2406 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2407 as_fn_set_status $ac_retval 2408 2409 } # ac_fn_c_try_compile 2410 2411 # ac_fn_cxx_try_compile LINENO 2412 # ---------------------------- 2413 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2414 ac_fn_cxx_try_compile () 2415 { 2416 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2417 rm -f conftest.$ac_objext 2418 if { { ac_try="$ac_compile" 2419 case "(($ac_try" in 2420 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2421 *) ac_try_echo=$ac_try;; 2422 esac 2423 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2424 $as_echo "$ac_try_echo"; } >&5 2425 (eval "$ac_compile") 2>conftest.err 2426 ac_status=$? 2427 if test -s conftest.err; then 2428 grep -v '^ *+' conftest.err >conftest.er1 2429 cat conftest.er1 >&5 2430 mv -f conftest.er1 conftest.err 2431 fi 2432 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2433 test $ac_status = 0; } && { 2434 test -z "$ac_cxx_werror_flag" || 2435 test ! -s conftest.err 2436 } && test -s conftest.$ac_objext; then : 2437 ac_retval=0 2438 else 2439 $as_echo "$as_me: failed program was:" >&5 2440 sed 's/^/| /' conftest.$ac_ext >&5 2441 2442 ac_retval=1 2443 fi 2444 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2445 as_fn_set_status $ac_retval 2446 2447 } # ac_fn_cxx_try_compile 2448 2449 # ac_fn_c_try_cpp LINENO 2450 # ---------------------- 2451 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2452 ac_fn_c_try_cpp () 2453 { 2454 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2455 if { { ac_try="$ac_cpp conftest.$ac_ext" 2456 case "(($ac_try" in 2457 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2458 *) ac_try_echo=$ac_try;; 2459 esac 2460 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2461 $as_echo "$ac_try_echo"; } >&5 2462 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2463 ac_status=$? 2464 if test -s conftest.err; then 2465 grep -v '^ *+' conftest.err >conftest.er1 2466 cat conftest.er1 >&5 2467 mv -f conftest.er1 conftest.err 2468 fi 2469 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2470 test $ac_status = 0; } > conftest.i && { 2471 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2472 test ! -s conftest.err 2473 }; then : 2474 ac_retval=0 2475 else 2476 $as_echo "$as_me: failed program was:" >&5 2477 sed 's/^/| /' conftest.$ac_ext >&5 2478 2479 ac_retval=1 2480 fi 2481 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2482 as_fn_set_status $ac_retval 2483 2484 } # ac_fn_c_try_cpp 2485 2486 # ac_fn_cxx_try_cpp LINENO 2487 # ------------------------ 2488 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2489 ac_fn_cxx_try_cpp () 2490 { 2491 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2492 if { { ac_try="$ac_cpp conftest.$ac_ext" 2493 case "(($ac_try" in 2494 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2495 *) ac_try_echo=$ac_try;; 2496 esac 2497 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2498 $as_echo "$ac_try_echo"; } >&5 2499 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2500 ac_status=$? 2501 if test -s conftest.err; then 2502 grep -v '^ *+' conftest.err >conftest.er1 2503 cat conftest.er1 >&5 2504 mv -f conftest.er1 conftest.err 2505 fi 2506 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2507 test $ac_status = 0; } > conftest.i && { 2508 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2509 test ! -s conftest.err 2510 }; then : 2511 ac_retval=0 2512 else 2513 $as_echo "$as_me: failed program was:" >&5 2514 sed 's/^/| /' conftest.$ac_ext >&5 2515 2516 ac_retval=1 2517 fi 2518 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2519 as_fn_set_status $ac_retval 2520 2521 } # ac_fn_cxx_try_cpp 2522 2523 # ac_fn_c_try_link LINENO 2524 # ----------------------- 2525 # Try to link conftest.$ac_ext, and return whether this succeeded. 2526 ac_fn_c_try_link () 2527 { 2528 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2529 rm -f conftest.$ac_objext conftest$ac_exeext 2530 if { { ac_try="$ac_link" 2531 case "(($ac_try" in 2532 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2533 *) ac_try_echo=$ac_try;; 2534 esac 2535 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2536 $as_echo "$ac_try_echo"; } >&5 2537 (eval "$ac_link") 2>conftest.err 2538 ac_status=$? 2539 if test -s conftest.err; then 2540 grep -v '^ *+' conftest.err >conftest.er1 2541 cat conftest.er1 >&5 2542 mv -f conftest.er1 conftest.err 2543 fi 2544 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2545 test $ac_status = 0; } && { 2546 test -z "$ac_c_werror_flag" || 2547 test ! -s conftest.err 2548 } && test -s conftest$ac_exeext && { 2549 test "$cross_compiling" = yes || 2550 test -x conftest$ac_exeext 2551 }; then : 2552 ac_retval=0 2553 else 2554 $as_echo "$as_me: failed program was:" >&5 2555 sed 's/^/| /' conftest.$ac_ext >&5 2556 2557 ac_retval=1 2558 fi 2559 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2560 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2561 # interfere with the next link command; also delete a directory that is 2562 # left behind by Apple's compiler. We do this before executing the actions. 2563 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2564 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2565 as_fn_set_status $ac_retval 2566 2567 } # ac_fn_c_try_link 2568 2569 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2570 # --------------------------------------------------------- 2571 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2572 # the include files in INCLUDES and setting the cache variable VAR 2573 # accordingly. 2574 ac_fn_cxx_check_header_mongrel () 2575 { 2576 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2577 if eval \${$3+:} false; then : 2578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2579 $as_echo_n "checking for $2... " >&6; } 2580 if eval \${$3+:} false; then : 2581 $as_echo_n "(cached) " >&6 2582 fi 2583 eval ac_res=\$$3 2584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2585 $as_echo "$ac_res" >&6; } 2586 else 2587 # Is the header compilable? 2588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2589 $as_echo_n "checking $2 usability... " >&6; } 2590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2591 /* end confdefs.h. */ 2592 $4 2593 #include <$2> 2594 _ACEOF 2595 if ac_fn_cxx_try_compile "$LINENO"; then : 2596 ac_header_compiler=yes 2597 else 2598 ac_header_compiler=no 2599 fi 2600 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2602 $as_echo "$ac_header_compiler" >&6; } 2603 2604 # Is the header present? 2605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2606 $as_echo_n "checking $2 presence... " >&6; } 2607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2608 /* end confdefs.h. */ 2609 #include <$2> 2610 _ACEOF 2611 if ac_fn_cxx_try_cpp "$LINENO"; then : 2612 ac_header_preproc=yes 2613 else 2614 ac_header_preproc=no 2615 fi 2616 rm -f conftest.err conftest.i conftest.$ac_ext 2617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2618 $as_echo "$ac_header_preproc" >&6; } 2619 2620 # So? What about this header? 2621 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2622 yes:no: ) 2623 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2624 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2625 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2626 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2627 ;; 2628 no:yes:* ) 2629 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2630 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2631 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2632 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2633 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2634 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2636 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2637 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2638 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2639 ( $as_echo "## ----------------------------------------- ## 2640 ## Report this to build-dev@openjdk.java.net ## 2641 ## ----------------------------------------- ##" 2642 ) | sed "s/^/$as_me: WARNING: /" >&2 2643 ;; 2644 esac 2645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2646 $as_echo_n "checking for $2... " >&6; } 2647 if eval \${$3+:} false; then : 2648 $as_echo_n "(cached) " >&6 2649 else 2650 eval "$3=\$ac_header_compiler" 2651 fi 2652 eval ac_res=\$$3 2653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2654 $as_echo "$ac_res" >&6; } 2655 fi 2656 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2657 2658 } # ac_fn_cxx_check_header_mongrel 2659 2660 # ac_fn_cxx_try_run LINENO 2661 # ------------------------ 2662 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2663 # that executables *can* be run. 2664 ac_fn_cxx_try_run () 2665 { 2666 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2667 if { { ac_try="$ac_link" 2668 case "(($ac_try" in 2669 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2670 *) ac_try_echo=$ac_try;; 2671 esac 2672 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2673 $as_echo "$ac_try_echo"; } >&5 2674 (eval "$ac_link") 2>&5 2675 ac_status=$? 2676 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2677 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2678 { { case "(($ac_try" in 2679 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2680 *) ac_try_echo=$ac_try;; 2681 esac 2682 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2683 $as_echo "$ac_try_echo"; } >&5 2684 (eval "$ac_try") 2>&5 2685 ac_status=$? 2686 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2687 test $ac_status = 0; }; }; then : 2688 ac_retval=0 2689 else 2690 $as_echo "$as_me: program exited with status $ac_status" >&5 2691 $as_echo "$as_me: failed program was:" >&5 2692 sed 's/^/| /' conftest.$ac_ext >&5 2693 2694 ac_retval=$ac_status 2695 fi 2696 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2697 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2698 as_fn_set_status $ac_retval 2699 2700 } # ac_fn_cxx_try_run 2701 2702 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2703 # --------------------------------------------------------- 2704 # Tests whether HEADER exists and can be compiled using the include files in 2705 # INCLUDES, setting the cache variable VAR accordingly. 2706 ac_fn_cxx_check_header_compile () 2707 { 2708 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2710 $as_echo_n "checking for $2... " >&6; } 2711 if eval \${$3+:} false; then : 2712 $as_echo_n "(cached) " >&6 2713 else 2714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2715 /* end confdefs.h. */ 2716 $4 2717 #include <$2> 2718 _ACEOF 2719 if ac_fn_cxx_try_compile "$LINENO"; then : 2720 eval "$3=yes" 2721 else 2722 eval "$3=no" 2723 fi 2724 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2725 fi 2726 eval ac_res=\$$3 2727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2728 $as_echo "$ac_res" >&6; } 2729 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2730 2731 } # ac_fn_cxx_check_header_compile 2732 2733 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2734 # ---------------------------------------------- 2735 # Tries to find the compile-time value of EXPR in a program that includes 2736 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2737 # computed 2738 ac_fn_cxx_compute_int () 2739 { 2740 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2741 if test "$cross_compiling" = yes; then 2742 # Depending upon the size, compute the lo and hi bounds. 2743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2744 /* end confdefs.h. */ 2745 $4 2746 int 2747 main () 2748 { 2749 static int test_array [1 - 2 * !(($2) >= 0)]; 2750 test_array [0] = 0; 2751 return test_array [0]; 2752 2753 ; 2754 return 0; 2755 } 2756 _ACEOF 2757 if ac_fn_cxx_try_compile "$LINENO"; then : 2758 ac_lo=0 ac_mid=0 2759 while :; do 2760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2761 /* end confdefs.h. */ 2762 $4 2763 int 2764 main () 2765 { 2766 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2767 test_array [0] = 0; 2768 return test_array [0]; 2769 2770 ; 2771 return 0; 2772 } 2773 _ACEOF 2774 if ac_fn_cxx_try_compile "$LINENO"; then : 2775 ac_hi=$ac_mid; break 2776 else 2777 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2778 if test $ac_lo -le $ac_mid; then 2779 ac_lo= ac_hi= 2780 break 2781 fi 2782 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2783 fi 2784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2785 done 2786 else 2787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2788 /* end confdefs.h. */ 2789 $4 2790 int 2791 main () 2792 { 2793 static int test_array [1 - 2 * !(($2) < 0)]; 2794 test_array [0] = 0; 2795 return test_array [0]; 2796 2797 ; 2798 return 0; 2799 } 2800 _ACEOF 2801 if ac_fn_cxx_try_compile "$LINENO"; then : 2802 ac_hi=-1 ac_mid=-1 2803 while :; do 2804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2805 /* end confdefs.h. */ 2806 $4 2807 int 2808 main () 2809 { 2810 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2811 test_array [0] = 0; 2812 return test_array [0]; 2813 2814 ; 2815 return 0; 2816 } 2817 _ACEOF 2818 if ac_fn_cxx_try_compile "$LINENO"; then : 2819 ac_lo=$ac_mid; break 2820 else 2821 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2822 if test $ac_mid -le $ac_hi; then 2823 ac_lo= ac_hi= 2824 break 2825 fi 2826 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2827 fi 2828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2829 done 2830 else 2831 ac_lo= ac_hi= 2832 fi 2833 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2834 fi 2835 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2836 # Binary search between lo and hi bounds. 2837 while test "x$ac_lo" != "x$ac_hi"; do 2838 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2840 /* end confdefs.h. */ 2841 $4 2842 int 2843 main () 2844 { 2845 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2846 test_array [0] = 0; 2847 return test_array [0]; 2848 2849 ; 2850 return 0; 2851 } 2852 _ACEOF 2853 if ac_fn_cxx_try_compile "$LINENO"; then : 2854 ac_hi=$ac_mid 2855 else 2856 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2857 fi 2858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2859 done 2860 case $ac_lo in #(( 2861 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2862 '') ac_retval=1 ;; 2863 esac 2864 else 2865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2866 /* end confdefs.h. */ 2867 $4 2868 static long int longval () { return $2; } 2869 static unsigned long int ulongval () { return $2; } 2870 #include <stdio.h> 2871 #include <stdlib.h> 2872 int 2873 main () 2874 { 2875 2876 FILE *f = fopen ("conftest.val", "w"); 2877 if (! f) 2878 return 1; 2879 if (($2) < 0) 2880 { 2881 long int i = longval (); 2882 if (i != ($2)) 2883 return 1; 2884 fprintf (f, "%ld", i); 2885 } 2886 else 2887 { 2888 unsigned long int i = ulongval (); 2889 if (i != ($2)) 2890 return 1; 2891 fprintf (f, "%lu", i); 2892 } 2893 /* Do not output a trailing newline, as this causes \r\n confusion 2894 on some platforms. */ 2895 return ferror (f) || fclose (f) != 0; 2896 2897 ; 2898 return 0; 2899 } 2900 _ACEOF 2901 if ac_fn_cxx_try_run "$LINENO"; then : 2902 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2903 else 2904 ac_retval=1 2905 fi 2906 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2907 conftest.$ac_objext conftest.beam conftest.$ac_ext 2908 rm -f conftest.val 2909 2910 fi 2911 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2912 as_fn_set_status $ac_retval 2913 2914 } # ac_fn_cxx_compute_int 2915 2916 # ac_fn_cxx_try_link LINENO 2917 # ------------------------- 2918 # Try to link conftest.$ac_ext, and return whether this succeeded. 2919 ac_fn_cxx_try_link () 2920 { 2921 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2922 rm -f conftest.$ac_objext conftest$ac_exeext 2923 if { { ac_try="$ac_link" 2924 case "(($ac_try" in 2925 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2926 *) ac_try_echo=$ac_try;; 2927 esac 2928 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2929 $as_echo "$ac_try_echo"; } >&5 2930 (eval "$ac_link") 2>conftest.err 2931 ac_status=$? 2932 if test -s conftest.err; then 2933 grep -v '^ *+' conftest.err >conftest.er1 2934 cat conftest.er1 >&5 2935 mv -f conftest.er1 conftest.err 2936 fi 2937 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2938 test $ac_status = 0; } && { 2939 test -z "$ac_cxx_werror_flag" || 2940 test ! -s conftest.err 2941 } && test -s conftest$ac_exeext && { 2942 test "$cross_compiling" = yes || 2943 test -x conftest$ac_exeext 2944 }; then : 2945 ac_retval=0 2946 else 2947 $as_echo "$as_me: failed program was:" >&5 2948 sed 's/^/| /' conftest.$ac_ext >&5 2949 2950 ac_retval=1 2951 fi 2952 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2953 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2954 # interfere with the next link command; also delete a directory that is 2955 # left behind by Apple's compiler. We do this before executing the actions. 2956 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2957 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2958 as_fn_set_status $ac_retval 2959 2960 } # ac_fn_cxx_try_link 2961 2962 # ac_fn_cxx_check_func LINENO FUNC VAR 2963 # ------------------------------------ 2964 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2965 ac_fn_cxx_check_func () 2966 { 2967 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2969 $as_echo_n "checking for $2... " >&6; } 2970 if eval \${$3+:} false; then : 2971 $as_echo_n "(cached) " >&6 2972 else 2973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2974 /* end confdefs.h. */ 2975 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2976 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2977 #define $2 innocuous_$2 2978 2979 /* System header to define __stub macros and hopefully few prototypes, 2980 which can conflict with char $2 (); below. 2981 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2982 <limits.h> exists even on freestanding compilers. */ 2983 2984 #ifdef __STDC__ 2985 # include <limits.h> 2986 #else 2987 # include <assert.h> 2988 #endif 2989 2990 #undef $2 2991 2992 /* Override any GCC internal prototype to avoid an error. 2993 Use char because int might match the return type of a GCC 2994 builtin and then its argument prototype would still apply. */ 2995 #ifdef __cplusplus 2996 extern "C" 2997 #endif 2998 char $2 (); 2999 /* The GNU C library defines this for functions which it implements 3000 to always fail with ENOSYS. Some functions are actually named 3001 something starting with __ and the normal name is an alias. */ 3002 #if defined __stub_$2 || defined __stub___$2 3003 choke me 3004 #endif 3005 3006 int 3007 main () 3008 { 3009 return $2 (); 3010 ; 3011 return 0; 3012 } 3013 _ACEOF 3014 if ac_fn_cxx_try_link "$LINENO"; then : 3015 eval "$3=yes" 3016 else 3017 eval "$3=no" 3018 fi 3019 rm -f core conftest.err conftest.$ac_objext \ 3020 conftest$ac_exeext conftest.$ac_ext 3021 fi 3022 eval ac_res=\$$3 3023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3024 $as_echo "$ac_res" >&6; } 3025 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3026 3027 } # ac_fn_cxx_check_func 3028 3029 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3030 # ------------------------------------------------------- 3031 # Tests whether HEADER exists and can be compiled using the include files in 3032 # INCLUDES, setting the cache variable VAR accordingly. 3033 ac_fn_c_check_header_compile () 3034 { 3035 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3037 $as_echo_n "checking for $2... " >&6; } 3038 if eval \${$3+:} false; then : 3039 $as_echo_n "(cached) " >&6 3040 else 3041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3042 /* end confdefs.h. */ 3043 $4 3044 #include <$2> 3045 _ACEOF 3046 if ac_fn_c_try_compile "$LINENO"; then : 3047 eval "$3=yes" 3048 else 3049 eval "$3=no" 3050 fi 3051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3052 fi 3053 eval ac_res=\$$3 3054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3055 $as_echo "$ac_res" >&6; } 3056 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3057 3058 } # ac_fn_c_check_header_compile 3059 cat >config.log <<_ACEOF 3060 This file contains any messages produced by compilers while 3061 running configure, to aid debugging if configure makes a mistake. 3062 3063 It was created by OpenJDK $as_me jdk9, which was 3064 generated by GNU Autoconf 2.69. Invocation command line was 3065 3066 $ $0 $@ 3067 3068 _ACEOF 3069 exec 5>>config.log 3070 { 3071 cat <<_ASUNAME 3072 ## --------- ## 3073 ## Platform. ## 3074 ## --------- ## 3075 3076 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3077 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3078 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3079 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3080 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3081 3082 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3083 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3084 3085 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3086 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3087 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3088 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3089 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3090 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3091 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3092 3093 _ASUNAME 3094 3095 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3096 for as_dir in $PATH 3097 do 3098 IFS=$as_save_IFS 3099 test -z "$as_dir" && as_dir=. 3100 $as_echo "PATH: $as_dir" 3101 done 3102 IFS=$as_save_IFS 3103 3104 } >&5 3105 3106 cat >&5 <<_ACEOF 3107 3108 3109 ## ----------- ## 3110 ## Core tests. ## 3111 ## ----------- ## 3112 3113 _ACEOF 3114 3115 3116 # Keep a trace of the command line. 3117 # Strip out --no-create and --no-recursion so they do not pile up. 3118 # Strip out --silent because we don't want to record it for future runs. 3119 # Also quote any args containing shell meta-characters. 3120 # Make two passes to allow for proper duplicate-argument suppression. 3121 ac_configure_args= 3122 ac_configure_args0= 3123 ac_configure_args1= 3124 ac_must_keep_next=false 3125 for ac_pass in 1 2 3126 do 3127 for ac_arg 3128 do 3129 case $ac_arg in 3130 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3131 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3132 | -silent | --silent | --silen | --sile | --sil) 3133 continue ;; 3134 *\'*) 3135 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3136 esac 3137 case $ac_pass in 3138 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3139 2) 3140 as_fn_append ac_configure_args1 " '$ac_arg'" 3141 if test $ac_must_keep_next = true; then 3142 ac_must_keep_next=false # Got value, back to normal. 3143 else 3144 case $ac_arg in 3145 *=* | --config-cache | -C | -disable-* | --disable-* \ 3146 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3147 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3148 | -with-* | --with-* | -without-* | --without-* | --x) 3149 case "$ac_configure_args0 " in 3150 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3151 esac 3152 ;; 3153 -* ) ac_must_keep_next=true ;; 3154 esac 3155 fi 3156 as_fn_append ac_configure_args " '$ac_arg'" 3157 ;; 3158 esac 3159 done 3160 done 3161 { ac_configure_args0=; unset ac_configure_args0;} 3162 { ac_configure_args1=; unset ac_configure_args1;} 3163 3164 # When interrupted or exit'd, cleanup temporary files, and complete 3165 # config.log. We remove comments because anyway the quotes in there 3166 # would cause problems or look ugly. 3167 # WARNING: Use '\'' to represent an apostrophe within the trap. 3168 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3169 trap 'exit_status=$? 3170 # Save into config.log some information that might help in debugging. 3171 { 3172 echo 3173 3174 $as_echo "## ---------------- ## 3175 ## Cache variables. ## 3176 ## ---------------- ##" 3177 echo 3178 # The following way of writing the cache mishandles newlines in values, 3179 ( 3180 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3181 eval ac_val=\$$ac_var 3182 case $ac_val in #( 3183 *${as_nl}*) 3184 case $ac_var in #( 3185 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3186 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3187 esac 3188 case $ac_var in #( 3189 _ | IFS | as_nl) ;; #( 3190 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3191 *) { eval $ac_var=; unset $ac_var;} ;; 3192 esac ;; 3193 esac 3194 done 3195 (set) 2>&1 | 3196 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3197 *${as_nl}ac_space=\ *) 3198 sed -n \ 3199 "s/'\''/'\''\\\\'\'''\''/g; 3200 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3201 ;; #( 3202 *) 3203 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3204 ;; 3205 esac | 3206 sort 3207 ) 3208 echo 3209 3210 $as_echo "## ----------------- ## 3211 ## Output variables. ## 3212 ## ----------------- ##" 3213 echo 3214 for ac_var in $ac_subst_vars 3215 do 3216 eval ac_val=\$$ac_var 3217 case $ac_val in 3218 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3219 esac 3220 $as_echo "$ac_var='\''$ac_val'\''" 3221 done | sort 3222 echo 3223 3224 if test -n "$ac_subst_files"; then 3225 $as_echo "## ------------------- ## 3226 ## File substitutions. ## 3227 ## ------------------- ##" 3228 echo 3229 for ac_var in $ac_subst_files 3230 do 3231 eval ac_val=\$$ac_var 3232 case $ac_val in 3233 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3234 esac 3235 $as_echo "$ac_var='\''$ac_val'\''" 3236 done | sort 3237 echo 3238 fi 3239 3240 if test -s confdefs.h; then 3241 $as_echo "## ----------- ## 3242 ## confdefs.h. ## 3243 ## ----------- ##" 3244 echo 3245 cat confdefs.h 3246 echo 3247 fi 3248 test "$ac_signal" != 0 && 3249 $as_echo "$as_me: caught signal $ac_signal" 3250 $as_echo "$as_me: exit $exit_status" 3251 } >&5 3252 rm -f core *.core core.conftest.* && 3253 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3254 exit $exit_status 3255 ' 0 3256 for ac_signal in 1 2 13 15; do 3257 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3258 done 3259 ac_signal=0 3260 3261 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3262 rm -f -r conftest* confdefs.h 3263 3264 $as_echo "/* confdefs.h */" > confdefs.h 3265 3266 # Predefined preprocessor variables. 3267 3268 cat >>confdefs.h <<_ACEOF 3269 #define PACKAGE_NAME "$PACKAGE_NAME" 3270 _ACEOF 3271 3272 cat >>confdefs.h <<_ACEOF 3273 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3274 _ACEOF 3275 3276 cat >>confdefs.h <<_ACEOF 3277 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3278 _ACEOF 3279 3280 cat >>confdefs.h <<_ACEOF 3281 #define PACKAGE_STRING "$PACKAGE_STRING" 3282 _ACEOF 3283 3284 cat >>confdefs.h <<_ACEOF 3285 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3286 _ACEOF 3287 3288 cat >>confdefs.h <<_ACEOF 3289 #define PACKAGE_URL "$PACKAGE_URL" 3290 _ACEOF 3291 3292 3293 # Let the site file select an alternate cache file if it wants to. 3294 # Prefer an explicitly selected file to automatically selected ones. 3295 ac_site_file1=NONE 3296 ac_site_file2=NONE 3297 if test -n "$CONFIG_SITE"; then 3298 # We do not want a PATH search for config.site. 3299 case $CONFIG_SITE in #(( 3300 -*) ac_site_file1=./$CONFIG_SITE;; 3301 */*) ac_site_file1=$CONFIG_SITE;; 3302 *) ac_site_file1=./$CONFIG_SITE;; 3303 esac 3304 elif test "x$prefix" != xNONE; then 3305 ac_site_file1=$prefix/share/config.site 3306 ac_site_file2=$prefix/etc/config.site 3307 else 3308 ac_site_file1=$ac_default_prefix/share/config.site 3309 ac_site_file2=$ac_default_prefix/etc/config.site 3310 fi 3311 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3312 do 3313 test "x$ac_site_file" = xNONE && continue 3314 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3315 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3316 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3317 sed 's/^/| /' "$ac_site_file" >&5 3318 . "$ac_site_file" \ 3319 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3320 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3321 as_fn_error $? "failed to load site script $ac_site_file 3322 See \`config.log' for more details" "$LINENO" 5; } 3323 fi 3324 done 3325 3326 if test -r "$cache_file"; then 3327 # Some versions of bash will fail to source /dev/null (special files 3328 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3329 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3330 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3331 $as_echo "$as_me: loading cache $cache_file" >&6;} 3332 case $cache_file in 3333 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3334 *) . "./$cache_file";; 3335 esac 3336 fi 3337 else 3338 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3339 $as_echo "$as_me: creating cache $cache_file" >&6;} 3340 >$cache_file 3341 fi 3342 3343 # Check that the precious variables saved in the cache have kept the same 3344 # value. 3345 ac_cache_corrupted=false 3346 for ac_var in $ac_precious_vars; do 3347 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3348 eval ac_new_set=\$ac_env_${ac_var}_set 3349 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3350 eval ac_new_val=\$ac_env_${ac_var}_value 3351 case $ac_old_set,$ac_new_set in 3352 set,) 3353 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3354 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3355 ac_cache_corrupted=: ;; 3356 ,set) 3357 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3358 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3359 ac_cache_corrupted=: ;; 3360 ,);; 3361 *) 3362 if test "x$ac_old_val" != "x$ac_new_val"; then 3363 # differences in whitespace do not lead to failure. 3364 ac_old_val_w=`echo x $ac_old_val` 3365 ac_new_val_w=`echo x $ac_new_val` 3366 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3367 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3368 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3369 ac_cache_corrupted=: 3370 else 3371 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3372 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3373 eval $ac_var=\$ac_old_val 3374 fi 3375 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3376 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3377 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3378 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3379 fi;; 3380 esac 3381 # Pass precious variables to config.status. 3382 if test "$ac_new_set" = set; then 3383 case $ac_new_val in 3384 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3385 *) ac_arg=$ac_var=$ac_new_val ;; 3386 esac 3387 case " $ac_configure_args " in 3388 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3389 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3390 esac 3391 fi 3392 done 3393 if $ac_cache_corrupted; then 3394 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3395 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3396 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3397 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3398 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3399 fi 3400 ## -------------------- ## 3401 ## Main body of script. ## 3402 ## -------------------- ## 3403 3404 ac_ext=c 3405 ac_cpp='$CPP $CPPFLAGS' 3406 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3407 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3408 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3409 3410 3411 3412 ac_aux_dir= 3413 for ac_dir in $TOPDIR/make/autoconf/build-aux "$srcdir"/$TOPDIR/make/autoconf/build-aux; do 3414 if test -f "$ac_dir/install-sh"; then 3415 ac_aux_dir=$ac_dir 3416 ac_install_sh="$ac_aux_dir/install-sh -c" 3417 break 3418 elif test -f "$ac_dir/install.sh"; then 3419 ac_aux_dir=$ac_dir 3420 ac_install_sh="$ac_aux_dir/install.sh -c" 3421 break 3422 elif test -f "$ac_dir/shtool"; then 3423 ac_aux_dir=$ac_dir 3424 ac_install_sh="$ac_aux_dir/shtool install -c" 3425 break 3426 fi 3427 done 3428 if test -z "$ac_aux_dir"; then 3429 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 3430 fi 3431 3432 # These three variables are undocumented and unsupported, 3433 # and are intended to be withdrawn in a future Autoconf release. 3434 # They can cause serious problems if a builder's source tree is in a directory 3435 # whose full name contains unusual characters. 3436 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3437 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3438 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3439 3440 3441 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3442 3443 # 3444 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3445 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3446 # 3447 # This code is free software; you can redistribute it and/or modify it 3448 # under the terms of the GNU General Public License version 2 only, as 3449 # published by the Free Software Foundation. Oracle designates this 3450 # particular file as subject to the "Classpath" exception as provided 3451 # by Oracle in the LICENSE file that accompanied this code. 3452 # 3453 # This code is distributed in the hope that it will be useful, but WITHOUT 3454 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3455 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3456 # version 2 for more details (a copy is included in the LICENSE file that 3457 # accompanied this code). 3458 # 3459 # You should have received a copy of the GNU General Public License version 3460 # 2 along with this work; if not, write to the Free Software Foundation, 3461 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3462 # 3463 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3464 # or visit www.oracle.com if you need additional information or have any 3465 # questions. 3466 # 3467 3468 # 3469 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3470 # 3471 # This program is free software; you can redistribute it and/or modify 3472 # it under the terms of the GNU General Public License as published by 3473 # the Free Software Foundation; either version 2 of the License, or 3474 # (at your option) any later version. 3475 # 3476 # This program is distributed in the hope that it will be useful, but 3477 # WITHOUT ANY WARRANTY; without even the implied warranty of 3478 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3479 # General Public License for more details. 3480 # 3481 # You should have received a copy of the GNU General Public License 3482 # along with this program; if not, write to the Free Software 3483 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3484 # 3485 # As a special exception to the GNU General Public License, if you 3486 # distribute this file as part of a program that contains a 3487 # configuration script generated by Autoconf, you may include it under 3488 # the same distribution terms that you use for the rest of that program. 3489 3490 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3491 # ---------------------------------- 3492 # PKG_PROG_PKG_CONFIG 3493 3494 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3495 # 3496 # Check to see whether a particular set of modules exists. Similar 3497 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3498 # 3499 # 3500 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3501 # this or PKG_CHECK_MODULES is called, or make sure to call 3502 # PKG_CHECK_EXISTS manually 3503 # -------------------------------------------------------------- 3504 3505 3506 3507 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3508 # --------------------------------------------- 3509 # _PKG_CONFIG 3510 3511 # _PKG_SHORT_ERRORS_SUPPORTED 3512 # ----------------------------- 3513 # _PKG_SHORT_ERRORS_SUPPORTED 3514 3515 3516 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3517 # [ACTION-IF-NOT-FOUND]) 3518 # 3519 # 3520 # Note that if there is a possibility the first call to 3521 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3522 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3523 # 3524 # 3525 # -------------------------------------------------------------- 3526 # PKG_CHECK_MODULES 3527 3528 3529 # Include these first... 3530 # 3531 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3532 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3533 # 3534 # This code is free software; you can redistribute it and/or modify it 3535 # under the terms of the GNU General Public License version 2 only, as 3536 # published by the Free Software Foundation. Oracle designates this 3537 # particular file as subject to the "Classpath" exception as provided 3538 # by Oracle in the LICENSE file that accompanied this code. 3539 # 3540 # This code is distributed in the hope that it will be useful, but WITHOUT 3541 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3542 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3543 # version 2 for more details (a copy is included in the LICENSE file that 3544 # accompanied this code). 3545 # 3546 # You should have received a copy of the GNU General Public License version 3547 # 2 along with this work; if not, write to the Free Software Foundation, 3548 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3549 # 3550 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3551 # or visit www.oracle.com if you need additional information or have any 3552 # questions. 3553 # 3554 3555 # Create a function/macro that takes a series of named arguments. The call is 3556 # similar to AC_DEFUN, but the setup of the function looks like this: 3557 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3558 # ... do something 3559 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3560 # ]) 3561 # A star (*) in front of a named argument means that it is required and it's 3562 # presence will be verified. To pass e.g. the first value as a normal indexed 3563 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3564 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3565 # "ARG_FOO". 3566 # 3567 # The generated function can be called like this: 3568 # MYFUNC(FOO: [foo-val], 3569 # BAR: [ 3570 # $ECHO hello world 3571 # ]) 3572 # Note that the argument value must start on the same line as the argument name. 3573 # 3574 # Argument 1: Name of the function to define 3575 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3576 # Argument 3: Argument array to treat as named, typically $@ 3577 # Argument 4: The main function body 3578 3579 3580 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3581 # If so, then append $1 to $2 \ 3582 # Also set JVM_ARG_OK to true/false depending on outcome. 3583 3584 3585 # Appends a string to a path variable, only adding the : when needed. 3586 3587 3588 # Prepends a string to a path variable, only adding the : when needed. 3589 3590 3591 # This will make sure the given variable points to a full and proper 3592 # path. This means: 3593 # 1) There will be no spaces in the path. On unix platforms, 3594 # spaces in the path will result in an error. On Windows, 3595 # the path will be rewritten using short-style to be space-free. 3596 # 2) The path will be absolute, and it will be in unix-style (on 3597 # cygwin). 3598 # $1: The name of the variable to fix 3599 3600 3601 # This will make sure the given variable points to a executable 3602 # with a full and proper path. This means: 3603 # 1) There will be no spaces in the path. On unix platforms, 3604 # spaces in the path will result in an error. On Windows, 3605 # the path will be rewritten using short-style to be space-free. 3606 # 2) The path will be absolute, and it will be in unix-style (on 3607 # cygwin). 3608 # Any arguments given to the executable is preserved. 3609 # If the input variable does not have a directory specification, then 3610 # it need to be in the PATH. 3611 # $1: The name of the variable to fix 3612 3613 3614 3615 3616 # Register a --with argument but mark it as deprecated 3617 # $1: The name of the with argument to deprecate, not including --with- 3618 3619 3620 # Register a --enable argument but mark it as deprecated 3621 # $1: The name of the with argument to deprecate, not including --enable- 3622 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3623 # $3: Messages to user. 3624 3625 3626 3627 3628 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3629 # $1: variable to check 3630 3631 3632 # Check that there are no unprocessed overridden variables left. 3633 # If so, they are an incorrect argument and we will exit with an error. 3634 3635 3636 # Setup a tool for the given variable. If correctly specified by the user, 3637 # use that value, otherwise search for the tool using the supplied code snippet. 3638 # $1: variable to set 3639 # $2: code snippet to call to look for the tool 3640 # $3: code snippet to call if variable was used to find tool 3641 3642 3643 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3644 # $1: variable to set 3645 # $2: executable name (or list of names) to look for 3646 # $3: [path] 3647 3648 3649 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3650 # $1: variable to set 3651 # $2: executable name (or list of names) to look for 3652 3653 3654 # Like BASIC_PATH_PROGS but fails if no tool was found. 3655 # $1: variable to set 3656 # $2: executable name (or list of names) to look for 3657 # $3: [path] 3658 3659 3660 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3661 # $1: variable to set 3662 # $2: autoconf macro to call to look for the special tool 3663 3664 3665 # Setup the most fundamental tools that relies on not much else to set up, 3666 # but is used by much of the early bootstrap code. 3667 3668 3669 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3670 3671 3672 # Evaluates platform specific overrides for devkit variables. 3673 # $1: Name of variable 3674 3675 3676 3677 3678 3679 3680 #%%% Simple tools %%% 3681 3682 # Check if we have found a usable version of make 3683 # $1: the path to a potential make binary (or empty) 3684 # $2: the description on how we found this 3685 3686 3687 3688 3689 # Goes looking for a usable version of GNU make. 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 # Check if build directory is on local disk. If not possible to determine, 3701 # we prefer to claim it's local. 3702 # Argument 1: directory to test 3703 # Argument 2: what to do if it is on local disk 3704 # Argument 3: what to do otherwise (remote disk or failure) 3705 3706 3707 # Check that source files have basic read permissions set. This might 3708 # not be the case in cygwin in certain conditions. 3709 3710 3711 3712 3713 # Check for support for specific options in bash 3714 3715 3716 ################################################################################ 3717 # 3718 # Default make target 3719 # 3720 3721 3722 # Code to run after AC_OUTPUT 3723 3724 3725 # 3726 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3727 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3728 # 3729 # This code is free software; you can redistribute it and/or modify it 3730 # under the terms of the GNU General Public License version 2 only, as 3731 # published by the Free Software Foundation. Oracle designates this 3732 # particular file as subject to the "Classpath" exception as provided 3733 # by Oracle in the LICENSE file that accompanied this code. 3734 # 3735 # This code is distributed in the hope that it will be useful, but WITHOUT 3736 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3737 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3738 # version 2 for more details (a copy is included in the LICENSE file that 3739 # accompanied this code). 3740 # 3741 # You should have received a copy of the GNU General Public License version 3742 # 2 along with this work; if not, write to the Free Software Foundation, 3743 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3744 # 3745 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3746 # or visit www.oracle.com if you need additional information or have any 3747 # questions. 3748 # 3749 3750 3751 3752 3753 3754 # Helper function which possibly converts a path using DOS-style short mode. 3755 # If so, the updated path is stored in $new_path. 3756 # $1: The path to check 3757 3758 3759 # Helper function which possibly converts a path using DOS-style short mode. 3760 # If so, the updated path is stored in $new_path. 3761 # $1: The path to check 3762 3763 3764 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3765 # and could probably be heavily simplified. However, all changes in this 3766 # area tend to need lot of testing in different scenarios, and in lack of 3767 # proper unit testing, cleaning this up has not been deemed worth the effort 3768 # at the moment. 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3779 3780 3781 3782 3783 # ... then the rest 3784 # 3785 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3786 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3787 # 3788 # This code is free software; you can redistribute it and/or modify it 3789 # under the terms of the GNU General Public License version 2 only, as 3790 # published by the Free Software Foundation. Oracle designates this 3791 # particular file as subject to the "Classpath" exception as provided 3792 # by Oracle in the LICENSE file that accompanied this code. 3793 # 3794 # This code is distributed in the hope that it will be useful, but WITHOUT 3795 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3796 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3797 # version 2 for more details (a copy is included in the LICENSE file that 3798 # accompanied this code). 3799 # 3800 # You should have received a copy of the GNU General Public License version 3801 # 2 along with this work; if not, write to the Free Software Foundation, 3802 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3803 # 3804 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3805 # or visit www.oracle.com if you need additional information or have any 3806 # questions. 3807 # 3808 3809 ######################################################################## 3810 # This file handles detection of the Boot JDK. The Boot JDK detection 3811 # process has been developed as a response to solve a complex real-world 3812 # problem. Initially, it was simple, but it has grown as platform after 3813 # platform, idiosyncracy after idiosyncracy has been supported. 3814 # 3815 # The basic idea is this: 3816 # 1) You need an acceptable *) JDK to use as a Boot JDK 3817 # 2) There are several ways to locate a JDK, that are mostly platform 3818 # dependent **) 3819 # 3) You can have multiple JDKs installed 3820 # 4) If possible, configure should try to dig out an acceptable JDK 3821 # automatically, without having to resort to command-line options 3822 # 3823 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3824 # javac) and not a JRE, etc. 3825 # 3826 # **) On Windows we typically use a well-known path. 3827 # On MacOSX we typically use the tool java_home. 3828 # On Linux we typically find javac in the $PATH, and then follow a 3829 # chain of symlinks that often ends up in a real JDK. 3830 # 3831 # This leads to the code where we check in different ways to locate a 3832 # JDK, and if one is found, check if it is acceptable. If not, we print 3833 # our reasons for rejecting it (useful when debugging non-working 3834 # configure situations) and continue checking the next one. 3835 ######################################################################## 3836 3837 # Execute the check given as argument, and verify the result 3838 # If the Boot JDK was previously found, do nothing 3839 # $1 A command line (typically autoconf macro) to execute 3840 3841 3842 # Test: Is bootjdk explicitly set by command line arguments? 3843 3844 3845 # Test: Is $JAVA_HOME set? 3846 3847 3848 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3849 3850 3851 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3852 # $1: Argument to the java_home binary (optional) 3853 3854 3855 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3856 3857 3858 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3859 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3860 # $1 = Path to directory containing jdk installations. 3861 # $2 = String to append to the found JDK directory to get the proper JDK home 3862 3863 3864 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3865 # environmental variable as base for where to look. 3866 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3867 3868 3869 # Test: Is there a JDK installed in default, well-known locations? 3870 3871 3872 # Check that a command-line tool in the Boot JDK is correct 3873 # $1 = name of variable to assign 3874 # $2 = name of binary 3875 3876 3877 ############################################################################### 3878 # 3879 # We need a Boot JDK to bootstrap the build. 3880 # 3881 3882 3883 3884 3885 3886 # BUILD_JDK: the location of the latest JDK that can run 3887 # on the host system and supports the target class file version 3888 # generated in this JDK build. This variable should only be 3889 # used after the launchers are built. 3890 # 3891 3892 # Execute the check given as argument, and verify the result. 3893 # If the JDK was previously found, do nothing. 3894 # $1 A command line (typically autoconf macro) to execute 3895 3896 3897 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3898 # is different than the host system doing the build (e.g. cross-compilation), 3899 # a special BUILD_JDK is built as part of the build process. An external 3900 # prebuilt BUILD_JDK can also be supplied. 3901 3902 3903 # 3904 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3905 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3906 # 3907 # This code is free software; you can redistribute it and/or modify it 3908 # under the terms of the GNU General Public License version 2 only, as 3909 # published by the Free Software Foundation. Oracle designates this 3910 # particular file as subject to the "Classpath" exception as provided 3911 # by Oracle in the LICENSE file that accompanied this code. 3912 # 3913 # This code is distributed in the hope that it will be useful, but WITHOUT 3914 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3915 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3916 # version 2 for more details (a copy is included in the LICENSE file that 3917 # accompanied this code). 3918 # 3919 # You should have received a copy of the GNU General Public License version 3920 # 2 along with this work; if not, write to the Free Software Foundation, 3921 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3922 # 3923 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3924 # or visit www.oracle.com if you need additional information or have any 3925 # questions. 3926 # 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 ################################################################################ 3945 # 3946 # Runs icecc-create-env once and prints the error if it fails 3947 # 3948 # $1: arguments to icecc-create-env 3949 # $2: log file 3950 # 3951 3952 3953 ################################################################################ 3954 # 3955 # Optionally enable distributed compilation of native code using icecc/icecream 3956 # 3957 3958 3959 3960 3961 3962 3963 3964 # 3965 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3966 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3967 # 3968 # This code is free software; you can redistribute it and/or modify it 3969 # under the terms of the GNU General Public License version 2 only, as 3970 # published by the Free Software Foundation. Oracle designates this 3971 # particular file as subject to the "Classpath" exception as provided 3972 # by Oracle in the LICENSE file that accompanied this code. 3973 # 3974 # This code is distributed in the hope that it will be useful, but WITHOUT 3975 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3976 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3977 # version 2 for more details (a copy is included in the LICENSE file that 3978 # accompanied this code). 3979 # 3980 # You should have received a copy of the GNU General Public License version 3981 # 2 along with this work; if not, write to the Free Software Foundation, 3982 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3983 # 3984 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3985 # or visit www.oracle.com if you need additional information or have any 3986 # questions. 3987 # 3988 3989 ################################################################################ 3990 # 3991 # Setup ABI profile (for arm) 3992 # 3993 3994 3995 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 3996 # corresponding configure arguments instead 3997 3998 3999 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4000 # that configure can use them while detecting compilers. 4001 # TOOLCHAIN_TYPE is available here. 4002 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4003 4004 4005 4006 4007 4008 4009 # Documentation on common flags used for solstudio in HIGHEST. 4010 # 4011 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4012 # done with care, there are some assumptions below that need to 4013 # be understood about the use of pointers, and IEEE behavior. 4014 # 4015 # -fns: Use non-standard floating point mode (not IEEE 754) 4016 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4017 # -fsingle: Use single precision floating point with 'float' 4018 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4019 # (Source with excessing pointer casting and data access with mixed 4020 # pointer types are not recommended) 4021 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4022 # (If you expect perfect errno behavior, do not use this) 4023 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4024 # -xrestrict: Pointer parameters to functions do not overlap 4025 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4026 # If you pass in multiple pointers to the same data, do not use this) 4027 # -xlibmil: Inline some library routines 4028 # (If you expect perfect errno behavior, do not use this) 4029 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4030 # (If you expect perfect errno behavior, do not use this) 4031 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4032 4033 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4034 # Bug? 4035 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4036 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4037 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4038 #fi 4039 4040 4041 4042 4043 4044 4045 ################################################################################ 4046 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4047 # conditionals against. 4048 # $2 - Optional prefix for each variable defined. 4049 4050 4051 # FLAGS_C_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4052 # IF_FALSE: [RUN-IF-FALSE]) 4053 # ------------------------------------------------------------ 4054 # Check that the C compiler supports an argument 4055 4056 4057 4058 4059 # FLAGS_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4060 # IF_FALSE: [RUN-IF-FALSE]) 4061 # ------------------------------------------------------------ 4062 # Check that the C++ compiler supports an argument 4063 4064 4065 4066 4067 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4068 # IF_FALSE: [RUN-IF-FALSE]) 4069 # ------------------------------------------------------------ 4070 # Check that the C and C++ compilers support an argument 4071 4072 4073 4074 4075 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4076 # IF_FALSE: [RUN-IF-FALSE]) 4077 # ------------------------------------------------------------ 4078 # Check that the linker support an argument 4079 4080 4081 4082 4083 4084 4085 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4086 # Arguments: 4087 # $1 - Optional prefix for each variable defined. 4088 4089 4090 # 4091 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4092 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4093 # 4094 # This code is free software; you can redistribute it and/or modify it 4095 # under the terms of the GNU General Public License version 2 only, as 4096 # published by the Free Software Foundation. Oracle designates this 4097 # particular file as subject to the "Classpath" exception as provided 4098 # by Oracle in the LICENSE file that accompanied this code. 4099 # 4100 # This code is distributed in the hope that it will be useful, but WITHOUT 4101 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4102 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4103 # version 2 for more details (a copy is included in the LICENSE file that 4104 # accompanied this code). 4105 # 4106 # You should have received a copy of the GNU General Public License version 4107 # 2 along with this work; if not, write to the Free Software Foundation, 4108 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4109 # 4110 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4111 # or visit www.oracle.com if you need additional information or have any 4112 # questions. 4113 # 4114 4115 4116 4117 4118 4119 cygwin_help() { 4120 case $1 in 4121 unzip) 4122 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4123 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4124 ;; 4125 zip) 4126 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4127 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4128 ;; 4129 make) 4130 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4131 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4132 ;; 4133 freetype) 4134 HELP_MSG=" 4135 The freetype library can now be build during the configure process. 4136 Download the freetype sources and unpack them into an arbitrary directory: 4137 4138 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4139 tar -xzf freetype-2.5.3.tar.gz 4140 4141 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4142 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4143 builds or into '<freetype_src>/lib32' for 32-bit builds. 4144 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4145 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4146 4147 Alternatively you can unpack the sources like this to use the default directory: 4148 4149 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4150 ;; 4151 esac 4152 } 4153 4154 msys_help() { 4155 PKGHANDLER_COMMAND="" 4156 } 4157 4158 apt_help() { 4159 case $1 in 4160 reduced) 4161 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4162 devkit) 4163 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4164 openjdk) 4165 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4166 alsa) 4167 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4168 cups) 4169 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 4170 freetype) 4171 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 4172 ffi) 4173 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 4174 x11) 4175 PKGHANDLER_COMMAND="sudo apt-get install libx11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 4176 ccache) 4177 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 4178 dtrace) 4179 PKGHANDLER_COMMAND="sudo apt-get install systemtap-sdt-dev" ;; 4180 esac 4181 } 4182 4183 yum_help() { 4184 case $1 in 4185 devkit) 4186 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4187 openjdk) 4188 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4189 alsa) 4190 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4191 cups) 4192 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4193 freetype) 4194 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4195 x11) 4196 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4197 ccache) 4198 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4199 esac 4200 } 4201 4202 brew_help() { 4203 case $1 in 4204 openjdk) 4205 PKGHANDLER_COMMAND="brew cask install java" ;; 4206 freetype) 4207 PKGHANDLER_COMMAND="brew install freetype" ;; 4208 ccache) 4209 PKGHANDLER_COMMAND="brew install ccache" ;; 4210 esac 4211 } 4212 4213 port_help() { 4214 PKGHANDLER_COMMAND="" 4215 } 4216 4217 pkgutil_help() { 4218 PKGHANDLER_COMMAND="" 4219 } 4220 4221 pkgadd_help() { 4222 PKGHANDLER_COMMAND="" 4223 } 4224 4225 # This function will check if we're called from the "configure" wrapper while 4226 # printing --help. If so, we will print out additional information that can 4227 # only be extracted within the autoconf script, and then exit. This must be 4228 # called at the very beginning in configure.ac. 4229 4230 4231 4232 4233 4234 4235 # 4236 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4237 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4238 # 4239 # This code is free software; you can redistribute it and/or modify it 4240 # under the terms of the GNU General Public License version 2 only, as 4241 # published by the Free Software Foundation. Oracle designates this 4242 # particular file as subject to the "Classpath" exception as provided 4243 # by Oracle in the LICENSE file that accompanied this code. 4244 # 4245 # This code is distributed in the hope that it will be useful, but WITHOUT 4246 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4247 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4248 # version 2 for more details (a copy is included in the LICENSE file that 4249 # accompanied this code). 4250 # 4251 # You should have received a copy of the GNU General Public License version 4252 # 2 along with this work; if not, write to the Free Software Foundation, 4253 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4254 # 4255 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4256 # or visit www.oracle.com if you need additional information or have any 4257 # questions. 4258 # 4259 4260 # All valid JVM features, regardless of platform 4261 VALID_JVM_FEATURES="compiler1 compiler2 zero shark minimal dtrace jvmti jvmci \ 4262 graal vm-structs jni-check services management all-gcs nmt cds \ 4263 static-build link-time-opt aot" 4264 4265 # All valid JVM variants 4266 VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" 4267 4268 ############################################################################### 4269 # Check if the specified JVM variant should be built. To be used in shell if 4270 # constructs, like this: 4271 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4272 # 4273 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4274 4275 # Definition kept in one line to allow inlining in if statements. 4276 # Additional [] needed to keep m4 from mangling shell constructs. 4277 4278 4279 ############################################################################### 4280 # Check if the specified JVM features are explicitly enabled. To be used in 4281 # shell if constructs, like this: 4282 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4283 # 4284 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4285 4286 # Definition kept in one line to allow inlining in if statements. 4287 # Additional [] needed to keep m4 from mangling shell constructs. 4288 4289 4290 ############################################################################### 4291 # Check which variants of the JVM that we want to build. Available variants are: 4292 # server: normal interpreter, and a tiered C1/C2 compiler 4293 # client: normal interpreter, and C1 (no C2 compiler) 4294 # minimal: reduced form of client with optional features stripped out 4295 # core: normal interpreter only, no compiler 4296 # zero: C++ based interpreter only, no compiler 4297 # zeroshark: C++ based interpreter, and a llvm-based compiler 4298 # custom: baseline JVM with no default features 4299 # 4300 4301 4302 ############################################################################### 4303 # Check if dtrace should be enabled and has all prerequisites present. 4304 # 4305 4306 4307 ################################################################################ 4308 # Check if AOT should be enabled 4309 # 4310 4311 4312 ################################################################################ 4313 # Allow to disable CDS 4314 # 4315 4316 4317 ############################################################################### 4318 # Set up all JVM features for each JVM variant. 4319 # 4320 4321 4322 ############################################################################### 4323 # Validate JVM features once all setup is complete, including custom setup. 4324 # 4325 4326 4327 ################################################################################ 4328 # 4329 # Specify which sources will be used to build the 64-bit ARM port 4330 # 4331 # --with-cpu-port=arm64 will use hotspot/src/cpu/arm 4332 # --with-cpu-port=aarch64 will use hotspot/src/cpu/aarch64 4333 # 4334 4335 4336 4337 ################################################################################ 4338 # Check if gtest should be built 4339 # 4340 4341 4342 # 4343 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4344 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4345 # 4346 # This code is free software; you can redistribute it and/or modify it 4347 # under the terms of the GNU General Public License version 2 only, as 4348 # published by the Free Software Foundation. Oracle designates this 4349 # particular file as subject to the "Classpath" exception as provided 4350 # by Oracle in the LICENSE file that accompanied this code. 4351 # 4352 # This code is distributed in the hope that it will be useful, but WITHOUT 4353 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4354 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4355 # version 2 for more details (a copy is included in the LICENSE file that 4356 # accompanied this code). 4357 # 4358 # You should have received a copy of the GNU General Public License version 4359 # 2 along with this work; if not, write to the Free Software Foundation, 4360 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4361 # 4362 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4363 # or visit www.oracle.com if you need additional information or have any 4364 # questions. 4365 # 4366 4367 ############################################################################### 4368 # Check which variant of the JDK that we want to build. 4369 # Currently we have: 4370 # normal: standard edition 4371 # but the custom make system may add other variants 4372 # 4373 # Effectively the JDK variant gives a name to a specific set of 4374 # modules to compile into the JDK. 4375 4376 4377 ############################################################################### 4378 # Set the debug level 4379 # release: no debug information, all optimizations, no asserts. 4380 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4381 # fastdebug: debug information (-g), all optimizations, all asserts 4382 # slowdebug: debug information (-g), no optimizations, all asserts 4383 4384 4385 ############################################################################### 4386 # 4387 # Should we build only OpenJDK even if closed sources are present? 4388 # 4389 4390 4391 4392 4393 ############################################################################### 4394 # 4395 # Enable or disable the elliptic curve crypto implementation 4396 # 4397 4398 4399 4400 4401 ################################################################################ 4402 # 4403 # Gcov coverage data for hotspot 4404 # 4405 4406 4407 ################################################################################ 4408 # 4409 # Static build support. When enabled will generate static 4410 # libraries instead of shared libraries for all JDK libs. 4411 # 4412 4413 4414 ################################################################################ 4415 # 4416 # jlink options. 4417 # We always keep packaged modules in JDK image. 4418 # 4419 4420 4421 ################################################################################ 4422 # 4423 # Check if building of the jtreg failure handler should be enabled. 4424 # 4425 4426 4427 ################################################################################ 4428 # 4429 # Enable or disable generation of the classlist at build time 4430 # 4431 4432 4433 # 4434 # Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. 4435 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4436 # 4437 # This code is free software; you can redistribute it and/or modify it 4438 # under the terms of the GNU General Public License version 2 only, as 4439 # published by the Free Software Foundation. Oracle designates this 4440 # particular file as subject to the "Classpath" exception as provided 4441 # by Oracle in the LICENSE file that accompanied this code. 4442 # 4443 # This code is distributed in the hope that it will be useful, but WITHOUT 4444 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4445 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4446 # version 2 for more details (a copy is included in the LICENSE file that 4447 # accompanied this code). 4448 # 4449 # You should have received a copy of the GNU General Public License version 4450 # 2 along with this work; if not, write to the Free Software Foundation, 4451 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4452 # 4453 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4454 # or visit www.oracle.com if you need additional information or have any 4455 # questions. 4456 # 4457 4458 ############################################################################### 4459 # 4460 # Setup version numbers 4461 # 4462 4463 # Verify that a given string represents a valid version number, and assign it 4464 # to a variable. 4465 4466 # Argument 1: the variable to assign to 4467 # Argument 2: the value given by the user 4468 4469 4470 4471 4472 # 4473 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4474 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4475 # 4476 # This code is free software; you can redistribute it and/or modify it 4477 # under the terms of the GNU General Public License version 2 only, as 4478 # published by the Free Software Foundation. Oracle designates this 4479 # particular file as subject to the "Classpath" exception as provided 4480 # by Oracle in the LICENSE file that accompanied this code. 4481 # 4482 # This code is distributed in the hope that it will be useful, but WITHOUT 4483 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4484 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4485 # version 2 for more details (a copy is included in the LICENSE file that 4486 # accompanied this code). 4487 # 4488 # You should have received a copy of the GNU General Public License version 4489 # 2 along with this work; if not, write to the Free Software Foundation, 4490 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4491 # 4492 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4493 # or visit www.oracle.com if you need additional information or have any 4494 # questions. 4495 # 4496 4497 # Major library component reside in separate files. 4498 # 4499 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4500 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4501 # 4502 # This code is free software; you can redistribute it and/or modify it 4503 # under the terms of the GNU General Public License version 2 only, as 4504 # published by the Free Software Foundation. Oracle designates this 4505 # particular file as subject to the "Classpath" exception as provided 4506 # by Oracle in the LICENSE file that accompanied this code. 4507 # 4508 # This code is distributed in the hope that it will be useful, but WITHOUT 4509 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4510 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4511 # version 2 for more details (a copy is included in the LICENSE file that 4512 # accompanied this code). 4513 # 4514 # You should have received a copy of the GNU General Public License version 4515 # 2 along with this work; if not, write to the Free Software Foundation, 4516 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4517 # 4518 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4519 # or visit www.oracle.com if you need additional information or have any 4520 # questions. 4521 # 4522 4523 ################################################################################ 4524 # Setup alsa (Advanced Linux Sound Architecture) 4525 ################################################################################ 4526 4527 4528 # 4529 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4530 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4531 # 4532 # This code is free software; you can redistribute it and/or modify it 4533 # under the terms of the GNU General Public License version 2 only, as 4534 # published by the Free Software Foundation. Oracle designates this 4535 # particular file as subject to the "Classpath" exception as provided 4536 # by Oracle in the LICENSE file that accompanied this code. 4537 # 4538 # This code is distributed in the hope that it will be useful, but WITHOUT 4539 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4540 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4541 # version 2 for more details (a copy is included in the LICENSE file that 4542 # accompanied this code). 4543 # 4544 # You should have received a copy of the GNU General Public License version 4545 # 2 along with this work; if not, write to the Free Software Foundation, 4546 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4547 # 4548 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4549 # or visit www.oracle.com if you need additional information or have any 4550 # questions. 4551 # 4552 4553 ################################################################################ 4554 # Setup bundled libraries. 4555 # 4556 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4557 # OpenJDK repository. Default is to use these libraries as bundled, but they 4558 # might be replaced by en external version by the user. 4559 ################################################################################ 4560 4561 4562 ################################################################################ 4563 # Setup libjpeg 4564 ################################################################################ 4565 4566 4567 ################################################################################ 4568 # Setup giflib 4569 ################################################################################ 4570 4571 4572 ################################################################################ 4573 # Setup libpng 4574 ################################################################################ 4575 4576 4577 ################################################################################ 4578 # Setup zlib 4579 ################################################################################ 4580 4581 4582 ################################################################################ 4583 # Setup lcms (Little CMS) 4584 ################################################################################ 4585 4586 4587 # 4588 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4589 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4590 # 4591 # This code is free software; you can redistribute it and/or modify it 4592 # under the terms of the GNU General Public License version 2 only, as 4593 # published by the Free Software Foundation. Oracle designates this 4594 # particular file as subject to the "Classpath" exception as provided 4595 # by Oracle in the LICENSE file that accompanied this code. 4596 # 4597 # This code is distributed in the hope that it will be useful, but WITHOUT 4598 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4599 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4600 # version 2 for more details (a copy is included in the LICENSE file that 4601 # accompanied this code). 4602 # 4603 # You should have received a copy of the GNU General Public License version 4604 # 2 along with this work; if not, write to the Free Software Foundation, 4605 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4606 # 4607 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4608 # or visit www.oracle.com if you need additional information or have any 4609 # questions. 4610 # 4611 4612 ################################################################################ 4613 # Setup cups (Common Unix Printing System) 4614 ################################################################################ 4615 4616 4617 # 4618 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4619 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4620 # 4621 # This code is free software; you can redistribute it and/or modify it 4622 # under the terms of the GNU General Public License version 2 only, as 4623 # published by the Free Software Foundation. Oracle designates this 4624 # particular file as subject to the "Classpath" exception as provided 4625 # by Oracle in the LICENSE file that accompanied this code. 4626 # 4627 # This code is distributed in the hope that it will be useful, but WITHOUT 4628 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4629 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4630 # version 2 for more details (a copy is included in the LICENSE file that 4631 # accompanied this code). 4632 # 4633 # You should have received a copy of the GNU General Public License version 4634 # 2 along with this work; if not, write to the Free Software Foundation, 4635 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4636 # 4637 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4638 # or visit www.oracle.com if you need additional information or have any 4639 # questions. 4640 # 4641 4642 ################################################################################ 4643 # Setup libffi (Foreign Function Interface) 4644 ################################################################################ 4645 4646 4647 # 4648 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4649 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4650 # 4651 # This code is free software; you can redistribute it and/or modify it 4652 # under the terms of the GNU General Public License version 2 only, as 4653 # published by the Free Software Foundation. Oracle designates this 4654 # particular file as subject to the "Classpath" exception as provided 4655 # by Oracle in the LICENSE file that accompanied this code. 4656 # 4657 # This code is distributed in the hope that it will be useful, but WITHOUT 4658 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4659 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4660 # version 2 for more details (a copy is included in the LICENSE file that 4661 # accompanied this code). 4662 # 4663 # You should have received a copy of the GNU General Public License version 4664 # 2 along with this work; if not, write to the Free Software Foundation, 4665 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4666 # 4667 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4668 # or visit www.oracle.com if you need additional information or have any 4669 # questions. 4670 # 4671 4672 ################################################################################ 4673 # Build the freetype lib from source 4674 ################################################################################ 4675 4676 4677 ################################################################################ 4678 # Check if a potential freeype library match is correct and usable 4679 ################################################################################ 4680 4681 4682 ################################################################################ 4683 # Setup freetype (The FreeType2 font rendering library) 4684 ################################################################################ 4685 4686 4687 # 4688 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4689 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4690 # 4691 # This code is free software; you can redistribute it and/or modify it 4692 # under the terms of the GNU General Public License version 2 only, as 4693 # published by the Free Software Foundation. Oracle designates this 4694 # particular file as subject to the "Classpath" exception as provided 4695 # by Oracle in the LICENSE file that accompanied this code. 4696 # 4697 # This code is distributed in the hope that it will be useful, but WITHOUT 4698 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4699 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4700 # version 2 for more details (a copy is included in the LICENSE file that 4701 # accompanied this code). 4702 # 4703 # You should have received a copy of the GNU General Public License version 4704 # 2 along with this work; if not, write to the Free Software Foundation, 4705 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4706 # 4707 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4708 # or visit www.oracle.com if you need additional information or have any 4709 # questions. 4710 # 4711 4712 ################################################################################ 4713 # Setup the standard C/C++ runtime libraries. 4714 # 4715 # Most importantly, determine if stdc++ should be linked statically or 4716 # dynamically. 4717 ################################################################################ 4718 4719 4720 # 4721 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4722 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4723 # 4724 # This code is free software; you can redistribute it and/or modify it 4725 # under the terms of the GNU General Public License version 2 only, as 4726 # published by the Free Software Foundation. Oracle designates this 4727 # particular file as subject to the "Classpath" exception as provided 4728 # by Oracle in the LICENSE file that accompanied this code. 4729 # 4730 # This code is distributed in the hope that it will be useful, but WITHOUT 4731 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4732 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4733 # version 2 for more details (a copy is included in the LICENSE file that 4734 # accompanied this code). 4735 # 4736 # You should have received a copy of the GNU General Public License version 4737 # 2 along with this work; if not, write to the Free Software Foundation, 4738 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4739 # 4740 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4741 # or visit www.oracle.com if you need additional information or have any 4742 # questions. 4743 # 4744 4745 ################################################################################ 4746 # Setup X11 Windows system 4747 ################################################################################ 4748 4749 4750 4751 ################################################################################ 4752 # Determine which libraries are needed for this configuration 4753 ################################################################################ 4754 4755 4756 ################################################################################ 4757 # Parse library options, and setup needed libraries 4758 ################################################################################ 4759 4760 4761 ################################################################################ 4762 # Setup llvm (Low-Level VM) 4763 ################################################################################ 4764 4765 4766 ################################################################################ 4767 # Setup various libraries, typically small system libraries 4768 ################################################################################ 4769 4770 4771 ################################################################################ 4772 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4773 # redistribute it in the test image. 4774 ################################################################################ 4775 4776 4777 4778 # 4779 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4780 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4781 # 4782 # This code is free software; you can redistribute it and/or modify it 4783 # under the terms of the GNU General Public License version 2 only, as 4784 # published by the Free Software Foundation. Oracle designates this 4785 # particular file as subject to the "Classpath" exception as provided 4786 # by Oracle in the LICENSE file that accompanied this code. 4787 # 4788 # This code is distributed in the hope that it will be useful, but WITHOUT 4789 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4790 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4791 # version 2 for more details (a copy is included in the LICENSE file that 4792 # accompanied this code). 4793 # 4794 # You should have received a copy of the GNU General Public License version 4795 # 2 along with this work; if not, write to the Free Software Foundation, 4796 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4797 # 4798 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4799 # or visit www.oracle.com if you need additional information or have any 4800 # questions. 4801 # 4802 4803 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4804 # Converts autoconf style CPU name to OpenJDK style, into 4805 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4806 4807 4808 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4809 # Converts autoconf style OS name to OpenJDK style, into 4810 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4811 4812 4813 # Expects $host_os $host_cpu $build_os and $build_cpu 4814 # and $with_target_bits to have been setup! 4815 # 4816 # Translate the standard triplet(quadruplet) definition 4817 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4818 # OPENJDK_BUILD_OS, etc. 4819 4820 4821 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4822 # accordingly. Must be done after setting up build and target system, but before 4823 # doing anything else with these values. 4824 4825 4826 # Setup the legacy variables, for controlling the old makefiles. 4827 # 4828 4829 4830 # $1 - Either TARGET or BUILD to setup the variables for. 4831 4832 4833 4834 4835 4836 4837 #%%% Build and target systems %%% 4838 4839 4840 4841 4842 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4843 # Add -mX to various FLAGS variables. 4844 4845 4846 4847 4848 4849 4850 # 4851 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4852 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4853 # 4854 # This code is free software; you can redistribute it and/or modify it 4855 # under the terms of the GNU General Public License version 2 only, as 4856 # published by the Free Software Foundation. Oracle designates this 4857 # particular file as subject to the "Classpath" exception as provided 4858 # by Oracle in the LICENSE file that accompanied this code. 4859 # 4860 # This code is distributed in the hope that it will be useful, but WITHOUT 4861 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4862 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4863 # version 2 for more details (a copy is included in the LICENSE file that 4864 # accompanied this code). 4865 # 4866 # You should have received a copy of the GNU General Public License version 4867 # 2 along with this work; if not, write to the Free Software Foundation, 4868 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4869 # 4870 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4871 # or visit www.oracle.com if you need additional information or have any 4872 # questions. 4873 # 4874 4875 4876 4877 ################################################################################ 4878 # Define a mechanism for importing extra prebuilt modules 4879 # 4880 4881 4882 4883 # 4884 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4885 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4886 # 4887 # This code is free software; you can redistribute it and/or modify it 4888 # under the terms of the GNU General Public License version 2 only, as 4889 # published by the Free Software Foundation. Oracle designates this 4890 # particular file as subject to the "Classpath" exception as provided 4891 # by Oracle in the LICENSE file that accompanied this code. 4892 # 4893 # This code is distributed in the hope that it will be useful, but WITHOUT 4894 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4895 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4896 # version 2 for more details (a copy is included in the LICENSE file that 4897 # accompanied this code). 4898 # 4899 # You should have received a copy of the GNU General Public License version 4900 # 2 along with this work; if not, write to the Free Software Foundation, 4901 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4902 # 4903 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4904 # or visit www.oracle.com if you need additional information or have any 4905 # questions. 4906 # 4907 4908 ######################################################################## 4909 # This file is responsible for detecting, verifying and setting up the 4910 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4911 # proper paths to the binaries, but it will not setup any flags. 4912 # 4913 # The binaries used is determined by the toolchain type, which is the family of 4914 # compilers and related tools that are used. 4915 ######################################################################## 4916 4917 4918 # All valid toolchains, regardless of platform (used by help.m4) 4919 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4920 4921 # These toolchains are valid on different platforms 4922 VALID_TOOLCHAINS_linux="gcc clang" 4923 VALID_TOOLCHAINS_solaris="solstudio" 4924 VALID_TOOLCHAINS_macosx="gcc clang" 4925 VALID_TOOLCHAINS_aix="xlc" 4926 VALID_TOOLCHAINS_windows="microsoft" 4927 4928 # Toolchain descriptions 4929 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4930 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4931 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4932 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4933 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4934 4935 # Minimum supported versions, empty means unspecified 4936 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4937 TOOLCHAIN_MINIMUM_VERSION_gcc="4.7" 4938 TOOLCHAIN_MINIMUM_VERSION_microsoft="16.00.30319.01" # VS2010 4939 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 4940 TOOLCHAIN_MINIMUM_VERSION_xlc="" 4941 4942 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 4943 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 4944 # $1 - optional variable prefix for compiler and version variables (BUILD_) 4945 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 4946 4947 4948 # Check if the configured compiler (C and C++) is of a specific version or 4949 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 4950 # 4951 # Arguments: 4952 # VERSION: The version string to check against the found version 4953 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 4954 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 4955 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 4956 4957 4958 4959 4960 # Setup a number of variables describing how native output files are 4961 # named on this platform/toolchain. 4962 4963 4964 # Determine which toolchain type to use, and make sure it is valid for this 4965 # platform. Setup various information about the selected toolchain. 4966 4967 4968 # Before we start detecting the toolchain executables, we might need some 4969 # special setup, e.g. additional paths etc. 4970 4971 4972 # Restore path, etc 4973 4974 4975 # Check if a compiler is of the toolchain type we expect, and save the version 4976 # information from it. If the compiler does not match the expected type, 4977 # this function will abort using AC_MSG_ERROR. If it matches, the version will 4978 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 4979 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 4980 # 4981 # $1 = compiler to test (CC or CXX) 4982 # $2 = human readable name of compiler (C or C++) 4983 4984 4985 # Try to locate the given C or C++ compiler in the path, or otherwise. 4986 # 4987 # $1 = compiler to test (CC or CXX) 4988 # $2 = human readable name of compiler (C or C++) 4989 # $3 = compiler name to search for 4990 4991 4992 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 4993 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 4994 # archiver (AR). Verify that the compilers are correct according to the 4995 # toolchain type. 4996 4997 4998 # Setup additional tools that is considered a part of the toolchain, but not the 4999 # core part. Many of these are highly platform-specific and do not exist, 5000 # and/or are not needed on all platforms. 5001 5002 5003 # Setup the build tools (i.e, the compiler and linker used to build programs 5004 # that should be run on the build platform, not the target platform, as a build 5005 # helper). Since the non-cross-compile case uses the normal, target compilers 5006 # for this, we can only do this after these have been setup. 5007 5008 5009 # Do some additional checks on the detected tools. 5010 5011 5012 # Setup the JTReg Regression Test Harness. 5013 5014 5015 # Setup the JIB dependency resolver 5016 5017 5018 # 5019 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 5020 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5021 # 5022 # This code is free software; you can redistribute it and/or modify it 5023 # under the terms of the GNU General Public License version 2 only, as 5024 # published by the Free Software Foundation. Oracle designates this 5025 # particular file as subject to the "Classpath" exception as provided 5026 # by Oracle in the LICENSE file that accompanied this code. 5027 # 5028 # This code is distributed in the hope that it will be useful, but WITHOUT 5029 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5030 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5031 # version 2 for more details (a copy is included in the LICENSE file that 5032 # accompanied this code). 5033 # 5034 # You should have received a copy of the GNU General Public License version 5035 # 2 along with this work; if not, write to the Free Software Foundation, 5036 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5037 # 5038 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5039 # or visit www.oracle.com if you need additional information or have any 5040 # questions. 5041 # 5042 5043 ################################################################################ 5044 # The order of these defines the priority by which we try to find them. 5045 VALID_VS_VERSIONS="2013 2012 2010" 5046 5047 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5048 VS_VERSION_INTERNAL_2010=100 5049 VS_MSVCR_2010=msvcr100.dll 5050 # We don't use msvcp on Visual Studio 2010 5051 #VS_MSVCP_2010=msvcp100.dll 5052 VS_ENVVAR_2010="VS100COMNTOOLS" 5053 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5054 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5055 VS_VS_PLATFORM_NAME_2010="v100" 5056 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5057 5058 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5059 VS_VERSION_INTERNAL_2012=110 5060 VS_MSVCR_2012=msvcr110.dll 5061 VS_MSVCP_2012=msvcp110.dll 5062 VS_ENVVAR_2012="VS110COMNTOOLS" 5063 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5064 VS_SDK_INSTALLDIR_2012= 5065 VS_VS_PLATFORM_NAME_2012="v110" 5066 VS_SDK_PLATFORM_NAME_2012= 5067 5068 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5069 VS_VERSION_INTERNAL_2013=120 5070 VS_MSVCR_2013=msvcr120.dll 5071 VS_MSVCP_2013=msvcp120.dll 5072 VS_ENVVAR_2013="VS120COMNTOOLS" 5073 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5074 VS_SDK_INSTALLDIR_2013= 5075 VS_VS_PLATFORM_NAME_2013="v120" 5076 VS_SDK_PLATFORM_NAME_2013= 5077 5078 ################################################################################ 5079 5080 5081 5082 ################################################################################ 5083 5084 5085 5086 ################################################################################ 5087 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5088 # build environment and assigns it to VS_ENV_CMD 5089 5090 5091 ################################################################################ 5092 5093 5094 5095 ################################################################################ 5096 # Check if the VS env variables were setup prior to running configure. 5097 # If not, then find vcvarsall.bat and run it automatically, and integrate 5098 # the set env variables into the spec file. 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 # This line needs to be here, verbatim, after all includes and the dummy hook 5114 # definitions. It is replaced with custom functionality when building 5115 # custom sources. 5116 #CUSTOM_AUTOCONF_INCLUDE 5117 5118 # Do not change or remove the following line, it is needed for consistency checks: 5119 DATE_WHEN_GENERATED=1506027115 5120 5121 ############################################################################### 5122 # 5123 # Initialization / Boot-strapping 5124 # 5125 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5126 # thus it jumps back and forth, each time gaining something needed later on. 5127 # 5128 ############################################################################### 5129 5130 # If we are requested to print additional help, do that and then exit. 5131 # This must be the very first call. 5132 5133 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5134 5135 # Print available toolchains 5136 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5137 $PRINTF "Which are valid to use depends on the build platform.\n" 5138 for toolchain in $VALID_TOOLCHAINS_all; do 5139 # Use indirect variable referencing 5140 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5141 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5142 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5143 done 5144 $PRINTF "\n" 5145 5146 # Print available jvm features 5147 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5148 $PRINTF "Which are valid to use depends on the target platform.\n " 5149 $PRINTF "%s " $VALID_JVM_FEATURES 5150 $PRINTF "\n" 5151 5152 # And now exit directly 5153 exit 0 5154 fi 5155 5156 5157 # Basic initialization that must happen first of all in the normal process. 5158 5159 # Save the original command line. This is passed to us by the wrapper configure script. 5160 5161 # Save the path variable before it gets changed 5162 ORIGINAL_PATH="$PATH" 5163 5164 DATE_WHEN_CONFIGURED=`LANG=C date` 5165 5166 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5167 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5168 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5169 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5170 5171 5172 # Start with tools that do not need have cross compilation support 5173 # and can be expected to be found in the default PATH. These tools are 5174 # used by configure. 5175 5176 # First are all the simple required tools. 5177 5178 5179 5180 # Publish this variable in the help. 5181 5182 5183 if [ -z "${BASENAME+x}" ]; then 5184 # The variable is not set by user, try to locate tool using the code snippet 5185 for ac_prog in basename 5186 do 5187 # Extract the first word of "$ac_prog", so it can be a program name with args. 5188 set dummy $ac_prog; ac_word=$2 5189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5190 $as_echo_n "checking for $ac_word... " >&6; } 5191 if ${ac_cv_path_BASENAME+:} false; then : 5192 $as_echo_n "(cached) " >&6 5193 else 5194 case $BASENAME in 5195 [\\/]* | ?:[\\/]*) 5196 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5197 ;; 5198 *) 5199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5200 for as_dir in $PATH 5201 do 5202 IFS=$as_save_IFS 5203 test -z "$as_dir" && as_dir=. 5204 for ac_exec_ext in '' $ac_executable_extensions; do 5205 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5206 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5208 break 2 5209 fi 5210 done 5211 done 5212 IFS=$as_save_IFS 5213 5214 ;; 5215 esac 5216 fi 5217 BASENAME=$ac_cv_path_BASENAME 5218 if test -n "$BASENAME"; then 5219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5220 $as_echo "$BASENAME" >&6; } 5221 else 5222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5223 $as_echo "no" >&6; } 5224 fi 5225 5226 5227 test -n "$BASENAME" && break 5228 done 5229 5230 else 5231 # The variable is set, but is it from the command line or the environment? 5232 5233 # Try to remove the string !BASENAME! from our list. 5234 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5235 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5236 # If it failed, the variable was not from the command line. Ignore it, 5237 # but warn the user (except for BASH, which is always set by the calling BASH). 5238 if test "xBASENAME" != xBASH; then 5239 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5240 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5241 fi 5242 # Try to locate tool using the code snippet 5243 for ac_prog in basename 5244 do 5245 # Extract the first word of "$ac_prog", so it can be a program name with args. 5246 set dummy $ac_prog; ac_word=$2 5247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5248 $as_echo_n "checking for $ac_word... " >&6; } 5249 if ${ac_cv_path_BASENAME+:} false; then : 5250 $as_echo_n "(cached) " >&6 5251 else 5252 case $BASENAME in 5253 [\\/]* | ?:[\\/]*) 5254 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5255 ;; 5256 *) 5257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5258 for as_dir in $PATH 5259 do 5260 IFS=$as_save_IFS 5261 test -z "$as_dir" && as_dir=. 5262 for ac_exec_ext in '' $ac_executable_extensions; do 5263 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5264 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5265 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5266 break 2 5267 fi 5268 done 5269 done 5270 IFS=$as_save_IFS 5271 5272 ;; 5273 esac 5274 fi 5275 BASENAME=$ac_cv_path_BASENAME 5276 if test -n "$BASENAME"; then 5277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5278 $as_echo "$BASENAME" >&6; } 5279 else 5280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5281 $as_echo "no" >&6; } 5282 fi 5283 5284 5285 test -n "$BASENAME" && break 5286 done 5287 5288 else 5289 # If it succeeded, then it was overridden by the user. We will use it 5290 # for the tool. 5291 5292 # First remove it from the list of overridden variables, so we can test 5293 # for unknown variables in the end. 5294 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5295 5296 # Check if we try to supply an empty value 5297 if test "x$BASENAME" = x; then 5298 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5299 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5301 $as_echo_n "checking for BASENAME... " >&6; } 5302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5303 $as_echo "disabled" >&6; } 5304 else 5305 # Check if the provided tool contains a complete path. 5306 tool_specified="$BASENAME" 5307 tool_basename="${tool_specified##*/}" 5308 if test "x$tool_basename" = "x$tool_specified"; then 5309 # A command without a complete path is provided, search $PATH. 5310 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5311 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5312 # Extract the first word of "$tool_basename", so it can be a program name with args. 5313 set dummy $tool_basename; ac_word=$2 5314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5315 $as_echo_n "checking for $ac_word... " >&6; } 5316 if ${ac_cv_path_BASENAME+:} false; then : 5317 $as_echo_n "(cached) " >&6 5318 else 5319 case $BASENAME in 5320 [\\/]* | ?:[\\/]*) 5321 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5322 ;; 5323 *) 5324 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5325 for as_dir in $PATH 5326 do 5327 IFS=$as_save_IFS 5328 test -z "$as_dir" && as_dir=. 5329 for ac_exec_ext in '' $ac_executable_extensions; do 5330 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5331 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5332 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5333 break 2 5334 fi 5335 done 5336 done 5337 IFS=$as_save_IFS 5338 5339 ;; 5340 esac 5341 fi 5342 BASENAME=$ac_cv_path_BASENAME 5343 if test -n "$BASENAME"; then 5344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5345 $as_echo "$BASENAME" >&6; } 5346 else 5347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5348 $as_echo "no" >&6; } 5349 fi 5350 5351 5352 if test "x$BASENAME" = x; then 5353 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5354 fi 5355 else 5356 # Otherwise we believe it is a complete path. Use it as it is. 5357 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5358 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5360 $as_echo_n "checking for BASENAME... " >&6; } 5361 if test ! -x "$tool_specified"; then 5362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5363 $as_echo "not found" >&6; } 5364 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5365 fi 5366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5367 $as_echo "$tool_specified" >&6; } 5368 fi 5369 fi 5370 fi 5371 5372 fi 5373 5374 5375 5376 if test "x$BASENAME" = x; then 5377 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5378 fi 5379 5380 5381 5382 5383 5384 # Publish this variable in the help. 5385 5386 5387 if [ -z "${BASH+x}" ]; then 5388 # The variable is not set by user, try to locate tool using the code snippet 5389 for ac_prog in bash 5390 do 5391 # Extract the first word of "$ac_prog", so it can be a program name with args. 5392 set dummy $ac_prog; ac_word=$2 5393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5394 $as_echo_n "checking for $ac_word... " >&6; } 5395 if ${ac_cv_path_BASH+:} false; then : 5396 $as_echo_n "(cached) " >&6 5397 else 5398 case $BASH in 5399 [\\/]* | ?:[\\/]*) 5400 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5401 ;; 5402 *) 5403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5404 for as_dir in $PATH 5405 do 5406 IFS=$as_save_IFS 5407 test -z "$as_dir" && as_dir=. 5408 for ac_exec_ext in '' $ac_executable_extensions; do 5409 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5410 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5412 break 2 5413 fi 5414 done 5415 done 5416 IFS=$as_save_IFS 5417 5418 ;; 5419 esac 5420 fi 5421 BASH=$ac_cv_path_BASH 5422 if test -n "$BASH"; then 5423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5424 $as_echo "$BASH" >&6; } 5425 else 5426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5427 $as_echo "no" >&6; } 5428 fi 5429 5430 5431 test -n "$BASH" && break 5432 done 5433 5434 else 5435 # The variable is set, but is it from the command line or the environment? 5436 5437 # Try to remove the string !BASH! from our list. 5438 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5439 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5440 # If it failed, the variable was not from the command line. Ignore it, 5441 # but warn the user (except for BASH, which is always set by the calling BASH). 5442 if test "xBASH" != xBASH; then 5443 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5444 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5445 fi 5446 # Try to locate tool using the code snippet 5447 for ac_prog in bash 5448 do 5449 # Extract the first word of "$ac_prog", so it can be a program name with args. 5450 set dummy $ac_prog; ac_word=$2 5451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5452 $as_echo_n "checking for $ac_word... " >&6; } 5453 if ${ac_cv_path_BASH+:} false; then : 5454 $as_echo_n "(cached) " >&6 5455 else 5456 case $BASH in 5457 [\\/]* | ?:[\\/]*) 5458 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5459 ;; 5460 *) 5461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5462 for as_dir in $PATH 5463 do 5464 IFS=$as_save_IFS 5465 test -z "$as_dir" && as_dir=. 5466 for ac_exec_ext in '' $ac_executable_extensions; do 5467 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5468 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5470 break 2 5471 fi 5472 done 5473 done 5474 IFS=$as_save_IFS 5475 5476 ;; 5477 esac 5478 fi 5479 BASH=$ac_cv_path_BASH 5480 if test -n "$BASH"; then 5481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5482 $as_echo "$BASH" >&6; } 5483 else 5484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5485 $as_echo "no" >&6; } 5486 fi 5487 5488 5489 test -n "$BASH" && break 5490 done 5491 5492 else 5493 # If it succeeded, then it was overridden by the user. We will use it 5494 # for the tool. 5495 5496 # First remove it from the list of overridden variables, so we can test 5497 # for unknown variables in the end. 5498 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5499 5500 # Check if we try to supply an empty value 5501 if test "x$BASH" = x; then 5502 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5503 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5505 $as_echo_n "checking for BASH... " >&6; } 5506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5507 $as_echo "disabled" >&6; } 5508 else 5509 # Check if the provided tool contains a complete path. 5510 tool_specified="$BASH" 5511 tool_basename="${tool_specified##*/}" 5512 if test "x$tool_basename" = "x$tool_specified"; then 5513 # A command without a complete path is provided, search $PATH. 5514 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5515 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5516 # Extract the first word of "$tool_basename", so it can be a program name with args. 5517 set dummy $tool_basename; ac_word=$2 5518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5519 $as_echo_n "checking for $ac_word... " >&6; } 5520 if ${ac_cv_path_BASH+:} false; then : 5521 $as_echo_n "(cached) " >&6 5522 else 5523 case $BASH in 5524 [\\/]* | ?:[\\/]*) 5525 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5526 ;; 5527 *) 5528 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5529 for as_dir in $PATH 5530 do 5531 IFS=$as_save_IFS 5532 test -z "$as_dir" && as_dir=. 5533 for ac_exec_ext in '' $ac_executable_extensions; do 5534 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5535 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5536 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5537 break 2 5538 fi 5539 done 5540 done 5541 IFS=$as_save_IFS 5542 5543 ;; 5544 esac 5545 fi 5546 BASH=$ac_cv_path_BASH 5547 if test -n "$BASH"; then 5548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5549 $as_echo "$BASH" >&6; } 5550 else 5551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5552 $as_echo "no" >&6; } 5553 fi 5554 5555 5556 if test "x$BASH" = x; then 5557 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5558 fi 5559 else 5560 # Otherwise we believe it is a complete path. Use it as it is. 5561 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5562 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5564 $as_echo_n "checking for BASH... " >&6; } 5565 if test ! -x "$tool_specified"; then 5566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5567 $as_echo "not found" >&6; } 5568 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5569 fi 5570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5571 $as_echo "$tool_specified" >&6; } 5572 fi 5573 fi 5574 fi 5575 5576 fi 5577 5578 5579 5580 if test "x$BASH" = x; then 5581 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5582 fi 5583 5584 5585 5586 5587 5588 # Publish this variable in the help. 5589 5590 5591 if [ -z "${CAT+x}" ]; then 5592 # The variable is not set by user, try to locate tool using the code snippet 5593 for ac_prog in cat 5594 do 5595 # Extract the first word of "$ac_prog", so it can be a program name with args. 5596 set dummy $ac_prog; ac_word=$2 5597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5598 $as_echo_n "checking for $ac_word... " >&6; } 5599 if ${ac_cv_path_CAT+:} false; then : 5600 $as_echo_n "(cached) " >&6 5601 else 5602 case $CAT in 5603 [\\/]* | ?:[\\/]*) 5604 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5605 ;; 5606 *) 5607 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5608 for as_dir in $PATH 5609 do 5610 IFS=$as_save_IFS 5611 test -z "$as_dir" && as_dir=. 5612 for ac_exec_ext in '' $ac_executable_extensions; do 5613 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5614 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5615 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5616 break 2 5617 fi 5618 done 5619 done 5620 IFS=$as_save_IFS 5621 5622 ;; 5623 esac 5624 fi 5625 CAT=$ac_cv_path_CAT 5626 if test -n "$CAT"; then 5627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5628 $as_echo "$CAT" >&6; } 5629 else 5630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5631 $as_echo "no" >&6; } 5632 fi 5633 5634 5635 test -n "$CAT" && break 5636 done 5637 5638 else 5639 # The variable is set, but is it from the command line or the environment? 5640 5641 # Try to remove the string !CAT! from our list. 5642 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5643 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5644 # If it failed, the variable was not from the command line. Ignore it, 5645 # but warn the user (except for BASH, which is always set by the calling BASH). 5646 if test "xCAT" != xBASH; then 5647 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5648 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5649 fi 5650 # Try to locate tool using the code snippet 5651 for ac_prog in cat 5652 do 5653 # Extract the first word of "$ac_prog", so it can be a program name with args. 5654 set dummy $ac_prog; ac_word=$2 5655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5656 $as_echo_n "checking for $ac_word... " >&6; } 5657 if ${ac_cv_path_CAT+:} false; then : 5658 $as_echo_n "(cached) " >&6 5659 else 5660 case $CAT in 5661 [\\/]* | ?:[\\/]*) 5662 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5663 ;; 5664 *) 5665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5666 for as_dir in $PATH 5667 do 5668 IFS=$as_save_IFS 5669 test -z "$as_dir" && as_dir=. 5670 for ac_exec_ext in '' $ac_executable_extensions; do 5671 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5672 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5673 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5674 break 2 5675 fi 5676 done 5677 done 5678 IFS=$as_save_IFS 5679 5680 ;; 5681 esac 5682 fi 5683 CAT=$ac_cv_path_CAT 5684 if test -n "$CAT"; then 5685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5686 $as_echo "$CAT" >&6; } 5687 else 5688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5689 $as_echo "no" >&6; } 5690 fi 5691 5692 5693 test -n "$CAT" && break 5694 done 5695 5696 else 5697 # If it succeeded, then it was overridden by the user. We will use it 5698 # for the tool. 5699 5700 # First remove it from the list of overridden variables, so we can test 5701 # for unknown variables in the end. 5702 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5703 5704 # Check if we try to supply an empty value 5705 if test "x$CAT" = x; then 5706 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5707 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5709 $as_echo_n "checking for CAT... " >&6; } 5710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5711 $as_echo "disabled" >&6; } 5712 else 5713 # Check if the provided tool contains a complete path. 5714 tool_specified="$CAT" 5715 tool_basename="${tool_specified##*/}" 5716 if test "x$tool_basename" = "x$tool_specified"; then 5717 # A command without a complete path is provided, search $PATH. 5718 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5719 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5720 # Extract the first word of "$tool_basename", so it can be a program name with args. 5721 set dummy $tool_basename; ac_word=$2 5722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5723 $as_echo_n "checking for $ac_word... " >&6; } 5724 if ${ac_cv_path_CAT+:} false; then : 5725 $as_echo_n "(cached) " >&6 5726 else 5727 case $CAT in 5728 [\\/]* | ?:[\\/]*) 5729 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5730 ;; 5731 *) 5732 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5733 for as_dir in $PATH 5734 do 5735 IFS=$as_save_IFS 5736 test -z "$as_dir" && as_dir=. 5737 for ac_exec_ext in '' $ac_executable_extensions; do 5738 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5739 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5740 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5741 break 2 5742 fi 5743 done 5744 done 5745 IFS=$as_save_IFS 5746 5747 ;; 5748 esac 5749 fi 5750 CAT=$ac_cv_path_CAT 5751 if test -n "$CAT"; then 5752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5753 $as_echo "$CAT" >&6; } 5754 else 5755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5756 $as_echo "no" >&6; } 5757 fi 5758 5759 5760 if test "x$CAT" = x; then 5761 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5762 fi 5763 else 5764 # Otherwise we believe it is a complete path. Use it as it is. 5765 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5766 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5768 $as_echo_n "checking for CAT... " >&6; } 5769 if test ! -x "$tool_specified"; then 5770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5771 $as_echo "not found" >&6; } 5772 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5773 fi 5774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5775 $as_echo "$tool_specified" >&6; } 5776 fi 5777 fi 5778 fi 5779 5780 fi 5781 5782 5783 5784 if test "x$CAT" = x; then 5785 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5786 fi 5787 5788 5789 5790 5791 5792 # Publish this variable in the help. 5793 5794 5795 if [ -z "${CHMOD+x}" ]; then 5796 # The variable is not set by user, try to locate tool using the code snippet 5797 for ac_prog in chmod 5798 do 5799 # Extract the first word of "$ac_prog", so it can be a program name with args. 5800 set dummy $ac_prog; ac_word=$2 5801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5802 $as_echo_n "checking for $ac_word... " >&6; } 5803 if ${ac_cv_path_CHMOD+:} false; then : 5804 $as_echo_n "(cached) " >&6 5805 else 5806 case $CHMOD in 5807 [\\/]* | ?:[\\/]*) 5808 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5809 ;; 5810 *) 5811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5812 for as_dir in $PATH 5813 do 5814 IFS=$as_save_IFS 5815 test -z "$as_dir" && as_dir=. 5816 for ac_exec_ext in '' $ac_executable_extensions; do 5817 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5818 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5819 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5820 break 2 5821 fi 5822 done 5823 done 5824 IFS=$as_save_IFS 5825 5826 ;; 5827 esac 5828 fi 5829 CHMOD=$ac_cv_path_CHMOD 5830 if test -n "$CHMOD"; then 5831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5832 $as_echo "$CHMOD" >&6; } 5833 else 5834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5835 $as_echo "no" >&6; } 5836 fi 5837 5838 5839 test -n "$CHMOD" && break 5840 done 5841 5842 else 5843 # The variable is set, but is it from the command line or the environment? 5844 5845 # Try to remove the string !CHMOD! from our list. 5846 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5847 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5848 # If it failed, the variable was not from the command line. Ignore it, 5849 # but warn the user (except for BASH, which is always set by the calling BASH). 5850 if test "xCHMOD" != xBASH; then 5851 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5852 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5853 fi 5854 # Try to locate tool using the code snippet 5855 for ac_prog in chmod 5856 do 5857 # Extract the first word of "$ac_prog", so it can be a program name with args. 5858 set dummy $ac_prog; ac_word=$2 5859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5860 $as_echo_n "checking for $ac_word... " >&6; } 5861 if ${ac_cv_path_CHMOD+:} false; then : 5862 $as_echo_n "(cached) " >&6 5863 else 5864 case $CHMOD in 5865 [\\/]* | ?:[\\/]*) 5866 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5867 ;; 5868 *) 5869 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5870 for as_dir in $PATH 5871 do 5872 IFS=$as_save_IFS 5873 test -z "$as_dir" && as_dir=. 5874 for ac_exec_ext in '' $ac_executable_extensions; do 5875 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5876 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5877 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5878 break 2 5879 fi 5880 done 5881 done 5882 IFS=$as_save_IFS 5883 5884 ;; 5885 esac 5886 fi 5887 CHMOD=$ac_cv_path_CHMOD 5888 if test -n "$CHMOD"; then 5889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5890 $as_echo "$CHMOD" >&6; } 5891 else 5892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5893 $as_echo "no" >&6; } 5894 fi 5895 5896 5897 test -n "$CHMOD" && break 5898 done 5899 5900 else 5901 # If it succeeded, then it was overridden by the user. We will use it 5902 # for the tool. 5903 5904 # First remove it from the list of overridden variables, so we can test 5905 # for unknown variables in the end. 5906 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5907 5908 # Check if we try to supply an empty value 5909 if test "x$CHMOD" = x; then 5910 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5911 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5913 $as_echo_n "checking for CHMOD... " >&6; } 5914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5915 $as_echo "disabled" >&6; } 5916 else 5917 # Check if the provided tool contains a complete path. 5918 tool_specified="$CHMOD" 5919 tool_basename="${tool_specified##*/}" 5920 if test "x$tool_basename" = "x$tool_specified"; then 5921 # A command without a complete path is provided, search $PATH. 5922 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5923 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5924 # Extract the first word of "$tool_basename", so it can be a program name with args. 5925 set dummy $tool_basename; ac_word=$2 5926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5927 $as_echo_n "checking for $ac_word... " >&6; } 5928 if ${ac_cv_path_CHMOD+:} false; then : 5929 $as_echo_n "(cached) " >&6 5930 else 5931 case $CHMOD in 5932 [\\/]* | ?:[\\/]*) 5933 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5934 ;; 5935 *) 5936 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5937 for as_dir in $PATH 5938 do 5939 IFS=$as_save_IFS 5940 test -z "$as_dir" && as_dir=. 5941 for ac_exec_ext in '' $ac_executable_extensions; do 5942 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5943 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5944 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5945 break 2 5946 fi 5947 done 5948 done 5949 IFS=$as_save_IFS 5950 5951 ;; 5952 esac 5953 fi 5954 CHMOD=$ac_cv_path_CHMOD 5955 if test -n "$CHMOD"; then 5956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5957 $as_echo "$CHMOD" >&6; } 5958 else 5959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5960 $as_echo "no" >&6; } 5961 fi 5962 5963 5964 if test "x$CHMOD" = x; then 5965 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5966 fi 5967 else 5968 # Otherwise we believe it is a complete path. Use it as it is. 5969 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 5970 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 5971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5972 $as_echo_n "checking for CHMOD... " >&6; } 5973 if test ! -x "$tool_specified"; then 5974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5975 $as_echo "not found" >&6; } 5976 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 5977 fi 5978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5979 $as_echo "$tool_specified" >&6; } 5980 fi 5981 fi 5982 fi 5983 5984 fi 5985 5986 5987 5988 if test "x$CHMOD" = x; then 5989 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 5990 fi 5991 5992 5993 5994 5995 5996 # Publish this variable in the help. 5997 5998 5999 if [ -z "${CMP+x}" ]; then 6000 # The variable is not set by user, try to locate tool using the code snippet 6001 for ac_prog in cmp 6002 do 6003 # Extract the first word of "$ac_prog", so it can be a program name with args. 6004 set dummy $ac_prog; ac_word=$2 6005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6006 $as_echo_n "checking for $ac_word... " >&6; } 6007 if ${ac_cv_path_CMP+:} false; then : 6008 $as_echo_n "(cached) " >&6 6009 else 6010 case $CMP in 6011 [\\/]* | ?:[\\/]*) 6012 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6013 ;; 6014 *) 6015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6016 for as_dir in $PATH 6017 do 6018 IFS=$as_save_IFS 6019 test -z "$as_dir" && as_dir=. 6020 for ac_exec_ext in '' $ac_executable_extensions; do 6021 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6022 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6023 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6024 break 2 6025 fi 6026 done 6027 done 6028 IFS=$as_save_IFS 6029 6030 ;; 6031 esac 6032 fi 6033 CMP=$ac_cv_path_CMP 6034 if test -n "$CMP"; then 6035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6036 $as_echo "$CMP" >&6; } 6037 else 6038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6039 $as_echo "no" >&6; } 6040 fi 6041 6042 6043 test -n "$CMP" && break 6044 done 6045 6046 else 6047 # The variable is set, but is it from the command line or the environment? 6048 6049 # Try to remove the string !CMP! from our list. 6050 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6051 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6052 # If it failed, the variable was not from the command line. Ignore it, 6053 # but warn the user (except for BASH, which is always set by the calling BASH). 6054 if test "xCMP" != xBASH; then 6055 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6056 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6057 fi 6058 # Try to locate tool using the code snippet 6059 for ac_prog in cmp 6060 do 6061 # Extract the first word of "$ac_prog", so it can be a program name with args. 6062 set dummy $ac_prog; ac_word=$2 6063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6064 $as_echo_n "checking for $ac_word... " >&6; } 6065 if ${ac_cv_path_CMP+:} false; then : 6066 $as_echo_n "(cached) " >&6 6067 else 6068 case $CMP in 6069 [\\/]* | ?:[\\/]*) 6070 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6071 ;; 6072 *) 6073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6074 for as_dir in $PATH 6075 do 6076 IFS=$as_save_IFS 6077 test -z "$as_dir" && as_dir=. 6078 for ac_exec_ext in '' $ac_executable_extensions; do 6079 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6080 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6081 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6082 break 2 6083 fi 6084 done 6085 done 6086 IFS=$as_save_IFS 6087 6088 ;; 6089 esac 6090 fi 6091 CMP=$ac_cv_path_CMP 6092 if test -n "$CMP"; then 6093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6094 $as_echo "$CMP" >&6; } 6095 else 6096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6097 $as_echo "no" >&6; } 6098 fi 6099 6100 6101 test -n "$CMP" && break 6102 done 6103 6104 else 6105 # If it succeeded, then it was overridden by the user. We will use it 6106 # for the tool. 6107 6108 # First remove it from the list of overridden variables, so we can test 6109 # for unknown variables in the end. 6110 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6111 6112 # Check if we try to supply an empty value 6113 if test "x$CMP" = x; then 6114 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6115 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6117 $as_echo_n "checking for CMP... " >&6; } 6118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6119 $as_echo "disabled" >&6; } 6120 else 6121 # Check if the provided tool contains a complete path. 6122 tool_specified="$CMP" 6123 tool_basename="${tool_specified##*/}" 6124 if test "x$tool_basename" = "x$tool_specified"; then 6125 # A command without a complete path is provided, search $PATH. 6126 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6127 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6128 # Extract the first word of "$tool_basename", so it can be a program name with args. 6129 set dummy $tool_basename; ac_word=$2 6130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6131 $as_echo_n "checking for $ac_word... " >&6; } 6132 if ${ac_cv_path_CMP+:} false; then : 6133 $as_echo_n "(cached) " >&6 6134 else 6135 case $CMP in 6136 [\\/]* | ?:[\\/]*) 6137 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6138 ;; 6139 *) 6140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6141 for as_dir in $PATH 6142 do 6143 IFS=$as_save_IFS 6144 test -z "$as_dir" && as_dir=. 6145 for ac_exec_ext in '' $ac_executable_extensions; do 6146 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6147 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6148 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6149 break 2 6150 fi 6151 done 6152 done 6153 IFS=$as_save_IFS 6154 6155 ;; 6156 esac 6157 fi 6158 CMP=$ac_cv_path_CMP 6159 if test -n "$CMP"; then 6160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6161 $as_echo "$CMP" >&6; } 6162 else 6163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6164 $as_echo "no" >&6; } 6165 fi 6166 6167 6168 if test "x$CMP" = x; then 6169 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6170 fi 6171 else 6172 # Otherwise we believe it is a complete path. Use it as it is. 6173 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6174 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6176 $as_echo_n "checking for CMP... " >&6; } 6177 if test ! -x "$tool_specified"; then 6178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6179 $as_echo "not found" >&6; } 6180 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6181 fi 6182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6183 $as_echo "$tool_specified" >&6; } 6184 fi 6185 fi 6186 fi 6187 6188 fi 6189 6190 6191 6192 if test "x$CMP" = x; then 6193 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6194 fi 6195 6196 6197 6198 6199 6200 # Publish this variable in the help. 6201 6202 6203 if [ -z "${COMM+x}" ]; then 6204 # The variable is not set by user, try to locate tool using the code snippet 6205 for ac_prog in comm 6206 do 6207 # Extract the first word of "$ac_prog", so it can be a program name with args. 6208 set dummy $ac_prog; ac_word=$2 6209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6210 $as_echo_n "checking for $ac_word... " >&6; } 6211 if ${ac_cv_path_COMM+:} false; then : 6212 $as_echo_n "(cached) " >&6 6213 else 6214 case $COMM in 6215 [\\/]* | ?:[\\/]*) 6216 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6217 ;; 6218 *) 6219 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6220 for as_dir in $PATH 6221 do 6222 IFS=$as_save_IFS 6223 test -z "$as_dir" && as_dir=. 6224 for ac_exec_ext in '' $ac_executable_extensions; do 6225 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6226 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6227 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6228 break 2 6229 fi 6230 done 6231 done 6232 IFS=$as_save_IFS 6233 6234 ;; 6235 esac 6236 fi 6237 COMM=$ac_cv_path_COMM 6238 if test -n "$COMM"; then 6239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6240 $as_echo "$COMM" >&6; } 6241 else 6242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6243 $as_echo "no" >&6; } 6244 fi 6245 6246 6247 test -n "$COMM" && break 6248 done 6249 6250 else 6251 # The variable is set, but is it from the command line or the environment? 6252 6253 # Try to remove the string !COMM! from our list. 6254 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6255 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6256 # If it failed, the variable was not from the command line. Ignore it, 6257 # but warn the user (except for BASH, which is always set by the calling BASH). 6258 if test "xCOMM" != xBASH; then 6259 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6260 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6261 fi 6262 # Try to locate tool using the code snippet 6263 for ac_prog in comm 6264 do 6265 # Extract the first word of "$ac_prog", so it can be a program name with args. 6266 set dummy $ac_prog; ac_word=$2 6267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6268 $as_echo_n "checking for $ac_word... " >&6; } 6269 if ${ac_cv_path_COMM+:} false; then : 6270 $as_echo_n "(cached) " >&6 6271 else 6272 case $COMM in 6273 [\\/]* | ?:[\\/]*) 6274 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6275 ;; 6276 *) 6277 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6278 for as_dir in $PATH 6279 do 6280 IFS=$as_save_IFS 6281 test -z "$as_dir" && as_dir=. 6282 for ac_exec_ext in '' $ac_executable_extensions; do 6283 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6284 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6285 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6286 break 2 6287 fi 6288 done 6289 done 6290 IFS=$as_save_IFS 6291 6292 ;; 6293 esac 6294 fi 6295 COMM=$ac_cv_path_COMM 6296 if test -n "$COMM"; then 6297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6298 $as_echo "$COMM" >&6; } 6299 else 6300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6301 $as_echo "no" >&6; } 6302 fi 6303 6304 6305 test -n "$COMM" && break 6306 done 6307 6308 else 6309 # If it succeeded, then it was overridden by the user. We will use it 6310 # for the tool. 6311 6312 # First remove it from the list of overridden variables, so we can test 6313 # for unknown variables in the end. 6314 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6315 6316 # Check if we try to supply an empty value 6317 if test "x$COMM" = x; then 6318 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6319 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6321 $as_echo_n "checking for COMM... " >&6; } 6322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6323 $as_echo "disabled" >&6; } 6324 else 6325 # Check if the provided tool contains a complete path. 6326 tool_specified="$COMM" 6327 tool_basename="${tool_specified##*/}" 6328 if test "x$tool_basename" = "x$tool_specified"; then 6329 # A command without a complete path is provided, search $PATH. 6330 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6331 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6332 # Extract the first word of "$tool_basename", so it can be a program name with args. 6333 set dummy $tool_basename; ac_word=$2 6334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6335 $as_echo_n "checking for $ac_word... " >&6; } 6336 if ${ac_cv_path_COMM+:} false; then : 6337 $as_echo_n "(cached) " >&6 6338 else 6339 case $COMM in 6340 [\\/]* | ?:[\\/]*) 6341 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6342 ;; 6343 *) 6344 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6345 for as_dir in $PATH 6346 do 6347 IFS=$as_save_IFS 6348 test -z "$as_dir" && as_dir=. 6349 for ac_exec_ext in '' $ac_executable_extensions; do 6350 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6351 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6352 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6353 break 2 6354 fi 6355 done 6356 done 6357 IFS=$as_save_IFS 6358 6359 ;; 6360 esac 6361 fi 6362 COMM=$ac_cv_path_COMM 6363 if test -n "$COMM"; then 6364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6365 $as_echo "$COMM" >&6; } 6366 else 6367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6368 $as_echo "no" >&6; } 6369 fi 6370 6371 6372 if test "x$COMM" = x; then 6373 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6374 fi 6375 else 6376 # Otherwise we believe it is a complete path. Use it as it is. 6377 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6378 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6380 $as_echo_n "checking for COMM... " >&6; } 6381 if test ! -x "$tool_specified"; then 6382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6383 $as_echo "not found" >&6; } 6384 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6385 fi 6386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6387 $as_echo "$tool_specified" >&6; } 6388 fi 6389 fi 6390 fi 6391 6392 fi 6393 6394 6395 6396 if test "x$COMM" = x; then 6397 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6398 fi 6399 6400 6401 6402 6403 6404 # Publish this variable in the help. 6405 6406 6407 if [ -z "${CP+x}" ]; then 6408 # The variable is not set by user, try to locate tool using the code snippet 6409 for ac_prog in cp 6410 do 6411 # Extract the first word of "$ac_prog", so it can be a program name with args. 6412 set dummy $ac_prog; ac_word=$2 6413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6414 $as_echo_n "checking for $ac_word... " >&6; } 6415 if ${ac_cv_path_CP+:} false; then : 6416 $as_echo_n "(cached) " >&6 6417 else 6418 case $CP in 6419 [\\/]* | ?:[\\/]*) 6420 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6421 ;; 6422 *) 6423 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6424 for as_dir in $PATH 6425 do 6426 IFS=$as_save_IFS 6427 test -z "$as_dir" && as_dir=. 6428 for ac_exec_ext in '' $ac_executable_extensions; do 6429 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6430 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6431 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6432 break 2 6433 fi 6434 done 6435 done 6436 IFS=$as_save_IFS 6437 6438 ;; 6439 esac 6440 fi 6441 CP=$ac_cv_path_CP 6442 if test -n "$CP"; then 6443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6444 $as_echo "$CP" >&6; } 6445 else 6446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6447 $as_echo "no" >&6; } 6448 fi 6449 6450 6451 test -n "$CP" && break 6452 done 6453 6454 else 6455 # The variable is set, but is it from the command line or the environment? 6456 6457 # Try to remove the string !CP! from our list. 6458 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6459 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6460 # If it failed, the variable was not from the command line. Ignore it, 6461 # but warn the user (except for BASH, which is always set by the calling BASH). 6462 if test "xCP" != xBASH; then 6463 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6464 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6465 fi 6466 # Try to locate tool using the code snippet 6467 for ac_prog in cp 6468 do 6469 # Extract the first word of "$ac_prog", so it can be a program name with args. 6470 set dummy $ac_prog; ac_word=$2 6471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6472 $as_echo_n "checking for $ac_word... " >&6; } 6473 if ${ac_cv_path_CP+:} false; then : 6474 $as_echo_n "(cached) " >&6 6475 else 6476 case $CP in 6477 [\\/]* | ?:[\\/]*) 6478 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6479 ;; 6480 *) 6481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6482 for as_dir in $PATH 6483 do 6484 IFS=$as_save_IFS 6485 test -z "$as_dir" && as_dir=. 6486 for ac_exec_ext in '' $ac_executable_extensions; do 6487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6488 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6490 break 2 6491 fi 6492 done 6493 done 6494 IFS=$as_save_IFS 6495 6496 ;; 6497 esac 6498 fi 6499 CP=$ac_cv_path_CP 6500 if test -n "$CP"; then 6501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6502 $as_echo "$CP" >&6; } 6503 else 6504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6505 $as_echo "no" >&6; } 6506 fi 6507 6508 6509 test -n "$CP" && break 6510 done 6511 6512 else 6513 # If it succeeded, then it was overridden by the user. We will use it 6514 # for the tool. 6515 6516 # First remove it from the list of overridden variables, so we can test 6517 # for unknown variables in the end. 6518 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6519 6520 # Check if we try to supply an empty value 6521 if test "x$CP" = x; then 6522 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6523 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6525 $as_echo_n "checking for CP... " >&6; } 6526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6527 $as_echo "disabled" >&6; } 6528 else 6529 # Check if the provided tool contains a complete path. 6530 tool_specified="$CP" 6531 tool_basename="${tool_specified##*/}" 6532 if test "x$tool_basename" = "x$tool_specified"; then 6533 # A command without a complete path is provided, search $PATH. 6534 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6535 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6536 # Extract the first word of "$tool_basename", so it can be a program name with args. 6537 set dummy $tool_basename; ac_word=$2 6538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6539 $as_echo_n "checking for $ac_word... " >&6; } 6540 if ${ac_cv_path_CP+:} false; then : 6541 $as_echo_n "(cached) " >&6 6542 else 6543 case $CP in 6544 [\\/]* | ?:[\\/]*) 6545 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6546 ;; 6547 *) 6548 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6549 for as_dir in $PATH 6550 do 6551 IFS=$as_save_IFS 6552 test -z "$as_dir" && as_dir=. 6553 for ac_exec_ext in '' $ac_executable_extensions; do 6554 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6555 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6556 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6557 break 2 6558 fi 6559 done 6560 done 6561 IFS=$as_save_IFS 6562 6563 ;; 6564 esac 6565 fi 6566 CP=$ac_cv_path_CP 6567 if test -n "$CP"; then 6568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6569 $as_echo "$CP" >&6; } 6570 else 6571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6572 $as_echo "no" >&6; } 6573 fi 6574 6575 6576 if test "x$CP" = x; then 6577 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6578 fi 6579 else 6580 # Otherwise we believe it is a complete path. Use it as it is. 6581 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6582 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6584 $as_echo_n "checking for CP... " >&6; } 6585 if test ! -x "$tool_specified"; then 6586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6587 $as_echo "not found" >&6; } 6588 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6589 fi 6590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6591 $as_echo "$tool_specified" >&6; } 6592 fi 6593 fi 6594 fi 6595 6596 fi 6597 6598 6599 6600 if test "x$CP" = x; then 6601 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6602 fi 6603 6604 6605 6606 6607 6608 # Publish this variable in the help. 6609 6610 6611 if [ -z "${CUT+x}" ]; then 6612 # The variable is not set by user, try to locate tool using the code snippet 6613 for ac_prog in cut 6614 do 6615 # Extract the first word of "$ac_prog", so it can be a program name with args. 6616 set dummy $ac_prog; ac_word=$2 6617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6618 $as_echo_n "checking for $ac_word... " >&6; } 6619 if ${ac_cv_path_CUT+:} false; then : 6620 $as_echo_n "(cached) " >&6 6621 else 6622 case $CUT in 6623 [\\/]* | ?:[\\/]*) 6624 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6625 ;; 6626 *) 6627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6628 for as_dir in $PATH 6629 do 6630 IFS=$as_save_IFS 6631 test -z "$as_dir" && as_dir=. 6632 for ac_exec_ext in '' $ac_executable_extensions; do 6633 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6634 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6635 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6636 break 2 6637 fi 6638 done 6639 done 6640 IFS=$as_save_IFS 6641 6642 ;; 6643 esac 6644 fi 6645 CUT=$ac_cv_path_CUT 6646 if test -n "$CUT"; then 6647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6648 $as_echo "$CUT" >&6; } 6649 else 6650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6651 $as_echo "no" >&6; } 6652 fi 6653 6654 6655 test -n "$CUT" && break 6656 done 6657 6658 else 6659 # The variable is set, but is it from the command line or the environment? 6660 6661 # Try to remove the string !CUT! from our list. 6662 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6663 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6664 # If it failed, the variable was not from the command line. Ignore it, 6665 # but warn the user (except for BASH, which is always set by the calling BASH). 6666 if test "xCUT" != xBASH; then 6667 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6668 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6669 fi 6670 # Try to locate tool using the code snippet 6671 for ac_prog in cut 6672 do 6673 # Extract the first word of "$ac_prog", so it can be a program name with args. 6674 set dummy $ac_prog; ac_word=$2 6675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6676 $as_echo_n "checking for $ac_word... " >&6; } 6677 if ${ac_cv_path_CUT+:} false; then : 6678 $as_echo_n "(cached) " >&6 6679 else 6680 case $CUT in 6681 [\\/]* | ?:[\\/]*) 6682 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6683 ;; 6684 *) 6685 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6686 for as_dir in $PATH 6687 do 6688 IFS=$as_save_IFS 6689 test -z "$as_dir" && as_dir=. 6690 for ac_exec_ext in '' $ac_executable_extensions; do 6691 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6692 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6693 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6694 break 2 6695 fi 6696 done 6697 done 6698 IFS=$as_save_IFS 6699 6700 ;; 6701 esac 6702 fi 6703 CUT=$ac_cv_path_CUT 6704 if test -n "$CUT"; then 6705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6706 $as_echo "$CUT" >&6; } 6707 else 6708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6709 $as_echo "no" >&6; } 6710 fi 6711 6712 6713 test -n "$CUT" && break 6714 done 6715 6716 else 6717 # If it succeeded, then it was overridden by the user. We will use it 6718 # for the tool. 6719 6720 # First remove it from the list of overridden variables, so we can test 6721 # for unknown variables in the end. 6722 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6723 6724 # Check if we try to supply an empty value 6725 if test "x$CUT" = x; then 6726 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6727 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6729 $as_echo_n "checking for CUT... " >&6; } 6730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6731 $as_echo "disabled" >&6; } 6732 else 6733 # Check if the provided tool contains a complete path. 6734 tool_specified="$CUT" 6735 tool_basename="${tool_specified##*/}" 6736 if test "x$tool_basename" = "x$tool_specified"; then 6737 # A command without a complete path is provided, search $PATH. 6738 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6739 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6740 # Extract the first word of "$tool_basename", so it can be a program name with args. 6741 set dummy $tool_basename; ac_word=$2 6742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6743 $as_echo_n "checking for $ac_word... " >&6; } 6744 if ${ac_cv_path_CUT+:} false; then : 6745 $as_echo_n "(cached) " >&6 6746 else 6747 case $CUT in 6748 [\\/]* | ?:[\\/]*) 6749 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6750 ;; 6751 *) 6752 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6753 for as_dir in $PATH 6754 do 6755 IFS=$as_save_IFS 6756 test -z "$as_dir" && as_dir=. 6757 for ac_exec_ext in '' $ac_executable_extensions; do 6758 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6759 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6760 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6761 break 2 6762 fi 6763 done 6764 done 6765 IFS=$as_save_IFS 6766 6767 ;; 6768 esac 6769 fi 6770 CUT=$ac_cv_path_CUT 6771 if test -n "$CUT"; then 6772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6773 $as_echo "$CUT" >&6; } 6774 else 6775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6776 $as_echo "no" >&6; } 6777 fi 6778 6779 6780 if test "x$CUT" = x; then 6781 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6782 fi 6783 else 6784 # Otherwise we believe it is a complete path. Use it as it is. 6785 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6786 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6788 $as_echo_n "checking for CUT... " >&6; } 6789 if test ! -x "$tool_specified"; then 6790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6791 $as_echo "not found" >&6; } 6792 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6793 fi 6794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6795 $as_echo "$tool_specified" >&6; } 6796 fi 6797 fi 6798 fi 6799 6800 fi 6801 6802 6803 6804 if test "x$CUT" = x; then 6805 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6806 fi 6807 6808 6809 6810 6811 6812 # Publish this variable in the help. 6813 6814 6815 if [ -z "${DATE+x}" ]; then 6816 # The variable is not set by user, try to locate tool using the code snippet 6817 for ac_prog in date 6818 do 6819 # Extract the first word of "$ac_prog", so it can be a program name with args. 6820 set dummy $ac_prog; ac_word=$2 6821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6822 $as_echo_n "checking for $ac_word... " >&6; } 6823 if ${ac_cv_path_DATE+:} false; then : 6824 $as_echo_n "(cached) " >&6 6825 else 6826 case $DATE in 6827 [\\/]* | ?:[\\/]*) 6828 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6829 ;; 6830 *) 6831 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6832 for as_dir in $PATH 6833 do 6834 IFS=$as_save_IFS 6835 test -z "$as_dir" && as_dir=. 6836 for ac_exec_ext in '' $ac_executable_extensions; do 6837 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6838 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6839 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6840 break 2 6841 fi 6842 done 6843 done 6844 IFS=$as_save_IFS 6845 6846 ;; 6847 esac 6848 fi 6849 DATE=$ac_cv_path_DATE 6850 if test -n "$DATE"; then 6851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6852 $as_echo "$DATE" >&6; } 6853 else 6854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6855 $as_echo "no" >&6; } 6856 fi 6857 6858 6859 test -n "$DATE" && break 6860 done 6861 6862 else 6863 # The variable is set, but is it from the command line or the environment? 6864 6865 # Try to remove the string !DATE! from our list. 6866 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6867 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6868 # If it failed, the variable was not from the command line. Ignore it, 6869 # but warn the user (except for BASH, which is always set by the calling BASH). 6870 if test "xDATE" != xBASH; then 6871 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6872 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6873 fi 6874 # Try to locate tool using the code snippet 6875 for ac_prog in date 6876 do 6877 # Extract the first word of "$ac_prog", so it can be a program name with args. 6878 set dummy $ac_prog; ac_word=$2 6879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6880 $as_echo_n "checking for $ac_word... " >&6; } 6881 if ${ac_cv_path_DATE+:} false; then : 6882 $as_echo_n "(cached) " >&6 6883 else 6884 case $DATE in 6885 [\\/]* | ?:[\\/]*) 6886 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6887 ;; 6888 *) 6889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6890 for as_dir in $PATH 6891 do 6892 IFS=$as_save_IFS 6893 test -z "$as_dir" && as_dir=. 6894 for ac_exec_ext in '' $ac_executable_extensions; do 6895 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6896 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6897 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6898 break 2 6899 fi 6900 done 6901 done 6902 IFS=$as_save_IFS 6903 6904 ;; 6905 esac 6906 fi 6907 DATE=$ac_cv_path_DATE 6908 if test -n "$DATE"; then 6909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6910 $as_echo "$DATE" >&6; } 6911 else 6912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6913 $as_echo "no" >&6; } 6914 fi 6915 6916 6917 test -n "$DATE" && break 6918 done 6919 6920 else 6921 # If it succeeded, then it was overridden by the user. We will use it 6922 # for the tool. 6923 6924 # First remove it from the list of overridden variables, so we can test 6925 # for unknown variables in the end. 6926 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6927 6928 # Check if we try to supply an empty value 6929 if test "x$DATE" = x; then 6930 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6931 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6933 $as_echo_n "checking for DATE... " >&6; } 6934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6935 $as_echo "disabled" >&6; } 6936 else 6937 # Check if the provided tool contains a complete path. 6938 tool_specified="$DATE" 6939 tool_basename="${tool_specified##*/}" 6940 if test "x$tool_basename" = "x$tool_specified"; then 6941 # A command without a complete path is provided, search $PATH. 6942 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 6943 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 6944 # Extract the first word of "$tool_basename", so it can be a program name with args. 6945 set dummy $tool_basename; ac_word=$2 6946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6947 $as_echo_n "checking for $ac_word... " >&6; } 6948 if ${ac_cv_path_DATE+:} false; then : 6949 $as_echo_n "(cached) " >&6 6950 else 6951 case $DATE in 6952 [\\/]* | ?:[\\/]*) 6953 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6954 ;; 6955 *) 6956 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6957 for as_dir in $PATH 6958 do 6959 IFS=$as_save_IFS 6960 test -z "$as_dir" && as_dir=. 6961 for ac_exec_ext in '' $ac_executable_extensions; do 6962 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6963 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6964 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6965 break 2 6966 fi 6967 done 6968 done 6969 IFS=$as_save_IFS 6970 6971 ;; 6972 esac 6973 fi 6974 DATE=$ac_cv_path_DATE 6975 if test -n "$DATE"; then 6976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6977 $as_echo "$DATE" >&6; } 6978 else 6979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6980 $as_echo "no" >&6; } 6981 fi 6982 6983 6984 if test "x$DATE" = x; then 6985 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6986 fi 6987 else 6988 # Otherwise we believe it is a complete path. Use it as it is. 6989 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 6990 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 6991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6992 $as_echo_n "checking for DATE... " >&6; } 6993 if test ! -x "$tool_specified"; then 6994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6995 $as_echo "not found" >&6; } 6996 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 6997 fi 6998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6999 $as_echo "$tool_specified" >&6; } 7000 fi 7001 fi 7002 fi 7003 7004 fi 7005 7006 7007 7008 if test "x$DATE" = x; then 7009 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 7010 fi 7011 7012 7013 7014 7015 7016 # Publish this variable in the help. 7017 7018 7019 if [ -z "${DIFF+x}" ]; then 7020 # The variable is not set by user, try to locate tool using the code snippet 7021 for ac_prog in gdiff diff 7022 do 7023 # Extract the first word of "$ac_prog", so it can be a program name with args. 7024 set dummy $ac_prog; ac_word=$2 7025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7026 $as_echo_n "checking for $ac_word... " >&6; } 7027 if ${ac_cv_path_DIFF+:} false; then : 7028 $as_echo_n "(cached) " >&6 7029 else 7030 case $DIFF in 7031 [\\/]* | ?:[\\/]*) 7032 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7033 ;; 7034 *) 7035 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7036 for as_dir in $PATH 7037 do 7038 IFS=$as_save_IFS 7039 test -z "$as_dir" && as_dir=. 7040 for ac_exec_ext in '' $ac_executable_extensions; do 7041 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7042 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7043 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7044 break 2 7045 fi 7046 done 7047 done 7048 IFS=$as_save_IFS 7049 7050 ;; 7051 esac 7052 fi 7053 DIFF=$ac_cv_path_DIFF 7054 if test -n "$DIFF"; then 7055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7056 $as_echo "$DIFF" >&6; } 7057 else 7058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7059 $as_echo "no" >&6; } 7060 fi 7061 7062 7063 test -n "$DIFF" && break 7064 done 7065 7066 else 7067 # The variable is set, but is it from the command line or the environment? 7068 7069 # Try to remove the string !DIFF! from our list. 7070 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7071 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7072 # If it failed, the variable was not from the command line. Ignore it, 7073 # but warn the user (except for BASH, which is always set by the calling BASH). 7074 if test "xDIFF" != xBASH; then 7075 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7076 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7077 fi 7078 # Try to locate tool using the code snippet 7079 for ac_prog in gdiff diff 7080 do 7081 # Extract the first word of "$ac_prog", so it can be a program name with args. 7082 set dummy $ac_prog; ac_word=$2 7083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7084 $as_echo_n "checking for $ac_word... " >&6; } 7085 if ${ac_cv_path_DIFF+:} false; then : 7086 $as_echo_n "(cached) " >&6 7087 else 7088 case $DIFF in 7089 [\\/]* | ?:[\\/]*) 7090 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7091 ;; 7092 *) 7093 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7094 for as_dir in $PATH 7095 do 7096 IFS=$as_save_IFS 7097 test -z "$as_dir" && as_dir=. 7098 for ac_exec_ext in '' $ac_executable_extensions; do 7099 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7100 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7101 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7102 break 2 7103 fi 7104 done 7105 done 7106 IFS=$as_save_IFS 7107 7108 ;; 7109 esac 7110 fi 7111 DIFF=$ac_cv_path_DIFF 7112 if test -n "$DIFF"; then 7113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7114 $as_echo "$DIFF" >&6; } 7115 else 7116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7117 $as_echo "no" >&6; } 7118 fi 7119 7120 7121 test -n "$DIFF" && break 7122 done 7123 7124 else 7125 # If it succeeded, then it was overridden by the user. We will use it 7126 # for the tool. 7127 7128 # First remove it from the list of overridden variables, so we can test 7129 # for unknown variables in the end. 7130 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7131 7132 # Check if we try to supply an empty value 7133 if test "x$DIFF" = x; then 7134 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7135 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7137 $as_echo_n "checking for DIFF... " >&6; } 7138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7139 $as_echo "disabled" >&6; } 7140 else 7141 # Check if the provided tool contains a complete path. 7142 tool_specified="$DIFF" 7143 tool_basename="${tool_specified##*/}" 7144 if test "x$tool_basename" = "x$tool_specified"; then 7145 # A command without a complete path is provided, search $PATH. 7146 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7147 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7148 # Extract the first word of "$tool_basename", so it can be a program name with args. 7149 set dummy $tool_basename; ac_word=$2 7150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7151 $as_echo_n "checking for $ac_word... " >&6; } 7152 if ${ac_cv_path_DIFF+:} false; then : 7153 $as_echo_n "(cached) " >&6 7154 else 7155 case $DIFF in 7156 [\\/]* | ?:[\\/]*) 7157 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7158 ;; 7159 *) 7160 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7161 for as_dir in $PATH 7162 do 7163 IFS=$as_save_IFS 7164 test -z "$as_dir" && as_dir=. 7165 for ac_exec_ext in '' $ac_executable_extensions; do 7166 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7167 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7168 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7169 break 2 7170 fi 7171 done 7172 done 7173 IFS=$as_save_IFS 7174 7175 ;; 7176 esac 7177 fi 7178 DIFF=$ac_cv_path_DIFF 7179 if test -n "$DIFF"; then 7180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7181 $as_echo "$DIFF" >&6; } 7182 else 7183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7184 $as_echo "no" >&6; } 7185 fi 7186 7187 7188 if test "x$DIFF" = x; then 7189 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7190 fi 7191 else 7192 # Otherwise we believe it is a complete path. Use it as it is. 7193 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7194 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7196 $as_echo_n "checking for DIFF... " >&6; } 7197 if test ! -x "$tool_specified"; then 7198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7199 $as_echo "not found" >&6; } 7200 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7201 fi 7202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7203 $as_echo "$tool_specified" >&6; } 7204 fi 7205 fi 7206 fi 7207 7208 fi 7209 7210 7211 7212 if test "x$DIFF" = x; then 7213 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7214 fi 7215 7216 7217 7218 7219 7220 # Publish this variable in the help. 7221 7222 7223 if [ -z "${DIRNAME+x}" ]; then 7224 # The variable is not set by user, try to locate tool using the code snippet 7225 for ac_prog in dirname 7226 do 7227 # Extract the first word of "$ac_prog", so it can be a program name with args. 7228 set dummy $ac_prog; ac_word=$2 7229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7230 $as_echo_n "checking for $ac_word... " >&6; } 7231 if ${ac_cv_path_DIRNAME+:} false; then : 7232 $as_echo_n "(cached) " >&6 7233 else 7234 case $DIRNAME in 7235 [\\/]* | ?:[\\/]*) 7236 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7237 ;; 7238 *) 7239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7240 for as_dir in $PATH 7241 do 7242 IFS=$as_save_IFS 7243 test -z "$as_dir" && as_dir=. 7244 for ac_exec_ext in '' $ac_executable_extensions; do 7245 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7246 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7247 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7248 break 2 7249 fi 7250 done 7251 done 7252 IFS=$as_save_IFS 7253 7254 ;; 7255 esac 7256 fi 7257 DIRNAME=$ac_cv_path_DIRNAME 7258 if test -n "$DIRNAME"; then 7259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7260 $as_echo "$DIRNAME" >&6; } 7261 else 7262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7263 $as_echo "no" >&6; } 7264 fi 7265 7266 7267 test -n "$DIRNAME" && break 7268 done 7269 7270 else 7271 # The variable is set, but is it from the command line or the environment? 7272 7273 # Try to remove the string !DIRNAME! from our list. 7274 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7275 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7276 # If it failed, the variable was not from the command line. Ignore it, 7277 # but warn the user (except for BASH, which is always set by the calling BASH). 7278 if test "xDIRNAME" != xBASH; then 7279 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7280 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7281 fi 7282 # Try to locate tool using the code snippet 7283 for ac_prog in dirname 7284 do 7285 # Extract the first word of "$ac_prog", so it can be a program name with args. 7286 set dummy $ac_prog; ac_word=$2 7287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7288 $as_echo_n "checking for $ac_word... " >&6; } 7289 if ${ac_cv_path_DIRNAME+:} false; then : 7290 $as_echo_n "(cached) " >&6 7291 else 7292 case $DIRNAME in 7293 [\\/]* | ?:[\\/]*) 7294 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7295 ;; 7296 *) 7297 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7298 for as_dir in $PATH 7299 do 7300 IFS=$as_save_IFS 7301 test -z "$as_dir" && as_dir=. 7302 for ac_exec_ext in '' $ac_executable_extensions; do 7303 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7304 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7305 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7306 break 2 7307 fi 7308 done 7309 done 7310 IFS=$as_save_IFS 7311 7312 ;; 7313 esac 7314 fi 7315 DIRNAME=$ac_cv_path_DIRNAME 7316 if test -n "$DIRNAME"; then 7317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7318 $as_echo "$DIRNAME" >&6; } 7319 else 7320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7321 $as_echo "no" >&6; } 7322 fi 7323 7324 7325 test -n "$DIRNAME" && break 7326 done 7327 7328 else 7329 # If it succeeded, then it was overridden by the user. We will use it 7330 # for the tool. 7331 7332 # First remove it from the list of overridden variables, so we can test 7333 # for unknown variables in the end. 7334 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7335 7336 # Check if we try to supply an empty value 7337 if test "x$DIRNAME" = x; then 7338 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7339 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7341 $as_echo_n "checking for DIRNAME... " >&6; } 7342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7343 $as_echo "disabled" >&6; } 7344 else 7345 # Check if the provided tool contains a complete path. 7346 tool_specified="$DIRNAME" 7347 tool_basename="${tool_specified##*/}" 7348 if test "x$tool_basename" = "x$tool_specified"; then 7349 # A command without a complete path is provided, search $PATH. 7350 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7351 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7352 # Extract the first word of "$tool_basename", so it can be a program name with args. 7353 set dummy $tool_basename; ac_word=$2 7354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7355 $as_echo_n "checking for $ac_word... " >&6; } 7356 if ${ac_cv_path_DIRNAME+:} false; then : 7357 $as_echo_n "(cached) " >&6 7358 else 7359 case $DIRNAME in 7360 [\\/]* | ?:[\\/]*) 7361 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7362 ;; 7363 *) 7364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7365 for as_dir in $PATH 7366 do 7367 IFS=$as_save_IFS 7368 test -z "$as_dir" && as_dir=. 7369 for ac_exec_ext in '' $ac_executable_extensions; do 7370 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7371 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7372 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7373 break 2 7374 fi 7375 done 7376 done 7377 IFS=$as_save_IFS 7378 7379 ;; 7380 esac 7381 fi 7382 DIRNAME=$ac_cv_path_DIRNAME 7383 if test -n "$DIRNAME"; then 7384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7385 $as_echo "$DIRNAME" >&6; } 7386 else 7387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7388 $as_echo "no" >&6; } 7389 fi 7390 7391 7392 if test "x$DIRNAME" = x; then 7393 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7394 fi 7395 else 7396 # Otherwise we believe it is a complete path. Use it as it is. 7397 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7398 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7400 $as_echo_n "checking for DIRNAME... " >&6; } 7401 if test ! -x "$tool_specified"; then 7402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7403 $as_echo "not found" >&6; } 7404 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7405 fi 7406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7407 $as_echo "$tool_specified" >&6; } 7408 fi 7409 fi 7410 fi 7411 7412 fi 7413 7414 7415 7416 if test "x$DIRNAME" = x; then 7417 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7418 fi 7419 7420 7421 7422 7423 7424 # Publish this variable in the help. 7425 7426 7427 if [ -z "${ECHO+x}" ]; then 7428 # The variable is not set by user, try to locate tool using the code snippet 7429 for ac_prog in echo 7430 do 7431 # Extract the first word of "$ac_prog", so it can be a program name with args. 7432 set dummy $ac_prog; ac_word=$2 7433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7434 $as_echo_n "checking for $ac_word... " >&6; } 7435 if ${ac_cv_path_ECHO+:} false; then : 7436 $as_echo_n "(cached) " >&6 7437 else 7438 case $ECHO in 7439 [\\/]* | ?:[\\/]*) 7440 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7441 ;; 7442 *) 7443 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7444 for as_dir in $PATH 7445 do 7446 IFS=$as_save_IFS 7447 test -z "$as_dir" && as_dir=. 7448 for ac_exec_ext in '' $ac_executable_extensions; do 7449 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7450 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7451 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7452 break 2 7453 fi 7454 done 7455 done 7456 IFS=$as_save_IFS 7457 7458 ;; 7459 esac 7460 fi 7461 ECHO=$ac_cv_path_ECHO 7462 if test -n "$ECHO"; then 7463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7464 $as_echo "$ECHO" >&6; } 7465 else 7466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7467 $as_echo "no" >&6; } 7468 fi 7469 7470 7471 test -n "$ECHO" && break 7472 done 7473 7474 else 7475 # The variable is set, but is it from the command line or the environment? 7476 7477 # Try to remove the string !ECHO! from our list. 7478 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7479 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7480 # If it failed, the variable was not from the command line. Ignore it, 7481 # but warn the user (except for BASH, which is always set by the calling BASH). 7482 if test "xECHO" != xBASH; then 7483 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7484 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7485 fi 7486 # Try to locate tool using the code snippet 7487 for ac_prog in echo 7488 do 7489 # Extract the first word of "$ac_prog", so it can be a program name with args. 7490 set dummy $ac_prog; ac_word=$2 7491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7492 $as_echo_n "checking for $ac_word... " >&6; } 7493 if ${ac_cv_path_ECHO+:} false; then : 7494 $as_echo_n "(cached) " >&6 7495 else 7496 case $ECHO in 7497 [\\/]* | ?:[\\/]*) 7498 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7499 ;; 7500 *) 7501 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7502 for as_dir in $PATH 7503 do 7504 IFS=$as_save_IFS 7505 test -z "$as_dir" && as_dir=. 7506 for ac_exec_ext in '' $ac_executable_extensions; do 7507 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7508 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7509 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7510 break 2 7511 fi 7512 done 7513 done 7514 IFS=$as_save_IFS 7515 7516 ;; 7517 esac 7518 fi 7519 ECHO=$ac_cv_path_ECHO 7520 if test -n "$ECHO"; then 7521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7522 $as_echo "$ECHO" >&6; } 7523 else 7524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7525 $as_echo "no" >&6; } 7526 fi 7527 7528 7529 test -n "$ECHO" && break 7530 done 7531 7532 else 7533 # If it succeeded, then it was overridden by the user. We will use it 7534 # for the tool. 7535 7536 # First remove it from the list of overridden variables, so we can test 7537 # for unknown variables in the end. 7538 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7539 7540 # Check if we try to supply an empty value 7541 if test "x$ECHO" = x; then 7542 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7543 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7545 $as_echo_n "checking for ECHO... " >&6; } 7546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7547 $as_echo "disabled" >&6; } 7548 else 7549 # Check if the provided tool contains a complete path. 7550 tool_specified="$ECHO" 7551 tool_basename="${tool_specified##*/}" 7552 if test "x$tool_basename" = "x$tool_specified"; then 7553 # A command without a complete path is provided, search $PATH. 7554 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7555 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7556 # Extract the first word of "$tool_basename", so it can be a program name with args. 7557 set dummy $tool_basename; ac_word=$2 7558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7559 $as_echo_n "checking for $ac_word... " >&6; } 7560 if ${ac_cv_path_ECHO+:} false; then : 7561 $as_echo_n "(cached) " >&6 7562 else 7563 case $ECHO in 7564 [\\/]* | ?:[\\/]*) 7565 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7566 ;; 7567 *) 7568 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7569 for as_dir in $PATH 7570 do 7571 IFS=$as_save_IFS 7572 test -z "$as_dir" && as_dir=. 7573 for ac_exec_ext in '' $ac_executable_extensions; do 7574 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7575 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7576 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7577 break 2 7578 fi 7579 done 7580 done 7581 IFS=$as_save_IFS 7582 7583 ;; 7584 esac 7585 fi 7586 ECHO=$ac_cv_path_ECHO 7587 if test -n "$ECHO"; then 7588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7589 $as_echo "$ECHO" >&6; } 7590 else 7591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7592 $as_echo "no" >&6; } 7593 fi 7594 7595 7596 if test "x$ECHO" = x; then 7597 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7598 fi 7599 else 7600 # Otherwise we believe it is a complete path. Use it as it is. 7601 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7602 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7604 $as_echo_n "checking for ECHO... " >&6; } 7605 if test ! -x "$tool_specified"; then 7606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7607 $as_echo "not found" >&6; } 7608 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7609 fi 7610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7611 $as_echo "$tool_specified" >&6; } 7612 fi 7613 fi 7614 fi 7615 7616 fi 7617 7618 7619 7620 if test "x$ECHO" = x; then 7621 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7622 fi 7623 7624 7625 7626 7627 7628 # Publish this variable in the help. 7629 7630 7631 if [ -z "${EXPR+x}" ]; then 7632 # The variable is not set by user, try to locate tool using the code snippet 7633 for ac_prog in expr 7634 do 7635 # Extract the first word of "$ac_prog", so it can be a program name with args. 7636 set dummy $ac_prog; ac_word=$2 7637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7638 $as_echo_n "checking for $ac_word... " >&6; } 7639 if ${ac_cv_path_EXPR+:} false; then : 7640 $as_echo_n "(cached) " >&6 7641 else 7642 case $EXPR in 7643 [\\/]* | ?:[\\/]*) 7644 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7645 ;; 7646 *) 7647 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7648 for as_dir in $PATH 7649 do 7650 IFS=$as_save_IFS 7651 test -z "$as_dir" && as_dir=. 7652 for ac_exec_ext in '' $ac_executable_extensions; do 7653 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7654 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7655 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7656 break 2 7657 fi 7658 done 7659 done 7660 IFS=$as_save_IFS 7661 7662 ;; 7663 esac 7664 fi 7665 EXPR=$ac_cv_path_EXPR 7666 if test -n "$EXPR"; then 7667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7668 $as_echo "$EXPR" >&6; } 7669 else 7670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7671 $as_echo "no" >&6; } 7672 fi 7673 7674 7675 test -n "$EXPR" && break 7676 done 7677 7678 else 7679 # The variable is set, but is it from the command line or the environment? 7680 7681 # Try to remove the string !EXPR! from our list. 7682 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7683 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7684 # If it failed, the variable was not from the command line. Ignore it, 7685 # but warn the user (except for BASH, which is always set by the calling BASH). 7686 if test "xEXPR" != xBASH; then 7687 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7688 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7689 fi 7690 # Try to locate tool using the code snippet 7691 for ac_prog in expr 7692 do 7693 # Extract the first word of "$ac_prog", so it can be a program name with args. 7694 set dummy $ac_prog; ac_word=$2 7695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7696 $as_echo_n "checking for $ac_word... " >&6; } 7697 if ${ac_cv_path_EXPR+:} false; then : 7698 $as_echo_n "(cached) " >&6 7699 else 7700 case $EXPR in 7701 [\\/]* | ?:[\\/]*) 7702 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7703 ;; 7704 *) 7705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7706 for as_dir in $PATH 7707 do 7708 IFS=$as_save_IFS 7709 test -z "$as_dir" && as_dir=. 7710 for ac_exec_ext in '' $ac_executable_extensions; do 7711 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7712 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7713 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7714 break 2 7715 fi 7716 done 7717 done 7718 IFS=$as_save_IFS 7719 7720 ;; 7721 esac 7722 fi 7723 EXPR=$ac_cv_path_EXPR 7724 if test -n "$EXPR"; then 7725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7726 $as_echo "$EXPR" >&6; } 7727 else 7728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7729 $as_echo "no" >&6; } 7730 fi 7731 7732 7733 test -n "$EXPR" && break 7734 done 7735 7736 else 7737 # If it succeeded, then it was overridden by the user. We will use it 7738 # for the tool. 7739 7740 # First remove it from the list of overridden variables, so we can test 7741 # for unknown variables in the end. 7742 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7743 7744 # Check if we try to supply an empty value 7745 if test "x$EXPR" = x; then 7746 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7747 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7749 $as_echo_n "checking for EXPR... " >&6; } 7750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7751 $as_echo "disabled" >&6; } 7752 else 7753 # Check if the provided tool contains a complete path. 7754 tool_specified="$EXPR" 7755 tool_basename="${tool_specified##*/}" 7756 if test "x$tool_basename" = "x$tool_specified"; then 7757 # A command without a complete path is provided, search $PATH. 7758 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7759 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7760 # Extract the first word of "$tool_basename", so it can be a program name with args. 7761 set dummy $tool_basename; ac_word=$2 7762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7763 $as_echo_n "checking for $ac_word... " >&6; } 7764 if ${ac_cv_path_EXPR+:} false; then : 7765 $as_echo_n "(cached) " >&6 7766 else 7767 case $EXPR in 7768 [\\/]* | ?:[\\/]*) 7769 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7770 ;; 7771 *) 7772 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7773 for as_dir in $PATH 7774 do 7775 IFS=$as_save_IFS 7776 test -z "$as_dir" && as_dir=. 7777 for ac_exec_ext in '' $ac_executable_extensions; do 7778 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7779 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7780 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7781 break 2 7782 fi 7783 done 7784 done 7785 IFS=$as_save_IFS 7786 7787 ;; 7788 esac 7789 fi 7790 EXPR=$ac_cv_path_EXPR 7791 if test -n "$EXPR"; then 7792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7793 $as_echo "$EXPR" >&6; } 7794 else 7795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7796 $as_echo "no" >&6; } 7797 fi 7798 7799 7800 if test "x$EXPR" = x; then 7801 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7802 fi 7803 else 7804 # Otherwise we believe it is a complete path. Use it as it is. 7805 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7806 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7808 $as_echo_n "checking for EXPR... " >&6; } 7809 if test ! -x "$tool_specified"; then 7810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7811 $as_echo "not found" >&6; } 7812 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7813 fi 7814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7815 $as_echo "$tool_specified" >&6; } 7816 fi 7817 fi 7818 fi 7819 7820 fi 7821 7822 7823 7824 if test "x$EXPR" = x; then 7825 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7826 fi 7827 7828 7829 7830 7831 7832 # Publish this variable in the help. 7833 7834 7835 if [ -z "${FILE+x}" ]; then 7836 # The variable is not set by user, try to locate tool using the code snippet 7837 for ac_prog in file 7838 do 7839 # Extract the first word of "$ac_prog", so it can be a program name with args. 7840 set dummy $ac_prog; ac_word=$2 7841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7842 $as_echo_n "checking for $ac_word... " >&6; } 7843 if ${ac_cv_path_FILE+:} false; then : 7844 $as_echo_n "(cached) " >&6 7845 else 7846 case $FILE in 7847 [\\/]* | ?:[\\/]*) 7848 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7849 ;; 7850 *) 7851 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7852 for as_dir in $PATH 7853 do 7854 IFS=$as_save_IFS 7855 test -z "$as_dir" && as_dir=. 7856 for ac_exec_ext in '' $ac_executable_extensions; do 7857 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7858 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7859 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7860 break 2 7861 fi 7862 done 7863 done 7864 IFS=$as_save_IFS 7865 7866 ;; 7867 esac 7868 fi 7869 FILE=$ac_cv_path_FILE 7870 if test -n "$FILE"; then 7871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7872 $as_echo "$FILE" >&6; } 7873 else 7874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7875 $as_echo "no" >&6; } 7876 fi 7877 7878 7879 test -n "$FILE" && break 7880 done 7881 7882 else 7883 # The variable is set, but is it from the command line or the environment? 7884 7885 # Try to remove the string !FILE! from our list. 7886 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7887 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7888 # If it failed, the variable was not from the command line. Ignore it, 7889 # but warn the user (except for BASH, which is always set by the calling BASH). 7890 if test "xFILE" != xBASH; then 7891 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7892 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7893 fi 7894 # Try to locate tool using the code snippet 7895 for ac_prog in file 7896 do 7897 # Extract the first word of "$ac_prog", so it can be a program name with args. 7898 set dummy $ac_prog; ac_word=$2 7899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7900 $as_echo_n "checking for $ac_word... " >&6; } 7901 if ${ac_cv_path_FILE+:} false; then : 7902 $as_echo_n "(cached) " >&6 7903 else 7904 case $FILE in 7905 [\\/]* | ?:[\\/]*) 7906 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7907 ;; 7908 *) 7909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7910 for as_dir in $PATH 7911 do 7912 IFS=$as_save_IFS 7913 test -z "$as_dir" && as_dir=. 7914 for ac_exec_ext in '' $ac_executable_extensions; do 7915 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7916 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7917 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7918 break 2 7919 fi 7920 done 7921 done 7922 IFS=$as_save_IFS 7923 7924 ;; 7925 esac 7926 fi 7927 FILE=$ac_cv_path_FILE 7928 if test -n "$FILE"; then 7929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7930 $as_echo "$FILE" >&6; } 7931 else 7932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7933 $as_echo "no" >&6; } 7934 fi 7935 7936 7937 test -n "$FILE" && break 7938 done 7939 7940 else 7941 # If it succeeded, then it was overridden by the user. We will use it 7942 # for the tool. 7943 7944 # First remove it from the list of overridden variables, so we can test 7945 # for unknown variables in the end. 7946 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7947 7948 # Check if we try to supply an empty value 7949 if test "x$FILE" = x; then 7950 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 7951 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 7952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7953 $as_echo_n "checking for FILE... " >&6; } 7954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7955 $as_echo "disabled" >&6; } 7956 else 7957 # Check if the provided tool contains a complete path. 7958 tool_specified="$FILE" 7959 tool_basename="${tool_specified##*/}" 7960 if test "x$tool_basename" = "x$tool_specified"; then 7961 # A command without a complete path is provided, search $PATH. 7962 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 7963 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 7964 # Extract the first word of "$tool_basename", so it can be a program name with args. 7965 set dummy $tool_basename; ac_word=$2 7966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7967 $as_echo_n "checking for $ac_word... " >&6; } 7968 if ${ac_cv_path_FILE+:} false; then : 7969 $as_echo_n "(cached) " >&6 7970 else 7971 case $FILE in 7972 [\\/]* | ?:[\\/]*) 7973 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7974 ;; 7975 *) 7976 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7977 for as_dir in $PATH 7978 do 7979 IFS=$as_save_IFS 7980 test -z "$as_dir" && as_dir=. 7981 for ac_exec_ext in '' $ac_executable_extensions; do 7982 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7983 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7984 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7985 break 2 7986 fi 7987 done 7988 done 7989 IFS=$as_save_IFS 7990 7991 ;; 7992 esac 7993 fi 7994 FILE=$ac_cv_path_FILE 7995 if test -n "$FILE"; then 7996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7997 $as_echo "$FILE" >&6; } 7998 else 7999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8000 $as_echo "no" >&6; } 8001 fi 8002 8003 8004 if test "x$FILE" = x; then 8005 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8006 fi 8007 else 8008 # Otherwise we believe it is a complete path. Use it as it is. 8009 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 8010 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 8011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 8012 $as_echo_n "checking for FILE... " >&6; } 8013 if test ! -x "$tool_specified"; then 8014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8015 $as_echo "not found" >&6; } 8016 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 8017 fi 8018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8019 $as_echo "$tool_specified" >&6; } 8020 fi 8021 fi 8022 fi 8023 8024 fi 8025 8026 8027 8028 if test "x$FILE" = x; then 8029 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8030 fi 8031 8032 8033 8034 8035 8036 # Publish this variable in the help. 8037 8038 8039 if [ -z "${FIND+x}" ]; then 8040 # The variable is not set by user, try to locate tool using the code snippet 8041 for ac_prog in find 8042 do 8043 # Extract the first word of "$ac_prog", so it can be a program name with args. 8044 set dummy $ac_prog; ac_word=$2 8045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8046 $as_echo_n "checking for $ac_word... " >&6; } 8047 if ${ac_cv_path_FIND+:} false; then : 8048 $as_echo_n "(cached) " >&6 8049 else 8050 case $FIND in 8051 [\\/]* | ?:[\\/]*) 8052 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8053 ;; 8054 *) 8055 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8056 for as_dir in $PATH 8057 do 8058 IFS=$as_save_IFS 8059 test -z "$as_dir" && as_dir=. 8060 for ac_exec_ext in '' $ac_executable_extensions; do 8061 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8062 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8063 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8064 break 2 8065 fi 8066 done 8067 done 8068 IFS=$as_save_IFS 8069 8070 ;; 8071 esac 8072 fi 8073 FIND=$ac_cv_path_FIND 8074 if test -n "$FIND"; then 8075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8076 $as_echo "$FIND" >&6; } 8077 else 8078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8079 $as_echo "no" >&6; } 8080 fi 8081 8082 8083 test -n "$FIND" && break 8084 done 8085 8086 else 8087 # The variable is set, but is it from the command line or the environment? 8088 8089 # Try to remove the string !FIND! from our list. 8090 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8091 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8092 # If it failed, the variable was not from the command line. Ignore it, 8093 # but warn the user (except for BASH, which is always set by the calling BASH). 8094 if test "xFIND" != xBASH; then 8095 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8096 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8097 fi 8098 # Try to locate tool using the code snippet 8099 for ac_prog in find 8100 do 8101 # Extract the first word of "$ac_prog", so it can be a program name with args. 8102 set dummy $ac_prog; ac_word=$2 8103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8104 $as_echo_n "checking for $ac_word... " >&6; } 8105 if ${ac_cv_path_FIND+:} false; then : 8106 $as_echo_n "(cached) " >&6 8107 else 8108 case $FIND in 8109 [\\/]* | ?:[\\/]*) 8110 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8111 ;; 8112 *) 8113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8114 for as_dir in $PATH 8115 do 8116 IFS=$as_save_IFS 8117 test -z "$as_dir" && as_dir=. 8118 for ac_exec_ext in '' $ac_executable_extensions; do 8119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8120 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8122 break 2 8123 fi 8124 done 8125 done 8126 IFS=$as_save_IFS 8127 8128 ;; 8129 esac 8130 fi 8131 FIND=$ac_cv_path_FIND 8132 if test -n "$FIND"; then 8133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8134 $as_echo "$FIND" >&6; } 8135 else 8136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8137 $as_echo "no" >&6; } 8138 fi 8139 8140 8141 test -n "$FIND" && break 8142 done 8143 8144 else 8145 # If it succeeded, then it was overridden by the user. We will use it 8146 # for the tool. 8147 8148 # First remove it from the list of overridden variables, so we can test 8149 # for unknown variables in the end. 8150 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8151 8152 # Check if we try to supply an empty value 8153 if test "x$FIND" = x; then 8154 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8155 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8157 $as_echo_n "checking for FIND... " >&6; } 8158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8159 $as_echo "disabled" >&6; } 8160 else 8161 # Check if the provided tool contains a complete path. 8162 tool_specified="$FIND" 8163 tool_basename="${tool_specified##*/}" 8164 if test "x$tool_basename" = "x$tool_specified"; then 8165 # A command without a complete path is provided, search $PATH. 8166 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8167 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8168 # Extract the first word of "$tool_basename", so it can be a program name with args. 8169 set dummy $tool_basename; ac_word=$2 8170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8171 $as_echo_n "checking for $ac_word... " >&6; } 8172 if ${ac_cv_path_FIND+:} false; then : 8173 $as_echo_n "(cached) " >&6 8174 else 8175 case $FIND in 8176 [\\/]* | ?:[\\/]*) 8177 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8178 ;; 8179 *) 8180 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8181 for as_dir in $PATH 8182 do 8183 IFS=$as_save_IFS 8184 test -z "$as_dir" && as_dir=. 8185 for ac_exec_ext in '' $ac_executable_extensions; do 8186 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8187 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8188 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8189 break 2 8190 fi 8191 done 8192 done 8193 IFS=$as_save_IFS 8194 8195 ;; 8196 esac 8197 fi 8198 FIND=$ac_cv_path_FIND 8199 if test -n "$FIND"; then 8200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8201 $as_echo "$FIND" >&6; } 8202 else 8203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8204 $as_echo "no" >&6; } 8205 fi 8206 8207 8208 if test "x$FIND" = x; then 8209 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8210 fi 8211 else 8212 # Otherwise we believe it is a complete path. Use it as it is. 8213 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8214 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8216 $as_echo_n "checking for FIND... " >&6; } 8217 if test ! -x "$tool_specified"; then 8218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8219 $as_echo "not found" >&6; } 8220 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8221 fi 8222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8223 $as_echo "$tool_specified" >&6; } 8224 fi 8225 fi 8226 fi 8227 8228 fi 8229 8230 8231 8232 if test "x$FIND" = x; then 8233 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8234 fi 8235 8236 8237 8238 8239 8240 # Publish this variable in the help. 8241 8242 8243 if [ -z "${HEAD+x}" ]; then 8244 # The variable is not set by user, try to locate tool using the code snippet 8245 for ac_prog in head 8246 do 8247 # Extract the first word of "$ac_prog", so it can be a program name with args. 8248 set dummy $ac_prog; ac_word=$2 8249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8250 $as_echo_n "checking for $ac_word... " >&6; } 8251 if ${ac_cv_path_HEAD+:} false; then : 8252 $as_echo_n "(cached) " >&6 8253 else 8254 case $HEAD in 8255 [\\/]* | ?:[\\/]*) 8256 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8257 ;; 8258 *) 8259 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8260 for as_dir in $PATH 8261 do 8262 IFS=$as_save_IFS 8263 test -z "$as_dir" && as_dir=. 8264 for ac_exec_ext in '' $ac_executable_extensions; do 8265 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8266 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8267 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8268 break 2 8269 fi 8270 done 8271 done 8272 IFS=$as_save_IFS 8273 8274 ;; 8275 esac 8276 fi 8277 HEAD=$ac_cv_path_HEAD 8278 if test -n "$HEAD"; then 8279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8280 $as_echo "$HEAD" >&6; } 8281 else 8282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8283 $as_echo "no" >&6; } 8284 fi 8285 8286 8287 test -n "$HEAD" && break 8288 done 8289 8290 else 8291 # The variable is set, but is it from the command line or the environment? 8292 8293 # Try to remove the string !HEAD! from our list. 8294 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8295 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8296 # If it failed, the variable was not from the command line. Ignore it, 8297 # but warn the user (except for BASH, which is always set by the calling BASH). 8298 if test "xHEAD" != xBASH; then 8299 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8300 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8301 fi 8302 # Try to locate tool using the code snippet 8303 for ac_prog in head 8304 do 8305 # Extract the first word of "$ac_prog", so it can be a program name with args. 8306 set dummy $ac_prog; ac_word=$2 8307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8308 $as_echo_n "checking for $ac_word... " >&6; } 8309 if ${ac_cv_path_HEAD+:} false; then : 8310 $as_echo_n "(cached) " >&6 8311 else 8312 case $HEAD in 8313 [\\/]* | ?:[\\/]*) 8314 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8315 ;; 8316 *) 8317 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8318 for as_dir in $PATH 8319 do 8320 IFS=$as_save_IFS 8321 test -z "$as_dir" && as_dir=. 8322 for ac_exec_ext in '' $ac_executable_extensions; do 8323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8324 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8326 break 2 8327 fi 8328 done 8329 done 8330 IFS=$as_save_IFS 8331 8332 ;; 8333 esac 8334 fi 8335 HEAD=$ac_cv_path_HEAD 8336 if test -n "$HEAD"; then 8337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8338 $as_echo "$HEAD" >&6; } 8339 else 8340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8341 $as_echo "no" >&6; } 8342 fi 8343 8344 8345 test -n "$HEAD" && break 8346 done 8347 8348 else 8349 # If it succeeded, then it was overridden by the user. We will use it 8350 # for the tool. 8351 8352 # First remove it from the list of overridden variables, so we can test 8353 # for unknown variables in the end. 8354 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8355 8356 # Check if we try to supply an empty value 8357 if test "x$HEAD" = x; then 8358 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8359 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8361 $as_echo_n "checking for HEAD... " >&6; } 8362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8363 $as_echo "disabled" >&6; } 8364 else 8365 # Check if the provided tool contains a complete path. 8366 tool_specified="$HEAD" 8367 tool_basename="${tool_specified##*/}" 8368 if test "x$tool_basename" = "x$tool_specified"; then 8369 # A command without a complete path is provided, search $PATH. 8370 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8371 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8372 # Extract the first word of "$tool_basename", so it can be a program name with args. 8373 set dummy $tool_basename; ac_word=$2 8374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8375 $as_echo_n "checking for $ac_word... " >&6; } 8376 if ${ac_cv_path_HEAD+:} false; then : 8377 $as_echo_n "(cached) " >&6 8378 else 8379 case $HEAD in 8380 [\\/]* | ?:[\\/]*) 8381 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8382 ;; 8383 *) 8384 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8385 for as_dir in $PATH 8386 do 8387 IFS=$as_save_IFS 8388 test -z "$as_dir" && as_dir=. 8389 for ac_exec_ext in '' $ac_executable_extensions; do 8390 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8391 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8392 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8393 break 2 8394 fi 8395 done 8396 done 8397 IFS=$as_save_IFS 8398 8399 ;; 8400 esac 8401 fi 8402 HEAD=$ac_cv_path_HEAD 8403 if test -n "$HEAD"; then 8404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8405 $as_echo "$HEAD" >&6; } 8406 else 8407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8408 $as_echo "no" >&6; } 8409 fi 8410 8411 8412 if test "x$HEAD" = x; then 8413 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8414 fi 8415 else 8416 # Otherwise we believe it is a complete path. Use it as it is. 8417 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8418 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8420 $as_echo_n "checking for HEAD... " >&6; } 8421 if test ! -x "$tool_specified"; then 8422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8423 $as_echo "not found" >&6; } 8424 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8425 fi 8426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8427 $as_echo "$tool_specified" >&6; } 8428 fi 8429 fi 8430 fi 8431 8432 fi 8433 8434 8435 8436 if test "x$HEAD" = x; then 8437 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8438 fi 8439 8440 8441 8442 8443 8444 # Publish this variable in the help. 8445 8446 8447 if [ -z "${GUNZIP+x}" ]; then 8448 # The variable is not set by user, try to locate tool using the code snippet 8449 for ac_prog in gunzip 8450 do 8451 # Extract the first word of "$ac_prog", so it can be a program name with args. 8452 set dummy $ac_prog; ac_word=$2 8453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8454 $as_echo_n "checking for $ac_word... " >&6; } 8455 if ${ac_cv_path_GUNZIP+:} false; then : 8456 $as_echo_n "(cached) " >&6 8457 else 8458 case $GUNZIP in 8459 [\\/]* | ?:[\\/]*) 8460 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8461 ;; 8462 *) 8463 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8464 for as_dir in $PATH 8465 do 8466 IFS=$as_save_IFS 8467 test -z "$as_dir" && as_dir=. 8468 for ac_exec_ext in '' $ac_executable_extensions; do 8469 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8470 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8471 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8472 break 2 8473 fi 8474 done 8475 done 8476 IFS=$as_save_IFS 8477 8478 ;; 8479 esac 8480 fi 8481 GUNZIP=$ac_cv_path_GUNZIP 8482 if test -n "$GUNZIP"; then 8483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8484 $as_echo "$GUNZIP" >&6; } 8485 else 8486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8487 $as_echo "no" >&6; } 8488 fi 8489 8490 8491 test -n "$GUNZIP" && break 8492 done 8493 8494 else 8495 # The variable is set, but is it from the command line or the environment? 8496 8497 # Try to remove the string !GUNZIP! from our list. 8498 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8499 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8500 # If it failed, the variable was not from the command line. Ignore it, 8501 # but warn the user (except for BASH, which is always set by the calling BASH). 8502 if test "xGUNZIP" != xBASH; then 8503 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8504 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8505 fi 8506 # Try to locate tool using the code snippet 8507 for ac_prog in gunzip 8508 do 8509 # Extract the first word of "$ac_prog", so it can be a program name with args. 8510 set dummy $ac_prog; ac_word=$2 8511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8512 $as_echo_n "checking for $ac_word... " >&6; } 8513 if ${ac_cv_path_GUNZIP+:} false; then : 8514 $as_echo_n "(cached) " >&6 8515 else 8516 case $GUNZIP in 8517 [\\/]* | ?:[\\/]*) 8518 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8519 ;; 8520 *) 8521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8522 for as_dir in $PATH 8523 do 8524 IFS=$as_save_IFS 8525 test -z "$as_dir" && as_dir=. 8526 for ac_exec_ext in '' $ac_executable_extensions; do 8527 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8528 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8529 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8530 break 2 8531 fi 8532 done 8533 done 8534 IFS=$as_save_IFS 8535 8536 ;; 8537 esac 8538 fi 8539 GUNZIP=$ac_cv_path_GUNZIP 8540 if test -n "$GUNZIP"; then 8541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8542 $as_echo "$GUNZIP" >&6; } 8543 else 8544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8545 $as_echo "no" >&6; } 8546 fi 8547 8548 8549 test -n "$GUNZIP" && break 8550 done 8551 8552 else 8553 # If it succeeded, then it was overridden by the user. We will use it 8554 # for the tool. 8555 8556 # First remove it from the list of overridden variables, so we can test 8557 # for unknown variables in the end. 8558 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8559 8560 # Check if we try to supply an empty value 8561 if test "x$GUNZIP" = x; then 8562 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8563 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8565 $as_echo_n "checking for GUNZIP... " >&6; } 8566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8567 $as_echo "disabled" >&6; } 8568 else 8569 # Check if the provided tool contains a complete path. 8570 tool_specified="$GUNZIP" 8571 tool_basename="${tool_specified##*/}" 8572 if test "x$tool_basename" = "x$tool_specified"; then 8573 # A command without a complete path is provided, search $PATH. 8574 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8575 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8576 # Extract the first word of "$tool_basename", so it can be a program name with args. 8577 set dummy $tool_basename; ac_word=$2 8578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8579 $as_echo_n "checking for $ac_word... " >&6; } 8580 if ${ac_cv_path_GUNZIP+:} false; then : 8581 $as_echo_n "(cached) " >&6 8582 else 8583 case $GUNZIP in 8584 [\\/]* | ?:[\\/]*) 8585 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8586 ;; 8587 *) 8588 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8589 for as_dir in $PATH 8590 do 8591 IFS=$as_save_IFS 8592 test -z "$as_dir" && as_dir=. 8593 for ac_exec_ext in '' $ac_executable_extensions; do 8594 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8595 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8596 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8597 break 2 8598 fi 8599 done 8600 done 8601 IFS=$as_save_IFS 8602 8603 ;; 8604 esac 8605 fi 8606 GUNZIP=$ac_cv_path_GUNZIP 8607 if test -n "$GUNZIP"; then 8608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8609 $as_echo "$GUNZIP" >&6; } 8610 else 8611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8612 $as_echo "no" >&6; } 8613 fi 8614 8615 8616 if test "x$GUNZIP" = x; then 8617 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8618 fi 8619 else 8620 # Otherwise we believe it is a complete path. Use it as it is. 8621 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8622 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8624 $as_echo_n "checking for GUNZIP... " >&6; } 8625 if test ! -x "$tool_specified"; then 8626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8627 $as_echo "not found" >&6; } 8628 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8629 fi 8630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8631 $as_echo "$tool_specified" >&6; } 8632 fi 8633 fi 8634 fi 8635 8636 fi 8637 8638 8639 8640 if test "x$GUNZIP" = x; then 8641 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8642 fi 8643 8644 8645 8646 8647 8648 # Publish this variable in the help. 8649 8650 8651 if [ -z "${GZIP+x}" ]; then 8652 # The variable is not set by user, try to locate tool using the code snippet 8653 for ac_prog in pigz gzip 8654 do 8655 # Extract the first word of "$ac_prog", so it can be a program name with args. 8656 set dummy $ac_prog; ac_word=$2 8657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8658 $as_echo_n "checking for $ac_word... " >&6; } 8659 if ${ac_cv_path_GZIP+:} false; then : 8660 $as_echo_n "(cached) " >&6 8661 else 8662 case $GZIP in 8663 [\\/]* | ?:[\\/]*) 8664 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8665 ;; 8666 *) 8667 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8668 for as_dir in $PATH 8669 do 8670 IFS=$as_save_IFS 8671 test -z "$as_dir" && as_dir=. 8672 for ac_exec_ext in '' $ac_executable_extensions; do 8673 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8674 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8675 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8676 break 2 8677 fi 8678 done 8679 done 8680 IFS=$as_save_IFS 8681 8682 ;; 8683 esac 8684 fi 8685 GZIP=$ac_cv_path_GZIP 8686 if test -n "$GZIP"; then 8687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8688 $as_echo "$GZIP" >&6; } 8689 else 8690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8691 $as_echo "no" >&6; } 8692 fi 8693 8694 8695 test -n "$GZIP" && break 8696 done 8697 8698 else 8699 # The variable is set, but is it from the command line or the environment? 8700 8701 # Try to remove the string !GZIP! from our list. 8702 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8703 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8704 # If it failed, the variable was not from the command line. Ignore it, 8705 # but warn the user (except for BASH, which is always set by the calling BASH). 8706 if test "xGZIP" != xBASH; then 8707 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8708 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8709 fi 8710 # Try to locate tool using the code snippet 8711 for ac_prog in pigz gzip 8712 do 8713 # Extract the first word of "$ac_prog", so it can be a program name with args. 8714 set dummy $ac_prog; ac_word=$2 8715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8716 $as_echo_n "checking for $ac_word... " >&6; } 8717 if ${ac_cv_path_GZIP+:} false; then : 8718 $as_echo_n "(cached) " >&6 8719 else 8720 case $GZIP in 8721 [\\/]* | ?:[\\/]*) 8722 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8723 ;; 8724 *) 8725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8726 for as_dir in $PATH 8727 do 8728 IFS=$as_save_IFS 8729 test -z "$as_dir" && as_dir=. 8730 for ac_exec_ext in '' $ac_executable_extensions; do 8731 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8732 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8733 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8734 break 2 8735 fi 8736 done 8737 done 8738 IFS=$as_save_IFS 8739 8740 ;; 8741 esac 8742 fi 8743 GZIP=$ac_cv_path_GZIP 8744 if test -n "$GZIP"; then 8745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8746 $as_echo "$GZIP" >&6; } 8747 else 8748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8749 $as_echo "no" >&6; } 8750 fi 8751 8752 8753 test -n "$GZIP" && break 8754 done 8755 8756 else 8757 # If it succeeded, then it was overridden by the user. We will use it 8758 # for the tool. 8759 8760 # First remove it from the list of overridden variables, so we can test 8761 # for unknown variables in the end. 8762 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8763 8764 # Check if we try to supply an empty value 8765 if test "x$GZIP" = x; then 8766 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8767 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8769 $as_echo_n "checking for GZIP... " >&6; } 8770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8771 $as_echo "disabled" >&6; } 8772 else 8773 # Check if the provided tool contains a complete path. 8774 tool_specified="$GZIP" 8775 tool_basename="${tool_specified##*/}" 8776 if test "x$tool_basename" = "x$tool_specified"; then 8777 # A command without a complete path is provided, search $PATH. 8778 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8779 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8780 # Extract the first word of "$tool_basename", so it can be a program name with args. 8781 set dummy $tool_basename; ac_word=$2 8782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8783 $as_echo_n "checking for $ac_word... " >&6; } 8784 if ${ac_cv_path_GZIP+:} false; then : 8785 $as_echo_n "(cached) " >&6 8786 else 8787 case $GZIP in 8788 [\\/]* | ?:[\\/]*) 8789 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8790 ;; 8791 *) 8792 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8793 for as_dir in $PATH 8794 do 8795 IFS=$as_save_IFS 8796 test -z "$as_dir" && as_dir=. 8797 for ac_exec_ext in '' $ac_executable_extensions; do 8798 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8799 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8800 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8801 break 2 8802 fi 8803 done 8804 done 8805 IFS=$as_save_IFS 8806 8807 ;; 8808 esac 8809 fi 8810 GZIP=$ac_cv_path_GZIP 8811 if test -n "$GZIP"; then 8812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8813 $as_echo "$GZIP" >&6; } 8814 else 8815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8816 $as_echo "no" >&6; } 8817 fi 8818 8819 8820 if test "x$GZIP" = x; then 8821 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8822 fi 8823 else 8824 # Otherwise we believe it is a complete path. Use it as it is. 8825 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8826 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8828 $as_echo_n "checking for GZIP... " >&6; } 8829 if test ! -x "$tool_specified"; then 8830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8831 $as_echo "not found" >&6; } 8832 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8833 fi 8834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8835 $as_echo "$tool_specified" >&6; } 8836 fi 8837 fi 8838 fi 8839 8840 fi 8841 8842 8843 8844 if test "x$GZIP" = x; then 8845 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8846 fi 8847 8848 8849 8850 8851 8852 # Publish this variable in the help. 8853 8854 8855 if [ -z "${LN+x}" ]; then 8856 # The variable is not set by user, try to locate tool using the code snippet 8857 for ac_prog in ln 8858 do 8859 # Extract the first word of "$ac_prog", so it can be a program name with args. 8860 set dummy $ac_prog; ac_word=$2 8861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8862 $as_echo_n "checking for $ac_word... " >&6; } 8863 if ${ac_cv_path_LN+:} false; then : 8864 $as_echo_n "(cached) " >&6 8865 else 8866 case $LN in 8867 [\\/]* | ?:[\\/]*) 8868 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8869 ;; 8870 *) 8871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8872 for as_dir in $PATH 8873 do 8874 IFS=$as_save_IFS 8875 test -z "$as_dir" && as_dir=. 8876 for ac_exec_ext in '' $ac_executable_extensions; do 8877 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8878 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8879 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8880 break 2 8881 fi 8882 done 8883 done 8884 IFS=$as_save_IFS 8885 8886 ;; 8887 esac 8888 fi 8889 LN=$ac_cv_path_LN 8890 if test -n "$LN"; then 8891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8892 $as_echo "$LN" >&6; } 8893 else 8894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8895 $as_echo "no" >&6; } 8896 fi 8897 8898 8899 test -n "$LN" && break 8900 done 8901 8902 else 8903 # The variable is set, but is it from the command line or the environment? 8904 8905 # Try to remove the string !LN! from our list. 8906 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8907 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8908 # If it failed, the variable was not from the command line. Ignore it, 8909 # but warn the user (except for BASH, which is always set by the calling BASH). 8910 if test "xLN" != xBASH; then 8911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8912 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8913 fi 8914 # Try to locate tool using the code snippet 8915 for ac_prog in ln 8916 do 8917 # Extract the first word of "$ac_prog", so it can be a program name with args. 8918 set dummy $ac_prog; ac_word=$2 8919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8920 $as_echo_n "checking for $ac_word... " >&6; } 8921 if ${ac_cv_path_LN+:} false; then : 8922 $as_echo_n "(cached) " >&6 8923 else 8924 case $LN in 8925 [\\/]* | ?:[\\/]*) 8926 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8927 ;; 8928 *) 8929 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8930 for as_dir in $PATH 8931 do 8932 IFS=$as_save_IFS 8933 test -z "$as_dir" && as_dir=. 8934 for ac_exec_ext in '' $ac_executable_extensions; do 8935 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8936 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8937 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8938 break 2 8939 fi 8940 done 8941 done 8942 IFS=$as_save_IFS 8943 8944 ;; 8945 esac 8946 fi 8947 LN=$ac_cv_path_LN 8948 if test -n "$LN"; then 8949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8950 $as_echo "$LN" >&6; } 8951 else 8952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8953 $as_echo "no" >&6; } 8954 fi 8955 8956 8957 test -n "$LN" && break 8958 done 8959 8960 else 8961 # If it succeeded, then it was overridden by the user. We will use it 8962 # for the tool. 8963 8964 # First remove it from the list of overridden variables, so we can test 8965 # for unknown variables in the end. 8966 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8967 8968 # Check if we try to supply an empty value 8969 if test "x$LN" = x; then 8970 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 8971 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 8972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8973 $as_echo_n "checking for LN... " >&6; } 8974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8975 $as_echo "disabled" >&6; } 8976 else 8977 # Check if the provided tool contains a complete path. 8978 tool_specified="$LN" 8979 tool_basename="${tool_specified##*/}" 8980 if test "x$tool_basename" = "x$tool_specified"; then 8981 # A command without a complete path is provided, search $PATH. 8982 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 8983 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 8984 # Extract the first word of "$tool_basename", so it can be a program name with args. 8985 set dummy $tool_basename; ac_word=$2 8986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8987 $as_echo_n "checking for $ac_word... " >&6; } 8988 if ${ac_cv_path_LN+:} false; then : 8989 $as_echo_n "(cached) " >&6 8990 else 8991 case $LN in 8992 [\\/]* | ?:[\\/]*) 8993 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8994 ;; 8995 *) 8996 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8997 for as_dir in $PATH 8998 do 8999 IFS=$as_save_IFS 9000 test -z "$as_dir" && as_dir=. 9001 for ac_exec_ext in '' $ac_executable_extensions; do 9002 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9003 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 9004 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9005 break 2 9006 fi 9007 done 9008 done 9009 IFS=$as_save_IFS 9010 9011 ;; 9012 esac 9013 fi 9014 LN=$ac_cv_path_LN 9015 if test -n "$LN"; then 9016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 9017 $as_echo "$LN" >&6; } 9018 else 9019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9020 $as_echo "no" >&6; } 9021 fi 9022 9023 9024 if test "x$LN" = x; then 9025 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9026 fi 9027 else 9028 # Otherwise we believe it is a complete path. Use it as it is. 9029 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9030 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9032 $as_echo_n "checking for LN... " >&6; } 9033 if test ! -x "$tool_specified"; then 9034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9035 $as_echo "not found" >&6; } 9036 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9037 fi 9038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9039 $as_echo "$tool_specified" >&6; } 9040 fi 9041 fi 9042 fi 9043 9044 fi 9045 9046 9047 9048 if test "x$LN" = x; then 9049 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9050 fi 9051 9052 9053 9054 9055 9056 # Publish this variable in the help. 9057 9058 9059 if [ -z "${LS+x}" ]; then 9060 # The variable is not set by user, try to locate tool using the code snippet 9061 for ac_prog in ls 9062 do 9063 # Extract the first word of "$ac_prog", so it can be a program name with args. 9064 set dummy $ac_prog; ac_word=$2 9065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9066 $as_echo_n "checking for $ac_word... " >&6; } 9067 if ${ac_cv_path_LS+:} false; then : 9068 $as_echo_n "(cached) " >&6 9069 else 9070 case $LS in 9071 [\\/]* | ?:[\\/]*) 9072 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9073 ;; 9074 *) 9075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9076 for as_dir in $PATH 9077 do 9078 IFS=$as_save_IFS 9079 test -z "$as_dir" && as_dir=. 9080 for ac_exec_ext in '' $ac_executable_extensions; do 9081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9082 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9084 break 2 9085 fi 9086 done 9087 done 9088 IFS=$as_save_IFS 9089 9090 ;; 9091 esac 9092 fi 9093 LS=$ac_cv_path_LS 9094 if test -n "$LS"; then 9095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9096 $as_echo "$LS" >&6; } 9097 else 9098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9099 $as_echo "no" >&6; } 9100 fi 9101 9102 9103 test -n "$LS" && break 9104 done 9105 9106 else 9107 # The variable is set, but is it from the command line or the environment? 9108 9109 # Try to remove the string !LS! from our list. 9110 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9111 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9112 # If it failed, the variable was not from the command line. Ignore it, 9113 # but warn the user (except for BASH, which is always set by the calling BASH). 9114 if test "xLS" != xBASH; then 9115 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9116 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9117 fi 9118 # Try to locate tool using the code snippet 9119 for ac_prog in ls 9120 do 9121 # Extract the first word of "$ac_prog", so it can be a program name with args. 9122 set dummy $ac_prog; ac_word=$2 9123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9124 $as_echo_n "checking for $ac_word... " >&6; } 9125 if ${ac_cv_path_LS+:} false; then : 9126 $as_echo_n "(cached) " >&6 9127 else 9128 case $LS in 9129 [\\/]* | ?:[\\/]*) 9130 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9131 ;; 9132 *) 9133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9134 for as_dir in $PATH 9135 do 9136 IFS=$as_save_IFS 9137 test -z "$as_dir" && as_dir=. 9138 for ac_exec_ext in '' $ac_executable_extensions; do 9139 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9140 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9142 break 2 9143 fi 9144 done 9145 done 9146 IFS=$as_save_IFS 9147 9148 ;; 9149 esac 9150 fi 9151 LS=$ac_cv_path_LS 9152 if test -n "$LS"; then 9153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9154 $as_echo "$LS" >&6; } 9155 else 9156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9157 $as_echo "no" >&6; } 9158 fi 9159 9160 9161 test -n "$LS" && break 9162 done 9163 9164 else 9165 # If it succeeded, then it was overridden by the user. We will use it 9166 # for the tool. 9167 9168 # First remove it from the list of overridden variables, so we can test 9169 # for unknown variables in the end. 9170 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9171 9172 # Check if we try to supply an empty value 9173 if test "x$LS" = x; then 9174 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9175 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9177 $as_echo_n "checking for LS... " >&6; } 9178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9179 $as_echo "disabled" >&6; } 9180 else 9181 # Check if the provided tool contains a complete path. 9182 tool_specified="$LS" 9183 tool_basename="${tool_specified##*/}" 9184 if test "x$tool_basename" = "x$tool_specified"; then 9185 # A command without a complete path is provided, search $PATH. 9186 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9187 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9188 # Extract the first word of "$tool_basename", so it can be a program name with args. 9189 set dummy $tool_basename; ac_word=$2 9190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9191 $as_echo_n "checking for $ac_word... " >&6; } 9192 if ${ac_cv_path_LS+:} false; then : 9193 $as_echo_n "(cached) " >&6 9194 else 9195 case $LS in 9196 [\\/]* | ?:[\\/]*) 9197 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9198 ;; 9199 *) 9200 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9201 for as_dir in $PATH 9202 do 9203 IFS=$as_save_IFS 9204 test -z "$as_dir" && as_dir=. 9205 for ac_exec_ext in '' $ac_executable_extensions; do 9206 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9207 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9208 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9209 break 2 9210 fi 9211 done 9212 done 9213 IFS=$as_save_IFS 9214 9215 ;; 9216 esac 9217 fi 9218 LS=$ac_cv_path_LS 9219 if test -n "$LS"; then 9220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9221 $as_echo "$LS" >&6; } 9222 else 9223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9224 $as_echo "no" >&6; } 9225 fi 9226 9227 9228 if test "x$LS" = x; then 9229 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9230 fi 9231 else 9232 # Otherwise we believe it is a complete path. Use it as it is. 9233 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9234 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9236 $as_echo_n "checking for LS... " >&6; } 9237 if test ! -x "$tool_specified"; then 9238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9239 $as_echo "not found" >&6; } 9240 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9241 fi 9242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9243 $as_echo "$tool_specified" >&6; } 9244 fi 9245 fi 9246 fi 9247 9248 fi 9249 9250 9251 9252 if test "x$LS" = x; then 9253 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9254 fi 9255 9256 9257 9258 9259 9260 # Publish this variable in the help. 9261 9262 9263 if [ -z "${MKDIR+x}" ]; then 9264 # The variable is not set by user, try to locate tool using the code snippet 9265 for ac_prog in mkdir 9266 do 9267 # Extract the first word of "$ac_prog", so it can be a program name with args. 9268 set dummy $ac_prog; ac_word=$2 9269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9270 $as_echo_n "checking for $ac_word... " >&6; } 9271 if ${ac_cv_path_MKDIR+:} false; then : 9272 $as_echo_n "(cached) " >&6 9273 else 9274 case $MKDIR in 9275 [\\/]* | ?:[\\/]*) 9276 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9277 ;; 9278 *) 9279 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9280 for as_dir in $PATH 9281 do 9282 IFS=$as_save_IFS 9283 test -z "$as_dir" && as_dir=. 9284 for ac_exec_ext in '' $ac_executable_extensions; do 9285 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9286 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9287 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9288 break 2 9289 fi 9290 done 9291 done 9292 IFS=$as_save_IFS 9293 9294 ;; 9295 esac 9296 fi 9297 MKDIR=$ac_cv_path_MKDIR 9298 if test -n "$MKDIR"; then 9299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9300 $as_echo "$MKDIR" >&6; } 9301 else 9302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9303 $as_echo "no" >&6; } 9304 fi 9305 9306 9307 test -n "$MKDIR" && break 9308 done 9309 9310 else 9311 # The variable is set, but is it from the command line or the environment? 9312 9313 # Try to remove the string !MKDIR! from our list. 9314 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9315 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9316 # If it failed, the variable was not from the command line. Ignore it, 9317 # but warn the user (except for BASH, which is always set by the calling BASH). 9318 if test "xMKDIR" != xBASH; then 9319 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9320 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9321 fi 9322 # Try to locate tool using the code snippet 9323 for ac_prog in mkdir 9324 do 9325 # Extract the first word of "$ac_prog", so it can be a program name with args. 9326 set dummy $ac_prog; ac_word=$2 9327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9328 $as_echo_n "checking for $ac_word... " >&6; } 9329 if ${ac_cv_path_MKDIR+:} false; then : 9330 $as_echo_n "(cached) " >&6 9331 else 9332 case $MKDIR in 9333 [\\/]* | ?:[\\/]*) 9334 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9335 ;; 9336 *) 9337 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9338 for as_dir in $PATH 9339 do 9340 IFS=$as_save_IFS 9341 test -z "$as_dir" && as_dir=. 9342 for ac_exec_ext in '' $ac_executable_extensions; do 9343 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9344 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9345 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9346 break 2 9347 fi 9348 done 9349 done 9350 IFS=$as_save_IFS 9351 9352 ;; 9353 esac 9354 fi 9355 MKDIR=$ac_cv_path_MKDIR 9356 if test -n "$MKDIR"; then 9357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9358 $as_echo "$MKDIR" >&6; } 9359 else 9360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9361 $as_echo "no" >&6; } 9362 fi 9363 9364 9365 test -n "$MKDIR" && break 9366 done 9367 9368 else 9369 # If it succeeded, then it was overridden by the user. We will use it 9370 # for the tool. 9371 9372 # First remove it from the list of overridden variables, so we can test 9373 # for unknown variables in the end. 9374 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9375 9376 # Check if we try to supply an empty value 9377 if test "x$MKDIR" = x; then 9378 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9379 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9381 $as_echo_n "checking for MKDIR... " >&6; } 9382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9383 $as_echo "disabled" >&6; } 9384 else 9385 # Check if the provided tool contains a complete path. 9386 tool_specified="$MKDIR" 9387 tool_basename="${tool_specified##*/}" 9388 if test "x$tool_basename" = "x$tool_specified"; then 9389 # A command without a complete path is provided, search $PATH. 9390 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9391 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9392 # Extract the first word of "$tool_basename", so it can be a program name with args. 9393 set dummy $tool_basename; ac_word=$2 9394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9395 $as_echo_n "checking for $ac_word... " >&6; } 9396 if ${ac_cv_path_MKDIR+:} false; then : 9397 $as_echo_n "(cached) " >&6 9398 else 9399 case $MKDIR in 9400 [\\/]* | ?:[\\/]*) 9401 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9402 ;; 9403 *) 9404 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9405 for as_dir in $PATH 9406 do 9407 IFS=$as_save_IFS 9408 test -z "$as_dir" && as_dir=. 9409 for ac_exec_ext in '' $ac_executable_extensions; do 9410 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9411 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9412 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9413 break 2 9414 fi 9415 done 9416 done 9417 IFS=$as_save_IFS 9418 9419 ;; 9420 esac 9421 fi 9422 MKDIR=$ac_cv_path_MKDIR 9423 if test -n "$MKDIR"; then 9424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9425 $as_echo "$MKDIR" >&6; } 9426 else 9427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9428 $as_echo "no" >&6; } 9429 fi 9430 9431 9432 if test "x$MKDIR" = x; then 9433 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9434 fi 9435 else 9436 # Otherwise we believe it is a complete path. Use it as it is. 9437 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9438 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9440 $as_echo_n "checking for MKDIR... " >&6; } 9441 if test ! -x "$tool_specified"; then 9442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9443 $as_echo "not found" >&6; } 9444 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9445 fi 9446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9447 $as_echo "$tool_specified" >&6; } 9448 fi 9449 fi 9450 fi 9451 9452 fi 9453 9454 9455 9456 if test "x$MKDIR" = x; then 9457 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9458 fi 9459 9460 9461 9462 9463 9464 # Publish this variable in the help. 9465 9466 9467 if [ -z "${MKTEMP+x}" ]; then 9468 # The variable is not set by user, try to locate tool using the code snippet 9469 for ac_prog in mktemp 9470 do 9471 # Extract the first word of "$ac_prog", so it can be a program name with args. 9472 set dummy $ac_prog; ac_word=$2 9473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9474 $as_echo_n "checking for $ac_word... " >&6; } 9475 if ${ac_cv_path_MKTEMP+:} false; then : 9476 $as_echo_n "(cached) " >&6 9477 else 9478 case $MKTEMP in 9479 [\\/]* | ?:[\\/]*) 9480 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9481 ;; 9482 *) 9483 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9484 for as_dir in $PATH 9485 do 9486 IFS=$as_save_IFS 9487 test -z "$as_dir" && as_dir=. 9488 for ac_exec_ext in '' $ac_executable_extensions; do 9489 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9490 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9491 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9492 break 2 9493 fi 9494 done 9495 done 9496 IFS=$as_save_IFS 9497 9498 ;; 9499 esac 9500 fi 9501 MKTEMP=$ac_cv_path_MKTEMP 9502 if test -n "$MKTEMP"; then 9503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9504 $as_echo "$MKTEMP" >&6; } 9505 else 9506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9507 $as_echo "no" >&6; } 9508 fi 9509 9510 9511 test -n "$MKTEMP" && break 9512 done 9513 9514 else 9515 # The variable is set, but is it from the command line or the environment? 9516 9517 # Try to remove the string !MKTEMP! from our list. 9518 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9519 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9520 # If it failed, the variable was not from the command line. Ignore it, 9521 # but warn the user (except for BASH, which is always set by the calling BASH). 9522 if test "xMKTEMP" != xBASH; then 9523 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9524 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9525 fi 9526 # Try to locate tool using the code snippet 9527 for ac_prog in mktemp 9528 do 9529 # Extract the first word of "$ac_prog", so it can be a program name with args. 9530 set dummy $ac_prog; ac_word=$2 9531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9532 $as_echo_n "checking for $ac_word... " >&6; } 9533 if ${ac_cv_path_MKTEMP+:} false; then : 9534 $as_echo_n "(cached) " >&6 9535 else 9536 case $MKTEMP in 9537 [\\/]* | ?:[\\/]*) 9538 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9539 ;; 9540 *) 9541 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9542 for as_dir in $PATH 9543 do 9544 IFS=$as_save_IFS 9545 test -z "$as_dir" && as_dir=. 9546 for ac_exec_ext in '' $ac_executable_extensions; do 9547 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9548 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9549 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9550 break 2 9551 fi 9552 done 9553 done 9554 IFS=$as_save_IFS 9555 9556 ;; 9557 esac 9558 fi 9559 MKTEMP=$ac_cv_path_MKTEMP 9560 if test -n "$MKTEMP"; then 9561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9562 $as_echo "$MKTEMP" >&6; } 9563 else 9564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9565 $as_echo "no" >&6; } 9566 fi 9567 9568 9569 test -n "$MKTEMP" && break 9570 done 9571 9572 else 9573 # If it succeeded, then it was overridden by the user. We will use it 9574 # for the tool. 9575 9576 # First remove it from the list of overridden variables, so we can test 9577 # for unknown variables in the end. 9578 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9579 9580 # Check if we try to supply an empty value 9581 if test "x$MKTEMP" = x; then 9582 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9583 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9585 $as_echo_n "checking for MKTEMP... " >&6; } 9586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9587 $as_echo "disabled" >&6; } 9588 else 9589 # Check if the provided tool contains a complete path. 9590 tool_specified="$MKTEMP" 9591 tool_basename="${tool_specified##*/}" 9592 if test "x$tool_basename" = "x$tool_specified"; then 9593 # A command without a complete path is provided, search $PATH. 9594 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9595 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9596 # Extract the first word of "$tool_basename", so it can be a program name with args. 9597 set dummy $tool_basename; ac_word=$2 9598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9599 $as_echo_n "checking for $ac_word... " >&6; } 9600 if ${ac_cv_path_MKTEMP+:} false; then : 9601 $as_echo_n "(cached) " >&6 9602 else 9603 case $MKTEMP in 9604 [\\/]* | ?:[\\/]*) 9605 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9606 ;; 9607 *) 9608 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9609 for as_dir in $PATH 9610 do 9611 IFS=$as_save_IFS 9612 test -z "$as_dir" && as_dir=. 9613 for ac_exec_ext in '' $ac_executable_extensions; do 9614 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9615 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9616 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9617 break 2 9618 fi 9619 done 9620 done 9621 IFS=$as_save_IFS 9622 9623 ;; 9624 esac 9625 fi 9626 MKTEMP=$ac_cv_path_MKTEMP 9627 if test -n "$MKTEMP"; then 9628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9629 $as_echo "$MKTEMP" >&6; } 9630 else 9631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9632 $as_echo "no" >&6; } 9633 fi 9634 9635 9636 if test "x$MKTEMP" = x; then 9637 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9638 fi 9639 else 9640 # Otherwise we believe it is a complete path. Use it as it is. 9641 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9642 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9644 $as_echo_n "checking for MKTEMP... " >&6; } 9645 if test ! -x "$tool_specified"; then 9646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9647 $as_echo "not found" >&6; } 9648 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9649 fi 9650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9651 $as_echo "$tool_specified" >&6; } 9652 fi 9653 fi 9654 fi 9655 9656 fi 9657 9658 9659 9660 if test "x$MKTEMP" = x; then 9661 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9662 fi 9663 9664 9665 9666 9667 9668 # Publish this variable in the help. 9669 9670 9671 if [ -z "${MV+x}" ]; then 9672 # The variable is not set by user, try to locate tool using the code snippet 9673 for ac_prog in mv 9674 do 9675 # Extract the first word of "$ac_prog", so it can be a program name with args. 9676 set dummy $ac_prog; ac_word=$2 9677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9678 $as_echo_n "checking for $ac_word... " >&6; } 9679 if ${ac_cv_path_MV+:} false; then : 9680 $as_echo_n "(cached) " >&6 9681 else 9682 case $MV in 9683 [\\/]* | ?:[\\/]*) 9684 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9685 ;; 9686 *) 9687 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9688 for as_dir in $PATH 9689 do 9690 IFS=$as_save_IFS 9691 test -z "$as_dir" && as_dir=. 9692 for ac_exec_ext in '' $ac_executable_extensions; do 9693 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9694 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9695 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9696 break 2 9697 fi 9698 done 9699 done 9700 IFS=$as_save_IFS 9701 9702 ;; 9703 esac 9704 fi 9705 MV=$ac_cv_path_MV 9706 if test -n "$MV"; then 9707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9708 $as_echo "$MV" >&6; } 9709 else 9710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9711 $as_echo "no" >&6; } 9712 fi 9713 9714 9715 test -n "$MV" && break 9716 done 9717 9718 else 9719 # The variable is set, but is it from the command line or the environment? 9720 9721 # Try to remove the string !MV! from our list. 9722 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9723 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9724 # If it failed, the variable was not from the command line. Ignore it, 9725 # but warn the user (except for BASH, which is always set by the calling BASH). 9726 if test "xMV" != xBASH; then 9727 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9728 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9729 fi 9730 # Try to locate tool using the code snippet 9731 for ac_prog in mv 9732 do 9733 # Extract the first word of "$ac_prog", so it can be a program name with args. 9734 set dummy $ac_prog; ac_word=$2 9735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9736 $as_echo_n "checking for $ac_word... " >&6; } 9737 if ${ac_cv_path_MV+:} false; then : 9738 $as_echo_n "(cached) " >&6 9739 else 9740 case $MV in 9741 [\\/]* | ?:[\\/]*) 9742 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9743 ;; 9744 *) 9745 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9746 for as_dir in $PATH 9747 do 9748 IFS=$as_save_IFS 9749 test -z "$as_dir" && as_dir=. 9750 for ac_exec_ext in '' $ac_executable_extensions; do 9751 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9752 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9753 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9754 break 2 9755 fi 9756 done 9757 done 9758 IFS=$as_save_IFS 9759 9760 ;; 9761 esac 9762 fi 9763 MV=$ac_cv_path_MV 9764 if test -n "$MV"; then 9765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9766 $as_echo "$MV" >&6; } 9767 else 9768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9769 $as_echo "no" >&6; } 9770 fi 9771 9772 9773 test -n "$MV" && break 9774 done 9775 9776 else 9777 # If it succeeded, then it was overridden by the user. We will use it 9778 # for the tool. 9779 9780 # First remove it from the list of overridden variables, so we can test 9781 # for unknown variables in the end. 9782 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9783 9784 # Check if we try to supply an empty value 9785 if test "x$MV" = x; then 9786 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9787 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9789 $as_echo_n "checking for MV... " >&6; } 9790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9791 $as_echo "disabled" >&6; } 9792 else 9793 # Check if the provided tool contains a complete path. 9794 tool_specified="$MV" 9795 tool_basename="${tool_specified##*/}" 9796 if test "x$tool_basename" = "x$tool_specified"; then 9797 # A command without a complete path is provided, search $PATH. 9798 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9799 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9800 # Extract the first word of "$tool_basename", so it can be a program name with args. 9801 set dummy $tool_basename; ac_word=$2 9802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9803 $as_echo_n "checking for $ac_word... " >&6; } 9804 if ${ac_cv_path_MV+:} false; then : 9805 $as_echo_n "(cached) " >&6 9806 else 9807 case $MV in 9808 [\\/]* | ?:[\\/]*) 9809 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9810 ;; 9811 *) 9812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9813 for as_dir in $PATH 9814 do 9815 IFS=$as_save_IFS 9816 test -z "$as_dir" && as_dir=. 9817 for ac_exec_ext in '' $ac_executable_extensions; do 9818 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9819 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9820 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9821 break 2 9822 fi 9823 done 9824 done 9825 IFS=$as_save_IFS 9826 9827 ;; 9828 esac 9829 fi 9830 MV=$ac_cv_path_MV 9831 if test -n "$MV"; then 9832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9833 $as_echo "$MV" >&6; } 9834 else 9835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9836 $as_echo "no" >&6; } 9837 fi 9838 9839 9840 if test "x$MV" = x; then 9841 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9842 fi 9843 else 9844 # Otherwise we believe it is a complete path. Use it as it is. 9845 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9846 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9848 $as_echo_n "checking for MV... " >&6; } 9849 if test ! -x "$tool_specified"; then 9850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9851 $as_echo "not found" >&6; } 9852 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9853 fi 9854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9855 $as_echo "$tool_specified" >&6; } 9856 fi 9857 fi 9858 fi 9859 9860 fi 9861 9862 9863 9864 if test "x$MV" = x; then 9865 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9866 fi 9867 9868 9869 9870 9871 9872 # Publish this variable in the help. 9873 9874 9875 if [ -z "${NAWK+x}" ]; then 9876 # The variable is not set by user, try to locate tool using the code snippet 9877 for ac_prog in nawk gawk awk 9878 do 9879 # Extract the first word of "$ac_prog", so it can be a program name with args. 9880 set dummy $ac_prog; ac_word=$2 9881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9882 $as_echo_n "checking for $ac_word... " >&6; } 9883 if ${ac_cv_path_NAWK+:} false; then : 9884 $as_echo_n "(cached) " >&6 9885 else 9886 case $NAWK in 9887 [\\/]* | ?:[\\/]*) 9888 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9889 ;; 9890 *) 9891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9892 for as_dir in $PATH 9893 do 9894 IFS=$as_save_IFS 9895 test -z "$as_dir" && as_dir=. 9896 for ac_exec_ext in '' $ac_executable_extensions; do 9897 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9898 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9900 break 2 9901 fi 9902 done 9903 done 9904 IFS=$as_save_IFS 9905 9906 ;; 9907 esac 9908 fi 9909 NAWK=$ac_cv_path_NAWK 9910 if test -n "$NAWK"; then 9911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9912 $as_echo "$NAWK" >&6; } 9913 else 9914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9915 $as_echo "no" >&6; } 9916 fi 9917 9918 9919 test -n "$NAWK" && break 9920 done 9921 9922 else 9923 # The variable is set, but is it from the command line or the environment? 9924 9925 # Try to remove the string !NAWK! from our list. 9926 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9927 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9928 # If it failed, the variable was not from the command line. Ignore it, 9929 # but warn the user (except for BASH, which is always set by the calling BASH). 9930 if test "xNAWK" != xBASH; then 9931 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9932 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9933 fi 9934 # Try to locate tool using the code snippet 9935 for ac_prog in nawk gawk awk 9936 do 9937 # Extract the first word of "$ac_prog", so it can be a program name with args. 9938 set dummy $ac_prog; ac_word=$2 9939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9940 $as_echo_n "checking for $ac_word... " >&6; } 9941 if ${ac_cv_path_NAWK+:} false; then : 9942 $as_echo_n "(cached) " >&6 9943 else 9944 case $NAWK in 9945 [\\/]* | ?:[\\/]*) 9946 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9947 ;; 9948 *) 9949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9950 for as_dir in $PATH 9951 do 9952 IFS=$as_save_IFS 9953 test -z "$as_dir" && as_dir=. 9954 for ac_exec_ext in '' $ac_executable_extensions; do 9955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9956 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9958 break 2 9959 fi 9960 done 9961 done 9962 IFS=$as_save_IFS 9963 9964 ;; 9965 esac 9966 fi 9967 NAWK=$ac_cv_path_NAWK 9968 if test -n "$NAWK"; then 9969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9970 $as_echo "$NAWK" >&6; } 9971 else 9972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9973 $as_echo "no" >&6; } 9974 fi 9975 9976 9977 test -n "$NAWK" && break 9978 done 9979 9980 else 9981 # If it succeeded, then it was overridden by the user. We will use it 9982 # for the tool. 9983 9984 # First remove it from the list of overridden variables, so we can test 9985 # for unknown variables in the end. 9986 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9987 9988 # Check if we try to supply an empty value 9989 if test "x$NAWK" = x; then 9990 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 9991 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 9992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9993 $as_echo_n "checking for NAWK... " >&6; } 9994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9995 $as_echo "disabled" >&6; } 9996 else 9997 # Check if the provided tool contains a complete path. 9998 tool_specified="$NAWK" 9999 tool_basename="${tool_specified##*/}" 10000 if test "x$tool_basename" = "x$tool_specified"; then 10001 # A command without a complete path is provided, search $PATH. 10002 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 10003 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 10004 # Extract the first word of "$tool_basename", so it can be a program name with args. 10005 set dummy $tool_basename; ac_word=$2 10006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10007 $as_echo_n "checking for $ac_word... " >&6; } 10008 if ${ac_cv_path_NAWK+:} false; then : 10009 $as_echo_n "(cached) " >&6 10010 else 10011 case $NAWK in 10012 [\\/]* | ?:[\\/]*) 10013 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 10014 ;; 10015 *) 10016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10017 for as_dir in $PATH 10018 do 10019 IFS=$as_save_IFS 10020 test -z "$as_dir" && as_dir=. 10021 for ac_exec_ext in '' $ac_executable_extensions; do 10022 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10023 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10024 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10025 break 2 10026 fi 10027 done 10028 done 10029 IFS=$as_save_IFS 10030 10031 ;; 10032 esac 10033 fi 10034 NAWK=$ac_cv_path_NAWK 10035 if test -n "$NAWK"; then 10036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10037 $as_echo "$NAWK" >&6; } 10038 else 10039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10040 $as_echo "no" >&6; } 10041 fi 10042 10043 10044 if test "x$NAWK" = x; then 10045 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10046 fi 10047 else 10048 # Otherwise we believe it is a complete path. Use it as it is. 10049 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10050 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10052 $as_echo_n "checking for NAWK... " >&6; } 10053 if test ! -x "$tool_specified"; then 10054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10055 $as_echo "not found" >&6; } 10056 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10057 fi 10058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10059 $as_echo "$tool_specified" >&6; } 10060 fi 10061 fi 10062 fi 10063 10064 fi 10065 10066 10067 10068 if test "x$NAWK" = x; then 10069 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10070 fi 10071 10072 10073 10074 10075 10076 # Publish this variable in the help. 10077 10078 10079 if [ -z "${PRINTF+x}" ]; then 10080 # The variable is not set by user, try to locate tool using the code snippet 10081 for ac_prog in printf 10082 do 10083 # Extract the first word of "$ac_prog", so it can be a program name with args. 10084 set dummy $ac_prog; ac_word=$2 10085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10086 $as_echo_n "checking for $ac_word... " >&6; } 10087 if ${ac_cv_path_PRINTF+:} false; then : 10088 $as_echo_n "(cached) " >&6 10089 else 10090 case $PRINTF in 10091 [\\/]* | ?:[\\/]*) 10092 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10093 ;; 10094 *) 10095 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10096 for as_dir in $PATH 10097 do 10098 IFS=$as_save_IFS 10099 test -z "$as_dir" && as_dir=. 10100 for ac_exec_ext in '' $ac_executable_extensions; do 10101 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10102 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10103 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10104 break 2 10105 fi 10106 done 10107 done 10108 IFS=$as_save_IFS 10109 10110 ;; 10111 esac 10112 fi 10113 PRINTF=$ac_cv_path_PRINTF 10114 if test -n "$PRINTF"; then 10115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10116 $as_echo "$PRINTF" >&6; } 10117 else 10118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10119 $as_echo "no" >&6; } 10120 fi 10121 10122 10123 test -n "$PRINTF" && break 10124 done 10125 10126 else 10127 # The variable is set, but is it from the command line or the environment? 10128 10129 # Try to remove the string !PRINTF! from our list. 10130 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10131 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10132 # If it failed, the variable was not from the command line. Ignore it, 10133 # but warn the user (except for BASH, which is always set by the calling BASH). 10134 if test "xPRINTF" != xBASH; then 10135 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10136 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10137 fi 10138 # Try to locate tool using the code snippet 10139 for ac_prog in printf 10140 do 10141 # Extract the first word of "$ac_prog", so it can be a program name with args. 10142 set dummy $ac_prog; ac_word=$2 10143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10144 $as_echo_n "checking for $ac_word... " >&6; } 10145 if ${ac_cv_path_PRINTF+:} false; then : 10146 $as_echo_n "(cached) " >&6 10147 else 10148 case $PRINTF in 10149 [\\/]* | ?:[\\/]*) 10150 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10151 ;; 10152 *) 10153 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10154 for as_dir in $PATH 10155 do 10156 IFS=$as_save_IFS 10157 test -z "$as_dir" && as_dir=. 10158 for ac_exec_ext in '' $ac_executable_extensions; do 10159 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10160 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10161 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10162 break 2 10163 fi 10164 done 10165 done 10166 IFS=$as_save_IFS 10167 10168 ;; 10169 esac 10170 fi 10171 PRINTF=$ac_cv_path_PRINTF 10172 if test -n "$PRINTF"; then 10173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10174 $as_echo "$PRINTF" >&6; } 10175 else 10176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10177 $as_echo "no" >&6; } 10178 fi 10179 10180 10181 test -n "$PRINTF" && break 10182 done 10183 10184 else 10185 # If it succeeded, then it was overridden by the user. We will use it 10186 # for the tool. 10187 10188 # First remove it from the list of overridden variables, so we can test 10189 # for unknown variables in the end. 10190 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10191 10192 # Check if we try to supply an empty value 10193 if test "x$PRINTF" = x; then 10194 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10195 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10197 $as_echo_n "checking for PRINTF... " >&6; } 10198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10199 $as_echo "disabled" >&6; } 10200 else 10201 # Check if the provided tool contains a complete path. 10202 tool_specified="$PRINTF" 10203 tool_basename="${tool_specified##*/}" 10204 if test "x$tool_basename" = "x$tool_specified"; then 10205 # A command without a complete path is provided, search $PATH. 10206 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10207 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10208 # Extract the first word of "$tool_basename", so it can be a program name with args. 10209 set dummy $tool_basename; ac_word=$2 10210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10211 $as_echo_n "checking for $ac_word... " >&6; } 10212 if ${ac_cv_path_PRINTF+:} false; then : 10213 $as_echo_n "(cached) " >&6 10214 else 10215 case $PRINTF in 10216 [\\/]* | ?:[\\/]*) 10217 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10218 ;; 10219 *) 10220 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10221 for as_dir in $PATH 10222 do 10223 IFS=$as_save_IFS 10224 test -z "$as_dir" && as_dir=. 10225 for ac_exec_ext in '' $ac_executable_extensions; do 10226 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10227 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10228 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10229 break 2 10230 fi 10231 done 10232 done 10233 IFS=$as_save_IFS 10234 10235 ;; 10236 esac 10237 fi 10238 PRINTF=$ac_cv_path_PRINTF 10239 if test -n "$PRINTF"; then 10240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10241 $as_echo "$PRINTF" >&6; } 10242 else 10243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10244 $as_echo "no" >&6; } 10245 fi 10246 10247 10248 if test "x$PRINTF" = x; then 10249 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10250 fi 10251 else 10252 # Otherwise we believe it is a complete path. Use it as it is. 10253 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10254 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10256 $as_echo_n "checking for PRINTF... " >&6; } 10257 if test ! -x "$tool_specified"; then 10258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10259 $as_echo "not found" >&6; } 10260 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10261 fi 10262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10263 $as_echo "$tool_specified" >&6; } 10264 fi 10265 fi 10266 fi 10267 10268 fi 10269 10270 10271 10272 if test "x$PRINTF" = x; then 10273 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10274 fi 10275 10276 10277 10278 10279 10280 # Publish this variable in the help. 10281 10282 10283 if [ -z "${RM+x}" ]; then 10284 # The variable is not set by user, try to locate tool using the code snippet 10285 for ac_prog in rm 10286 do 10287 # Extract the first word of "$ac_prog", so it can be a program name with args. 10288 set dummy $ac_prog; ac_word=$2 10289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10290 $as_echo_n "checking for $ac_word... " >&6; } 10291 if ${ac_cv_path_RM+:} false; then : 10292 $as_echo_n "(cached) " >&6 10293 else 10294 case $RM in 10295 [\\/]* | ?:[\\/]*) 10296 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10297 ;; 10298 *) 10299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10300 for as_dir in $PATH 10301 do 10302 IFS=$as_save_IFS 10303 test -z "$as_dir" && as_dir=. 10304 for ac_exec_ext in '' $ac_executable_extensions; do 10305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10306 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10308 break 2 10309 fi 10310 done 10311 done 10312 IFS=$as_save_IFS 10313 10314 ;; 10315 esac 10316 fi 10317 RM=$ac_cv_path_RM 10318 if test -n "$RM"; then 10319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10320 $as_echo "$RM" >&6; } 10321 else 10322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10323 $as_echo "no" >&6; } 10324 fi 10325 10326 10327 test -n "$RM" && break 10328 done 10329 10330 else 10331 # The variable is set, but is it from the command line or the environment? 10332 10333 # Try to remove the string !RM! from our list. 10334 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10335 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10336 # If it failed, the variable was not from the command line. Ignore it, 10337 # but warn the user (except for BASH, which is always set by the calling BASH). 10338 if test "xRM" != xBASH; then 10339 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10340 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10341 fi 10342 # Try to locate tool using the code snippet 10343 for ac_prog in rm 10344 do 10345 # Extract the first word of "$ac_prog", so it can be a program name with args. 10346 set dummy $ac_prog; ac_word=$2 10347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10348 $as_echo_n "checking for $ac_word... " >&6; } 10349 if ${ac_cv_path_RM+:} false; then : 10350 $as_echo_n "(cached) " >&6 10351 else 10352 case $RM in 10353 [\\/]* | ?:[\\/]*) 10354 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10355 ;; 10356 *) 10357 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10358 for as_dir in $PATH 10359 do 10360 IFS=$as_save_IFS 10361 test -z "$as_dir" && as_dir=. 10362 for ac_exec_ext in '' $ac_executable_extensions; do 10363 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10364 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10365 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10366 break 2 10367 fi 10368 done 10369 done 10370 IFS=$as_save_IFS 10371 10372 ;; 10373 esac 10374 fi 10375 RM=$ac_cv_path_RM 10376 if test -n "$RM"; then 10377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10378 $as_echo "$RM" >&6; } 10379 else 10380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10381 $as_echo "no" >&6; } 10382 fi 10383 10384 10385 test -n "$RM" && break 10386 done 10387 10388 else 10389 # If it succeeded, then it was overridden by the user. We will use it 10390 # for the tool. 10391 10392 # First remove it from the list of overridden variables, so we can test 10393 # for unknown variables in the end. 10394 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10395 10396 # Check if we try to supply an empty value 10397 if test "x$RM" = x; then 10398 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10399 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10401 $as_echo_n "checking for RM... " >&6; } 10402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10403 $as_echo "disabled" >&6; } 10404 else 10405 # Check if the provided tool contains a complete path. 10406 tool_specified="$RM" 10407 tool_basename="${tool_specified##*/}" 10408 if test "x$tool_basename" = "x$tool_specified"; then 10409 # A command without a complete path is provided, search $PATH. 10410 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10411 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10412 # Extract the first word of "$tool_basename", so it can be a program name with args. 10413 set dummy $tool_basename; ac_word=$2 10414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10415 $as_echo_n "checking for $ac_word... " >&6; } 10416 if ${ac_cv_path_RM+:} false; then : 10417 $as_echo_n "(cached) " >&6 10418 else 10419 case $RM in 10420 [\\/]* | ?:[\\/]*) 10421 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10422 ;; 10423 *) 10424 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10425 for as_dir in $PATH 10426 do 10427 IFS=$as_save_IFS 10428 test -z "$as_dir" && as_dir=. 10429 for ac_exec_ext in '' $ac_executable_extensions; do 10430 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10431 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10432 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10433 break 2 10434 fi 10435 done 10436 done 10437 IFS=$as_save_IFS 10438 10439 ;; 10440 esac 10441 fi 10442 RM=$ac_cv_path_RM 10443 if test -n "$RM"; then 10444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10445 $as_echo "$RM" >&6; } 10446 else 10447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10448 $as_echo "no" >&6; } 10449 fi 10450 10451 10452 if test "x$RM" = x; then 10453 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10454 fi 10455 else 10456 # Otherwise we believe it is a complete path. Use it as it is. 10457 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10458 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10460 $as_echo_n "checking for RM... " >&6; } 10461 if test ! -x "$tool_specified"; then 10462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10463 $as_echo "not found" >&6; } 10464 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10465 fi 10466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10467 $as_echo "$tool_specified" >&6; } 10468 fi 10469 fi 10470 fi 10471 10472 fi 10473 10474 10475 10476 if test "x$RM" = x; then 10477 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10478 fi 10479 10480 10481 10482 10483 10484 # Publish this variable in the help. 10485 10486 10487 if [ -z "${RMDIR+x}" ]; then 10488 # The variable is not set by user, try to locate tool using the code snippet 10489 for ac_prog in rmdir 10490 do 10491 # Extract the first word of "$ac_prog", so it can be a program name with args. 10492 set dummy $ac_prog; ac_word=$2 10493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10494 $as_echo_n "checking for $ac_word... " >&6; } 10495 if ${ac_cv_path_RMDIR+:} false; then : 10496 $as_echo_n "(cached) " >&6 10497 else 10498 case $RMDIR in 10499 [\\/]* | ?:[\\/]*) 10500 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10501 ;; 10502 *) 10503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10504 for as_dir in $PATH 10505 do 10506 IFS=$as_save_IFS 10507 test -z "$as_dir" && as_dir=. 10508 for ac_exec_ext in '' $ac_executable_extensions; do 10509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10510 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10512 break 2 10513 fi 10514 done 10515 done 10516 IFS=$as_save_IFS 10517 10518 ;; 10519 esac 10520 fi 10521 RMDIR=$ac_cv_path_RMDIR 10522 if test -n "$RMDIR"; then 10523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10524 $as_echo "$RMDIR" >&6; } 10525 else 10526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10527 $as_echo "no" >&6; } 10528 fi 10529 10530 10531 test -n "$RMDIR" && break 10532 done 10533 10534 else 10535 # The variable is set, but is it from the command line or the environment? 10536 10537 # Try to remove the string !RMDIR! from our list. 10538 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10539 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10540 # If it failed, the variable was not from the command line. Ignore it, 10541 # but warn the user (except for BASH, which is always set by the calling BASH). 10542 if test "xRMDIR" != xBASH; then 10543 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10544 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10545 fi 10546 # Try to locate tool using the code snippet 10547 for ac_prog in rmdir 10548 do 10549 # Extract the first word of "$ac_prog", so it can be a program name with args. 10550 set dummy $ac_prog; ac_word=$2 10551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10552 $as_echo_n "checking for $ac_word... " >&6; } 10553 if ${ac_cv_path_RMDIR+:} false; then : 10554 $as_echo_n "(cached) " >&6 10555 else 10556 case $RMDIR in 10557 [\\/]* | ?:[\\/]*) 10558 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10559 ;; 10560 *) 10561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10562 for as_dir in $PATH 10563 do 10564 IFS=$as_save_IFS 10565 test -z "$as_dir" && as_dir=. 10566 for ac_exec_ext in '' $ac_executable_extensions; do 10567 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10568 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10570 break 2 10571 fi 10572 done 10573 done 10574 IFS=$as_save_IFS 10575 10576 ;; 10577 esac 10578 fi 10579 RMDIR=$ac_cv_path_RMDIR 10580 if test -n "$RMDIR"; then 10581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10582 $as_echo "$RMDIR" >&6; } 10583 else 10584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10585 $as_echo "no" >&6; } 10586 fi 10587 10588 10589 test -n "$RMDIR" && break 10590 done 10591 10592 else 10593 # If it succeeded, then it was overridden by the user. We will use it 10594 # for the tool. 10595 10596 # First remove it from the list of overridden variables, so we can test 10597 # for unknown variables in the end. 10598 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10599 10600 # Check if we try to supply an empty value 10601 if test "x$RMDIR" = x; then 10602 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10603 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10605 $as_echo_n "checking for RMDIR... " >&6; } 10606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10607 $as_echo "disabled" >&6; } 10608 else 10609 # Check if the provided tool contains a complete path. 10610 tool_specified="$RMDIR" 10611 tool_basename="${tool_specified##*/}" 10612 if test "x$tool_basename" = "x$tool_specified"; then 10613 # A command without a complete path is provided, search $PATH. 10614 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10615 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10616 # Extract the first word of "$tool_basename", so it can be a program name with args. 10617 set dummy $tool_basename; ac_word=$2 10618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10619 $as_echo_n "checking for $ac_word... " >&6; } 10620 if ${ac_cv_path_RMDIR+:} false; then : 10621 $as_echo_n "(cached) " >&6 10622 else 10623 case $RMDIR in 10624 [\\/]* | ?:[\\/]*) 10625 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10626 ;; 10627 *) 10628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10629 for as_dir in $PATH 10630 do 10631 IFS=$as_save_IFS 10632 test -z "$as_dir" && as_dir=. 10633 for ac_exec_ext in '' $ac_executable_extensions; do 10634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10635 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10637 break 2 10638 fi 10639 done 10640 done 10641 IFS=$as_save_IFS 10642 10643 ;; 10644 esac 10645 fi 10646 RMDIR=$ac_cv_path_RMDIR 10647 if test -n "$RMDIR"; then 10648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10649 $as_echo "$RMDIR" >&6; } 10650 else 10651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10652 $as_echo "no" >&6; } 10653 fi 10654 10655 10656 if test "x$RMDIR" = x; then 10657 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10658 fi 10659 else 10660 # Otherwise we believe it is a complete path. Use it as it is. 10661 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10662 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10664 $as_echo_n "checking for RMDIR... " >&6; } 10665 if test ! -x "$tool_specified"; then 10666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10667 $as_echo "not found" >&6; } 10668 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10669 fi 10670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10671 $as_echo "$tool_specified" >&6; } 10672 fi 10673 fi 10674 fi 10675 10676 fi 10677 10678 10679 10680 if test "x$RMDIR" = x; then 10681 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10682 fi 10683 10684 10685 10686 10687 10688 # Publish this variable in the help. 10689 10690 10691 if [ -z "${SH+x}" ]; then 10692 # The variable is not set by user, try to locate tool using the code snippet 10693 for ac_prog in sh 10694 do 10695 # Extract the first word of "$ac_prog", so it can be a program name with args. 10696 set dummy $ac_prog; ac_word=$2 10697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10698 $as_echo_n "checking for $ac_word... " >&6; } 10699 if ${ac_cv_path_SH+:} false; then : 10700 $as_echo_n "(cached) " >&6 10701 else 10702 case $SH in 10703 [\\/]* | ?:[\\/]*) 10704 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10705 ;; 10706 *) 10707 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10708 for as_dir in $PATH 10709 do 10710 IFS=$as_save_IFS 10711 test -z "$as_dir" && as_dir=. 10712 for ac_exec_ext in '' $ac_executable_extensions; do 10713 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10714 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10715 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10716 break 2 10717 fi 10718 done 10719 done 10720 IFS=$as_save_IFS 10721 10722 ;; 10723 esac 10724 fi 10725 SH=$ac_cv_path_SH 10726 if test -n "$SH"; then 10727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10728 $as_echo "$SH" >&6; } 10729 else 10730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10731 $as_echo "no" >&6; } 10732 fi 10733 10734 10735 test -n "$SH" && break 10736 done 10737 10738 else 10739 # The variable is set, but is it from the command line or the environment? 10740 10741 # Try to remove the string !SH! from our list. 10742 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10743 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10744 # If it failed, the variable was not from the command line. Ignore it, 10745 # but warn the user (except for BASH, which is always set by the calling BASH). 10746 if test "xSH" != xBASH; then 10747 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10748 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10749 fi 10750 # Try to locate tool using the code snippet 10751 for ac_prog in sh 10752 do 10753 # Extract the first word of "$ac_prog", so it can be a program name with args. 10754 set dummy $ac_prog; ac_word=$2 10755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10756 $as_echo_n "checking for $ac_word... " >&6; } 10757 if ${ac_cv_path_SH+:} false; then : 10758 $as_echo_n "(cached) " >&6 10759 else 10760 case $SH in 10761 [\\/]* | ?:[\\/]*) 10762 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10763 ;; 10764 *) 10765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10766 for as_dir in $PATH 10767 do 10768 IFS=$as_save_IFS 10769 test -z "$as_dir" && as_dir=. 10770 for ac_exec_ext in '' $ac_executable_extensions; do 10771 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10772 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10773 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10774 break 2 10775 fi 10776 done 10777 done 10778 IFS=$as_save_IFS 10779 10780 ;; 10781 esac 10782 fi 10783 SH=$ac_cv_path_SH 10784 if test -n "$SH"; then 10785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10786 $as_echo "$SH" >&6; } 10787 else 10788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10789 $as_echo "no" >&6; } 10790 fi 10791 10792 10793 test -n "$SH" && break 10794 done 10795 10796 else 10797 # If it succeeded, then it was overridden by the user. We will use it 10798 # for the tool. 10799 10800 # First remove it from the list of overridden variables, so we can test 10801 # for unknown variables in the end. 10802 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10803 10804 # Check if we try to supply an empty value 10805 if test "x$SH" = x; then 10806 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10807 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10809 $as_echo_n "checking for SH... " >&6; } 10810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10811 $as_echo "disabled" >&6; } 10812 else 10813 # Check if the provided tool contains a complete path. 10814 tool_specified="$SH" 10815 tool_basename="${tool_specified##*/}" 10816 if test "x$tool_basename" = "x$tool_specified"; then 10817 # A command without a complete path is provided, search $PATH. 10818 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10819 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10820 # Extract the first word of "$tool_basename", so it can be a program name with args. 10821 set dummy $tool_basename; ac_word=$2 10822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10823 $as_echo_n "checking for $ac_word... " >&6; } 10824 if ${ac_cv_path_SH+:} false; then : 10825 $as_echo_n "(cached) " >&6 10826 else 10827 case $SH in 10828 [\\/]* | ?:[\\/]*) 10829 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10830 ;; 10831 *) 10832 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10833 for as_dir in $PATH 10834 do 10835 IFS=$as_save_IFS 10836 test -z "$as_dir" && as_dir=. 10837 for ac_exec_ext in '' $ac_executable_extensions; do 10838 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10839 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10840 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10841 break 2 10842 fi 10843 done 10844 done 10845 IFS=$as_save_IFS 10846 10847 ;; 10848 esac 10849 fi 10850 SH=$ac_cv_path_SH 10851 if test -n "$SH"; then 10852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10853 $as_echo "$SH" >&6; } 10854 else 10855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10856 $as_echo "no" >&6; } 10857 fi 10858 10859 10860 if test "x$SH" = x; then 10861 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10862 fi 10863 else 10864 # Otherwise we believe it is a complete path. Use it as it is. 10865 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10866 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10868 $as_echo_n "checking for SH... " >&6; } 10869 if test ! -x "$tool_specified"; then 10870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10871 $as_echo "not found" >&6; } 10872 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10873 fi 10874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10875 $as_echo "$tool_specified" >&6; } 10876 fi 10877 fi 10878 fi 10879 10880 fi 10881 10882 10883 10884 if test "x$SH" = x; then 10885 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10886 fi 10887 10888 10889 10890 10891 10892 # Publish this variable in the help. 10893 10894 10895 if [ -z "${SORT+x}" ]; then 10896 # The variable is not set by user, try to locate tool using the code snippet 10897 for ac_prog in sort 10898 do 10899 # Extract the first word of "$ac_prog", so it can be a program name with args. 10900 set dummy $ac_prog; ac_word=$2 10901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10902 $as_echo_n "checking for $ac_word... " >&6; } 10903 if ${ac_cv_path_SORT+:} false; then : 10904 $as_echo_n "(cached) " >&6 10905 else 10906 case $SORT in 10907 [\\/]* | ?:[\\/]*) 10908 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10909 ;; 10910 *) 10911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10912 for as_dir in $PATH 10913 do 10914 IFS=$as_save_IFS 10915 test -z "$as_dir" && as_dir=. 10916 for ac_exec_ext in '' $ac_executable_extensions; do 10917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10918 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10920 break 2 10921 fi 10922 done 10923 done 10924 IFS=$as_save_IFS 10925 10926 ;; 10927 esac 10928 fi 10929 SORT=$ac_cv_path_SORT 10930 if test -n "$SORT"; then 10931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10932 $as_echo "$SORT" >&6; } 10933 else 10934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10935 $as_echo "no" >&6; } 10936 fi 10937 10938 10939 test -n "$SORT" && break 10940 done 10941 10942 else 10943 # The variable is set, but is it from the command line or the environment? 10944 10945 # Try to remove the string !SORT! from our list. 10946 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 10947 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10948 # If it failed, the variable was not from the command line. Ignore it, 10949 # but warn the user (except for BASH, which is always set by the calling BASH). 10950 if test "xSORT" != xBASH; then 10951 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 10952 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 10953 fi 10954 # Try to locate tool using the code snippet 10955 for ac_prog in sort 10956 do 10957 # Extract the first word of "$ac_prog", so it can be a program name with args. 10958 set dummy $ac_prog; ac_word=$2 10959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10960 $as_echo_n "checking for $ac_word... " >&6; } 10961 if ${ac_cv_path_SORT+:} false; then : 10962 $as_echo_n "(cached) " >&6 10963 else 10964 case $SORT in 10965 [\\/]* | ?:[\\/]*) 10966 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10967 ;; 10968 *) 10969 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10970 for as_dir in $PATH 10971 do 10972 IFS=$as_save_IFS 10973 test -z "$as_dir" && as_dir=. 10974 for ac_exec_ext in '' $ac_executable_extensions; do 10975 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10976 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10977 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10978 break 2 10979 fi 10980 done 10981 done 10982 IFS=$as_save_IFS 10983 10984 ;; 10985 esac 10986 fi 10987 SORT=$ac_cv_path_SORT 10988 if test -n "$SORT"; then 10989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10990 $as_echo "$SORT" >&6; } 10991 else 10992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10993 $as_echo "no" >&6; } 10994 fi 10995 10996 10997 test -n "$SORT" && break 10998 done 10999 11000 else 11001 # If it succeeded, then it was overridden by the user. We will use it 11002 # for the tool. 11003 11004 # First remove it from the list of overridden variables, so we can test 11005 # for unknown variables in the end. 11006 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11007 11008 # Check if we try to supply an empty value 11009 if test "x$SORT" = x; then 11010 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 11011 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 11012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11013 $as_echo_n "checking for SORT... " >&6; } 11014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11015 $as_echo "disabled" >&6; } 11016 else 11017 # Check if the provided tool contains a complete path. 11018 tool_specified="$SORT" 11019 tool_basename="${tool_specified##*/}" 11020 if test "x$tool_basename" = "x$tool_specified"; then 11021 # A command without a complete path is provided, search $PATH. 11022 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 11023 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 11024 # Extract the first word of "$tool_basename", so it can be a program name with args. 11025 set dummy $tool_basename; ac_word=$2 11026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11027 $as_echo_n "checking for $ac_word... " >&6; } 11028 if ${ac_cv_path_SORT+:} false; then : 11029 $as_echo_n "(cached) " >&6 11030 else 11031 case $SORT in 11032 [\\/]* | ?:[\\/]*) 11033 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11034 ;; 11035 *) 11036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11037 for as_dir in $PATH 11038 do 11039 IFS=$as_save_IFS 11040 test -z "$as_dir" && as_dir=. 11041 for ac_exec_ext in '' $ac_executable_extensions; do 11042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11043 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11045 break 2 11046 fi 11047 done 11048 done 11049 IFS=$as_save_IFS 11050 11051 ;; 11052 esac 11053 fi 11054 SORT=$ac_cv_path_SORT 11055 if test -n "$SORT"; then 11056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11057 $as_echo "$SORT" >&6; } 11058 else 11059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11060 $as_echo "no" >&6; } 11061 fi 11062 11063 11064 if test "x$SORT" = x; then 11065 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11066 fi 11067 else 11068 # Otherwise we believe it is a complete path. Use it as it is. 11069 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11070 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11072 $as_echo_n "checking for SORT... " >&6; } 11073 if test ! -x "$tool_specified"; then 11074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11075 $as_echo "not found" >&6; } 11076 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11077 fi 11078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11079 $as_echo "$tool_specified" >&6; } 11080 fi 11081 fi 11082 fi 11083 11084 fi 11085 11086 11087 11088 if test "x$SORT" = x; then 11089 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11090 fi 11091 11092 11093 11094 11095 11096 # Publish this variable in the help. 11097 11098 11099 if [ -z "${TAIL+x}" ]; then 11100 # The variable is not set by user, try to locate tool using the code snippet 11101 for ac_prog in tail 11102 do 11103 # Extract the first word of "$ac_prog", so it can be a program name with args. 11104 set dummy $ac_prog; ac_word=$2 11105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11106 $as_echo_n "checking for $ac_word... " >&6; } 11107 if ${ac_cv_path_TAIL+:} false; then : 11108 $as_echo_n "(cached) " >&6 11109 else 11110 case $TAIL in 11111 [\\/]* | ?:[\\/]*) 11112 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11113 ;; 11114 *) 11115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11116 for as_dir in $PATH 11117 do 11118 IFS=$as_save_IFS 11119 test -z "$as_dir" && as_dir=. 11120 for ac_exec_ext in '' $ac_executable_extensions; do 11121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11122 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11124 break 2 11125 fi 11126 done 11127 done 11128 IFS=$as_save_IFS 11129 11130 ;; 11131 esac 11132 fi 11133 TAIL=$ac_cv_path_TAIL 11134 if test -n "$TAIL"; then 11135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11136 $as_echo "$TAIL" >&6; } 11137 else 11138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11139 $as_echo "no" >&6; } 11140 fi 11141 11142 11143 test -n "$TAIL" && break 11144 done 11145 11146 else 11147 # The variable is set, but is it from the command line or the environment? 11148 11149 # Try to remove the string !TAIL! from our list. 11150 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11151 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11152 # If it failed, the variable was not from the command line. Ignore it, 11153 # but warn the user (except for BASH, which is always set by the calling BASH). 11154 if test "xTAIL" != xBASH; then 11155 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11156 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11157 fi 11158 # Try to locate tool using the code snippet 11159 for ac_prog in tail 11160 do 11161 # Extract the first word of "$ac_prog", so it can be a program name with args. 11162 set dummy $ac_prog; ac_word=$2 11163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11164 $as_echo_n "checking for $ac_word... " >&6; } 11165 if ${ac_cv_path_TAIL+:} false; then : 11166 $as_echo_n "(cached) " >&6 11167 else 11168 case $TAIL in 11169 [\\/]* | ?:[\\/]*) 11170 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11171 ;; 11172 *) 11173 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11174 for as_dir in $PATH 11175 do 11176 IFS=$as_save_IFS 11177 test -z "$as_dir" && as_dir=. 11178 for ac_exec_ext in '' $ac_executable_extensions; do 11179 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11180 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11181 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11182 break 2 11183 fi 11184 done 11185 done 11186 IFS=$as_save_IFS 11187 11188 ;; 11189 esac 11190 fi 11191 TAIL=$ac_cv_path_TAIL 11192 if test -n "$TAIL"; then 11193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11194 $as_echo "$TAIL" >&6; } 11195 else 11196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11197 $as_echo "no" >&6; } 11198 fi 11199 11200 11201 test -n "$TAIL" && break 11202 done 11203 11204 else 11205 # If it succeeded, then it was overridden by the user. We will use it 11206 # for the tool. 11207 11208 # First remove it from the list of overridden variables, so we can test 11209 # for unknown variables in the end. 11210 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11211 11212 # Check if we try to supply an empty value 11213 if test "x$TAIL" = x; then 11214 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11215 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11217 $as_echo_n "checking for TAIL... " >&6; } 11218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11219 $as_echo "disabled" >&6; } 11220 else 11221 # Check if the provided tool contains a complete path. 11222 tool_specified="$TAIL" 11223 tool_basename="${tool_specified##*/}" 11224 if test "x$tool_basename" = "x$tool_specified"; then 11225 # A command without a complete path is provided, search $PATH. 11226 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11227 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11228 # Extract the first word of "$tool_basename", so it can be a program name with args. 11229 set dummy $tool_basename; ac_word=$2 11230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11231 $as_echo_n "checking for $ac_word... " >&6; } 11232 if ${ac_cv_path_TAIL+:} false; then : 11233 $as_echo_n "(cached) " >&6 11234 else 11235 case $TAIL in 11236 [\\/]* | ?:[\\/]*) 11237 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11238 ;; 11239 *) 11240 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11241 for as_dir in $PATH 11242 do 11243 IFS=$as_save_IFS 11244 test -z "$as_dir" && as_dir=. 11245 for ac_exec_ext in '' $ac_executable_extensions; do 11246 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11247 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11248 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11249 break 2 11250 fi 11251 done 11252 done 11253 IFS=$as_save_IFS 11254 11255 ;; 11256 esac 11257 fi 11258 TAIL=$ac_cv_path_TAIL 11259 if test -n "$TAIL"; then 11260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11261 $as_echo "$TAIL" >&6; } 11262 else 11263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11264 $as_echo "no" >&6; } 11265 fi 11266 11267 11268 if test "x$TAIL" = x; then 11269 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11270 fi 11271 else 11272 # Otherwise we believe it is a complete path. Use it as it is. 11273 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11274 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11276 $as_echo_n "checking for TAIL... " >&6; } 11277 if test ! -x "$tool_specified"; then 11278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11279 $as_echo "not found" >&6; } 11280 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11281 fi 11282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11283 $as_echo "$tool_specified" >&6; } 11284 fi 11285 fi 11286 fi 11287 11288 fi 11289 11290 11291 11292 if test "x$TAIL" = x; then 11293 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11294 fi 11295 11296 11297 11298 11299 11300 # Publish this variable in the help. 11301 11302 11303 if [ -z "${TAR+x}" ]; then 11304 # The variable is not set by user, try to locate tool using the code snippet 11305 for ac_prog in gtar tar 11306 do 11307 # Extract the first word of "$ac_prog", so it can be a program name with args. 11308 set dummy $ac_prog; ac_word=$2 11309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11310 $as_echo_n "checking for $ac_word... " >&6; } 11311 if ${ac_cv_path_TAR+:} false; then : 11312 $as_echo_n "(cached) " >&6 11313 else 11314 case $TAR in 11315 [\\/]* | ?:[\\/]*) 11316 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11317 ;; 11318 *) 11319 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11320 for as_dir in $PATH 11321 do 11322 IFS=$as_save_IFS 11323 test -z "$as_dir" && as_dir=. 11324 for ac_exec_ext in '' $ac_executable_extensions; do 11325 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11326 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11327 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11328 break 2 11329 fi 11330 done 11331 done 11332 IFS=$as_save_IFS 11333 11334 ;; 11335 esac 11336 fi 11337 TAR=$ac_cv_path_TAR 11338 if test -n "$TAR"; then 11339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11340 $as_echo "$TAR" >&6; } 11341 else 11342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11343 $as_echo "no" >&6; } 11344 fi 11345 11346 11347 test -n "$TAR" && break 11348 done 11349 11350 else 11351 # The variable is set, but is it from the command line or the environment? 11352 11353 # Try to remove the string !TAR! from our list. 11354 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11355 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11356 # If it failed, the variable was not from the command line. Ignore it, 11357 # but warn the user (except for BASH, which is always set by the calling BASH). 11358 if test "xTAR" != xBASH; then 11359 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11360 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11361 fi 11362 # Try to locate tool using the code snippet 11363 for ac_prog in gtar tar 11364 do 11365 # Extract the first word of "$ac_prog", so it can be a program name with args. 11366 set dummy $ac_prog; ac_word=$2 11367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11368 $as_echo_n "checking for $ac_word... " >&6; } 11369 if ${ac_cv_path_TAR+:} false; then : 11370 $as_echo_n "(cached) " >&6 11371 else 11372 case $TAR in 11373 [\\/]* | ?:[\\/]*) 11374 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11375 ;; 11376 *) 11377 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11378 for as_dir in $PATH 11379 do 11380 IFS=$as_save_IFS 11381 test -z "$as_dir" && as_dir=. 11382 for ac_exec_ext in '' $ac_executable_extensions; do 11383 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11384 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11385 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11386 break 2 11387 fi 11388 done 11389 done 11390 IFS=$as_save_IFS 11391 11392 ;; 11393 esac 11394 fi 11395 TAR=$ac_cv_path_TAR 11396 if test -n "$TAR"; then 11397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11398 $as_echo "$TAR" >&6; } 11399 else 11400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11401 $as_echo "no" >&6; } 11402 fi 11403 11404 11405 test -n "$TAR" && break 11406 done 11407 11408 else 11409 # If it succeeded, then it was overridden by the user. We will use it 11410 # for the tool. 11411 11412 # First remove it from the list of overridden variables, so we can test 11413 # for unknown variables in the end. 11414 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11415 11416 # Check if we try to supply an empty value 11417 if test "x$TAR" = x; then 11418 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11419 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11421 $as_echo_n "checking for TAR... " >&6; } 11422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11423 $as_echo "disabled" >&6; } 11424 else 11425 # Check if the provided tool contains a complete path. 11426 tool_specified="$TAR" 11427 tool_basename="${tool_specified##*/}" 11428 if test "x$tool_basename" = "x$tool_specified"; then 11429 # A command without a complete path is provided, search $PATH. 11430 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11431 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11432 # Extract the first word of "$tool_basename", so it can be a program name with args. 11433 set dummy $tool_basename; ac_word=$2 11434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11435 $as_echo_n "checking for $ac_word... " >&6; } 11436 if ${ac_cv_path_TAR+:} false; then : 11437 $as_echo_n "(cached) " >&6 11438 else 11439 case $TAR in 11440 [\\/]* | ?:[\\/]*) 11441 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11442 ;; 11443 *) 11444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11445 for as_dir in $PATH 11446 do 11447 IFS=$as_save_IFS 11448 test -z "$as_dir" && as_dir=. 11449 for ac_exec_ext in '' $ac_executable_extensions; do 11450 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11451 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11452 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11453 break 2 11454 fi 11455 done 11456 done 11457 IFS=$as_save_IFS 11458 11459 ;; 11460 esac 11461 fi 11462 TAR=$ac_cv_path_TAR 11463 if test -n "$TAR"; then 11464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11465 $as_echo "$TAR" >&6; } 11466 else 11467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11468 $as_echo "no" >&6; } 11469 fi 11470 11471 11472 if test "x$TAR" = x; then 11473 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11474 fi 11475 else 11476 # Otherwise we believe it is a complete path. Use it as it is. 11477 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11478 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11480 $as_echo_n "checking for TAR... " >&6; } 11481 if test ! -x "$tool_specified"; then 11482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11483 $as_echo "not found" >&6; } 11484 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11485 fi 11486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11487 $as_echo "$tool_specified" >&6; } 11488 fi 11489 fi 11490 fi 11491 11492 fi 11493 11494 11495 11496 if test "x$TAR" = x; then 11497 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11498 fi 11499 11500 11501 11502 11503 11504 # Publish this variable in the help. 11505 11506 11507 if [ -z "${TEE+x}" ]; then 11508 # The variable is not set by user, try to locate tool using the code snippet 11509 for ac_prog in tee 11510 do 11511 # Extract the first word of "$ac_prog", so it can be a program name with args. 11512 set dummy $ac_prog; ac_word=$2 11513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11514 $as_echo_n "checking for $ac_word... " >&6; } 11515 if ${ac_cv_path_TEE+:} false; then : 11516 $as_echo_n "(cached) " >&6 11517 else 11518 case $TEE in 11519 [\\/]* | ?:[\\/]*) 11520 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11521 ;; 11522 *) 11523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11524 for as_dir in $PATH 11525 do 11526 IFS=$as_save_IFS 11527 test -z "$as_dir" && as_dir=. 11528 for ac_exec_ext in '' $ac_executable_extensions; do 11529 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11530 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11532 break 2 11533 fi 11534 done 11535 done 11536 IFS=$as_save_IFS 11537 11538 ;; 11539 esac 11540 fi 11541 TEE=$ac_cv_path_TEE 11542 if test -n "$TEE"; then 11543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11544 $as_echo "$TEE" >&6; } 11545 else 11546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11547 $as_echo "no" >&6; } 11548 fi 11549 11550 11551 test -n "$TEE" && break 11552 done 11553 11554 else 11555 # The variable is set, but is it from the command line or the environment? 11556 11557 # Try to remove the string !TEE! from our list. 11558 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11559 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11560 # If it failed, the variable was not from the command line. Ignore it, 11561 # but warn the user (except for BASH, which is always set by the calling BASH). 11562 if test "xTEE" != xBASH; then 11563 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11564 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11565 fi 11566 # Try to locate tool using the code snippet 11567 for ac_prog in tee 11568 do 11569 # Extract the first word of "$ac_prog", so it can be a program name with args. 11570 set dummy $ac_prog; ac_word=$2 11571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11572 $as_echo_n "checking for $ac_word... " >&6; } 11573 if ${ac_cv_path_TEE+:} false; then : 11574 $as_echo_n "(cached) " >&6 11575 else 11576 case $TEE in 11577 [\\/]* | ?:[\\/]*) 11578 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11579 ;; 11580 *) 11581 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11582 for as_dir in $PATH 11583 do 11584 IFS=$as_save_IFS 11585 test -z "$as_dir" && as_dir=. 11586 for ac_exec_ext in '' $ac_executable_extensions; do 11587 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11588 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11589 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11590 break 2 11591 fi 11592 done 11593 done 11594 IFS=$as_save_IFS 11595 11596 ;; 11597 esac 11598 fi 11599 TEE=$ac_cv_path_TEE 11600 if test -n "$TEE"; then 11601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11602 $as_echo "$TEE" >&6; } 11603 else 11604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11605 $as_echo "no" >&6; } 11606 fi 11607 11608 11609 test -n "$TEE" && break 11610 done 11611 11612 else 11613 # If it succeeded, then it was overridden by the user. We will use it 11614 # for the tool. 11615 11616 # First remove it from the list of overridden variables, so we can test 11617 # for unknown variables in the end. 11618 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11619 11620 # Check if we try to supply an empty value 11621 if test "x$TEE" = x; then 11622 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11623 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11625 $as_echo_n "checking for TEE... " >&6; } 11626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11627 $as_echo "disabled" >&6; } 11628 else 11629 # Check if the provided tool contains a complete path. 11630 tool_specified="$TEE" 11631 tool_basename="${tool_specified##*/}" 11632 if test "x$tool_basename" = "x$tool_specified"; then 11633 # A command without a complete path is provided, search $PATH. 11634 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11635 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11636 # Extract the first word of "$tool_basename", so it can be a program name with args. 11637 set dummy $tool_basename; ac_word=$2 11638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11639 $as_echo_n "checking for $ac_word... " >&6; } 11640 if ${ac_cv_path_TEE+:} false; then : 11641 $as_echo_n "(cached) " >&6 11642 else 11643 case $TEE in 11644 [\\/]* | ?:[\\/]*) 11645 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11646 ;; 11647 *) 11648 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11649 for as_dir in $PATH 11650 do 11651 IFS=$as_save_IFS 11652 test -z "$as_dir" && as_dir=. 11653 for ac_exec_ext in '' $ac_executable_extensions; do 11654 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11655 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11656 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11657 break 2 11658 fi 11659 done 11660 done 11661 IFS=$as_save_IFS 11662 11663 ;; 11664 esac 11665 fi 11666 TEE=$ac_cv_path_TEE 11667 if test -n "$TEE"; then 11668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11669 $as_echo "$TEE" >&6; } 11670 else 11671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11672 $as_echo "no" >&6; } 11673 fi 11674 11675 11676 if test "x$TEE" = x; then 11677 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11678 fi 11679 else 11680 # Otherwise we believe it is a complete path. Use it as it is. 11681 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11682 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11684 $as_echo_n "checking for TEE... " >&6; } 11685 if test ! -x "$tool_specified"; then 11686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11687 $as_echo "not found" >&6; } 11688 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11689 fi 11690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11691 $as_echo "$tool_specified" >&6; } 11692 fi 11693 fi 11694 fi 11695 11696 fi 11697 11698 11699 11700 if test "x$TEE" = x; then 11701 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11702 fi 11703 11704 11705 11706 11707 11708 # Publish this variable in the help. 11709 11710 11711 if [ -z "${TOUCH+x}" ]; then 11712 # The variable is not set by user, try to locate tool using the code snippet 11713 for ac_prog in touch 11714 do 11715 # Extract the first word of "$ac_prog", so it can be a program name with args. 11716 set dummy $ac_prog; ac_word=$2 11717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11718 $as_echo_n "checking for $ac_word... " >&6; } 11719 if ${ac_cv_path_TOUCH+:} false; then : 11720 $as_echo_n "(cached) " >&6 11721 else 11722 case $TOUCH in 11723 [\\/]* | ?:[\\/]*) 11724 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11725 ;; 11726 *) 11727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11728 for as_dir in $PATH 11729 do 11730 IFS=$as_save_IFS 11731 test -z "$as_dir" && as_dir=. 11732 for ac_exec_ext in '' $ac_executable_extensions; do 11733 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11734 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11736 break 2 11737 fi 11738 done 11739 done 11740 IFS=$as_save_IFS 11741 11742 ;; 11743 esac 11744 fi 11745 TOUCH=$ac_cv_path_TOUCH 11746 if test -n "$TOUCH"; then 11747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11748 $as_echo "$TOUCH" >&6; } 11749 else 11750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11751 $as_echo "no" >&6; } 11752 fi 11753 11754 11755 test -n "$TOUCH" && break 11756 done 11757 11758 else 11759 # The variable is set, but is it from the command line or the environment? 11760 11761 # Try to remove the string !TOUCH! from our list. 11762 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11763 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11764 # If it failed, the variable was not from the command line. Ignore it, 11765 # but warn the user (except for BASH, which is always set by the calling BASH). 11766 if test "xTOUCH" != xBASH; then 11767 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11768 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11769 fi 11770 # Try to locate tool using the code snippet 11771 for ac_prog in touch 11772 do 11773 # Extract the first word of "$ac_prog", so it can be a program name with args. 11774 set dummy $ac_prog; ac_word=$2 11775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11776 $as_echo_n "checking for $ac_word... " >&6; } 11777 if ${ac_cv_path_TOUCH+:} false; then : 11778 $as_echo_n "(cached) " >&6 11779 else 11780 case $TOUCH in 11781 [\\/]* | ?:[\\/]*) 11782 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11783 ;; 11784 *) 11785 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11786 for as_dir in $PATH 11787 do 11788 IFS=$as_save_IFS 11789 test -z "$as_dir" && as_dir=. 11790 for ac_exec_ext in '' $ac_executable_extensions; do 11791 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11792 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11793 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11794 break 2 11795 fi 11796 done 11797 done 11798 IFS=$as_save_IFS 11799 11800 ;; 11801 esac 11802 fi 11803 TOUCH=$ac_cv_path_TOUCH 11804 if test -n "$TOUCH"; then 11805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11806 $as_echo "$TOUCH" >&6; } 11807 else 11808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11809 $as_echo "no" >&6; } 11810 fi 11811 11812 11813 test -n "$TOUCH" && break 11814 done 11815 11816 else 11817 # If it succeeded, then it was overridden by the user. We will use it 11818 # for the tool. 11819 11820 # First remove it from the list of overridden variables, so we can test 11821 # for unknown variables in the end. 11822 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11823 11824 # Check if we try to supply an empty value 11825 if test "x$TOUCH" = x; then 11826 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11827 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11829 $as_echo_n "checking for TOUCH... " >&6; } 11830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11831 $as_echo "disabled" >&6; } 11832 else 11833 # Check if the provided tool contains a complete path. 11834 tool_specified="$TOUCH" 11835 tool_basename="${tool_specified##*/}" 11836 if test "x$tool_basename" = "x$tool_specified"; then 11837 # A command without a complete path is provided, search $PATH. 11838 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11839 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11840 # Extract the first word of "$tool_basename", so it can be a program name with args. 11841 set dummy $tool_basename; ac_word=$2 11842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11843 $as_echo_n "checking for $ac_word... " >&6; } 11844 if ${ac_cv_path_TOUCH+:} false; then : 11845 $as_echo_n "(cached) " >&6 11846 else 11847 case $TOUCH in 11848 [\\/]* | ?:[\\/]*) 11849 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11850 ;; 11851 *) 11852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11853 for as_dir in $PATH 11854 do 11855 IFS=$as_save_IFS 11856 test -z "$as_dir" && as_dir=. 11857 for ac_exec_ext in '' $ac_executable_extensions; do 11858 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11859 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11860 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11861 break 2 11862 fi 11863 done 11864 done 11865 IFS=$as_save_IFS 11866 11867 ;; 11868 esac 11869 fi 11870 TOUCH=$ac_cv_path_TOUCH 11871 if test -n "$TOUCH"; then 11872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11873 $as_echo "$TOUCH" >&6; } 11874 else 11875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11876 $as_echo "no" >&6; } 11877 fi 11878 11879 11880 if test "x$TOUCH" = x; then 11881 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11882 fi 11883 else 11884 # Otherwise we believe it is a complete path. Use it as it is. 11885 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11886 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11888 $as_echo_n "checking for TOUCH... " >&6; } 11889 if test ! -x "$tool_specified"; then 11890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11891 $as_echo "not found" >&6; } 11892 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11893 fi 11894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11895 $as_echo "$tool_specified" >&6; } 11896 fi 11897 fi 11898 fi 11899 11900 fi 11901 11902 11903 11904 if test "x$TOUCH" = x; then 11905 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11906 fi 11907 11908 11909 11910 11911 11912 # Publish this variable in the help. 11913 11914 11915 if [ -z "${TR+x}" ]; then 11916 # The variable is not set by user, try to locate tool using the code snippet 11917 for ac_prog in tr 11918 do 11919 # Extract the first word of "$ac_prog", so it can be a program name with args. 11920 set dummy $ac_prog; ac_word=$2 11921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11922 $as_echo_n "checking for $ac_word... " >&6; } 11923 if ${ac_cv_path_TR+:} false; then : 11924 $as_echo_n "(cached) " >&6 11925 else 11926 case $TR in 11927 [\\/]* | ?:[\\/]*) 11928 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11929 ;; 11930 *) 11931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11932 for as_dir in $PATH 11933 do 11934 IFS=$as_save_IFS 11935 test -z "$as_dir" && as_dir=. 11936 for ac_exec_ext in '' $ac_executable_extensions; do 11937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11938 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11940 break 2 11941 fi 11942 done 11943 done 11944 IFS=$as_save_IFS 11945 11946 ;; 11947 esac 11948 fi 11949 TR=$ac_cv_path_TR 11950 if test -n "$TR"; then 11951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11952 $as_echo "$TR" >&6; } 11953 else 11954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11955 $as_echo "no" >&6; } 11956 fi 11957 11958 11959 test -n "$TR" && break 11960 done 11961 11962 else 11963 # The variable is set, but is it from the command line or the environment? 11964 11965 # Try to remove the string !TR! from our list. 11966 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 11967 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11968 # If it failed, the variable was not from the command line. Ignore it, 11969 # but warn the user (except for BASH, which is always set by the calling BASH). 11970 if test "xTR" != xBASH; then 11971 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 11972 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 11973 fi 11974 # Try to locate tool using the code snippet 11975 for ac_prog in tr 11976 do 11977 # Extract the first word of "$ac_prog", so it can be a program name with args. 11978 set dummy $ac_prog; ac_word=$2 11979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11980 $as_echo_n "checking for $ac_word... " >&6; } 11981 if ${ac_cv_path_TR+:} false; then : 11982 $as_echo_n "(cached) " >&6 11983 else 11984 case $TR in 11985 [\\/]* | ?:[\\/]*) 11986 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11987 ;; 11988 *) 11989 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11990 for as_dir in $PATH 11991 do 11992 IFS=$as_save_IFS 11993 test -z "$as_dir" && as_dir=. 11994 for ac_exec_ext in '' $ac_executable_extensions; do 11995 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11996 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11997 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11998 break 2 11999 fi 12000 done 12001 done 12002 IFS=$as_save_IFS 12003 12004 ;; 12005 esac 12006 fi 12007 TR=$ac_cv_path_TR 12008 if test -n "$TR"; then 12009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12010 $as_echo "$TR" >&6; } 12011 else 12012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12013 $as_echo "no" >&6; } 12014 fi 12015 12016 12017 test -n "$TR" && break 12018 done 12019 12020 else 12021 # If it succeeded, then it was overridden by the user. We will use it 12022 # for the tool. 12023 12024 # First remove it from the list of overridden variables, so we can test 12025 # for unknown variables in the end. 12026 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12027 12028 # Check if we try to supply an empty value 12029 if test "x$TR" = x; then 12030 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12031 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12033 $as_echo_n "checking for TR... " >&6; } 12034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12035 $as_echo "disabled" >&6; } 12036 else 12037 # Check if the provided tool contains a complete path. 12038 tool_specified="$TR" 12039 tool_basename="${tool_specified##*/}" 12040 if test "x$tool_basename" = "x$tool_specified"; then 12041 # A command without a complete path is provided, search $PATH. 12042 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12043 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12044 # Extract the first word of "$tool_basename", so it can be a program name with args. 12045 set dummy $tool_basename; ac_word=$2 12046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12047 $as_echo_n "checking for $ac_word... " >&6; } 12048 if ${ac_cv_path_TR+:} false; then : 12049 $as_echo_n "(cached) " >&6 12050 else 12051 case $TR in 12052 [\\/]* | ?:[\\/]*) 12053 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12054 ;; 12055 *) 12056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12057 for as_dir in $PATH 12058 do 12059 IFS=$as_save_IFS 12060 test -z "$as_dir" && as_dir=. 12061 for ac_exec_ext in '' $ac_executable_extensions; do 12062 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12063 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12065 break 2 12066 fi 12067 done 12068 done 12069 IFS=$as_save_IFS 12070 12071 ;; 12072 esac 12073 fi 12074 TR=$ac_cv_path_TR 12075 if test -n "$TR"; then 12076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12077 $as_echo "$TR" >&6; } 12078 else 12079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12080 $as_echo "no" >&6; } 12081 fi 12082 12083 12084 if test "x$TR" = x; then 12085 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12086 fi 12087 else 12088 # Otherwise we believe it is a complete path. Use it as it is. 12089 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12090 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12092 $as_echo_n "checking for TR... " >&6; } 12093 if test ! -x "$tool_specified"; then 12094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12095 $as_echo "not found" >&6; } 12096 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12097 fi 12098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12099 $as_echo "$tool_specified" >&6; } 12100 fi 12101 fi 12102 fi 12103 12104 fi 12105 12106 12107 12108 if test "x$TR" = x; then 12109 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12110 fi 12111 12112 12113 12114 12115 12116 # Publish this variable in the help. 12117 12118 12119 if [ -z "${UNAME+x}" ]; then 12120 # The variable is not set by user, try to locate tool using the code snippet 12121 for ac_prog in uname 12122 do 12123 # Extract the first word of "$ac_prog", so it can be a program name with args. 12124 set dummy $ac_prog; ac_word=$2 12125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12126 $as_echo_n "checking for $ac_word... " >&6; } 12127 if ${ac_cv_path_UNAME+:} false; then : 12128 $as_echo_n "(cached) " >&6 12129 else 12130 case $UNAME in 12131 [\\/]* | ?:[\\/]*) 12132 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12133 ;; 12134 *) 12135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12136 for as_dir in $PATH 12137 do 12138 IFS=$as_save_IFS 12139 test -z "$as_dir" && as_dir=. 12140 for ac_exec_ext in '' $ac_executable_extensions; do 12141 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12142 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12143 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12144 break 2 12145 fi 12146 done 12147 done 12148 IFS=$as_save_IFS 12149 12150 ;; 12151 esac 12152 fi 12153 UNAME=$ac_cv_path_UNAME 12154 if test -n "$UNAME"; then 12155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12156 $as_echo "$UNAME" >&6; } 12157 else 12158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12159 $as_echo "no" >&6; } 12160 fi 12161 12162 12163 test -n "$UNAME" && break 12164 done 12165 12166 else 12167 # The variable is set, but is it from the command line or the environment? 12168 12169 # Try to remove the string !UNAME! from our list. 12170 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12171 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12172 # If it failed, the variable was not from the command line. Ignore it, 12173 # but warn the user (except for BASH, which is always set by the calling BASH). 12174 if test "xUNAME" != xBASH; then 12175 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12176 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12177 fi 12178 # Try to locate tool using the code snippet 12179 for ac_prog in uname 12180 do 12181 # Extract the first word of "$ac_prog", so it can be a program name with args. 12182 set dummy $ac_prog; ac_word=$2 12183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12184 $as_echo_n "checking for $ac_word... " >&6; } 12185 if ${ac_cv_path_UNAME+:} false; then : 12186 $as_echo_n "(cached) " >&6 12187 else 12188 case $UNAME in 12189 [\\/]* | ?:[\\/]*) 12190 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12191 ;; 12192 *) 12193 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12194 for as_dir in $PATH 12195 do 12196 IFS=$as_save_IFS 12197 test -z "$as_dir" && as_dir=. 12198 for ac_exec_ext in '' $ac_executable_extensions; do 12199 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12200 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12201 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12202 break 2 12203 fi 12204 done 12205 done 12206 IFS=$as_save_IFS 12207 12208 ;; 12209 esac 12210 fi 12211 UNAME=$ac_cv_path_UNAME 12212 if test -n "$UNAME"; then 12213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12214 $as_echo "$UNAME" >&6; } 12215 else 12216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12217 $as_echo "no" >&6; } 12218 fi 12219 12220 12221 test -n "$UNAME" && break 12222 done 12223 12224 else 12225 # If it succeeded, then it was overridden by the user. We will use it 12226 # for the tool. 12227 12228 # First remove it from the list of overridden variables, so we can test 12229 # for unknown variables in the end. 12230 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12231 12232 # Check if we try to supply an empty value 12233 if test "x$UNAME" = x; then 12234 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12235 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12237 $as_echo_n "checking for UNAME... " >&6; } 12238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12239 $as_echo "disabled" >&6; } 12240 else 12241 # Check if the provided tool contains a complete path. 12242 tool_specified="$UNAME" 12243 tool_basename="${tool_specified##*/}" 12244 if test "x$tool_basename" = "x$tool_specified"; then 12245 # A command without a complete path is provided, search $PATH. 12246 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12247 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12248 # Extract the first word of "$tool_basename", so it can be a program name with args. 12249 set dummy $tool_basename; ac_word=$2 12250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12251 $as_echo_n "checking for $ac_word... " >&6; } 12252 if ${ac_cv_path_UNAME+:} false; then : 12253 $as_echo_n "(cached) " >&6 12254 else 12255 case $UNAME in 12256 [\\/]* | ?:[\\/]*) 12257 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12258 ;; 12259 *) 12260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12261 for as_dir in $PATH 12262 do 12263 IFS=$as_save_IFS 12264 test -z "$as_dir" && as_dir=. 12265 for ac_exec_ext in '' $ac_executable_extensions; do 12266 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12267 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12268 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12269 break 2 12270 fi 12271 done 12272 done 12273 IFS=$as_save_IFS 12274 12275 ;; 12276 esac 12277 fi 12278 UNAME=$ac_cv_path_UNAME 12279 if test -n "$UNAME"; then 12280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12281 $as_echo "$UNAME" >&6; } 12282 else 12283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12284 $as_echo "no" >&6; } 12285 fi 12286 12287 12288 if test "x$UNAME" = x; then 12289 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12290 fi 12291 else 12292 # Otherwise we believe it is a complete path. Use it as it is. 12293 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12294 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12296 $as_echo_n "checking for UNAME... " >&6; } 12297 if test ! -x "$tool_specified"; then 12298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12299 $as_echo "not found" >&6; } 12300 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12301 fi 12302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12303 $as_echo "$tool_specified" >&6; } 12304 fi 12305 fi 12306 fi 12307 12308 fi 12309 12310 12311 12312 if test "x$UNAME" = x; then 12313 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12314 fi 12315 12316 12317 12318 12319 12320 # Publish this variable in the help. 12321 12322 12323 if [ -z "${UNIQ+x}" ]; then 12324 # The variable is not set by user, try to locate tool using the code snippet 12325 for ac_prog in uniq 12326 do 12327 # Extract the first word of "$ac_prog", so it can be a program name with args. 12328 set dummy $ac_prog; ac_word=$2 12329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12330 $as_echo_n "checking for $ac_word... " >&6; } 12331 if ${ac_cv_path_UNIQ+:} false; then : 12332 $as_echo_n "(cached) " >&6 12333 else 12334 case $UNIQ in 12335 [\\/]* | ?:[\\/]*) 12336 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12337 ;; 12338 *) 12339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12340 for as_dir in $PATH 12341 do 12342 IFS=$as_save_IFS 12343 test -z "$as_dir" && as_dir=. 12344 for ac_exec_ext in '' $ac_executable_extensions; do 12345 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12346 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12347 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12348 break 2 12349 fi 12350 done 12351 done 12352 IFS=$as_save_IFS 12353 12354 ;; 12355 esac 12356 fi 12357 UNIQ=$ac_cv_path_UNIQ 12358 if test -n "$UNIQ"; then 12359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12360 $as_echo "$UNIQ" >&6; } 12361 else 12362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12363 $as_echo "no" >&6; } 12364 fi 12365 12366 12367 test -n "$UNIQ" && break 12368 done 12369 12370 else 12371 # The variable is set, but is it from the command line or the environment? 12372 12373 # Try to remove the string !UNIQ! from our list. 12374 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12375 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12376 # If it failed, the variable was not from the command line. Ignore it, 12377 # but warn the user (except for BASH, which is always set by the calling BASH). 12378 if test "xUNIQ" != xBASH; then 12379 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12380 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12381 fi 12382 # Try to locate tool using the code snippet 12383 for ac_prog in uniq 12384 do 12385 # Extract the first word of "$ac_prog", so it can be a program name with args. 12386 set dummy $ac_prog; ac_word=$2 12387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12388 $as_echo_n "checking for $ac_word... " >&6; } 12389 if ${ac_cv_path_UNIQ+:} false; then : 12390 $as_echo_n "(cached) " >&6 12391 else 12392 case $UNIQ in 12393 [\\/]* | ?:[\\/]*) 12394 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12395 ;; 12396 *) 12397 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12398 for as_dir in $PATH 12399 do 12400 IFS=$as_save_IFS 12401 test -z "$as_dir" && as_dir=. 12402 for ac_exec_ext in '' $ac_executable_extensions; do 12403 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12404 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12405 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12406 break 2 12407 fi 12408 done 12409 done 12410 IFS=$as_save_IFS 12411 12412 ;; 12413 esac 12414 fi 12415 UNIQ=$ac_cv_path_UNIQ 12416 if test -n "$UNIQ"; then 12417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12418 $as_echo "$UNIQ" >&6; } 12419 else 12420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12421 $as_echo "no" >&6; } 12422 fi 12423 12424 12425 test -n "$UNIQ" && break 12426 done 12427 12428 else 12429 # If it succeeded, then it was overridden by the user. We will use it 12430 # for the tool. 12431 12432 # First remove it from the list of overridden variables, so we can test 12433 # for unknown variables in the end. 12434 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12435 12436 # Check if we try to supply an empty value 12437 if test "x$UNIQ" = x; then 12438 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12439 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12441 $as_echo_n "checking for UNIQ... " >&6; } 12442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12443 $as_echo "disabled" >&6; } 12444 else 12445 # Check if the provided tool contains a complete path. 12446 tool_specified="$UNIQ" 12447 tool_basename="${tool_specified##*/}" 12448 if test "x$tool_basename" = "x$tool_specified"; then 12449 # A command without a complete path is provided, search $PATH. 12450 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12451 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12452 # Extract the first word of "$tool_basename", so it can be a program name with args. 12453 set dummy $tool_basename; ac_word=$2 12454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12455 $as_echo_n "checking for $ac_word... " >&6; } 12456 if ${ac_cv_path_UNIQ+:} false; then : 12457 $as_echo_n "(cached) " >&6 12458 else 12459 case $UNIQ in 12460 [\\/]* | ?:[\\/]*) 12461 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12462 ;; 12463 *) 12464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12465 for as_dir in $PATH 12466 do 12467 IFS=$as_save_IFS 12468 test -z "$as_dir" && as_dir=. 12469 for ac_exec_ext in '' $ac_executable_extensions; do 12470 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12471 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12472 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12473 break 2 12474 fi 12475 done 12476 done 12477 IFS=$as_save_IFS 12478 12479 ;; 12480 esac 12481 fi 12482 UNIQ=$ac_cv_path_UNIQ 12483 if test -n "$UNIQ"; then 12484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12485 $as_echo "$UNIQ" >&6; } 12486 else 12487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12488 $as_echo "no" >&6; } 12489 fi 12490 12491 12492 if test "x$UNIQ" = x; then 12493 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12494 fi 12495 else 12496 # Otherwise we believe it is a complete path. Use it as it is. 12497 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12498 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12500 $as_echo_n "checking for UNIQ... " >&6; } 12501 if test ! -x "$tool_specified"; then 12502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12503 $as_echo "not found" >&6; } 12504 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12505 fi 12506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12507 $as_echo "$tool_specified" >&6; } 12508 fi 12509 fi 12510 fi 12511 12512 fi 12513 12514 12515 12516 if test "x$UNIQ" = x; then 12517 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12518 fi 12519 12520 12521 12522 12523 12524 # Publish this variable in the help. 12525 12526 12527 if [ -z "${WC+x}" ]; then 12528 # The variable is not set by user, try to locate tool using the code snippet 12529 for ac_prog in wc 12530 do 12531 # Extract the first word of "$ac_prog", so it can be a program name with args. 12532 set dummy $ac_prog; ac_word=$2 12533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12534 $as_echo_n "checking for $ac_word... " >&6; } 12535 if ${ac_cv_path_WC+:} false; then : 12536 $as_echo_n "(cached) " >&6 12537 else 12538 case $WC in 12539 [\\/]* | ?:[\\/]*) 12540 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12541 ;; 12542 *) 12543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12544 for as_dir in $PATH 12545 do 12546 IFS=$as_save_IFS 12547 test -z "$as_dir" && as_dir=. 12548 for ac_exec_ext in '' $ac_executable_extensions; do 12549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12550 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12552 break 2 12553 fi 12554 done 12555 done 12556 IFS=$as_save_IFS 12557 12558 ;; 12559 esac 12560 fi 12561 WC=$ac_cv_path_WC 12562 if test -n "$WC"; then 12563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12564 $as_echo "$WC" >&6; } 12565 else 12566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12567 $as_echo "no" >&6; } 12568 fi 12569 12570 12571 test -n "$WC" && break 12572 done 12573 12574 else 12575 # The variable is set, but is it from the command line or the environment? 12576 12577 # Try to remove the string !WC! from our list. 12578 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12579 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12580 # If it failed, the variable was not from the command line. Ignore it, 12581 # but warn the user (except for BASH, which is always set by the calling BASH). 12582 if test "xWC" != xBASH; then 12583 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12584 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12585 fi 12586 # Try to locate tool using the code snippet 12587 for ac_prog in wc 12588 do 12589 # Extract the first word of "$ac_prog", so it can be a program name with args. 12590 set dummy $ac_prog; ac_word=$2 12591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12592 $as_echo_n "checking for $ac_word... " >&6; } 12593 if ${ac_cv_path_WC+:} false; then : 12594 $as_echo_n "(cached) " >&6 12595 else 12596 case $WC in 12597 [\\/]* | ?:[\\/]*) 12598 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12599 ;; 12600 *) 12601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12602 for as_dir in $PATH 12603 do 12604 IFS=$as_save_IFS 12605 test -z "$as_dir" && as_dir=. 12606 for ac_exec_ext in '' $ac_executable_extensions; do 12607 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12608 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12610 break 2 12611 fi 12612 done 12613 done 12614 IFS=$as_save_IFS 12615 12616 ;; 12617 esac 12618 fi 12619 WC=$ac_cv_path_WC 12620 if test -n "$WC"; then 12621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12622 $as_echo "$WC" >&6; } 12623 else 12624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12625 $as_echo "no" >&6; } 12626 fi 12627 12628 12629 test -n "$WC" && break 12630 done 12631 12632 else 12633 # If it succeeded, then it was overridden by the user. We will use it 12634 # for the tool. 12635 12636 # First remove it from the list of overridden variables, so we can test 12637 # for unknown variables in the end. 12638 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12639 12640 # Check if we try to supply an empty value 12641 if test "x$WC" = x; then 12642 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12643 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12645 $as_echo_n "checking for WC... " >&6; } 12646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12647 $as_echo "disabled" >&6; } 12648 else 12649 # Check if the provided tool contains a complete path. 12650 tool_specified="$WC" 12651 tool_basename="${tool_specified##*/}" 12652 if test "x$tool_basename" = "x$tool_specified"; then 12653 # A command without a complete path is provided, search $PATH. 12654 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12655 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12656 # Extract the first word of "$tool_basename", so it can be a program name with args. 12657 set dummy $tool_basename; ac_word=$2 12658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12659 $as_echo_n "checking for $ac_word... " >&6; } 12660 if ${ac_cv_path_WC+:} false; then : 12661 $as_echo_n "(cached) " >&6 12662 else 12663 case $WC in 12664 [\\/]* | ?:[\\/]*) 12665 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12666 ;; 12667 *) 12668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12669 for as_dir in $PATH 12670 do 12671 IFS=$as_save_IFS 12672 test -z "$as_dir" && as_dir=. 12673 for ac_exec_ext in '' $ac_executable_extensions; do 12674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12675 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12677 break 2 12678 fi 12679 done 12680 done 12681 IFS=$as_save_IFS 12682 12683 ;; 12684 esac 12685 fi 12686 WC=$ac_cv_path_WC 12687 if test -n "$WC"; then 12688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12689 $as_echo "$WC" >&6; } 12690 else 12691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12692 $as_echo "no" >&6; } 12693 fi 12694 12695 12696 if test "x$WC" = x; then 12697 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12698 fi 12699 else 12700 # Otherwise we believe it is a complete path. Use it as it is. 12701 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12702 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12704 $as_echo_n "checking for WC... " >&6; } 12705 if test ! -x "$tool_specified"; then 12706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12707 $as_echo "not found" >&6; } 12708 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12709 fi 12710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12711 $as_echo "$tool_specified" >&6; } 12712 fi 12713 fi 12714 fi 12715 12716 fi 12717 12718 12719 12720 if test "x$WC" = x; then 12721 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12722 fi 12723 12724 12725 12726 12727 12728 # Publish this variable in the help. 12729 12730 12731 if [ -z "${WHICH+x}" ]; then 12732 # The variable is not set by user, try to locate tool using the code snippet 12733 for ac_prog in which 12734 do 12735 # Extract the first word of "$ac_prog", so it can be a program name with args. 12736 set dummy $ac_prog; ac_word=$2 12737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12738 $as_echo_n "checking for $ac_word... " >&6; } 12739 if ${ac_cv_path_WHICH+:} false; then : 12740 $as_echo_n "(cached) " >&6 12741 else 12742 case $WHICH in 12743 [\\/]* | ?:[\\/]*) 12744 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12745 ;; 12746 *) 12747 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12748 for as_dir in $PATH 12749 do 12750 IFS=$as_save_IFS 12751 test -z "$as_dir" && as_dir=. 12752 for ac_exec_ext in '' $ac_executable_extensions; do 12753 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12754 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12755 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12756 break 2 12757 fi 12758 done 12759 done 12760 IFS=$as_save_IFS 12761 12762 ;; 12763 esac 12764 fi 12765 WHICH=$ac_cv_path_WHICH 12766 if test -n "$WHICH"; then 12767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12768 $as_echo "$WHICH" >&6; } 12769 else 12770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12771 $as_echo "no" >&6; } 12772 fi 12773 12774 12775 test -n "$WHICH" && break 12776 done 12777 12778 else 12779 # The variable is set, but is it from the command line or the environment? 12780 12781 # Try to remove the string !WHICH! from our list. 12782 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12783 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12784 # If it failed, the variable was not from the command line. Ignore it, 12785 # but warn the user (except for BASH, which is always set by the calling BASH). 12786 if test "xWHICH" != xBASH; then 12787 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12788 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12789 fi 12790 # Try to locate tool using the code snippet 12791 for ac_prog in which 12792 do 12793 # Extract the first word of "$ac_prog", so it can be a program name with args. 12794 set dummy $ac_prog; ac_word=$2 12795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12796 $as_echo_n "checking for $ac_word... " >&6; } 12797 if ${ac_cv_path_WHICH+:} false; then : 12798 $as_echo_n "(cached) " >&6 12799 else 12800 case $WHICH in 12801 [\\/]* | ?:[\\/]*) 12802 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12803 ;; 12804 *) 12805 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12806 for as_dir in $PATH 12807 do 12808 IFS=$as_save_IFS 12809 test -z "$as_dir" && as_dir=. 12810 for ac_exec_ext in '' $ac_executable_extensions; do 12811 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12812 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12813 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12814 break 2 12815 fi 12816 done 12817 done 12818 IFS=$as_save_IFS 12819 12820 ;; 12821 esac 12822 fi 12823 WHICH=$ac_cv_path_WHICH 12824 if test -n "$WHICH"; then 12825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12826 $as_echo "$WHICH" >&6; } 12827 else 12828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12829 $as_echo "no" >&6; } 12830 fi 12831 12832 12833 test -n "$WHICH" && break 12834 done 12835 12836 else 12837 # If it succeeded, then it was overridden by the user. We will use it 12838 # for the tool. 12839 12840 # First remove it from the list of overridden variables, so we can test 12841 # for unknown variables in the end. 12842 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12843 12844 # Check if we try to supply an empty value 12845 if test "x$WHICH" = x; then 12846 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12847 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12849 $as_echo_n "checking for WHICH... " >&6; } 12850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12851 $as_echo "disabled" >&6; } 12852 else 12853 # Check if the provided tool contains a complete path. 12854 tool_specified="$WHICH" 12855 tool_basename="${tool_specified##*/}" 12856 if test "x$tool_basename" = "x$tool_specified"; then 12857 # A command without a complete path is provided, search $PATH. 12858 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12859 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12860 # Extract the first word of "$tool_basename", so it can be a program name with args. 12861 set dummy $tool_basename; ac_word=$2 12862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12863 $as_echo_n "checking for $ac_word... " >&6; } 12864 if ${ac_cv_path_WHICH+:} false; then : 12865 $as_echo_n "(cached) " >&6 12866 else 12867 case $WHICH in 12868 [\\/]* | ?:[\\/]*) 12869 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12870 ;; 12871 *) 12872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12873 for as_dir in $PATH 12874 do 12875 IFS=$as_save_IFS 12876 test -z "$as_dir" && as_dir=. 12877 for ac_exec_ext in '' $ac_executable_extensions; do 12878 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12879 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12880 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12881 break 2 12882 fi 12883 done 12884 done 12885 IFS=$as_save_IFS 12886 12887 ;; 12888 esac 12889 fi 12890 WHICH=$ac_cv_path_WHICH 12891 if test -n "$WHICH"; then 12892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12893 $as_echo "$WHICH" >&6; } 12894 else 12895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12896 $as_echo "no" >&6; } 12897 fi 12898 12899 12900 if test "x$WHICH" = x; then 12901 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12902 fi 12903 else 12904 # Otherwise we believe it is a complete path. Use it as it is. 12905 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12906 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12908 $as_echo_n "checking for WHICH... " >&6; } 12909 if test ! -x "$tool_specified"; then 12910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12911 $as_echo "not found" >&6; } 12912 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12913 fi 12914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12915 $as_echo "$tool_specified" >&6; } 12916 fi 12917 fi 12918 fi 12919 12920 fi 12921 12922 12923 12924 if test "x$WHICH" = x; then 12925 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12926 fi 12927 12928 12929 12930 12931 12932 # Publish this variable in the help. 12933 12934 12935 if [ -z "${XARGS+x}" ]; then 12936 # The variable is not set by user, try to locate tool using the code snippet 12937 for ac_prog in xargs 12938 do 12939 # Extract the first word of "$ac_prog", so it can be a program name with args. 12940 set dummy $ac_prog; ac_word=$2 12941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12942 $as_echo_n "checking for $ac_word... " >&6; } 12943 if ${ac_cv_path_XARGS+:} false; then : 12944 $as_echo_n "(cached) " >&6 12945 else 12946 case $XARGS in 12947 [\\/]* | ?:[\\/]*) 12948 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12949 ;; 12950 *) 12951 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12952 for as_dir in $PATH 12953 do 12954 IFS=$as_save_IFS 12955 test -z "$as_dir" && as_dir=. 12956 for ac_exec_ext in '' $ac_executable_extensions; do 12957 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12958 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12959 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12960 break 2 12961 fi 12962 done 12963 done 12964 IFS=$as_save_IFS 12965 12966 ;; 12967 esac 12968 fi 12969 XARGS=$ac_cv_path_XARGS 12970 if test -n "$XARGS"; then 12971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12972 $as_echo "$XARGS" >&6; } 12973 else 12974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12975 $as_echo "no" >&6; } 12976 fi 12977 12978 12979 test -n "$XARGS" && break 12980 done 12981 12982 else 12983 # The variable is set, but is it from the command line or the environment? 12984 12985 # Try to remove the string !XARGS! from our list. 12986 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 12987 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12988 # If it failed, the variable was not from the command line. Ignore it, 12989 # but warn the user (except for BASH, which is always set by the calling BASH). 12990 if test "xXARGS" != xBASH; then 12991 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 12992 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 12993 fi 12994 # Try to locate tool using the code snippet 12995 for ac_prog in xargs 12996 do 12997 # Extract the first word of "$ac_prog", so it can be a program name with args. 12998 set dummy $ac_prog; ac_word=$2 12999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13000 $as_echo_n "checking for $ac_word... " >&6; } 13001 if ${ac_cv_path_XARGS+:} false; then : 13002 $as_echo_n "(cached) " >&6 13003 else 13004 case $XARGS in 13005 [\\/]* | ?:[\\/]*) 13006 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13007 ;; 13008 *) 13009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13010 for as_dir in $PATH 13011 do 13012 IFS=$as_save_IFS 13013 test -z "$as_dir" && as_dir=. 13014 for ac_exec_ext in '' $ac_executable_extensions; do 13015 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13016 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13017 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13018 break 2 13019 fi 13020 done 13021 done 13022 IFS=$as_save_IFS 13023 13024 ;; 13025 esac 13026 fi 13027 XARGS=$ac_cv_path_XARGS 13028 if test -n "$XARGS"; then 13029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13030 $as_echo "$XARGS" >&6; } 13031 else 13032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13033 $as_echo "no" >&6; } 13034 fi 13035 13036 13037 test -n "$XARGS" && break 13038 done 13039 13040 else 13041 # If it succeeded, then it was overridden by the user. We will use it 13042 # for the tool. 13043 13044 # First remove it from the list of overridden variables, so we can test 13045 # for unknown variables in the end. 13046 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13047 13048 # Check if we try to supply an empty value 13049 if test "x$XARGS" = x; then 13050 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13051 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13053 $as_echo_n "checking for XARGS... " >&6; } 13054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13055 $as_echo "disabled" >&6; } 13056 else 13057 # Check if the provided tool contains a complete path. 13058 tool_specified="$XARGS" 13059 tool_basename="${tool_specified##*/}" 13060 if test "x$tool_basename" = "x$tool_specified"; then 13061 # A command without a complete path is provided, search $PATH. 13062 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13063 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13064 # Extract the first word of "$tool_basename", so it can be a program name with args. 13065 set dummy $tool_basename; ac_word=$2 13066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13067 $as_echo_n "checking for $ac_word... " >&6; } 13068 if ${ac_cv_path_XARGS+:} false; then : 13069 $as_echo_n "(cached) " >&6 13070 else 13071 case $XARGS in 13072 [\\/]* | ?:[\\/]*) 13073 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13074 ;; 13075 *) 13076 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13077 for as_dir in $PATH 13078 do 13079 IFS=$as_save_IFS 13080 test -z "$as_dir" && as_dir=. 13081 for ac_exec_ext in '' $ac_executable_extensions; do 13082 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13083 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13084 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13085 break 2 13086 fi 13087 done 13088 done 13089 IFS=$as_save_IFS 13090 13091 ;; 13092 esac 13093 fi 13094 XARGS=$ac_cv_path_XARGS 13095 if test -n "$XARGS"; then 13096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13097 $as_echo "$XARGS" >&6; } 13098 else 13099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13100 $as_echo "no" >&6; } 13101 fi 13102 13103 13104 if test "x$XARGS" = x; then 13105 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13106 fi 13107 else 13108 # Otherwise we believe it is a complete path. Use it as it is. 13109 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13110 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13112 $as_echo_n "checking for XARGS... " >&6; } 13113 if test ! -x "$tool_specified"; then 13114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13115 $as_echo "not found" >&6; } 13116 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13117 fi 13118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13119 $as_echo "$tool_specified" >&6; } 13120 fi 13121 fi 13122 fi 13123 13124 fi 13125 13126 13127 13128 if test "x$XARGS" = x; then 13129 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13130 fi 13131 13132 13133 13134 # Then required tools that require some special treatment. 13135 13136 13137 # Publish this variable in the help. 13138 13139 13140 if [ -z "${AWK+x}" ]; then 13141 # The variable is not set by user, try to locate tool using the code snippet 13142 for ac_prog in gawk mawk nawk awk 13143 do 13144 # Extract the first word of "$ac_prog", so it can be a program name with args. 13145 set dummy $ac_prog; ac_word=$2 13146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13147 $as_echo_n "checking for $ac_word... " >&6; } 13148 if ${ac_cv_prog_AWK+:} false; then : 13149 $as_echo_n "(cached) " >&6 13150 else 13151 if test -n "$AWK"; then 13152 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13153 else 13154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13155 for as_dir in $PATH 13156 do 13157 IFS=$as_save_IFS 13158 test -z "$as_dir" && as_dir=. 13159 for ac_exec_ext in '' $ac_executable_extensions; do 13160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13161 ac_cv_prog_AWK="$ac_prog" 13162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13163 break 2 13164 fi 13165 done 13166 done 13167 IFS=$as_save_IFS 13168 13169 fi 13170 fi 13171 AWK=$ac_cv_prog_AWK 13172 if test -n "$AWK"; then 13173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13174 $as_echo "$AWK" >&6; } 13175 else 13176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13177 $as_echo "no" >&6; } 13178 fi 13179 13180 13181 test -n "$AWK" && break 13182 done 13183 13184 else 13185 # The variable is set, but is it from the command line or the environment? 13186 13187 # Try to remove the string !AWK! from our list. 13188 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13189 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13190 # If it failed, the variable was not from the command line. Ignore it, 13191 # but warn the user (except for BASH, which is always set by the calling BASH). 13192 if test "xAWK" != xBASH; then 13193 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13194 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13195 fi 13196 # Try to locate tool using the code snippet 13197 for ac_prog in gawk mawk nawk awk 13198 do 13199 # Extract the first word of "$ac_prog", so it can be a program name with args. 13200 set dummy $ac_prog; ac_word=$2 13201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13202 $as_echo_n "checking for $ac_word... " >&6; } 13203 if ${ac_cv_prog_AWK+:} false; then : 13204 $as_echo_n "(cached) " >&6 13205 else 13206 if test -n "$AWK"; then 13207 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13208 else 13209 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13210 for as_dir in $PATH 13211 do 13212 IFS=$as_save_IFS 13213 test -z "$as_dir" && as_dir=. 13214 for ac_exec_ext in '' $ac_executable_extensions; do 13215 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13216 ac_cv_prog_AWK="$ac_prog" 13217 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13218 break 2 13219 fi 13220 done 13221 done 13222 IFS=$as_save_IFS 13223 13224 fi 13225 fi 13226 AWK=$ac_cv_prog_AWK 13227 if test -n "$AWK"; then 13228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13229 $as_echo "$AWK" >&6; } 13230 else 13231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13232 $as_echo "no" >&6; } 13233 fi 13234 13235 13236 test -n "$AWK" && break 13237 done 13238 13239 else 13240 # If it succeeded, then it was overridden by the user. We will use it 13241 # for the tool. 13242 13243 # First remove it from the list of overridden variables, so we can test 13244 # for unknown variables in the end. 13245 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13246 13247 # Check if we try to supply an empty value 13248 if test "x$AWK" = x; then 13249 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13250 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13252 $as_echo_n "checking for AWK... " >&6; } 13253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13254 $as_echo "disabled" >&6; } 13255 else 13256 # Check if the provided tool contains a complete path. 13257 tool_specified="$AWK" 13258 tool_basename="${tool_specified##*/}" 13259 if test "x$tool_basename" = "x$tool_specified"; then 13260 # A command without a complete path is provided, search $PATH. 13261 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13262 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13263 # Extract the first word of "$tool_basename", so it can be a program name with args. 13264 set dummy $tool_basename; ac_word=$2 13265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13266 $as_echo_n "checking for $ac_word... " >&6; } 13267 if ${ac_cv_path_AWK+:} false; then : 13268 $as_echo_n "(cached) " >&6 13269 else 13270 case $AWK in 13271 [\\/]* | ?:[\\/]*) 13272 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13273 ;; 13274 *) 13275 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13276 for as_dir in $PATH 13277 do 13278 IFS=$as_save_IFS 13279 test -z "$as_dir" && as_dir=. 13280 for ac_exec_ext in '' $ac_executable_extensions; do 13281 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13282 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13283 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13284 break 2 13285 fi 13286 done 13287 done 13288 IFS=$as_save_IFS 13289 13290 ;; 13291 esac 13292 fi 13293 AWK=$ac_cv_path_AWK 13294 if test -n "$AWK"; then 13295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13296 $as_echo "$AWK" >&6; } 13297 else 13298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13299 $as_echo "no" >&6; } 13300 fi 13301 13302 13303 if test "x$AWK" = x; then 13304 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13305 fi 13306 else 13307 # Otherwise we believe it is a complete path. Use it as it is. 13308 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13309 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13311 $as_echo_n "checking for AWK... " >&6; } 13312 if test ! -x "$tool_specified"; then 13313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13314 $as_echo "not found" >&6; } 13315 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13316 fi 13317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13318 $as_echo "$tool_specified" >&6; } 13319 fi 13320 fi 13321 fi 13322 13323 fi 13324 13325 13326 if test "x$AWK" = x; then 13327 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13328 fi 13329 13330 13331 13332 13333 # Publish this variable in the help. 13334 13335 13336 if [ -z "${GREP+x}" ]; then 13337 # The variable is not set by user, try to locate tool using the code snippet 13338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13339 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13340 if ${ac_cv_path_GREP+:} false; then : 13341 $as_echo_n "(cached) " >&6 13342 else 13343 if test -z "$GREP"; then 13344 ac_path_GREP_found=false 13345 # Loop through the user's path and test for each of PROGNAME-LIST 13346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13347 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13348 do 13349 IFS=$as_save_IFS 13350 test -z "$as_dir" && as_dir=. 13351 for ac_prog in grep ggrep; do 13352 for ac_exec_ext in '' $ac_executable_extensions; do 13353 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13354 as_fn_executable_p "$ac_path_GREP" || continue 13355 # Check for GNU ac_path_GREP and select it if it is found. 13356 # Check for GNU $ac_path_GREP 13357 case `"$ac_path_GREP" --version 2>&1` in 13358 *GNU*) 13359 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13360 *) 13361 ac_count=0 13362 $as_echo_n 0123456789 >"conftest.in" 13363 while : 13364 do 13365 cat "conftest.in" "conftest.in" >"conftest.tmp" 13366 mv "conftest.tmp" "conftest.in" 13367 cp "conftest.in" "conftest.nl" 13368 $as_echo 'GREP' >> "conftest.nl" 13369 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13370 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13371 as_fn_arith $ac_count + 1 && ac_count=$as_val 13372 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13373 # Best one so far, save it but keep looking for a better one 13374 ac_cv_path_GREP="$ac_path_GREP" 13375 ac_path_GREP_max=$ac_count 13376 fi 13377 # 10*(2^10) chars as input seems more than enough 13378 test $ac_count -gt 10 && break 13379 done 13380 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13381 esac 13382 13383 $ac_path_GREP_found && break 3 13384 done 13385 done 13386 done 13387 IFS=$as_save_IFS 13388 if test -z "$ac_cv_path_GREP"; then 13389 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13390 fi 13391 else 13392 ac_cv_path_GREP=$GREP 13393 fi 13394 13395 fi 13396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13397 $as_echo "$ac_cv_path_GREP" >&6; } 13398 GREP="$ac_cv_path_GREP" 13399 13400 13401 else 13402 # The variable is set, but is it from the command line or the environment? 13403 13404 # Try to remove the string !GREP! from our list. 13405 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13406 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13407 # If it failed, the variable was not from the command line. Ignore it, 13408 # but warn the user (except for BASH, which is always set by the calling BASH). 13409 if test "xGREP" != xBASH; then 13410 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13411 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13412 fi 13413 # Try to locate tool using the code snippet 13414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13415 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13416 if ${ac_cv_path_GREP+:} false; then : 13417 $as_echo_n "(cached) " >&6 13418 else 13419 if test -z "$GREP"; then 13420 ac_path_GREP_found=false 13421 # Loop through the user's path and test for each of PROGNAME-LIST 13422 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13423 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13424 do 13425 IFS=$as_save_IFS 13426 test -z "$as_dir" && as_dir=. 13427 for ac_prog in grep ggrep; do 13428 for ac_exec_ext in '' $ac_executable_extensions; do 13429 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13430 as_fn_executable_p "$ac_path_GREP" || continue 13431 # Check for GNU ac_path_GREP and select it if it is found. 13432 # Check for GNU $ac_path_GREP 13433 case `"$ac_path_GREP" --version 2>&1` in 13434 *GNU*) 13435 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13436 *) 13437 ac_count=0 13438 $as_echo_n 0123456789 >"conftest.in" 13439 while : 13440 do 13441 cat "conftest.in" "conftest.in" >"conftest.tmp" 13442 mv "conftest.tmp" "conftest.in" 13443 cp "conftest.in" "conftest.nl" 13444 $as_echo 'GREP' >> "conftest.nl" 13445 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13446 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13447 as_fn_arith $ac_count + 1 && ac_count=$as_val 13448 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13449 # Best one so far, save it but keep looking for a better one 13450 ac_cv_path_GREP="$ac_path_GREP" 13451 ac_path_GREP_max=$ac_count 13452 fi 13453 # 10*(2^10) chars as input seems more than enough 13454 test $ac_count -gt 10 && break 13455 done 13456 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13457 esac 13458 13459 $ac_path_GREP_found && break 3 13460 done 13461 done 13462 done 13463 IFS=$as_save_IFS 13464 if test -z "$ac_cv_path_GREP"; then 13465 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13466 fi 13467 else 13468 ac_cv_path_GREP=$GREP 13469 fi 13470 13471 fi 13472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13473 $as_echo "$ac_cv_path_GREP" >&6; } 13474 GREP="$ac_cv_path_GREP" 13475 13476 13477 else 13478 # If it succeeded, then it was overridden by the user. We will use it 13479 # for the tool. 13480 13481 # First remove it from the list of overridden variables, so we can test 13482 # for unknown variables in the end. 13483 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13484 13485 # Check if we try to supply an empty value 13486 if test "x$GREP" = x; then 13487 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13488 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13490 $as_echo_n "checking for GREP... " >&6; } 13491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13492 $as_echo "disabled" >&6; } 13493 else 13494 # Check if the provided tool contains a complete path. 13495 tool_specified="$GREP" 13496 tool_basename="${tool_specified##*/}" 13497 if test "x$tool_basename" = "x$tool_specified"; then 13498 # A command without a complete path is provided, search $PATH. 13499 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13500 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13501 # Extract the first word of "$tool_basename", so it can be a program name with args. 13502 set dummy $tool_basename; ac_word=$2 13503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13504 $as_echo_n "checking for $ac_word... " >&6; } 13505 if ${ac_cv_path_GREP+:} false; then : 13506 $as_echo_n "(cached) " >&6 13507 else 13508 case $GREP in 13509 [\\/]* | ?:[\\/]*) 13510 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13511 ;; 13512 *) 13513 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13514 for as_dir in $PATH 13515 do 13516 IFS=$as_save_IFS 13517 test -z "$as_dir" && as_dir=. 13518 for ac_exec_ext in '' $ac_executable_extensions; do 13519 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13520 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13521 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13522 break 2 13523 fi 13524 done 13525 done 13526 IFS=$as_save_IFS 13527 13528 ;; 13529 esac 13530 fi 13531 GREP=$ac_cv_path_GREP 13532 if test -n "$GREP"; then 13533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13534 $as_echo "$GREP" >&6; } 13535 else 13536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13537 $as_echo "no" >&6; } 13538 fi 13539 13540 13541 if test "x$GREP" = x; then 13542 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13543 fi 13544 else 13545 # Otherwise we believe it is a complete path. Use it as it is. 13546 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13547 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13549 $as_echo_n "checking for GREP... " >&6; } 13550 if test ! -x "$tool_specified"; then 13551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13552 $as_echo "not found" >&6; } 13553 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13554 fi 13555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13556 $as_echo "$tool_specified" >&6; } 13557 fi 13558 fi 13559 fi 13560 13561 fi 13562 13563 13564 if test "x$GREP" = x; then 13565 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13566 fi 13567 13568 13569 13570 13571 # Publish this variable in the help. 13572 13573 13574 if [ -z "${EGREP+x}" ]; then 13575 # The variable is not set by user, try to locate tool using the code snippet 13576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13577 $as_echo_n "checking for egrep... " >&6; } 13578 if ${ac_cv_path_EGREP+:} false; then : 13579 $as_echo_n "(cached) " >&6 13580 else 13581 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13582 then ac_cv_path_EGREP="$GREP -E" 13583 else 13584 if test -z "$EGREP"; then 13585 ac_path_EGREP_found=false 13586 # Loop through the user's path and test for each of PROGNAME-LIST 13587 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13588 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13589 do 13590 IFS=$as_save_IFS 13591 test -z "$as_dir" && as_dir=. 13592 for ac_prog in egrep; do 13593 for ac_exec_ext in '' $ac_executable_extensions; do 13594 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13595 as_fn_executable_p "$ac_path_EGREP" || continue 13596 # Check for GNU ac_path_EGREP and select it if it is found. 13597 # Check for GNU $ac_path_EGREP 13598 case `"$ac_path_EGREP" --version 2>&1` in 13599 *GNU*) 13600 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13601 *) 13602 ac_count=0 13603 $as_echo_n 0123456789 >"conftest.in" 13604 while : 13605 do 13606 cat "conftest.in" "conftest.in" >"conftest.tmp" 13607 mv "conftest.tmp" "conftest.in" 13608 cp "conftest.in" "conftest.nl" 13609 $as_echo 'EGREP' >> "conftest.nl" 13610 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13611 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13612 as_fn_arith $ac_count + 1 && ac_count=$as_val 13613 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13614 # Best one so far, save it but keep looking for a better one 13615 ac_cv_path_EGREP="$ac_path_EGREP" 13616 ac_path_EGREP_max=$ac_count 13617 fi 13618 # 10*(2^10) chars as input seems more than enough 13619 test $ac_count -gt 10 && break 13620 done 13621 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13622 esac 13623 13624 $ac_path_EGREP_found && break 3 13625 done 13626 done 13627 done 13628 IFS=$as_save_IFS 13629 if test -z "$ac_cv_path_EGREP"; then 13630 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13631 fi 13632 else 13633 ac_cv_path_EGREP=$EGREP 13634 fi 13635 13636 fi 13637 fi 13638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13639 $as_echo "$ac_cv_path_EGREP" >&6; } 13640 EGREP="$ac_cv_path_EGREP" 13641 13642 13643 else 13644 # The variable is set, but is it from the command line or the environment? 13645 13646 # Try to remove the string !EGREP! from our list. 13647 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13648 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13649 # If it failed, the variable was not from the command line. Ignore it, 13650 # but warn the user (except for BASH, which is always set by the calling BASH). 13651 if test "xEGREP" != xBASH; then 13652 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13653 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13654 fi 13655 # Try to locate tool using the code snippet 13656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13657 $as_echo_n "checking for egrep... " >&6; } 13658 if ${ac_cv_path_EGREP+:} false; then : 13659 $as_echo_n "(cached) " >&6 13660 else 13661 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13662 then ac_cv_path_EGREP="$GREP -E" 13663 else 13664 if test -z "$EGREP"; then 13665 ac_path_EGREP_found=false 13666 # Loop through the user's path and test for each of PROGNAME-LIST 13667 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13668 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13669 do 13670 IFS=$as_save_IFS 13671 test -z "$as_dir" && as_dir=. 13672 for ac_prog in egrep; do 13673 for ac_exec_ext in '' $ac_executable_extensions; do 13674 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13675 as_fn_executable_p "$ac_path_EGREP" || continue 13676 # Check for GNU ac_path_EGREP and select it if it is found. 13677 # Check for GNU $ac_path_EGREP 13678 case `"$ac_path_EGREP" --version 2>&1` in 13679 *GNU*) 13680 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13681 *) 13682 ac_count=0 13683 $as_echo_n 0123456789 >"conftest.in" 13684 while : 13685 do 13686 cat "conftest.in" "conftest.in" >"conftest.tmp" 13687 mv "conftest.tmp" "conftest.in" 13688 cp "conftest.in" "conftest.nl" 13689 $as_echo 'EGREP' >> "conftest.nl" 13690 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13691 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13692 as_fn_arith $ac_count + 1 && ac_count=$as_val 13693 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13694 # Best one so far, save it but keep looking for a better one 13695 ac_cv_path_EGREP="$ac_path_EGREP" 13696 ac_path_EGREP_max=$ac_count 13697 fi 13698 # 10*(2^10) chars as input seems more than enough 13699 test $ac_count -gt 10 && break 13700 done 13701 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13702 esac 13703 13704 $ac_path_EGREP_found && break 3 13705 done 13706 done 13707 done 13708 IFS=$as_save_IFS 13709 if test -z "$ac_cv_path_EGREP"; then 13710 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13711 fi 13712 else 13713 ac_cv_path_EGREP=$EGREP 13714 fi 13715 13716 fi 13717 fi 13718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13719 $as_echo "$ac_cv_path_EGREP" >&6; } 13720 EGREP="$ac_cv_path_EGREP" 13721 13722 13723 else 13724 # If it succeeded, then it was overridden by the user. We will use it 13725 # for the tool. 13726 13727 # First remove it from the list of overridden variables, so we can test 13728 # for unknown variables in the end. 13729 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13730 13731 # Check if we try to supply an empty value 13732 if test "x$EGREP" = x; then 13733 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13734 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13736 $as_echo_n "checking for EGREP... " >&6; } 13737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13738 $as_echo "disabled" >&6; } 13739 else 13740 # Check if the provided tool contains a complete path. 13741 tool_specified="$EGREP" 13742 tool_basename="${tool_specified##*/}" 13743 if test "x$tool_basename" = "x$tool_specified"; then 13744 # A command without a complete path is provided, search $PATH. 13745 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13746 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13747 # Extract the first word of "$tool_basename", so it can be a program name with args. 13748 set dummy $tool_basename; ac_word=$2 13749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13750 $as_echo_n "checking for $ac_word... " >&6; } 13751 if ${ac_cv_path_EGREP+:} false; then : 13752 $as_echo_n "(cached) " >&6 13753 else 13754 case $EGREP in 13755 [\\/]* | ?:[\\/]*) 13756 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13757 ;; 13758 *) 13759 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13760 for as_dir in $PATH 13761 do 13762 IFS=$as_save_IFS 13763 test -z "$as_dir" && as_dir=. 13764 for ac_exec_ext in '' $ac_executable_extensions; do 13765 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13766 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13767 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13768 break 2 13769 fi 13770 done 13771 done 13772 IFS=$as_save_IFS 13773 13774 ;; 13775 esac 13776 fi 13777 EGREP=$ac_cv_path_EGREP 13778 if test -n "$EGREP"; then 13779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13780 $as_echo "$EGREP" >&6; } 13781 else 13782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13783 $as_echo "no" >&6; } 13784 fi 13785 13786 13787 if test "x$EGREP" = x; then 13788 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13789 fi 13790 else 13791 # Otherwise we believe it is a complete path. Use it as it is. 13792 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13793 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13795 $as_echo_n "checking for EGREP... " >&6; } 13796 if test ! -x "$tool_specified"; then 13797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13798 $as_echo "not found" >&6; } 13799 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13800 fi 13801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13802 $as_echo "$tool_specified" >&6; } 13803 fi 13804 fi 13805 fi 13806 13807 fi 13808 13809 13810 if test "x$EGREP" = x; then 13811 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13812 fi 13813 13814 13815 13816 13817 # Publish this variable in the help. 13818 13819 13820 if [ -z "${FGREP+x}" ]; then 13821 # The variable is not set by user, try to locate tool using the code snippet 13822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13823 $as_echo_n "checking for fgrep... " >&6; } 13824 if ${ac_cv_path_FGREP+:} false; then : 13825 $as_echo_n "(cached) " >&6 13826 else 13827 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13828 then ac_cv_path_FGREP="$GREP -F" 13829 else 13830 if test -z "$FGREP"; then 13831 ac_path_FGREP_found=false 13832 # Loop through the user's path and test for each of PROGNAME-LIST 13833 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13834 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13835 do 13836 IFS=$as_save_IFS 13837 test -z "$as_dir" && as_dir=. 13838 for ac_prog in fgrep; do 13839 for ac_exec_ext in '' $ac_executable_extensions; do 13840 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13841 as_fn_executable_p "$ac_path_FGREP" || continue 13842 # Check for GNU ac_path_FGREP and select it if it is found. 13843 # Check for GNU $ac_path_FGREP 13844 case `"$ac_path_FGREP" --version 2>&1` in 13845 *GNU*) 13846 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13847 *) 13848 ac_count=0 13849 $as_echo_n 0123456789 >"conftest.in" 13850 while : 13851 do 13852 cat "conftest.in" "conftest.in" >"conftest.tmp" 13853 mv "conftest.tmp" "conftest.in" 13854 cp "conftest.in" "conftest.nl" 13855 $as_echo 'FGREP' >> "conftest.nl" 13856 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13857 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13858 as_fn_arith $ac_count + 1 && ac_count=$as_val 13859 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13860 # Best one so far, save it but keep looking for a better one 13861 ac_cv_path_FGREP="$ac_path_FGREP" 13862 ac_path_FGREP_max=$ac_count 13863 fi 13864 # 10*(2^10) chars as input seems more than enough 13865 test $ac_count -gt 10 && break 13866 done 13867 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13868 esac 13869 13870 $ac_path_FGREP_found && break 3 13871 done 13872 done 13873 done 13874 IFS=$as_save_IFS 13875 if test -z "$ac_cv_path_FGREP"; then 13876 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13877 fi 13878 else 13879 ac_cv_path_FGREP=$FGREP 13880 fi 13881 13882 fi 13883 fi 13884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13885 $as_echo "$ac_cv_path_FGREP" >&6; } 13886 FGREP="$ac_cv_path_FGREP" 13887 13888 13889 else 13890 # The variable is set, but is it from the command line or the environment? 13891 13892 # Try to remove the string !FGREP! from our list. 13893 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13894 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13895 # If it failed, the variable was not from the command line. Ignore it, 13896 # but warn the user (except for BASH, which is always set by the calling BASH). 13897 if test "xFGREP" != xBASH; then 13898 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13899 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13900 fi 13901 # Try to locate tool using the code snippet 13902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13903 $as_echo_n "checking for fgrep... " >&6; } 13904 if ${ac_cv_path_FGREP+:} false; then : 13905 $as_echo_n "(cached) " >&6 13906 else 13907 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13908 then ac_cv_path_FGREP="$GREP -F" 13909 else 13910 if test -z "$FGREP"; then 13911 ac_path_FGREP_found=false 13912 # Loop through the user's path and test for each of PROGNAME-LIST 13913 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13914 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13915 do 13916 IFS=$as_save_IFS 13917 test -z "$as_dir" && as_dir=. 13918 for ac_prog in fgrep; do 13919 for ac_exec_ext in '' $ac_executable_extensions; do 13920 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13921 as_fn_executable_p "$ac_path_FGREP" || continue 13922 # Check for GNU ac_path_FGREP and select it if it is found. 13923 # Check for GNU $ac_path_FGREP 13924 case `"$ac_path_FGREP" --version 2>&1` in 13925 *GNU*) 13926 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13927 *) 13928 ac_count=0 13929 $as_echo_n 0123456789 >"conftest.in" 13930 while : 13931 do 13932 cat "conftest.in" "conftest.in" >"conftest.tmp" 13933 mv "conftest.tmp" "conftest.in" 13934 cp "conftest.in" "conftest.nl" 13935 $as_echo 'FGREP' >> "conftest.nl" 13936 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13937 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13938 as_fn_arith $ac_count + 1 && ac_count=$as_val 13939 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13940 # Best one so far, save it but keep looking for a better one 13941 ac_cv_path_FGREP="$ac_path_FGREP" 13942 ac_path_FGREP_max=$ac_count 13943 fi 13944 # 10*(2^10) chars as input seems more than enough 13945 test $ac_count -gt 10 && break 13946 done 13947 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13948 esac 13949 13950 $ac_path_FGREP_found && break 3 13951 done 13952 done 13953 done 13954 IFS=$as_save_IFS 13955 if test -z "$ac_cv_path_FGREP"; then 13956 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13957 fi 13958 else 13959 ac_cv_path_FGREP=$FGREP 13960 fi 13961 13962 fi 13963 fi 13964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13965 $as_echo "$ac_cv_path_FGREP" >&6; } 13966 FGREP="$ac_cv_path_FGREP" 13967 13968 13969 else 13970 # If it succeeded, then it was overridden by the user. We will use it 13971 # for the tool. 13972 13973 # First remove it from the list of overridden variables, so we can test 13974 # for unknown variables in the end. 13975 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13976 13977 # Check if we try to supply an empty value 13978 if test "x$FGREP" = x; then 13979 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 13980 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 13981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13982 $as_echo_n "checking for FGREP... " >&6; } 13983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13984 $as_echo "disabled" >&6; } 13985 else 13986 # Check if the provided tool contains a complete path. 13987 tool_specified="$FGREP" 13988 tool_basename="${tool_specified##*/}" 13989 if test "x$tool_basename" = "x$tool_specified"; then 13990 # A command without a complete path is provided, search $PATH. 13991 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 13992 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 13993 # Extract the first word of "$tool_basename", so it can be a program name with args. 13994 set dummy $tool_basename; ac_word=$2 13995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13996 $as_echo_n "checking for $ac_word... " >&6; } 13997 if ${ac_cv_path_FGREP+:} false; then : 13998 $as_echo_n "(cached) " >&6 13999 else 14000 case $FGREP in 14001 [\\/]* | ?:[\\/]*) 14002 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 14003 ;; 14004 *) 14005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14006 for as_dir in $PATH 14007 do 14008 IFS=$as_save_IFS 14009 test -z "$as_dir" && as_dir=. 14010 for ac_exec_ext in '' $ac_executable_extensions; do 14011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14012 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 14013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14014 break 2 14015 fi 14016 done 14017 done 14018 IFS=$as_save_IFS 14019 14020 ;; 14021 esac 14022 fi 14023 FGREP=$ac_cv_path_FGREP 14024 if test -n "$FGREP"; then 14025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14026 $as_echo "$FGREP" >&6; } 14027 else 14028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14029 $as_echo "no" >&6; } 14030 fi 14031 14032 14033 if test "x$FGREP" = x; then 14034 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14035 fi 14036 else 14037 # Otherwise we believe it is a complete path. Use it as it is. 14038 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14039 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14041 $as_echo_n "checking for FGREP... " >&6; } 14042 if test ! -x "$tool_specified"; then 14043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14044 $as_echo "not found" >&6; } 14045 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14046 fi 14047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14048 $as_echo "$tool_specified" >&6; } 14049 fi 14050 fi 14051 fi 14052 14053 fi 14054 14055 14056 if test "x$FGREP" = x; then 14057 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14058 fi 14059 14060 14061 14062 14063 # Publish this variable in the help. 14064 14065 14066 if [ -z "${SED+x}" ]; then 14067 # The variable is not set by user, try to locate tool using the code snippet 14068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14069 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14070 if ${ac_cv_path_SED+:} false; then : 14071 $as_echo_n "(cached) " >&6 14072 else 14073 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14074 for ac_i in 1 2 3 4 5 6 7; do 14075 ac_script="$ac_script$as_nl$ac_script" 14076 done 14077 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14078 { ac_script=; unset ac_script;} 14079 if test -z "$SED"; then 14080 ac_path_SED_found=false 14081 # Loop through the user's path and test for each of PROGNAME-LIST 14082 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14083 for as_dir in $PATH 14084 do 14085 IFS=$as_save_IFS 14086 test -z "$as_dir" && as_dir=. 14087 for ac_prog in sed gsed; do 14088 for ac_exec_ext in '' $ac_executable_extensions; do 14089 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14090 as_fn_executable_p "$ac_path_SED" || continue 14091 # Check for GNU ac_path_SED and select it if it is found. 14092 # Check for GNU $ac_path_SED 14093 case `"$ac_path_SED" --version 2>&1` in 14094 *GNU*) 14095 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14096 *) 14097 ac_count=0 14098 $as_echo_n 0123456789 >"conftest.in" 14099 while : 14100 do 14101 cat "conftest.in" "conftest.in" >"conftest.tmp" 14102 mv "conftest.tmp" "conftest.in" 14103 cp "conftest.in" "conftest.nl" 14104 $as_echo '' >> "conftest.nl" 14105 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14106 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14107 as_fn_arith $ac_count + 1 && ac_count=$as_val 14108 if test $ac_count -gt ${ac_path_SED_max-0}; then 14109 # Best one so far, save it but keep looking for a better one 14110 ac_cv_path_SED="$ac_path_SED" 14111 ac_path_SED_max=$ac_count 14112 fi 14113 # 10*(2^10) chars as input seems more than enough 14114 test $ac_count -gt 10 && break 14115 done 14116 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14117 esac 14118 14119 $ac_path_SED_found && break 3 14120 done 14121 done 14122 done 14123 IFS=$as_save_IFS 14124 if test -z "$ac_cv_path_SED"; then 14125 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14126 fi 14127 else 14128 ac_cv_path_SED=$SED 14129 fi 14130 14131 fi 14132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14133 $as_echo "$ac_cv_path_SED" >&6; } 14134 SED="$ac_cv_path_SED" 14135 rm -f conftest.sed 14136 14137 else 14138 # The variable is set, but is it from the command line or the environment? 14139 14140 # Try to remove the string !SED! from our list. 14141 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14142 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14143 # If it failed, the variable was not from the command line. Ignore it, 14144 # but warn the user (except for BASH, which is always set by the calling BASH). 14145 if test "xSED" != xBASH; then 14146 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14147 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14148 fi 14149 # Try to locate tool using the code snippet 14150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14151 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14152 if ${ac_cv_path_SED+:} false; then : 14153 $as_echo_n "(cached) " >&6 14154 else 14155 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14156 for ac_i in 1 2 3 4 5 6 7; do 14157 ac_script="$ac_script$as_nl$ac_script" 14158 done 14159 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14160 { ac_script=; unset ac_script;} 14161 if test -z "$SED"; then 14162 ac_path_SED_found=false 14163 # Loop through the user's path and test for each of PROGNAME-LIST 14164 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14165 for as_dir in $PATH 14166 do 14167 IFS=$as_save_IFS 14168 test -z "$as_dir" && as_dir=. 14169 for ac_prog in sed gsed; do 14170 for ac_exec_ext in '' $ac_executable_extensions; do 14171 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14172 as_fn_executable_p "$ac_path_SED" || continue 14173 # Check for GNU ac_path_SED and select it if it is found. 14174 # Check for GNU $ac_path_SED 14175 case `"$ac_path_SED" --version 2>&1` in 14176 *GNU*) 14177 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14178 *) 14179 ac_count=0 14180 $as_echo_n 0123456789 >"conftest.in" 14181 while : 14182 do 14183 cat "conftest.in" "conftest.in" >"conftest.tmp" 14184 mv "conftest.tmp" "conftest.in" 14185 cp "conftest.in" "conftest.nl" 14186 $as_echo '' >> "conftest.nl" 14187 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14188 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14189 as_fn_arith $ac_count + 1 && ac_count=$as_val 14190 if test $ac_count -gt ${ac_path_SED_max-0}; then 14191 # Best one so far, save it but keep looking for a better one 14192 ac_cv_path_SED="$ac_path_SED" 14193 ac_path_SED_max=$ac_count 14194 fi 14195 # 10*(2^10) chars as input seems more than enough 14196 test $ac_count -gt 10 && break 14197 done 14198 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14199 esac 14200 14201 $ac_path_SED_found && break 3 14202 done 14203 done 14204 done 14205 IFS=$as_save_IFS 14206 if test -z "$ac_cv_path_SED"; then 14207 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14208 fi 14209 else 14210 ac_cv_path_SED=$SED 14211 fi 14212 14213 fi 14214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14215 $as_echo "$ac_cv_path_SED" >&6; } 14216 SED="$ac_cv_path_SED" 14217 rm -f conftest.sed 14218 14219 else 14220 # If it succeeded, then it was overridden by the user. We will use it 14221 # for the tool. 14222 14223 # First remove it from the list of overridden variables, so we can test 14224 # for unknown variables in the end. 14225 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14226 14227 # Check if we try to supply an empty value 14228 if test "x$SED" = x; then 14229 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14230 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14232 $as_echo_n "checking for SED... " >&6; } 14233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14234 $as_echo "disabled" >&6; } 14235 else 14236 # Check if the provided tool contains a complete path. 14237 tool_specified="$SED" 14238 tool_basename="${tool_specified##*/}" 14239 if test "x$tool_basename" = "x$tool_specified"; then 14240 # A command without a complete path is provided, search $PATH. 14241 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14242 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14243 # Extract the first word of "$tool_basename", so it can be a program name with args. 14244 set dummy $tool_basename; ac_word=$2 14245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14246 $as_echo_n "checking for $ac_word... " >&6; } 14247 if ${ac_cv_path_SED+:} false; then : 14248 $as_echo_n "(cached) " >&6 14249 else 14250 case $SED in 14251 [\\/]* | ?:[\\/]*) 14252 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14253 ;; 14254 *) 14255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14256 for as_dir in $PATH 14257 do 14258 IFS=$as_save_IFS 14259 test -z "$as_dir" && as_dir=. 14260 for ac_exec_ext in '' $ac_executable_extensions; do 14261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14262 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14264 break 2 14265 fi 14266 done 14267 done 14268 IFS=$as_save_IFS 14269 14270 ;; 14271 esac 14272 fi 14273 SED=$ac_cv_path_SED 14274 if test -n "$SED"; then 14275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14276 $as_echo "$SED" >&6; } 14277 else 14278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14279 $as_echo "no" >&6; } 14280 fi 14281 14282 14283 if test "x$SED" = x; then 14284 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14285 fi 14286 else 14287 # Otherwise we believe it is a complete path. Use it as it is. 14288 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14289 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14291 $as_echo_n "checking for SED... " >&6; } 14292 if test ! -x "$tool_specified"; then 14293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14294 $as_echo "not found" >&6; } 14295 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14296 fi 14297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14298 $as_echo "$tool_specified" >&6; } 14299 fi 14300 fi 14301 fi 14302 14303 fi 14304 14305 14306 if test "x$SED" = x; then 14307 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14308 fi 14309 14310 14311 14312 # Always force rm. 14313 RM="$RM -f" 14314 14315 # pwd behaves differently on various platforms and some don't support the -L flag. 14316 # Always use the bash builtin pwd to get uniform behavior. 14317 THEPWDCMD=pwd 14318 14319 # These are not required on all platforms 14320 14321 14322 # Publish this variable in the help. 14323 14324 14325 if [ -z "${CYGPATH+x}" ]; then 14326 # The variable is not set by user, try to locate tool using the code snippet 14327 for ac_prog in cygpath 14328 do 14329 # Extract the first word of "$ac_prog", so it can be a program name with args. 14330 set dummy $ac_prog; ac_word=$2 14331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14332 $as_echo_n "checking for $ac_word... " >&6; } 14333 if ${ac_cv_path_CYGPATH+:} false; then : 14334 $as_echo_n "(cached) " >&6 14335 else 14336 case $CYGPATH in 14337 [\\/]* | ?:[\\/]*) 14338 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14339 ;; 14340 *) 14341 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14342 for as_dir in $PATH 14343 do 14344 IFS=$as_save_IFS 14345 test -z "$as_dir" && as_dir=. 14346 for ac_exec_ext in '' $ac_executable_extensions; do 14347 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14348 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14349 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14350 break 2 14351 fi 14352 done 14353 done 14354 IFS=$as_save_IFS 14355 14356 ;; 14357 esac 14358 fi 14359 CYGPATH=$ac_cv_path_CYGPATH 14360 if test -n "$CYGPATH"; then 14361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14362 $as_echo "$CYGPATH" >&6; } 14363 else 14364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14365 $as_echo "no" >&6; } 14366 fi 14367 14368 14369 test -n "$CYGPATH" && break 14370 done 14371 14372 else 14373 # The variable is set, but is it from the command line or the environment? 14374 14375 # Try to remove the string !CYGPATH! from our list. 14376 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14377 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14378 # If it failed, the variable was not from the command line. Ignore it, 14379 # but warn the user (except for BASH, which is always set by the calling BASH). 14380 if test "xCYGPATH" != xBASH; then 14381 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14382 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14383 fi 14384 # Try to locate tool using the code snippet 14385 for ac_prog in cygpath 14386 do 14387 # Extract the first word of "$ac_prog", so it can be a program name with args. 14388 set dummy $ac_prog; ac_word=$2 14389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14390 $as_echo_n "checking for $ac_word... " >&6; } 14391 if ${ac_cv_path_CYGPATH+:} false; then : 14392 $as_echo_n "(cached) " >&6 14393 else 14394 case $CYGPATH in 14395 [\\/]* | ?:[\\/]*) 14396 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14397 ;; 14398 *) 14399 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14400 for as_dir in $PATH 14401 do 14402 IFS=$as_save_IFS 14403 test -z "$as_dir" && as_dir=. 14404 for ac_exec_ext in '' $ac_executable_extensions; do 14405 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14406 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14408 break 2 14409 fi 14410 done 14411 done 14412 IFS=$as_save_IFS 14413 14414 ;; 14415 esac 14416 fi 14417 CYGPATH=$ac_cv_path_CYGPATH 14418 if test -n "$CYGPATH"; then 14419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14420 $as_echo "$CYGPATH" >&6; } 14421 else 14422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14423 $as_echo "no" >&6; } 14424 fi 14425 14426 14427 test -n "$CYGPATH" && break 14428 done 14429 14430 else 14431 # If it succeeded, then it was overridden by the user. We will use it 14432 # for the tool. 14433 14434 # First remove it from the list of overridden variables, so we can test 14435 # for unknown variables in the end. 14436 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14437 14438 # Check if we try to supply an empty value 14439 if test "x$CYGPATH" = x; then 14440 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14441 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14443 $as_echo_n "checking for CYGPATH... " >&6; } 14444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14445 $as_echo "disabled" >&6; } 14446 else 14447 # Check if the provided tool contains a complete path. 14448 tool_specified="$CYGPATH" 14449 tool_basename="${tool_specified##*/}" 14450 if test "x$tool_basename" = "x$tool_specified"; then 14451 # A command without a complete path is provided, search $PATH. 14452 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14453 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14454 # Extract the first word of "$tool_basename", so it can be a program name with args. 14455 set dummy $tool_basename; ac_word=$2 14456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14457 $as_echo_n "checking for $ac_word... " >&6; } 14458 if ${ac_cv_path_CYGPATH+:} false; then : 14459 $as_echo_n "(cached) " >&6 14460 else 14461 case $CYGPATH in 14462 [\\/]* | ?:[\\/]*) 14463 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14464 ;; 14465 *) 14466 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14467 for as_dir in $PATH 14468 do 14469 IFS=$as_save_IFS 14470 test -z "$as_dir" && as_dir=. 14471 for ac_exec_ext in '' $ac_executable_extensions; do 14472 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14473 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14474 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14475 break 2 14476 fi 14477 done 14478 done 14479 IFS=$as_save_IFS 14480 14481 ;; 14482 esac 14483 fi 14484 CYGPATH=$ac_cv_path_CYGPATH 14485 if test -n "$CYGPATH"; then 14486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14487 $as_echo "$CYGPATH" >&6; } 14488 else 14489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14490 $as_echo "no" >&6; } 14491 fi 14492 14493 14494 if test "x$CYGPATH" = x; then 14495 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14496 fi 14497 else 14498 # Otherwise we believe it is a complete path. Use it as it is. 14499 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14500 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14502 $as_echo_n "checking for CYGPATH... " >&6; } 14503 if test ! -x "$tool_specified"; then 14504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14505 $as_echo "not found" >&6; } 14506 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14507 fi 14508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14509 $as_echo "$tool_specified" >&6; } 14510 fi 14511 fi 14512 fi 14513 14514 fi 14515 14516 14517 14518 14519 # Publish this variable in the help. 14520 14521 14522 if [ -z "${READLINK+x}" ]; then 14523 # The variable is not set by user, try to locate tool using the code snippet 14524 for ac_prog in greadlink readlink 14525 do 14526 # Extract the first word of "$ac_prog", so it can be a program name with args. 14527 set dummy $ac_prog; ac_word=$2 14528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14529 $as_echo_n "checking for $ac_word... " >&6; } 14530 if ${ac_cv_path_READLINK+:} false; then : 14531 $as_echo_n "(cached) " >&6 14532 else 14533 case $READLINK in 14534 [\\/]* | ?:[\\/]*) 14535 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14536 ;; 14537 *) 14538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14539 for as_dir in $PATH 14540 do 14541 IFS=$as_save_IFS 14542 test -z "$as_dir" && as_dir=. 14543 for ac_exec_ext in '' $ac_executable_extensions; do 14544 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14545 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14546 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14547 break 2 14548 fi 14549 done 14550 done 14551 IFS=$as_save_IFS 14552 14553 ;; 14554 esac 14555 fi 14556 READLINK=$ac_cv_path_READLINK 14557 if test -n "$READLINK"; then 14558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14559 $as_echo "$READLINK" >&6; } 14560 else 14561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14562 $as_echo "no" >&6; } 14563 fi 14564 14565 14566 test -n "$READLINK" && break 14567 done 14568 14569 else 14570 # The variable is set, but is it from the command line or the environment? 14571 14572 # Try to remove the string !READLINK! from our list. 14573 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14574 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14575 # If it failed, the variable was not from the command line. Ignore it, 14576 # but warn the user (except for BASH, which is always set by the calling BASH). 14577 if test "xREADLINK" != xBASH; then 14578 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14579 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14580 fi 14581 # Try to locate tool using the code snippet 14582 for ac_prog in greadlink readlink 14583 do 14584 # Extract the first word of "$ac_prog", so it can be a program name with args. 14585 set dummy $ac_prog; ac_word=$2 14586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14587 $as_echo_n "checking for $ac_word... " >&6; } 14588 if ${ac_cv_path_READLINK+:} false; then : 14589 $as_echo_n "(cached) " >&6 14590 else 14591 case $READLINK in 14592 [\\/]* | ?:[\\/]*) 14593 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14594 ;; 14595 *) 14596 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14597 for as_dir in $PATH 14598 do 14599 IFS=$as_save_IFS 14600 test -z "$as_dir" && as_dir=. 14601 for ac_exec_ext in '' $ac_executable_extensions; do 14602 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14603 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14604 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14605 break 2 14606 fi 14607 done 14608 done 14609 IFS=$as_save_IFS 14610 14611 ;; 14612 esac 14613 fi 14614 READLINK=$ac_cv_path_READLINK 14615 if test -n "$READLINK"; then 14616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14617 $as_echo "$READLINK" >&6; } 14618 else 14619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14620 $as_echo "no" >&6; } 14621 fi 14622 14623 14624 test -n "$READLINK" && break 14625 done 14626 14627 else 14628 # If it succeeded, then it was overridden by the user. We will use it 14629 # for the tool. 14630 14631 # First remove it from the list of overridden variables, so we can test 14632 # for unknown variables in the end. 14633 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14634 14635 # Check if we try to supply an empty value 14636 if test "x$READLINK" = x; then 14637 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14638 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14640 $as_echo_n "checking for READLINK... " >&6; } 14641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14642 $as_echo "disabled" >&6; } 14643 else 14644 # Check if the provided tool contains a complete path. 14645 tool_specified="$READLINK" 14646 tool_basename="${tool_specified##*/}" 14647 if test "x$tool_basename" = "x$tool_specified"; then 14648 # A command without a complete path is provided, search $PATH. 14649 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14650 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14651 # Extract the first word of "$tool_basename", so it can be a program name with args. 14652 set dummy $tool_basename; ac_word=$2 14653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14654 $as_echo_n "checking for $ac_word... " >&6; } 14655 if ${ac_cv_path_READLINK+:} false; then : 14656 $as_echo_n "(cached) " >&6 14657 else 14658 case $READLINK in 14659 [\\/]* | ?:[\\/]*) 14660 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14661 ;; 14662 *) 14663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14664 for as_dir in $PATH 14665 do 14666 IFS=$as_save_IFS 14667 test -z "$as_dir" && as_dir=. 14668 for ac_exec_ext in '' $ac_executable_extensions; do 14669 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14670 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14671 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14672 break 2 14673 fi 14674 done 14675 done 14676 IFS=$as_save_IFS 14677 14678 ;; 14679 esac 14680 fi 14681 READLINK=$ac_cv_path_READLINK 14682 if test -n "$READLINK"; then 14683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14684 $as_echo "$READLINK" >&6; } 14685 else 14686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14687 $as_echo "no" >&6; } 14688 fi 14689 14690 14691 if test "x$READLINK" = x; then 14692 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14693 fi 14694 else 14695 # Otherwise we believe it is a complete path. Use it as it is. 14696 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14697 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14699 $as_echo_n "checking for READLINK... " >&6; } 14700 if test ! -x "$tool_specified"; then 14701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14702 $as_echo "not found" >&6; } 14703 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14704 fi 14705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14706 $as_echo "$tool_specified" >&6; } 14707 fi 14708 fi 14709 fi 14710 14711 fi 14712 14713 14714 14715 14716 # Publish this variable in the help. 14717 14718 14719 if [ -z "${DF+x}" ]; then 14720 # The variable is not set by user, try to locate tool using the code snippet 14721 for ac_prog in df 14722 do 14723 # Extract the first word of "$ac_prog", so it can be a program name with args. 14724 set dummy $ac_prog; ac_word=$2 14725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14726 $as_echo_n "checking for $ac_word... " >&6; } 14727 if ${ac_cv_path_DF+:} false; then : 14728 $as_echo_n "(cached) " >&6 14729 else 14730 case $DF in 14731 [\\/]* | ?:[\\/]*) 14732 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14733 ;; 14734 *) 14735 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14736 for as_dir in $PATH 14737 do 14738 IFS=$as_save_IFS 14739 test -z "$as_dir" && as_dir=. 14740 for ac_exec_ext in '' $ac_executable_extensions; do 14741 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14742 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14743 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14744 break 2 14745 fi 14746 done 14747 done 14748 IFS=$as_save_IFS 14749 14750 ;; 14751 esac 14752 fi 14753 DF=$ac_cv_path_DF 14754 if test -n "$DF"; then 14755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14756 $as_echo "$DF" >&6; } 14757 else 14758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14759 $as_echo "no" >&6; } 14760 fi 14761 14762 14763 test -n "$DF" && break 14764 done 14765 14766 else 14767 # The variable is set, but is it from the command line or the environment? 14768 14769 # Try to remove the string !DF! from our list. 14770 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14771 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14772 # If it failed, the variable was not from the command line. Ignore it, 14773 # but warn the user (except for BASH, which is always set by the calling BASH). 14774 if test "xDF" != xBASH; then 14775 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14776 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14777 fi 14778 # Try to locate tool using the code snippet 14779 for ac_prog in df 14780 do 14781 # Extract the first word of "$ac_prog", so it can be a program name with args. 14782 set dummy $ac_prog; ac_word=$2 14783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14784 $as_echo_n "checking for $ac_word... " >&6; } 14785 if ${ac_cv_path_DF+:} false; then : 14786 $as_echo_n "(cached) " >&6 14787 else 14788 case $DF in 14789 [\\/]* | ?:[\\/]*) 14790 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14791 ;; 14792 *) 14793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14794 for as_dir in $PATH 14795 do 14796 IFS=$as_save_IFS 14797 test -z "$as_dir" && as_dir=. 14798 for ac_exec_ext in '' $ac_executable_extensions; do 14799 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14800 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14802 break 2 14803 fi 14804 done 14805 done 14806 IFS=$as_save_IFS 14807 14808 ;; 14809 esac 14810 fi 14811 DF=$ac_cv_path_DF 14812 if test -n "$DF"; then 14813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14814 $as_echo "$DF" >&6; } 14815 else 14816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14817 $as_echo "no" >&6; } 14818 fi 14819 14820 14821 test -n "$DF" && break 14822 done 14823 14824 else 14825 # If it succeeded, then it was overridden by the user. We will use it 14826 # for the tool. 14827 14828 # First remove it from the list of overridden variables, so we can test 14829 # for unknown variables in the end. 14830 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14831 14832 # Check if we try to supply an empty value 14833 if test "x$DF" = x; then 14834 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14835 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14837 $as_echo_n "checking for DF... " >&6; } 14838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14839 $as_echo "disabled" >&6; } 14840 else 14841 # Check if the provided tool contains a complete path. 14842 tool_specified="$DF" 14843 tool_basename="${tool_specified##*/}" 14844 if test "x$tool_basename" = "x$tool_specified"; then 14845 # A command without a complete path is provided, search $PATH. 14846 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14847 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14848 # Extract the first word of "$tool_basename", so it can be a program name with args. 14849 set dummy $tool_basename; ac_word=$2 14850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14851 $as_echo_n "checking for $ac_word... " >&6; } 14852 if ${ac_cv_path_DF+:} false; then : 14853 $as_echo_n "(cached) " >&6 14854 else 14855 case $DF in 14856 [\\/]* | ?:[\\/]*) 14857 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14858 ;; 14859 *) 14860 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14861 for as_dir in $PATH 14862 do 14863 IFS=$as_save_IFS 14864 test -z "$as_dir" && as_dir=. 14865 for ac_exec_ext in '' $ac_executable_extensions; do 14866 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14867 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14868 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14869 break 2 14870 fi 14871 done 14872 done 14873 IFS=$as_save_IFS 14874 14875 ;; 14876 esac 14877 fi 14878 DF=$ac_cv_path_DF 14879 if test -n "$DF"; then 14880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14881 $as_echo "$DF" >&6; } 14882 else 14883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14884 $as_echo "no" >&6; } 14885 fi 14886 14887 14888 if test "x$DF" = x; then 14889 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14890 fi 14891 else 14892 # Otherwise we believe it is a complete path. Use it as it is. 14893 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14894 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14896 $as_echo_n "checking for DF... " >&6; } 14897 if test ! -x "$tool_specified"; then 14898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14899 $as_echo "not found" >&6; } 14900 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14901 fi 14902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14903 $as_echo "$tool_specified" >&6; } 14904 fi 14905 fi 14906 fi 14907 14908 fi 14909 14910 14911 14912 14913 # Publish this variable in the help. 14914 14915 14916 if [ -z "${CPIO+x}" ]; then 14917 # The variable is not set by user, try to locate tool using the code snippet 14918 for ac_prog in cpio bsdcpio 14919 do 14920 # Extract the first word of "$ac_prog", so it can be a program name with args. 14921 set dummy $ac_prog; ac_word=$2 14922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14923 $as_echo_n "checking for $ac_word... " >&6; } 14924 if ${ac_cv_path_CPIO+:} false; then : 14925 $as_echo_n "(cached) " >&6 14926 else 14927 case $CPIO in 14928 [\\/]* | ?:[\\/]*) 14929 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14930 ;; 14931 *) 14932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14933 for as_dir in $PATH 14934 do 14935 IFS=$as_save_IFS 14936 test -z "$as_dir" && as_dir=. 14937 for ac_exec_ext in '' $ac_executable_extensions; do 14938 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14939 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14940 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14941 break 2 14942 fi 14943 done 14944 done 14945 IFS=$as_save_IFS 14946 14947 ;; 14948 esac 14949 fi 14950 CPIO=$ac_cv_path_CPIO 14951 if test -n "$CPIO"; then 14952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14953 $as_echo "$CPIO" >&6; } 14954 else 14955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14956 $as_echo "no" >&6; } 14957 fi 14958 14959 14960 test -n "$CPIO" && break 14961 done 14962 14963 else 14964 # The variable is set, but is it from the command line or the environment? 14965 14966 # Try to remove the string !CPIO! from our list. 14967 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 14968 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14969 # If it failed, the variable was not from the command line. Ignore it, 14970 # but warn the user (except for BASH, which is always set by the calling BASH). 14971 if test "xCPIO" != xBASH; then 14972 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 14973 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 14974 fi 14975 # Try to locate tool using the code snippet 14976 for ac_prog in cpio bsdcpio 14977 do 14978 # Extract the first word of "$ac_prog", so it can be a program name with args. 14979 set dummy $ac_prog; ac_word=$2 14980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14981 $as_echo_n "checking for $ac_word... " >&6; } 14982 if ${ac_cv_path_CPIO+:} false; then : 14983 $as_echo_n "(cached) " >&6 14984 else 14985 case $CPIO in 14986 [\\/]* | ?:[\\/]*) 14987 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14988 ;; 14989 *) 14990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14991 for as_dir in $PATH 14992 do 14993 IFS=$as_save_IFS 14994 test -z "$as_dir" && as_dir=. 14995 for ac_exec_ext in '' $ac_executable_extensions; do 14996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14997 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14999 break 2 15000 fi 15001 done 15002 done 15003 IFS=$as_save_IFS 15004 15005 ;; 15006 esac 15007 fi 15008 CPIO=$ac_cv_path_CPIO 15009 if test -n "$CPIO"; then 15010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15011 $as_echo "$CPIO" >&6; } 15012 else 15013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15014 $as_echo "no" >&6; } 15015 fi 15016 15017 15018 test -n "$CPIO" && break 15019 done 15020 15021 else 15022 # If it succeeded, then it was overridden by the user. We will use it 15023 # for the tool. 15024 15025 # First remove it from the list of overridden variables, so we can test 15026 # for unknown variables in the end. 15027 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15028 15029 # Check if we try to supply an empty value 15030 if test "x$CPIO" = x; then 15031 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15032 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15034 $as_echo_n "checking for CPIO... " >&6; } 15035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15036 $as_echo "disabled" >&6; } 15037 else 15038 # Check if the provided tool contains a complete path. 15039 tool_specified="$CPIO" 15040 tool_basename="${tool_specified##*/}" 15041 if test "x$tool_basename" = "x$tool_specified"; then 15042 # A command without a complete path is provided, search $PATH. 15043 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15044 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15045 # Extract the first word of "$tool_basename", so it can be a program name with args. 15046 set dummy $tool_basename; ac_word=$2 15047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15048 $as_echo_n "checking for $ac_word... " >&6; } 15049 if ${ac_cv_path_CPIO+:} false; then : 15050 $as_echo_n "(cached) " >&6 15051 else 15052 case $CPIO in 15053 [\\/]* | ?:[\\/]*) 15054 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15055 ;; 15056 *) 15057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15058 for as_dir in $PATH 15059 do 15060 IFS=$as_save_IFS 15061 test -z "$as_dir" && as_dir=. 15062 for ac_exec_ext in '' $ac_executable_extensions; do 15063 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15064 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15065 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15066 break 2 15067 fi 15068 done 15069 done 15070 IFS=$as_save_IFS 15071 15072 ;; 15073 esac 15074 fi 15075 CPIO=$ac_cv_path_CPIO 15076 if test -n "$CPIO"; then 15077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15078 $as_echo "$CPIO" >&6; } 15079 else 15080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15081 $as_echo "no" >&6; } 15082 fi 15083 15084 15085 if test "x$CPIO" = x; then 15086 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15087 fi 15088 else 15089 # Otherwise we believe it is a complete path. Use it as it is. 15090 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15091 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15093 $as_echo_n "checking for CPIO... " >&6; } 15094 if test ! -x "$tool_specified"; then 15095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15096 $as_echo "not found" >&6; } 15097 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15098 fi 15099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15100 $as_echo "$tool_specified" >&6; } 15101 fi 15102 fi 15103 fi 15104 15105 fi 15106 15107 15108 15109 15110 # Publish this variable in the help. 15111 15112 15113 if [ -z "${NICE+x}" ]; then 15114 # The variable is not set by user, try to locate tool using the code snippet 15115 for ac_prog in nice 15116 do 15117 # Extract the first word of "$ac_prog", so it can be a program name with args. 15118 set dummy $ac_prog; ac_word=$2 15119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15120 $as_echo_n "checking for $ac_word... " >&6; } 15121 if ${ac_cv_path_NICE+:} false; then : 15122 $as_echo_n "(cached) " >&6 15123 else 15124 case $NICE in 15125 [\\/]* | ?:[\\/]*) 15126 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15127 ;; 15128 *) 15129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15130 for as_dir in $PATH 15131 do 15132 IFS=$as_save_IFS 15133 test -z "$as_dir" && as_dir=. 15134 for ac_exec_ext in '' $ac_executable_extensions; do 15135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15136 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15138 break 2 15139 fi 15140 done 15141 done 15142 IFS=$as_save_IFS 15143 15144 ;; 15145 esac 15146 fi 15147 NICE=$ac_cv_path_NICE 15148 if test -n "$NICE"; then 15149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15150 $as_echo "$NICE" >&6; } 15151 else 15152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15153 $as_echo "no" >&6; } 15154 fi 15155 15156 15157 test -n "$NICE" && break 15158 done 15159 15160 else 15161 # The variable is set, but is it from the command line or the environment? 15162 15163 # Try to remove the string !NICE! from our list. 15164 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15165 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15166 # If it failed, the variable was not from the command line. Ignore it, 15167 # but warn the user (except for BASH, which is always set by the calling BASH). 15168 if test "xNICE" != xBASH; then 15169 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15170 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15171 fi 15172 # Try to locate tool using the code snippet 15173 for ac_prog in nice 15174 do 15175 # Extract the first word of "$ac_prog", so it can be a program name with args. 15176 set dummy $ac_prog; ac_word=$2 15177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15178 $as_echo_n "checking for $ac_word... " >&6; } 15179 if ${ac_cv_path_NICE+:} false; then : 15180 $as_echo_n "(cached) " >&6 15181 else 15182 case $NICE in 15183 [\\/]* | ?:[\\/]*) 15184 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15185 ;; 15186 *) 15187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15188 for as_dir in $PATH 15189 do 15190 IFS=$as_save_IFS 15191 test -z "$as_dir" && as_dir=. 15192 for ac_exec_ext in '' $ac_executable_extensions; do 15193 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15194 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15195 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15196 break 2 15197 fi 15198 done 15199 done 15200 IFS=$as_save_IFS 15201 15202 ;; 15203 esac 15204 fi 15205 NICE=$ac_cv_path_NICE 15206 if test -n "$NICE"; then 15207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15208 $as_echo "$NICE" >&6; } 15209 else 15210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15211 $as_echo "no" >&6; } 15212 fi 15213 15214 15215 test -n "$NICE" && break 15216 done 15217 15218 else 15219 # If it succeeded, then it was overridden by the user. We will use it 15220 # for the tool. 15221 15222 # First remove it from the list of overridden variables, so we can test 15223 # for unknown variables in the end. 15224 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15225 15226 # Check if we try to supply an empty value 15227 if test "x$NICE" = x; then 15228 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15229 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15231 $as_echo_n "checking for NICE... " >&6; } 15232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15233 $as_echo "disabled" >&6; } 15234 else 15235 # Check if the provided tool contains a complete path. 15236 tool_specified="$NICE" 15237 tool_basename="${tool_specified##*/}" 15238 if test "x$tool_basename" = "x$tool_specified"; then 15239 # A command without a complete path is provided, search $PATH. 15240 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15241 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15242 # Extract the first word of "$tool_basename", so it can be a program name with args. 15243 set dummy $tool_basename; ac_word=$2 15244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15245 $as_echo_n "checking for $ac_word... " >&6; } 15246 if ${ac_cv_path_NICE+:} false; then : 15247 $as_echo_n "(cached) " >&6 15248 else 15249 case $NICE in 15250 [\\/]* | ?:[\\/]*) 15251 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15252 ;; 15253 *) 15254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15255 for as_dir in $PATH 15256 do 15257 IFS=$as_save_IFS 15258 test -z "$as_dir" && as_dir=. 15259 for ac_exec_ext in '' $ac_executable_extensions; do 15260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15261 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15263 break 2 15264 fi 15265 done 15266 done 15267 IFS=$as_save_IFS 15268 15269 ;; 15270 esac 15271 fi 15272 NICE=$ac_cv_path_NICE 15273 if test -n "$NICE"; then 15274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15275 $as_echo "$NICE" >&6; } 15276 else 15277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15278 $as_echo "no" >&6; } 15279 fi 15280 15281 15282 if test "x$NICE" = x; then 15283 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15284 fi 15285 else 15286 # Otherwise we believe it is a complete path. Use it as it is. 15287 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15288 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15290 $as_echo_n "checking for NICE... " >&6; } 15291 if test ! -x "$tool_specified"; then 15292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15293 $as_echo "not found" >&6; } 15294 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15295 fi 15296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15297 $as_echo "$tool_specified" >&6; } 15298 fi 15299 fi 15300 fi 15301 15302 fi 15303 15304 15305 15306 15307 # Publish this variable in the help. 15308 15309 15310 if [ -z "${PANDOC+x}" ]; then 15311 # The variable is not set by user, try to locate tool using the code snippet 15312 for ac_prog in pandoc 15313 do 15314 # Extract the first word of "$ac_prog", so it can be a program name with args. 15315 set dummy $ac_prog; ac_word=$2 15316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15317 $as_echo_n "checking for $ac_word... " >&6; } 15318 if ${ac_cv_path_PANDOC+:} false; then : 15319 $as_echo_n "(cached) " >&6 15320 else 15321 case $PANDOC in 15322 [\\/]* | ?:[\\/]*) 15323 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15324 ;; 15325 *) 15326 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15327 for as_dir in $PATH 15328 do 15329 IFS=$as_save_IFS 15330 test -z "$as_dir" && as_dir=. 15331 for ac_exec_ext in '' $ac_executable_extensions; do 15332 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15333 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15334 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15335 break 2 15336 fi 15337 done 15338 done 15339 IFS=$as_save_IFS 15340 15341 ;; 15342 esac 15343 fi 15344 PANDOC=$ac_cv_path_PANDOC 15345 if test -n "$PANDOC"; then 15346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15347 $as_echo "$PANDOC" >&6; } 15348 else 15349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15350 $as_echo "no" >&6; } 15351 fi 15352 15353 15354 test -n "$PANDOC" && break 15355 done 15356 15357 else 15358 # The variable is set, but is it from the command line or the environment? 15359 15360 # Try to remove the string !PANDOC! from our list. 15361 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PANDOC!/} 15362 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15363 # If it failed, the variable was not from the command line. Ignore it, 15364 # but warn the user (except for BASH, which is always set by the calling BASH). 15365 if test "xPANDOC" != xBASH; then 15366 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&5 15367 $as_echo "$as_me: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&2;} 15368 fi 15369 # Try to locate tool using the code snippet 15370 for ac_prog in pandoc 15371 do 15372 # Extract the first word of "$ac_prog", so it can be a program name with args. 15373 set dummy $ac_prog; ac_word=$2 15374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15375 $as_echo_n "checking for $ac_word... " >&6; } 15376 if ${ac_cv_path_PANDOC+:} false; then : 15377 $as_echo_n "(cached) " >&6 15378 else 15379 case $PANDOC in 15380 [\\/]* | ?:[\\/]*) 15381 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15382 ;; 15383 *) 15384 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15385 for as_dir in $PATH 15386 do 15387 IFS=$as_save_IFS 15388 test -z "$as_dir" && as_dir=. 15389 for ac_exec_ext in '' $ac_executable_extensions; do 15390 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15391 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15392 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15393 break 2 15394 fi 15395 done 15396 done 15397 IFS=$as_save_IFS 15398 15399 ;; 15400 esac 15401 fi 15402 PANDOC=$ac_cv_path_PANDOC 15403 if test -n "$PANDOC"; then 15404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15405 $as_echo "$PANDOC" >&6; } 15406 else 15407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15408 $as_echo "no" >&6; } 15409 fi 15410 15411 15412 test -n "$PANDOC" && break 15413 done 15414 15415 else 15416 # If it succeeded, then it was overridden by the user. We will use it 15417 # for the tool. 15418 15419 # First remove it from the list of overridden variables, so we can test 15420 # for unknown variables in the end. 15421 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15422 15423 # Check if we try to supply an empty value 15424 if test "x$PANDOC" = x; then 15425 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PANDOC= (no value)" >&5 15426 $as_echo "$as_me: Setting user supplied tool PANDOC= (no value)" >&6;} 15427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15428 $as_echo_n "checking for PANDOC... " >&6; } 15429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15430 $as_echo "disabled" >&6; } 15431 else 15432 # Check if the provided tool contains a complete path. 15433 tool_specified="$PANDOC" 15434 tool_basename="${tool_specified##*/}" 15435 if test "x$tool_basename" = "x$tool_specified"; then 15436 # A command without a complete path is provided, search $PATH. 15437 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PANDOC=$tool_basename" >&5 15438 $as_echo "$as_me: Will search for user supplied tool PANDOC=$tool_basename" >&6;} 15439 # Extract the first word of "$tool_basename", so it can be a program name with args. 15440 set dummy $tool_basename; ac_word=$2 15441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15442 $as_echo_n "checking for $ac_word... " >&6; } 15443 if ${ac_cv_path_PANDOC+:} false; then : 15444 $as_echo_n "(cached) " >&6 15445 else 15446 case $PANDOC in 15447 [\\/]* | ?:[\\/]*) 15448 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15449 ;; 15450 *) 15451 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15452 for as_dir in $PATH 15453 do 15454 IFS=$as_save_IFS 15455 test -z "$as_dir" && as_dir=. 15456 for ac_exec_ext in '' $ac_executable_extensions; do 15457 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15458 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15459 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15460 break 2 15461 fi 15462 done 15463 done 15464 IFS=$as_save_IFS 15465 15466 ;; 15467 esac 15468 fi 15469 PANDOC=$ac_cv_path_PANDOC 15470 if test -n "$PANDOC"; then 15471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15472 $as_echo "$PANDOC" >&6; } 15473 else 15474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15475 $as_echo "no" >&6; } 15476 fi 15477 15478 15479 if test "x$PANDOC" = x; then 15480 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15481 fi 15482 else 15483 # Otherwise we believe it is a complete path. Use it as it is. 15484 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PANDOC=$tool_specified" >&5 15485 $as_echo "$as_me: Will use user supplied tool PANDOC=$tool_specified" >&6;} 15486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15487 $as_echo_n "checking for PANDOC... " >&6; } 15488 if test ! -x "$tool_specified"; then 15489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15490 $as_echo "not found" >&6; } 15491 as_fn_error $? "User supplied tool PANDOC=$tool_specified does not exist or is not executable" "$LINENO" 5 15492 fi 15493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15494 $as_echo "$tool_specified" >&6; } 15495 fi 15496 fi 15497 fi 15498 15499 fi 15500 15501 15502 15503 15504 # Now we can determine OpenJDK build and target platforms. This is required to 15505 # have early on. 15506 # Make sure we can run config.sub. 15507 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15508 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15509 15510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15511 $as_echo_n "checking build system type... " >&6; } 15512 if ${ac_cv_build+:} false; then : 15513 $as_echo_n "(cached) " >&6 15514 else 15515 ac_build_alias=$build_alias 15516 test "x$ac_build_alias" = x && 15517 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15518 test "x$ac_build_alias" = x && 15519 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15520 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15521 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15522 15523 fi 15524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15525 $as_echo "$ac_cv_build" >&6; } 15526 case $ac_cv_build in 15527 *-*-*) ;; 15528 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15529 esac 15530 build=$ac_cv_build 15531 ac_save_IFS=$IFS; IFS='-' 15532 set x $ac_cv_build 15533 shift 15534 build_cpu=$1 15535 build_vendor=$2 15536 shift; shift 15537 # Remember, the first character of IFS is used to create $*, 15538 # except with old shells: 15539 build_os=$* 15540 IFS=$ac_save_IFS 15541 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15542 15543 15544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15545 $as_echo_n "checking host system type... " >&6; } 15546 if ${ac_cv_host+:} false; then : 15547 $as_echo_n "(cached) " >&6 15548 else 15549 if test "x$host_alias" = x; then 15550 ac_cv_host=$ac_cv_build 15551 else 15552 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15553 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15554 fi 15555 15556 fi 15557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15558 $as_echo "$ac_cv_host" >&6; } 15559 case $ac_cv_host in 15560 *-*-*) ;; 15561 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15562 esac 15563 host=$ac_cv_host 15564 ac_save_IFS=$IFS; IFS='-' 15565 set x $ac_cv_host 15566 shift 15567 host_cpu=$1 15568 host_vendor=$2 15569 shift; shift 15570 # Remember, the first character of IFS is used to create $*, 15571 # except with old shells: 15572 host_os=$* 15573 IFS=$ac_save_IFS 15574 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15575 15576 15577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15578 $as_echo_n "checking target system type... " >&6; } 15579 if ${ac_cv_target+:} false; then : 15580 $as_echo_n "(cached) " >&6 15581 else 15582 if test "x$target_alias" = x; then 15583 ac_cv_target=$ac_cv_host 15584 else 15585 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15586 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15587 fi 15588 15589 fi 15590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15591 $as_echo "$ac_cv_target" >&6; } 15592 case $ac_cv_target in 15593 *-*-*) ;; 15594 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15595 esac 15596 target=$ac_cv_target 15597 ac_save_IFS=$IFS; IFS='-' 15598 set x $ac_cv_target 15599 shift 15600 target_cpu=$1 15601 target_vendor=$2 15602 shift; shift 15603 # Remember, the first character of IFS is used to create $*, 15604 # except with old shells: 15605 target_os=$* 15606 IFS=$ac_save_IFS 15607 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15608 15609 15610 # The aliases save the names the user supplied, while $host etc. 15611 # will get canonicalized. 15612 test -n "$target_alias" && 15613 test "$program_prefix$program_suffix$program_transform_name" = \ 15614 NONENONEs,x,x, && 15615 program_prefix=${target_alias}- 15616 15617 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15618 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15619 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15620 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15621 # to use the configure naming style. 15622 15623 15624 15625 15626 15627 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15628 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15629 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15630 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15631 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15632 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15633 15634 15635 15636 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15637 15638 case "$build_os" in 15639 *linux*) 15640 VAR_OS=linux 15641 VAR_OS_TYPE=unix 15642 ;; 15643 *solaris*) 15644 VAR_OS=solaris 15645 VAR_OS_TYPE=unix 15646 ;; 15647 *darwin*) 15648 VAR_OS=macosx 15649 VAR_OS_TYPE=unix 15650 ;; 15651 *bsd*) 15652 VAR_OS=bsd 15653 VAR_OS_TYPE=unix 15654 ;; 15655 *cygwin*) 15656 VAR_OS=windows 15657 VAR_OS_ENV=windows.cygwin 15658 ;; 15659 *mingw*) 15660 VAR_OS=windows 15661 VAR_OS_ENV=windows.msys 15662 ;; 15663 *aix*) 15664 VAR_OS=aix 15665 VAR_OS_TYPE=unix 15666 ;; 15667 *) 15668 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15669 ;; 15670 esac 15671 15672 15673 # First argument is the cpu name from the trip/quad 15674 case "$build_cpu" in 15675 x86_64) 15676 VAR_CPU=x86_64 15677 VAR_CPU_ARCH=x86 15678 VAR_CPU_BITS=64 15679 VAR_CPU_ENDIAN=little 15680 ;; 15681 i?86) 15682 VAR_CPU=x86 15683 VAR_CPU_ARCH=x86 15684 VAR_CPU_BITS=32 15685 VAR_CPU_ENDIAN=little 15686 ;; 15687 alpha*) 15688 VAR_CPU=alpha 15689 VAR_CPU_ARCH=alpha 15690 VAR_CPU_BITS=64 15691 VAR_CPU_ENDIAN=little 15692 ;; 15693 arm*) 15694 VAR_CPU=arm 15695 VAR_CPU_ARCH=arm 15696 VAR_CPU_BITS=32 15697 VAR_CPU_ENDIAN=little 15698 ;; 15699 aarch64) 15700 VAR_CPU=aarch64 15701 VAR_CPU_ARCH=aarch64 15702 VAR_CPU_BITS=64 15703 VAR_CPU_ENDIAN=little 15704 ;; 15705 m68k) 15706 VAR_CPU=m68k 15707 VAR_CPU_ARCH=m68k 15708 VAR_CPU_BITS=32 15709 VAR_CPU_ENDIAN=big 15710 ;; 15711 mips) 15712 VAR_CPU=mips 15713 VAR_CPU_ARCH=mips 15714 VAR_CPU_BITS=32 15715 VAR_CPU_ENDIAN=big 15716 ;; 15717 mipsel) 15718 VAR_CPU=mipsel 15719 VAR_CPU_ARCH=mipsel 15720 VAR_CPU_BITS=32 15721 VAR_CPU_ENDIAN=little 15722 ;; 15723 mips64) 15724 VAR_CPU=mips64 15725 VAR_CPU_ARCH=mips64 15726 VAR_CPU_BITS=64 15727 VAR_CPU_ENDIAN=big 15728 ;; 15729 mips64el) 15730 VAR_CPU=mips64el 15731 VAR_CPU_ARCH=mips64el 15732 VAR_CPU_BITS=64 15733 VAR_CPU_ENDIAN=little 15734 ;; 15735 powerpc) 15736 VAR_CPU=ppc 15737 VAR_CPU_ARCH=ppc 15738 VAR_CPU_BITS=32 15739 VAR_CPU_ENDIAN=big 15740 ;; 15741 powerpc64) 15742 VAR_CPU=ppc64 15743 VAR_CPU_ARCH=ppc 15744 VAR_CPU_BITS=64 15745 VAR_CPU_ENDIAN=big 15746 ;; 15747 powerpc64le) 15748 VAR_CPU=ppc64le 15749 VAR_CPU_ARCH=ppc 15750 VAR_CPU_BITS=64 15751 VAR_CPU_ENDIAN=little 15752 ;; 15753 s390) 15754 VAR_CPU=s390 15755 VAR_CPU_ARCH=s390 15756 VAR_CPU_BITS=32 15757 VAR_CPU_ENDIAN=big 15758 ;; 15759 s390x) 15760 VAR_CPU=s390x 15761 VAR_CPU_ARCH=s390 15762 VAR_CPU_BITS=64 15763 VAR_CPU_ENDIAN=big 15764 ;; 15765 sh*eb) 15766 VAR_CPU=sh 15767 VAR_CPU_ARCH=sh 15768 VAR_CPU_BITS=32 15769 VAR_CPU_ENDIAN=big 15770 ;; 15771 sh*) 15772 VAR_CPU=sh 15773 VAR_CPU_ARCH=sh 15774 VAR_CPU_BITS=32 15775 VAR_CPU_ENDIAN=little 15776 ;; 15777 sparc) 15778 VAR_CPU=sparc 15779 VAR_CPU_ARCH=sparc 15780 VAR_CPU_BITS=32 15781 VAR_CPU_ENDIAN=big 15782 ;; 15783 sparcv9|sparc64) 15784 VAR_CPU=sparcv9 15785 VAR_CPU_ARCH=sparc 15786 VAR_CPU_BITS=64 15787 VAR_CPU_ENDIAN=big 15788 ;; 15789 *) 15790 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15791 ;; 15792 esac 15793 15794 # ..and setup our own variables. (Do this explicitly to facilitate searching) 15795 OPENJDK_BUILD_OS="$VAR_OS" 15796 if test "x$VAR_OS_TYPE" != x; then 15797 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15798 else 15799 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15800 fi 15801 if test "x$VAR_OS_ENV" != x; then 15802 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15803 else 15804 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15805 fi 15806 OPENJDK_BUILD_CPU="$VAR_CPU" 15807 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15808 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15809 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15810 15811 15812 15813 15814 15815 15816 15817 15818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15819 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15821 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15822 15823 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15824 15825 case "$host_os" in 15826 *linux*) 15827 VAR_OS=linux 15828 VAR_OS_TYPE=unix 15829 ;; 15830 *solaris*) 15831 VAR_OS=solaris 15832 VAR_OS_TYPE=unix 15833 ;; 15834 *darwin*) 15835 VAR_OS=macosx 15836 VAR_OS_TYPE=unix 15837 ;; 15838 *bsd*) 15839 VAR_OS=bsd 15840 VAR_OS_TYPE=unix 15841 ;; 15842 *cygwin*) 15843 VAR_OS=windows 15844 VAR_OS_ENV=windows.cygwin 15845 ;; 15846 *mingw*) 15847 VAR_OS=windows 15848 VAR_OS_ENV=windows.msys 15849 ;; 15850 *aix*) 15851 VAR_OS=aix 15852 VAR_OS_TYPE=unix 15853 ;; 15854 *) 15855 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15856 ;; 15857 esac 15858 15859 15860 # First argument is the cpu name from the trip/quad 15861 case "$host_cpu" in 15862 x86_64) 15863 VAR_CPU=x86_64 15864 VAR_CPU_ARCH=x86 15865 VAR_CPU_BITS=64 15866 VAR_CPU_ENDIAN=little 15867 ;; 15868 i?86) 15869 VAR_CPU=x86 15870 VAR_CPU_ARCH=x86 15871 VAR_CPU_BITS=32 15872 VAR_CPU_ENDIAN=little 15873 ;; 15874 alpha*) 15875 VAR_CPU=alpha 15876 VAR_CPU_ARCH=alpha 15877 VAR_CPU_BITS=64 15878 VAR_CPU_ENDIAN=little 15879 ;; 15880 arm*) 15881 VAR_CPU=arm 15882 VAR_CPU_ARCH=arm 15883 VAR_CPU_BITS=32 15884 VAR_CPU_ENDIAN=little 15885 ;; 15886 aarch64) 15887 VAR_CPU=aarch64 15888 VAR_CPU_ARCH=aarch64 15889 VAR_CPU_BITS=64 15890 VAR_CPU_ENDIAN=little 15891 ;; 15892 m68k) 15893 VAR_CPU=m68k 15894 VAR_CPU_ARCH=m68k 15895 VAR_CPU_BITS=32 15896 VAR_CPU_ENDIAN=big 15897 ;; 15898 mips) 15899 VAR_CPU=mips 15900 VAR_CPU_ARCH=mips 15901 VAR_CPU_BITS=32 15902 VAR_CPU_ENDIAN=big 15903 ;; 15904 mipsel) 15905 VAR_CPU=mipsel 15906 VAR_CPU_ARCH=mipsel 15907 VAR_CPU_BITS=32 15908 VAR_CPU_ENDIAN=little 15909 ;; 15910 mips64) 15911 VAR_CPU=mips64 15912 VAR_CPU_ARCH=mips64 15913 VAR_CPU_BITS=64 15914 VAR_CPU_ENDIAN=big 15915 ;; 15916 mips64el) 15917 VAR_CPU=mips64el 15918 VAR_CPU_ARCH=mips64el 15919 VAR_CPU_BITS=64 15920 VAR_CPU_ENDIAN=little 15921 ;; 15922 powerpc) 15923 VAR_CPU=ppc 15924 VAR_CPU_ARCH=ppc 15925 VAR_CPU_BITS=32 15926 VAR_CPU_ENDIAN=big 15927 ;; 15928 powerpc64) 15929 VAR_CPU=ppc64 15930 VAR_CPU_ARCH=ppc 15931 VAR_CPU_BITS=64 15932 VAR_CPU_ENDIAN=big 15933 ;; 15934 powerpc64le) 15935 VAR_CPU=ppc64le 15936 VAR_CPU_ARCH=ppc 15937 VAR_CPU_BITS=64 15938 VAR_CPU_ENDIAN=little 15939 ;; 15940 s390) 15941 VAR_CPU=s390 15942 VAR_CPU_ARCH=s390 15943 VAR_CPU_BITS=32 15944 VAR_CPU_ENDIAN=big 15945 ;; 15946 s390x) 15947 VAR_CPU=s390x 15948 VAR_CPU_ARCH=s390 15949 VAR_CPU_BITS=64 15950 VAR_CPU_ENDIAN=big 15951 ;; 15952 sh*eb) 15953 VAR_CPU=sh 15954 VAR_CPU_ARCH=sh 15955 VAR_CPU_BITS=32 15956 VAR_CPU_ENDIAN=big 15957 ;; 15958 sh*) 15959 VAR_CPU=sh 15960 VAR_CPU_ARCH=sh 15961 VAR_CPU_BITS=32 15962 VAR_CPU_ENDIAN=little 15963 ;; 15964 sparc) 15965 VAR_CPU=sparc 15966 VAR_CPU_ARCH=sparc 15967 VAR_CPU_BITS=32 15968 VAR_CPU_ENDIAN=big 15969 ;; 15970 sparcv9|sparc64) 15971 VAR_CPU=sparcv9 15972 VAR_CPU_ARCH=sparc 15973 VAR_CPU_BITS=64 15974 VAR_CPU_ENDIAN=big 15975 ;; 15976 *) 15977 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 15978 ;; 15979 esac 15980 15981 # ... and setup our own variables. (Do this explicitly to facilitate searching) 15982 OPENJDK_TARGET_OS="$VAR_OS" 15983 if test "x$VAR_OS_TYPE" != x; then 15984 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 15985 else 15986 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 15987 fi 15988 if test "x$VAR_OS_ENV" != x; then 15989 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 15990 else 15991 OPENJDK_TARGET_OS_ENV="$VAR_OS" 15992 fi 15993 OPENJDK_TARGET_CPU="$VAR_CPU" 15994 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 15995 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 15996 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15997 15998 15999 16000 16001 16002 16003 16004 16005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 16006 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 16007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 16008 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 16009 16010 16011 16012 # Check whether --with-target-bits was given. 16013 if test "${with_target_bits+set}" = set; then : 16014 withval=$with_target_bits; 16015 fi 16016 16017 16018 # We have three types of compiles: 16019 # native == normal compilation, target system == build system 16020 # cross == traditional cross compilation, target system != build system; special toolchain needed 16021 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 16022 # 16023 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 16024 # We're doing a proper cross-compilation 16025 COMPILE_TYPE="cross" 16026 else 16027 COMPILE_TYPE="native" 16028 fi 16029 16030 if test "x$with_target_bits" != x; then 16031 if test "x$COMPILE_TYPE" = "xcross"; then 16032 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 16033 fi 16034 16035 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16036 # A reduced build is requested 16037 COMPILE_TYPE="reduced" 16038 OPENJDK_TARGET_CPU_BITS=32 16039 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 16040 OPENJDK_TARGET_CPU=x86 16041 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 16042 OPENJDK_TARGET_CPU=sparc 16043 else 16044 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 16045 fi 16046 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16047 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 16048 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 16049 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 16050 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 16051 else 16052 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 16053 fi 16054 fi 16055 16056 16057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 16058 $as_echo_n "checking compilation type... " >&6; } 16059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 16060 $as_echo "$COMPILE_TYPE" >&6; } 16061 16062 16063 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16064 OPENJDK_MODULE_TARGET_OS_NAME="macos" 16065 else 16066 OPENJDK_MODULE_TARGET_OS_NAME="$OPENJDK_TARGET_OS" 16067 fi 16068 16069 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16070 OPENJDK_MODULE_TARGET_OS_ARCH="amd64" 16071 else 16072 OPENJDK_MODULE_TARGET_OS_ARCH="$OPENJDK_TARGET_CPU" 16073 fi 16074 16075 OPENJDK_MODULE_TARGET_PLATFORM="${OPENJDK_MODULE_TARGET_OS_NAME}-${OPENJDK_MODULE_TARGET_OS_ARCH}" 16076 16077 16078 16079 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 16080 RELEASE_FILE_OS_NAME=SunOS 16081 fi 16082 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 16083 RELEASE_FILE_OS_NAME=Linux 16084 fi 16085 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16086 RELEASE_FILE_OS_NAME=Windows 16087 fi 16088 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16089 RELEASE_FILE_OS_NAME="Darwin" 16090 fi 16091 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 16092 RELEASE_FILE_OS_NAME="AIX" 16093 fi 16094 RELEASE_FILE_OS_ARCH=${OPENJDK_TARGET_CPU} 16095 16096 16097 16098 16099 16100 16101 # Also store the legacy naming of the cpu. 16102 # Ie i586 and amd64 instead of x86 and x86_64 16103 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 16104 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16105 OPENJDK_TARGET_CPU_LEGACY="i586" 16106 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16107 # On all platforms except MacOSX replace x86_64 with amd64. 16108 OPENJDK_TARGET_CPU_LEGACY="amd64" 16109 elif test "x$OPENJDK_TARGET_CPU" = xalpha; then 16110 # Avoid name collisions with variables named alpha 16111 OPENJDK_TARGET_CPU_LEGACY="_alpha_" 16112 elif test "x$OPENJDK_TARGET_CPU" = xsh; then 16113 # Avoid name collisions with variables named sh 16114 OPENJDK_TARGET_CPU_LEGACY="_sh_" 16115 fi 16116 16117 16118 # And the second legacy naming of the cpu. 16119 # Ie i386 and amd64 instead of x86 and x86_64. 16120 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 16121 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16122 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 16123 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16124 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 16125 fi 16126 16127 16128 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16129 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16130 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 16131 OPENJDK_TARGET_CPU_ISADIR="" 16132 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 16133 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16134 OPENJDK_TARGET_CPU_ISADIR="/amd64" 16135 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16136 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 16137 fi 16138 fi 16139 16140 16141 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 16142 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 16143 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 16144 # On linux only, we replace x86 with i386. 16145 OPENJDK_TARGET_CPU_OSARCH="i386" 16146 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16147 # On all platforms except macosx, we replace x86_64 with amd64. 16148 OPENJDK_TARGET_CPU_OSARCH="amd64" 16149 fi 16150 16151 16152 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 16153 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16154 OPENJDK_TARGET_CPU_JLI="i386" 16155 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16156 # On all platforms except macosx, we replace x86_64 with amd64. 16157 OPENJDK_TARGET_CPU_JLI="amd64" 16158 fi 16159 16160 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16161 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 16162 else 16163 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 16164 fi 16165 16166 16167 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16168 # Macosx is osx and x86_64 is x64 16169 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16170 OPENJDK_TARGET_OS_BUNDLE="osx" 16171 else 16172 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 16173 fi 16174 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16175 OPENJDK_TARGET_CPU_BUNDLE="x64" 16176 else 16177 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 16178 fi 16179 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 16180 16181 16182 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16183 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16184 # unpack200.exe. This variable is used in 16185 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16186 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 16187 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 16188 fi 16189 fi 16190 16191 if test "x$COMPILE_TYPE" = "xcross"; then 16192 # FIXME: ... or should this include reduced builds..? 16193 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 16194 else 16195 DEFINE_CROSS_COMPILE_ARCH="" 16196 fi 16197 16198 16199 # Convert openjdk platform names to hotspot names 16200 16201 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 16202 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16203 HOTSPOT_TARGET_OS=bsd 16204 fi 16205 16206 16207 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 16208 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 16209 HOTSPOT_TARGET_OS_TYPE=posix 16210 fi 16211 16212 16213 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 16214 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16215 HOTSPOT_TARGET_CPU=x86_32 16216 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16217 HOTSPOT_TARGET_CPU=sparc 16218 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16219 HOTSPOT_TARGET_CPU=ppc_64 16220 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16221 HOTSPOT_TARGET_CPU=ppc_64 16222 fi 16223 16224 16225 # This is identical with OPENJDK_*, but define anyway for consistency. 16226 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 16227 16228 16229 # Setup HOTSPOT_TARGET_CPU_DEFINE 16230 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16231 HOTSPOT_TARGET_CPU_DEFINE=IA32 16232 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16233 HOTSPOT_TARGET_CPU_DEFINE=AMD64 16234 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16235 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16236 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 16237 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 16238 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16239 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16240 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16241 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16242 16243 # The cpu defines below are for zero, we don't support them directly. 16244 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 16245 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16246 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 16247 HOTSPOT_TARGET_CPU_DEFINE=PPC32 16248 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 16249 HOTSPOT_TARGET_CPU_DEFINE=S390 16250 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 16251 HOTSPOT_TARGET_CPU_DEFINE=S390 16252 elif test "x$OPENJDK_TARGET_CPU" != x; then 16253 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 16254 fi 16255 16256 16257 16258 16259 # Also store the legacy naming of the cpu. 16260 # Ie i586 and amd64 instead of x86 and x86_64 16261 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 16262 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16263 OPENJDK_BUILD_CPU_LEGACY="i586" 16264 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16265 # On all platforms except MacOSX replace x86_64 with amd64. 16266 OPENJDK_BUILD_CPU_LEGACY="amd64" 16267 elif test "x$OPENJDK_BUILD_CPU" = xalpha; then 16268 # Avoid name collisions with variables named alpha 16269 OPENJDK_BUILD_CPU_LEGACY="_alpha_" 16270 elif test "x$OPENJDK_BUILD_CPU" = xsh; then 16271 # Avoid name collisions with variables named sh 16272 OPENJDK_BUILD_CPU_LEGACY="_sh_" 16273 fi 16274 16275 16276 # And the second legacy naming of the cpu. 16277 # Ie i386 and amd64 instead of x86 and x86_64. 16278 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 16279 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16280 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 16281 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16282 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 16283 fi 16284 16285 16286 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16287 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16288 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 16289 OPENJDK_BUILD_CPU_ISADIR="" 16290 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16291 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16292 OPENJDK_BUILD_CPU_ISADIR="/amd64" 16293 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16294 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 16295 fi 16296 fi 16297 16298 16299 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 16300 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 16301 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 16302 # On linux only, we replace x86 with i386. 16303 OPENJDK_BUILD_CPU_OSARCH="i386" 16304 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16305 # On all platforms except macosx, we replace x86_64 with amd64. 16306 OPENJDK_BUILD_CPU_OSARCH="amd64" 16307 fi 16308 16309 16310 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16311 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16312 OPENJDK_BUILD_CPU_JLI="i386" 16313 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16314 # On all platforms except macosx, we replace x86_64 with amd64. 16315 OPENJDK_BUILD_CPU_JLI="amd64" 16316 fi 16317 16318 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16319 OPENJDK_BUILD_OS_EXPORT_DIR=macosx 16320 else 16321 OPENJDK_BUILD_OS_EXPORT_DIR=${OPENJDK_BUILD_OS_TYPE} 16322 fi 16323 16324 16325 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16326 # Macosx is osx and x86_64 is x64 16327 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16328 OPENJDK_BUILD_OS_BUNDLE="osx" 16329 else 16330 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16331 fi 16332 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16333 OPENJDK_BUILD_CPU_BUNDLE="x64" 16334 else 16335 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16336 fi 16337 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16338 16339 16340 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16341 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16342 # unpack200.exe. This variable is used in 16343 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16344 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16345 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16346 fi 16347 fi 16348 16349 if test "x$COMPILE_TYPE" = "xcross"; then 16350 # FIXME: ... or should this include reduced builds..? 16351 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16352 else 16353 DEFINE_CROSS_COMPILE_ARCH="" 16354 fi 16355 16356 16357 # Convert openjdk platform names to hotspot names 16358 16359 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16360 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16361 HOTSPOT_BUILD_OS=bsd 16362 fi 16363 16364 16365 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16366 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16367 HOTSPOT_BUILD_OS_TYPE=posix 16368 fi 16369 16370 16371 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16372 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16373 HOTSPOT_BUILD_CPU=x86_32 16374 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16375 HOTSPOT_BUILD_CPU=sparc 16376 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16377 HOTSPOT_BUILD_CPU=ppc_64 16378 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16379 HOTSPOT_BUILD_CPU=ppc_64 16380 fi 16381 16382 16383 # This is identical with OPENJDK_*, but define anyway for consistency. 16384 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16385 16386 16387 # Setup HOTSPOT_BUILD_CPU_DEFINE 16388 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16389 HOTSPOT_BUILD_CPU_DEFINE=IA32 16390 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16391 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16392 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16393 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16394 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16395 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16396 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16397 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16398 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16399 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16400 16401 # The cpu defines below are for zero, we don't support them directly. 16402 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16403 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16404 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16405 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16406 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16407 HOTSPOT_BUILD_CPU_DEFINE=S390 16408 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16409 HOTSPOT_BUILD_CPU_DEFINE=S390 16410 elif test "x$OPENJDK_BUILD_CPU" != x; then 16411 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16412 fi 16413 16414 16415 16416 16417 16418 16419 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16420 16421 # Save the current directory this script was started from 16422 CURDIR="$PWD" 16423 16424 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16425 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16426 # was not available at that time. 16427 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16428 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16429 ORIGINAL_PATH="$REWRITTEN_PATH" 16430 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16431 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16432 fi 16433 16434 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16435 PATH_SEP=";" 16436 16437 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16438 if test $SRC_ROOT_LENGTH -gt 100; then 16439 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16440 fi 16441 16442 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16444 $as_echo_n "checking cygwin release... " >&6; } 16445 CYGWIN_VERSION=`$UNAME -r` 16446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16447 $as_echo "$CYGWIN_VERSION" >&6; } 16448 WINDOWS_ENV_VENDOR='cygwin' 16449 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16450 16451 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16452 if test "x$CYGWIN_VERSION_OLD" != x; then 16453 { $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 16454 $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;} 16455 as_fn_error $? "Cannot continue" "$LINENO" 5 16456 fi 16457 if test "x$CYGPATH" = x; then 16458 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16459 fi 16460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16461 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16462 # The cmd output ends with Windows line endings (CR/LF) 16463 cygwin_winpath_root=`cd / ; cmd /c cd | $TR -d '\r\n'` 16464 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16465 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16467 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16468 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16469 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16470 if test "x$test_cygdrive_prefix" = x; then 16471 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16472 fi 16473 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16475 $as_echo_n "checking msys release... " >&6; } 16476 MSYS_VERSION=`$UNAME -r` 16477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16478 $as_echo "$MSYS_VERSION" >&6; } 16479 16480 WINDOWS_ENV_VENDOR='msys' 16481 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16482 16483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16484 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16485 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16486 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16487 16488 windows_path="$MSYS_ROOT_PATH" 16489 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16490 unix_path=`$CYGPATH -u "$windows_path"` 16491 MSYS_ROOT_PATH="$unix_path" 16492 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16493 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16494 MSYS_ROOT_PATH="$unix_path" 16495 fi 16496 16497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16498 $as_echo "$MSYS_ROOT_PATH" >&6; } 16499 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16500 else 16501 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16502 fi 16503 16504 # Test if windows or unix (cygwin/msys) find is first in path. 16505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16506 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16507 FIND_BINARY_OUTPUT=`find --version 2>&1` 16508 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16510 $as_echo "unix style" >&6; } 16511 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16513 $as_echo "Windows" >&6; } 16514 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16515 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16516 { $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 16517 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16518 as_fn_error $? "Cannot continue" "$LINENO" 5 16519 else 16520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16521 $as_echo "unknown" >&6; } 16522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16523 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16524 fi 16525 16526 else 16527 PATH_SEP=":" 16528 fi 16529 16530 16531 # We get the top-level directory from the supporting wrappers. 16532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16533 $as_echo_n "checking for top-level directory... " >&6; } 16534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16535 $as_echo "$TOPDIR" >&6; } 16536 16537 16538 # Save the original version of TOPDIR for string comparisons 16539 ORIGINAL_TOPDIR="$TOPDIR" 16540 16541 16542 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16543 16544 # Only process if variable expands to non-empty 16545 16546 if test "x$CURDIR" != x; then 16547 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16548 16549 # Input might be given as Windows format, start by converting to 16550 # unix format. 16551 path="$CURDIR" 16552 new_path=`$CYGPATH -u "$path"` 16553 16554 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16555 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16556 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16557 # "foo.exe" is OK but "foo" is an error. 16558 # 16559 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16560 # It is also a way to make sure we got the proper file name for the real test later on. 16561 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16562 if test "x$test_shortpath" = x; then 16563 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16564 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16565 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16566 fi 16567 16568 # Call helper function which possibly converts this using DOS-style short mode. 16569 # If so, the updated path is stored in $new_path. 16570 16571 input_path="$new_path" 16572 # Check if we need to convert this using DOS-style short mode. If the path 16573 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16574 # take no chances and rewrite it. 16575 # Note: m4 eats our [], so we need to use [ and ] instead. 16576 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16577 if test "x$has_forbidden_chars" != x; then 16578 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16579 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16580 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16581 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16582 # Going to short mode and back again did indeed matter. Since short mode is 16583 # case insensitive, let's make it lowercase to improve readability. 16584 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16585 # Now convert it back to Unix-style (cygpath) 16586 input_path=`$CYGPATH -u "$shortmode_path"` 16587 new_path="$input_path" 16588 fi 16589 fi 16590 16591 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16592 if test "x$test_cygdrive_prefix" = x; then 16593 # As a simple fix, exclude /usr/bin since it's not a real path. 16594 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16595 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16596 # a path prefixed by /cygdrive for fixpath to work. 16597 new_path="$CYGWIN_ROOT_PATH$input_path" 16598 fi 16599 fi 16600 16601 16602 if test "x$path" != "x$new_path"; then 16603 CURDIR="$new_path" 16604 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16605 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16606 fi 16607 16608 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16609 16610 path="$CURDIR" 16611 has_colon=`$ECHO $path | $GREP ^.:` 16612 new_path="$path" 16613 if test "x$has_colon" = x; then 16614 # Not in mixed or Windows style, start by that. 16615 new_path=`cmd //c echo $path` 16616 fi 16617 16618 16619 input_path="$new_path" 16620 # Check if we need to convert this using DOS-style short mode. If the path 16621 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16622 # take no chances and rewrite it. 16623 # Note: m4 eats our [], so we need to use [ and ] instead. 16624 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16625 if test "x$has_forbidden_chars" != x; then 16626 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16627 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16628 fi 16629 16630 16631 windows_path="$new_path" 16632 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16633 unix_path=`$CYGPATH -u "$windows_path"` 16634 new_path="$unix_path" 16635 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16636 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16637 new_path="$unix_path" 16638 fi 16639 16640 if test "x$path" != "x$new_path"; then 16641 CURDIR="$new_path" 16642 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16643 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16644 fi 16645 16646 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16647 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16648 16649 else 16650 # We're on a unix platform. Hooray! :) 16651 path="$CURDIR" 16652 has_space=`$ECHO "$path" | $GREP " "` 16653 if test "x$has_space" != x; then 16654 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16655 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16656 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16657 fi 16658 16659 # Use eval to expand a potential ~ 16660 eval path="$path" 16661 if test ! -f "$path" && test ! -d "$path"; then 16662 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16663 fi 16664 16665 if test -d "$path"; then 16666 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16667 else 16668 dir="`$DIRNAME "$path"`" 16669 base="`$BASENAME "$path"`" 16670 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16671 fi 16672 fi 16673 fi 16674 16675 16676 # Only process if variable expands to non-empty 16677 16678 if test "x$TOPDIR" != x; then 16679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16680 16681 # Input might be given as Windows format, start by converting to 16682 # unix format. 16683 path="$TOPDIR" 16684 new_path=`$CYGPATH -u "$path"` 16685 16686 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16687 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16688 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16689 # "foo.exe" is OK but "foo" is an error. 16690 # 16691 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16692 # It is also a way to make sure we got the proper file name for the real test later on. 16693 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16694 if test "x$test_shortpath" = x; then 16695 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16696 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16697 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16698 fi 16699 16700 # Call helper function which possibly converts this using DOS-style short mode. 16701 # If so, the updated path is stored in $new_path. 16702 16703 input_path="$new_path" 16704 # Check if we need to convert this using DOS-style short mode. If the path 16705 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16706 # take no chances and rewrite it. 16707 # Note: m4 eats our [], so we need to use [ and ] instead. 16708 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16709 if test "x$has_forbidden_chars" != x; then 16710 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16711 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16712 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16713 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16714 # Going to short mode and back again did indeed matter. Since short mode is 16715 # case insensitive, let's make it lowercase to improve readability. 16716 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16717 # Now convert it back to Unix-style (cygpath) 16718 input_path=`$CYGPATH -u "$shortmode_path"` 16719 new_path="$input_path" 16720 fi 16721 fi 16722 16723 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16724 if test "x$test_cygdrive_prefix" = x; then 16725 # As a simple fix, exclude /usr/bin since it's not a real path. 16726 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16727 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16728 # a path prefixed by /cygdrive for fixpath to work. 16729 new_path="$CYGWIN_ROOT_PATH$input_path" 16730 fi 16731 fi 16732 16733 16734 if test "x$path" != "x$new_path"; then 16735 TOPDIR="$new_path" 16736 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16737 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16738 fi 16739 16740 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16741 16742 path="$TOPDIR" 16743 has_colon=`$ECHO $path | $GREP ^.:` 16744 new_path="$path" 16745 if test "x$has_colon" = x; then 16746 # Not in mixed or Windows style, start by that. 16747 new_path=`cmd //c echo $path` 16748 fi 16749 16750 16751 input_path="$new_path" 16752 # Check if we need to convert this using DOS-style short mode. If the path 16753 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16754 # take no chances and rewrite it. 16755 # Note: m4 eats our [], so we need to use [ and ] instead. 16756 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16757 if test "x$has_forbidden_chars" != x; then 16758 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16759 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16760 fi 16761 16762 16763 windows_path="$new_path" 16764 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16765 unix_path=`$CYGPATH -u "$windows_path"` 16766 new_path="$unix_path" 16767 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16768 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16769 new_path="$unix_path" 16770 fi 16771 16772 if test "x$path" != "x$new_path"; then 16773 TOPDIR="$new_path" 16774 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16775 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16776 fi 16777 16778 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16779 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16780 16781 else 16782 # We're on a unix platform. Hooray! :) 16783 path="$TOPDIR" 16784 has_space=`$ECHO "$path" | $GREP " "` 16785 if test "x$has_space" != x; then 16786 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16787 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16788 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16789 fi 16790 16791 # Use eval to expand a potential ~ 16792 eval path="$path" 16793 if test ! -f "$path" && test ! -d "$path"; then 16794 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16795 fi 16796 16797 if test -d "$path"; then 16798 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16799 else 16800 dir="`$DIRNAME "$path"`" 16801 base="`$BASENAME "$path"`" 16802 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16803 fi 16804 fi 16805 fi 16806 16807 # SRC_ROOT is a traditional alias for TOPDIR. 16808 SRC_ROOT=$TOPDIR 16809 16810 # Calculate a canonical version of TOPDIR for string comparisons 16811 CANONICAL_TOPDIR=$TOPDIR 16812 16813 if test "x$OPENJDK_BUILD_OS" != xwindows; then 16814 # Follow a chain of symbolic links. Use readlink 16815 # where it exists, else fall back to horribly 16816 # complicated shell code. 16817 if test "x$READLINK_TESTED" != yes; then 16818 # On MacOSX there is a readlink tool with a different 16819 # purpose than the GNU readlink tool. Check the found readlink. 16820 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 16821 if test "x$ISGNU" = x; then 16822 # A readlink that we do not know how to use. 16823 # Are there other non-GNU readlinks out there? 16824 READLINK_TESTED=yes 16825 READLINK= 16826 fi 16827 fi 16828 16829 if test "x$READLINK" != x; then 16830 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 16831 else 16832 # Save the current directory for restoring afterwards 16833 STARTDIR=$PWD 16834 COUNTER=0 16835 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 16836 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 16837 cd $sym_link_dir 16838 # Use -P flag to resolve symlinks in directories. 16839 cd `$THEPWDCMD -P` 16840 sym_link_dir=`$THEPWDCMD -P` 16841 # Resolve file symlinks 16842 while test $COUNTER -lt 20; do 16843 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 16844 if test "x$ISLINK" == x; then 16845 # This is not a symbolic link! We are done! 16846 break 16847 fi 16848 # Again resolve directory symlinks since the target of the just found 16849 # link could be in a different directory 16850 cd `$DIRNAME $ISLINK` 16851 sym_link_dir=`$THEPWDCMD -P` 16852 sym_link_file=`$BASENAME $ISLINK` 16853 let COUNTER=COUNTER+1 16854 done 16855 cd $STARTDIR 16856 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 16857 fi 16858 fi 16859 16860 16861 16862 # Locate the directory of this script. 16863 AUTOCONF_DIR=$TOPDIR/make/autoconf 16864 16865 # Setup username (for use in adhoc version strings etc) 16866 # Outer [ ] to quote m4. 16867 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16868 16869 16870 16871 # Check if it's a pure open build or if custom sources are to be used. 16872 16873 # Check whether --enable-openjdk-only was given. 16874 if test "${enable_openjdk_only+set}" = set; then : 16875 enableval=$enable_openjdk_only; 16876 else 16877 enable_openjdk_only="no" 16878 fi 16879 16880 16881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16882 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16884 $as_echo "$enable_openjdk_only" >&6; } 16885 if test "x$enable_openjdk_only" = "xyes"; then 16886 SUPPRESS_CUSTOM_EXTENSIONS="true" 16887 elif test "x$enable_openjdk_only" = "xno"; then 16888 SUPPRESS_CUSTOM_EXTENSIONS="false" 16889 else 16890 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16891 fi 16892 16893 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16894 # the IncludeCustomExtension macro. 16895 16896 16897 # Check whether --with-custom-make-dir was given. 16898 if test "${with_custom_make_dir+set}" = set; then : 16899 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 16900 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16901 fi 16902 16903 16904 16905 16906 # These are needed to be able to create a configuration name (and thus the output directory) 16907 16908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16909 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16910 16911 # Check whether --with-jdk-variant was given. 16912 if test "${with_jdk_variant+set}" = set; then : 16913 withval=$with_jdk_variant; 16914 fi 16915 16916 16917 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16918 JDK_VARIANT="normal" 16919 else 16920 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16921 fi 16922 16923 16924 16925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16926 $as_echo "$JDK_VARIANT" >&6; } 16927 16928 16929 DEBUG_LEVEL="release" 16930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16931 $as_echo_n "checking which debug level to use... " >&6; } 16932 # Check whether --enable-debug was given. 16933 if test "${enable_debug+set}" = set; then : 16934 enableval=$enable_debug; 16935 ENABLE_DEBUG="${enableval}" 16936 DEBUG_LEVEL="fastdebug" 16937 16938 else 16939 ENABLE_DEBUG="no" 16940 fi 16941 16942 16943 16944 # Check whether --with-debug-level was given. 16945 if test "${with_debug_level+set}" = set; then : 16946 withval=$with_debug_level; 16947 DEBUG_LEVEL="${withval}" 16948 if test "x$ENABLE_DEBUG" = xyes; then 16949 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16950 fi 16951 16952 fi 16953 16954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16955 $as_echo "$DEBUG_LEVEL" >&6; } 16956 16957 if test "x$DEBUG_LEVEL" != xrelease && \ 16958 test "x$DEBUG_LEVEL" != xoptimized && \ 16959 test "x$DEBUG_LEVEL" != xfastdebug && \ 16960 test "x$DEBUG_LEVEL" != xslowdebug; then 16961 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16962 fi 16963 16964 # Translate DEBUG_LEVEL to debug level used by Hotspot 16965 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16966 if test "x$DEBUG_LEVEL" = xrelease; then 16967 HOTSPOT_DEBUG_LEVEL="product" 16968 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16969 HOTSPOT_DEBUG_LEVEL="debug" 16970 fi 16971 16972 if test "x$DEBUG_LEVEL" = xoptimized; then 16973 # The debug level 'optimized' is a little special because it is currently only 16974 # applicable to the HotSpot build where it means to build a completely 16975 # optimized version of the VM without any debugging code (like for the 16976 # 'release' debug level which is called 'product' in the HotSpot build) but 16977 # with the exception that it can contain additional code which is otherwise 16978 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16979 # test new and/or experimental features which are not intended for customer 16980 # shipment. Because these new features need to be tested and benchmarked in 16981 # real world scenarios, we want to build the containing JDK at the 'release' 16982 # debug level. 16983 DEBUG_LEVEL="release" 16984 fi 16985 16986 16987 16988 16989 16990 16991 # Check whether --with-jvm-variants was given. 16992 if test "${with_jvm_variants+set}" = set; then : 16993 withval=$with_jvm_variants; 16994 fi 16995 16996 16997 16998 16999 # Check whether --with-cpu-port was given. 17000 if test "${with_cpu_port+set}" = set; then : 17001 withval=$with_cpu_port; 17002 fi 17003 17004 17005 if test "x$with_cpu_port" != x; then 17006 if test "x$OPENJDK_TARGET_CPU" != xaarch64; then 17007 as_fn_error $? "--with-cpu-port only available on aarch64" "$LINENO" 5 17008 fi 17009 if test "x$with_cpu_port" != xarm64 && \ 17010 test "x$with_cpu_port" != xaarch64; then 17011 as_fn_error $? "--with-cpu-port must specify arm64 or aarch64" "$LINENO" 5 17012 fi 17013 HOTSPOT_TARGET_CPU_PORT="$with_cpu_port" 17014 fi 17015 17016 17017 if test "x$with_jvm_variants" = x; then 17018 with_jvm_variants="server" 17019 fi 17020 JVM_VARIANTS_OPT="$with_jvm_variants" 17021 17022 # Has the user listed more than one variant? 17023 # Additional [] needed to keep m4 from mangling shell constructs. 17024 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 17025 BUILDING_MULTIPLE_JVM_VARIANTS=true 17026 else 17027 BUILDING_MULTIPLE_JVM_VARIANTS=false 17028 fi 17029 # Replace the commas with AND for use in the build directory name. 17030 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 17031 17032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 17033 $as_echo_n "checking which variants of the JVM to build... " >&6; } 17034 # JVM_VARIANTS is a space-separated list. 17035 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 17036 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 17037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 17038 $as_echo "$JVM_VARIANTS" >&6; } 17039 17040 # Check that the selected variants are valid 17041 17042 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 17043 # Notice that the original variant failes on SLES 10 and 11 17044 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 17045 STACK=${JVM_VARIANTS// /$'\n'} 17046 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 17047 if test "x$INVALID_VARIANTS" != x; then 17048 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 17049 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 17050 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 17051 fi 17052 17053 # All "special" variants share the same output directory ("server") 17054 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 17055 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 17056 STACK=${JVM_VARIANTS// /$'\n'} 17057 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 17058 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 17059 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 17060 fi 17061 17062 # The "main" variant is the one used by other libs to link against during the 17063 # build. 17064 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 17065 MAIN_VARIANT_PRIO_ORDER="server client minimal" 17066 for variant in $MAIN_VARIANT_PRIO_ORDER; do 17067 if [[ " $JVM_VARIANTS " =~ " $variant " ]] ; then 17068 JVM_VARIANT_MAIN="$variant" 17069 break 17070 fi 17071 done 17072 else 17073 JVM_VARIANT_MAIN="$JVM_VARIANTS" 17074 fi 17075 17076 17077 17078 17079 17080 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 17081 # zero behaves as a platform and rewrites these values. This is really weird. :( 17082 # We are guaranteed that we do not build any other variants when building zero. 17083 HOTSPOT_TARGET_CPU=zero 17084 HOTSPOT_TARGET_CPU_ARCH=zero 17085 fi 17086 17087 17088 # With basic setup done, call the custom early hook. 17089 17090 17091 # Check if we have devkits, extra paths or sysroot set. 17092 17093 17094 # Check whether --with-devkit was given. 17095 if test "${with_devkit+set}" = set; then : 17096 withval=$with_devkit; 17097 17098 # Only process if variable expands to non-empty 17099 17100 if test "x$with_devkit" != x; then 17101 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17102 17103 # Input might be given as Windows format, start by converting to 17104 # unix format. 17105 path="$with_devkit" 17106 new_path=`$CYGPATH -u "$path"` 17107 17108 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17109 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17110 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17111 # "foo.exe" is OK but "foo" is an error. 17112 # 17113 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17114 # It is also a way to make sure we got the proper file name for the real test later on. 17115 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17116 if test "x$test_shortpath" = x; then 17117 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17118 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17119 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 17120 fi 17121 17122 # Call helper function which possibly converts this using DOS-style short mode. 17123 # If so, the updated path is stored in $new_path. 17124 17125 input_path="$new_path" 17126 # Check if we need to convert this using DOS-style short mode. If the path 17127 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17128 # take no chances and rewrite it. 17129 # Note: m4 eats our [], so we need to use [ and ] instead. 17130 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17131 if test "x$has_forbidden_chars" != x; then 17132 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17133 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17134 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17135 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17136 # Going to short mode and back again did indeed matter. Since short mode is 17137 # case insensitive, let's make it lowercase to improve readability. 17138 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17139 # Now convert it back to Unix-style (cygpath) 17140 input_path=`$CYGPATH -u "$shortmode_path"` 17141 new_path="$input_path" 17142 fi 17143 fi 17144 17145 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17146 if test "x$test_cygdrive_prefix" = x; then 17147 # As a simple fix, exclude /usr/bin since it's not a real path. 17148 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17149 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17150 # a path prefixed by /cygdrive for fixpath to work. 17151 new_path="$CYGWIN_ROOT_PATH$input_path" 17152 fi 17153 fi 17154 17155 17156 if test "x$path" != "x$new_path"; then 17157 with_devkit="$new_path" 17158 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17159 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17160 fi 17161 17162 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17163 17164 path="$with_devkit" 17165 has_colon=`$ECHO $path | $GREP ^.:` 17166 new_path="$path" 17167 if test "x$has_colon" = x; then 17168 # Not in mixed or Windows style, start by that. 17169 new_path=`cmd //c echo $path` 17170 fi 17171 17172 17173 input_path="$new_path" 17174 # Check if we need to convert this using DOS-style short mode. If the path 17175 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17176 # take no chances and rewrite it. 17177 # Note: m4 eats our [], so we need to use [ and ] instead. 17178 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17179 if test "x$has_forbidden_chars" != x; then 17180 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17181 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17182 fi 17183 17184 17185 windows_path="$new_path" 17186 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17187 unix_path=`$CYGPATH -u "$windows_path"` 17188 new_path="$unix_path" 17189 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17190 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17191 new_path="$unix_path" 17192 fi 17193 17194 if test "x$path" != "x$new_path"; then 17195 with_devkit="$new_path" 17196 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17197 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17198 fi 17199 17200 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17201 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17202 17203 else 17204 # We're on a unix platform. Hooray! :) 17205 path="$with_devkit" 17206 has_space=`$ECHO "$path" | $GREP " "` 17207 if test "x$has_space" != x; then 17208 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17209 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17210 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17211 fi 17212 17213 # Use eval to expand a potential ~ 17214 eval path="$path" 17215 if test ! -f "$path" && test ! -d "$path"; then 17216 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 17217 fi 17218 17219 if test -d "$path"; then 17220 with_devkit="`cd "$path"; $THEPWDCMD -L`" 17221 else 17222 dir="`$DIRNAME "$path"`" 17223 base="`$BASENAME "$path"`" 17224 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 17225 fi 17226 fi 17227 fi 17228 17229 DEVKIT_ROOT="$with_devkit" 17230 # Check for a meta data info file in the root of the devkit 17231 if test -f "$DEVKIT_ROOT/devkit.info"; then 17232 . $DEVKIT_ROOT/devkit.info 17233 # This potentially sets the following: 17234 # A descriptive name of the devkit 17235 17236 if test "x$DEVKIT_NAME" = x; then 17237 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 17238 fi 17239 17240 # Corresponds to --with-extra-path 17241 17242 if test "x$DEVKIT_EXTRA_PATH" = x; then 17243 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 17244 fi 17245 17246 # Corresponds to --with-toolchain-path 17247 17248 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17249 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 17250 fi 17251 17252 # Corresponds to --with-sysroot 17253 17254 if test "x$DEVKIT_SYSROOT" = x; then 17255 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 17256 fi 17257 17258 17259 # Identifies the Visual Studio version in the devkit 17260 17261 if test "x$DEVKIT_VS_VERSION" = x; then 17262 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 17263 fi 17264 17265 # The Visual Studio include environment variable 17266 17267 if test "x$DEVKIT_VS_INCLUDE" = x; then 17268 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 17269 fi 17270 17271 # The Visual Studio lib environment variable 17272 17273 if test "x$DEVKIT_VS_LIB" = x; then 17274 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 17275 fi 17276 17277 # Corresponds to --with-msvcr-dll 17278 17279 if test "x$DEVKIT_MSVCR_DLL" = x; then 17280 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 17281 fi 17282 17283 # Corresponds to --with-msvcp-dll 17284 17285 if test "x$DEVKIT_MSVCP_DLL" = x; then 17286 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 17287 fi 17288 17289 fi 17290 17291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 17292 $as_echo_n "checking for devkit... " >&6; } 17293 if test "x$DEVKIT_NAME" != x; then 17294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 17295 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 17296 else 17297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 17298 $as_echo "$DEVKIT_ROOT" >&6; } 17299 fi 17300 17301 17302 if test "x$DEVKIT_EXTRA_PATH" != x; then 17303 if test "x$EXTRA_PATH" = x; then 17304 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 17305 else 17306 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 17307 fi 17308 fi 17309 17310 17311 # Fallback default of just /bin if DEVKIT_PATH is not defined 17312 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17313 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 17314 fi 17315 17316 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 17317 if test "x$TOOLCHAIN_PATH" = x; then 17318 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 17319 else 17320 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17321 fi 17322 fi 17323 17324 17325 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17326 # places for backwards compatiblity. 17327 if test "x$DEVKIT_SYSROOT" != x; then 17328 SYSROOT="$DEVKIT_SYSROOT" 17329 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17330 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17331 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17332 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17333 fi 17334 17335 17336 fi 17337 17338 17339 # You can force the sysroot if the sysroot encoded into the compiler tools 17340 # is not correct. 17341 17342 # Check whether --with-sys-root was given. 17343 if test "${with_sys_root+set}" = set; then : 17344 withval=$with_sys_root; SYSROOT=$with_sys_root 17345 17346 fi 17347 17348 17349 17350 # Check whether --with-sysroot was given. 17351 if test "${with_sysroot+set}" = set; then : 17352 withval=$with_sysroot; SYSROOT=$with_sysroot 17353 17354 fi 17355 17356 17357 17358 # Check whether --with-tools-dir was given. 17359 if test "${with_tools_dir+set}" = set; then : 17360 withval=$with_tools_dir; 17361 if test "x$with_tools_dir" != x; then 17362 if test "x$TOOLCHAIN_PATH" = x; then 17363 TOOLCHAIN_PATH="$with_tools_dir" 17364 else 17365 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17366 fi 17367 fi 17368 17369 17370 fi 17371 17372 17373 17374 # Check whether --with-toolchain-path was given. 17375 if test "${with_toolchain_path+set}" = set; then : 17376 withval=$with_toolchain_path; 17377 if test "x$with_toolchain_path" != x; then 17378 if test "x$TOOLCHAIN_PATH" = x; then 17379 TOOLCHAIN_PATH="$with_toolchain_path" 17380 else 17381 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17382 fi 17383 fi 17384 17385 17386 fi 17387 17388 17389 17390 # Check whether --with-extra-path was given. 17391 if test "${with_extra_path+set}" = set; then : 17392 withval=$with_extra_path; 17393 if test "x$with_extra_path" != x; then 17394 if test "x$EXTRA_PATH" = x; then 17395 EXTRA_PATH="$with_extra_path" 17396 else 17397 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17398 fi 17399 fi 17400 17401 17402 fi 17403 17404 17405 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17406 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17407 # If not, detect if Xcode is installed by running xcodebuild -version 17408 # if no Xcode installed, xcodebuild exits with 1 17409 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17410 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17411 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17412 # fall back on the stub binary in /usr/bin/xcodebuild 17413 # Extract the first word of "xcodebuild", so it can be a program name with args. 17414 set dummy xcodebuild; ac_word=$2 17415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17416 $as_echo_n "checking for $ac_word... " >&6; } 17417 if ${ac_cv_path_XCODEBUILD+:} false; then : 17418 $as_echo_n "(cached) " >&6 17419 else 17420 case $XCODEBUILD in 17421 [\\/]* | ?:[\\/]*) 17422 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17423 ;; 17424 *) 17425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17426 for as_dir in $TOOLCHAIN_PATH 17427 do 17428 IFS=$as_save_IFS 17429 test -z "$as_dir" && as_dir=. 17430 for ac_exec_ext in '' $ac_executable_extensions; do 17431 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17432 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17433 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17434 break 2 17435 fi 17436 done 17437 done 17438 IFS=$as_save_IFS 17439 17440 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17441 ;; 17442 esac 17443 fi 17444 XCODEBUILD=$ac_cv_path_XCODEBUILD 17445 if test -n "$XCODEBUILD"; then 17446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17447 $as_echo "$XCODEBUILD" >&6; } 17448 else 17449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17450 $as_echo "no" >&6; } 17451 fi 17452 17453 17454 else 17455 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17456 # when only the command line tools are installed there are no SDKs, so headers 17457 # are copied into the system frameworks 17458 XCODEBUILD= 17459 17460 fi 17461 17462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17463 $as_echo_n "checking for sdk name... " >&6; } 17464 17465 # Check whether --with-sdk-name was given. 17466 if test "${with_sdk_name+set}" = set; then : 17467 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17468 17469 fi 17470 17471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17472 $as_echo "$SDKNAME" >&6; } 17473 17474 # if toolchain path is specified then don't rely on system headers, they may not compile 17475 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17476 test -z "$TOOLCHAIN_PATH" && \ 17477 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17478 17479 if test -z "$SYSROOT"; then 17480 if test -n "$XCODEBUILD"; then 17481 # if we don't have system headers, use default SDK name (last resort) 17482 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17483 SDKNAME=${SDKNAME:-macosx} 17484 fi 17485 17486 if test -n "$SDKNAME"; then 17487 # Call xcodebuild to determine SYSROOT 17488 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17489 fi 17490 else 17491 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17492 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 17493 fi 17494 fi 17495 else 17496 # warn user if --with-sdk-name was also set 17497 if test -n "$with_sdk_name"; then 17498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17499 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17500 fi 17501 fi 17502 17503 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17504 # If no system framework headers, then SYSROOT must be set, or we won't build 17505 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 17506 fi 17507 17508 # Perform a basic sanity test 17509 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17510 if test -z "$SYSROOT"; then 17511 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 17512 else 17513 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17514 fi 17515 fi 17516 17517 # set SDKROOT too, Xcode tools will pick it up 17518 SDKROOT="$SYSROOT" 17519 17520 fi 17521 17522 # Prepend the extra path to the global path 17523 17524 if test "x$EXTRA_PATH" != x; then 17525 if test "x$PATH" = x; then 17526 PATH="$EXTRA_PATH" 17527 else 17528 PATH="$EXTRA_PATH:$PATH" 17529 fi 17530 fi 17531 17532 17533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17534 $as_echo_n "checking for sysroot... " >&6; } 17535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17536 $as_echo "$SYSROOT" >&6; } 17537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17538 $as_echo_n "checking for toolchain path... " >&6; } 17539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17540 $as_echo "$TOOLCHAIN_PATH" >&6; } 17541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17542 $as_echo_n "checking for extra path... " >&6; } 17543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17544 $as_echo "$EXTRA_PATH" >&6; } 17545 17546 17547 # To properly create a configuration name, we need to have the OpenJDK target 17548 # and options (variants and debug level) parsed. 17549 17550 17551 17552 # Check whether --with-conf-name was given. 17553 if test "${with_conf_name+set}" = set; then : 17554 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17555 fi 17556 17557 17558 # Check whether --with-output-base-dir was given. 17559 if test "${with_output_base_dir+set}" = set; then : 17560 withval=$with_output_base_dir; OUTPUT_BASE=${with_output_base_dir} 17561 else 17562 OUTPUT_BASE="$SRC_ROOT/build" 17563 fi 17564 17565 17566 # Test from where we are running configure, in or outside of src root. 17567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17568 $as_echo_n "checking where to store configuration... " >&6; } 17569 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 17570 || test "x$CURDIR" = "x$SRC_ROOT/make/autoconf" \ 17571 || test "x$CURDIR" = "x$SRC_ROOT/make" ; then 17572 # We are running configure from the src root. 17573 # Create a default ./build/target-variant-debuglevel output root. 17574 if test "x${CONF_NAME}" = x; then 17575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17576 $as_echo "in default location" >&6; } 17577 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17578 else 17579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17580 $as_echo "in build directory with custom name" >&6; } 17581 fi 17582 OUTPUT_ROOT="${OUTPUT_BASE}/${CONF_NAME}" 17583 $MKDIR -p "$OUTPUT_ROOT" 17584 if test ! -d "$OUTPUT_ROOT"; then 17585 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 17586 fi 17587 else 17588 # We are running configure from outside of the src dir. 17589 # Then use the current directory as output dir! 17590 # If configuration is situated in normal build directory, just use the build 17591 # directory name as configuration name, otherwise use the complete path. 17592 if test "x${CONF_NAME}" = x; then 17593 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 17594 fi 17595 OUTPUT_ROOT="$CURDIR" 17596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17597 $as_echo "in current directory" >&6; } 17598 17599 # WARNING: This might be a bad thing to do. You need to be sure you want to 17600 # have a configuration in this directory. Do some sanity checks! 17601 17602 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 17603 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17604 # other files 17605 files_present=`$LS $OUTPUT_ROOT` 17606 # Configure has already touched config.log and confdefs.h in the current dir when this check 17607 # is performed. 17608 filtered_files=`$ECHO "$files_present" \ 17609 | $SED -e 's/config.log//g' \ 17610 -e 's/configure.log//g' \ 17611 -e 's/confdefs.h//g' \ 17612 -e 's/ //g' \ 17613 | $TR -d '\n'` 17614 if test "x$filtered_files" != x; then 17615 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17616 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17617 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17618 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17619 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17620 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17621 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17622 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17623 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17624 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17625 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 17626 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 17627 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17628 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17629 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17630 fi 17631 fi 17632 fi 17633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17634 $as_echo_n "checking what configuration name to use... " >&6; } 17635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17636 $as_echo "$CONF_NAME" >&6; } 17637 17638 17639 # Only process if variable expands to non-empty 17640 17641 if test "x$OUTPUT_ROOT" != x; then 17642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17643 17644 # Input might be given as Windows format, start by converting to 17645 # unix format. 17646 path="$OUTPUT_ROOT" 17647 new_path=`$CYGPATH -u "$path"` 17648 17649 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17650 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17651 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17652 # "foo.exe" is OK but "foo" is an error. 17653 # 17654 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17655 # It is also a way to make sure we got the proper file name for the real test later on. 17656 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17657 if test "x$test_shortpath" = x; then 17658 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17659 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17660 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 17661 fi 17662 17663 # Call helper function which possibly converts this using DOS-style short mode. 17664 # If so, the updated path is stored in $new_path. 17665 17666 input_path="$new_path" 17667 # Check if we need to convert this using DOS-style short mode. If the path 17668 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17669 # take no chances and rewrite it. 17670 # Note: m4 eats our [], so we need to use [ and ] instead. 17671 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17672 if test "x$has_forbidden_chars" != x; then 17673 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17674 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17675 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17676 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17677 # Going to short mode and back again did indeed matter. Since short mode is 17678 # case insensitive, let's make it lowercase to improve readability. 17679 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17680 # Now convert it back to Unix-style (cygpath) 17681 input_path=`$CYGPATH -u "$shortmode_path"` 17682 new_path="$input_path" 17683 fi 17684 fi 17685 17686 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17687 if test "x$test_cygdrive_prefix" = x; then 17688 # As a simple fix, exclude /usr/bin since it's not a real path. 17689 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17690 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17691 # a path prefixed by /cygdrive for fixpath to work. 17692 new_path="$CYGWIN_ROOT_PATH$input_path" 17693 fi 17694 fi 17695 17696 17697 if test "x$path" != "x$new_path"; then 17698 OUTPUT_ROOT="$new_path" 17699 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17700 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17701 fi 17702 17703 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17704 17705 path="$OUTPUT_ROOT" 17706 has_colon=`$ECHO $path | $GREP ^.:` 17707 new_path="$path" 17708 if test "x$has_colon" = x; then 17709 # Not in mixed or Windows style, start by that. 17710 new_path=`cmd //c echo $path` 17711 fi 17712 17713 17714 input_path="$new_path" 17715 # Check if we need to convert this using DOS-style short mode. If the path 17716 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17717 # take no chances and rewrite it. 17718 # Note: m4 eats our [], so we need to use [ and ] instead. 17719 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17720 if test "x$has_forbidden_chars" != x; then 17721 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17722 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17723 fi 17724 17725 17726 windows_path="$new_path" 17727 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17728 unix_path=`$CYGPATH -u "$windows_path"` 17729 new_path="$unix_path" 17730 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17731 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17732 new_path="$unix_path" 17733 fi 17734 17735 if test "x$path" != "x$new_path"; then 17736 OUTPUT_ROOT="$new_path" 17737 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17738 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17739 fi 17740 17741 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17742 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17743 17744 else 17745 # We're on a unix platform. Hooray! :) 17746 path="$OUTPUT_ROOT" 17747 has_space=`$ECHO "$path" | $GREP " "` 17748 if test "x$has_space" != x; then 17749 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17750 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17751 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17752 fi 17753 17754 # Use eval to expand a potential ~ 17755 eval path="$path" 17756 if test ! -f "$path" && test ! -d "$path"; then 17757 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 17758 fi 17759 17760 if test -d "$path"; then 17761 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 17762 else 17763 dir="`$DIRNAME "$path"`" 17764 base="`$BASENAME "$path"`" 17765 OUTPUT_ROOT="`cd "$dir"; $THEPWDCMD -L`/$base" 17766 fi 17767 fi 17768 fi 17769 17770 17771 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUT_ROOT/configure-support" 17772 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17773 17774 SPEC="$OUTPUT_ROOT/spec.gmk" 17775 17776 17777 17778 17779 17780 # The spec.gmk file contains all variables for the make system. 17781 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17782 17783 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17784 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17785 17786 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17787 ac_config_files="$ac_config_files $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17788 17789 # The compare.sh is used to compare the build output to other builds. 17790 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17791 17792 # The generated Makefile knows where the spec.gmk is and where the source is. 17793 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 17794 # which will look for generated configurations 17795 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 17796 17797 17798 17799 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17800 17801 for ac_prog in apt-get yum brew port pkgutil pkgadd 17802 do 17803 # Extract the first word of "$ac_prog", so it can be a program name with args. 17804 set dummy $ac_prog; ac_word=$2 17805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17806 $as_echo_n "checking for $ac_word... " >&6; } 17807 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17808 $as_echo_n "(cached) " >&6 17809 else 17810 if test -n "$PKGHANDLER"; then 17811 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17812 else 17813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17814 for as_dir in $PATH 17815 do 17816 IFS=$as_save_IFS 17817 test -z "$as_dir" && as_dir=. 17818 for ac_exec_ext in '' $ac_executable_extensions; do 17819 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17820 ac_cv_prog_PKGHANDLER="$ac_prog" 17821 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17822 break 2 17823 fi 17824 done 17825 done 17826 IFS=$as_save_IFS 17827 17828 fi 17829 fi 17830 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17831 if test -n "$PKGHANDLER"; then 17832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17833 $as_echo "$PKGHANDLER" >&6; } 17834 else 17835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17836 $as_echo "no" >&6; } 17837 fi 17838 17839 17840 test -n "$PKGHANDLER" && break 17841 done 17842 17843 17844 17845 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17846 17847 17848 17849 # Publish this variable in the help. 17850 17851 17852 if [ -z "${MAKE+x}" ]; then 17853 # The variable is not set by user, try to locate tool using the code snippet 17854 17855 # Try our hardest to locate a correct version of GNU make 17856 for ac_prog in gmake 17857 do 17858 # Extract the first word of "$ac_prog", so it can be a program name with args. 17859 set dummy $ac_prog; ac_word=$2 17860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17861 $as_echo_n "checking for $ac_word... " >&6; } 17862 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17863 $as_echo_n "(cached) " >&6 17864 else 17865 case $CHECK_GMAKE in 17866 [\\/]* | ?:[\\/]*) 17867 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17868 ;; 17869 *) 17870 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17871 for as_dir in $PATH 17872 do 17873 IFS=$as_save_IFS 17874 test -z "$as_dir" && as_dir=. 17875 for ac_exec_ext in '' $ac_executable_extensions; do 17876 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17877 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17879 break 2 17880 fi 17881 done 17882 done 17883 IFS=$as_save_IFS 17884 17885 ;; 17886 esac 17887 fi 17888 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17889 if test -n "$CHECK_GMAKE"; then 17890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17891 $as_echo "$CHECK_GMAKE" >&6; } 17892 else 17893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17894 $as_echo "no" >&6; } 17895 fi 17896 17897 17898 test -n "$CHECK_GMAKE" && break 17899 done 17900 17901 17902 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17903 DESCRIPTION="gmake in PATH" 17904 17905 # On Cygwin, we require a newer version of make than on other platforms 17906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17907 MAKE_VERSION_EXPR="-e 4\." 17908 MAKE_REQUIRED_VERSION="4.0" 17909 else 17910 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17911 MAKE_REQUIRED_VERSION="3.81" 17912 fi 17913 17914 if test "x$MAKE_CANDIDATE" != x; then 17915 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17916 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17917 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17918 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17919 if test "x$IS_GNU_MAKE" = x; then 17920 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17921 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17922 else 17923 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17924 if test "x$IS_MODERN_MAKE" = x; then 17925 { $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 17926 $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;} 17927 else 17928 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17929 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17930 MAKE_EXPECTED_ENV='cygwin' 17931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17932 MAKE_EXPECTED_ENV='msys' 17933 else 17934 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17935 fi 17936 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17937 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17938 else 17939 # Not relevant for non-Windows 17940 IS_MAKE_CORRECT_ENV=true 17941 fi 17942 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17943 { $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 17944 $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;} 17945 else 17946 FOUND_MAKE=$MAKE_CANDIDATE 17947 17948 # Only process if variable expands to non-empty 17949 17950 if test "x$FOUND_MAKE" != x; then 17951 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17952 17953 # First separate the path from the arguments. This will split at the first 17954 # space. 17955 complete="$FOUND_MAKE" 17956 path="${complete%% *}" 17957 tmp="$complete EOL" 17958 arguments="${tmp#* }" 17959 17960 # Input might be given as Windows format, start by converting to 17961 # unix format. 17962 new_path=`$CYGPATH -u "$path"` 17963 17964 # Now try to locate executable using which 17965 new_path=`$WHICH "$new_path" 2> /dev/null` 17966 # bat and cmd files are not always considered executable in cygwin causing which 17967 # to not find them 17968 if test "x$new_path" = x \ 17969 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17970 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17971 new_path=`$CYGPATH -u "$path"` 17972 fi 17973 if test "x$new_path" = x; then 17974 # Oops. Which didn't find the executable. 17975 # The splitting of arguments from the executable at a space might have been incorrect, 17976 # since paths with space are more likely in Windows. Give it another try with the whole 17977 # argument. 17978 path="$complete" 17979 arguments="EOL" 17980 new_path=`$CYGPATH -u "$path"` 17981 new_path=`$WHICH "$new_path" 2> /dev/null` 17982 # bat and cmd files are not always considered executable in cygwin causing which 17983 # to not find them 17984 if test "x$new_path" = x \ 17985 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17986 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17987 new_path=`$CYGPATH -u "$path"` 17988 fi 17989 if test "x$new_path" = x; then 17990 # It's still not found. Now this is an unrecoverable error. 17991 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17992 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17993 has_space=`$ECHO "$complete" | $GREP " "` 17994 if test "x$has_space" != x; then 17995 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17996 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17997 fi 17998 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17999 fi 18000 fi 18001 18002 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18003 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18004 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18005 # "foo.exe" is OK but "foo" is an error. 18006 # 18007 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18008 # It is also a way to make sure we got the proper file name for the real test later on. 18009 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18010 if test "x$test_shortpath" = x; then 18011 # Short path failed, file does not exist as specified. 18012 # Try adding .exe or .cmd 18013 if test -f "${new_path}.exe"; then 18014 input_to_shortpath="${new_path}.exe" 18015 elif test -f "${new_path}.cmd"; then 18016 input_to_shortpath="${new_path}.cmd" 18017 else 18018 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18019 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18020 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18021 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18022 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18023 fi 18024 else 18025 input_to_shortpath="$new_path" 18026 fi 18027 18028 # Call helper function which possibly converts this using DOS-style short mode. 18029 # If so, the updated path is stored in $new_path. 18030 new_path="$input_to_shortpath" 18031 18032 input_path="$input_to_shortpath" 18033 # Check if we need to convert this using DOS-style short mode. If the path 18034 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18035 # take no chances and rewrite it. 18036 # Note: m4 eats our [], so we need to use [ and ] instead. 18037 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18038 if test "x$has_forbidden_chars" != x; then 18039 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18040 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18041 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18042 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18043 # Going to short mode and back again did indeed matter. Since short mode is 18044 # case insensitive, let's make it lowercase to improve readability. 18045 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18046 # Now convert it back to Unix-style (cygpath) 18047 input_path=`$CYGPATH -u "$shortmode_path"` 18048 new_path="$input_path" 18049 fi 18050 fi 18051 18052 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18053 if test "x$test_cygdrive_prefix" = x; then 18054 # As a simple fix, exclude /usr/bin since it's not a real path. 18055 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18056 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18057 # a path prefixed by /cygdrive for fixpath to work. 18058 new_path="$CYGWIN_ROOT_PATH$input_path" 18059 fi 18060 fi 18061 18062 # remove trailing .exe if any 18063 new_path="${new_path/%.exe/}" 18064 18065 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18066 18067 # First separate the path from the arguments. This will split at the first 18068 # space. 18069 complete="$FOUND_MAKE" 18070 path="${complete%% *}" 18071 tmp="$complete EOL" 18072 arguments="${tmp#* }" 18073 18074 # Input might be given as Windows format, start by converting to 18075 # unix format. 18076 new_path="$path" 18077 18078 windows_path="$new_path" 18079 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18080 unix_path=`$CYGPATH -u "$windows_path"` 18081 new_path="$unix_path" 18082 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18083 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18084 new_path="$unix_path" 18085 fi 18086 18087 18088 # Now try to locate executable using which 18089 new_path=`$WHICH "$new_path" 2> /dev/null` 18090 18091 if test "x$new_path" = x; then 18092 # Oops. Which didn't find the executable. 18093 # The splitting of arguments from the executable at a space might have been incorrect, 18094 # since paths with space are more likely in Windows. Give it another try with the whole 18095 # argument. 18096 path="$complete" 18097 arguments="EOL" 18098 new_path="$path" 18099 18100 windows_path="$new_path" 18101 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18102 unix_path=`$CYGPATH -u "$windows_path"` 18103 new_path="$unix_path" 18104 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18105 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18106 new_path="$unix_path" 18107 fi 18108 18109 18110 new_path=`$WHICH "$new_path" 2> /dev/null` 18111 # bat and cmd files are not always considered executable in MSYS causing which 18112 # to not find them 18113 if test "x$new_path" = x \ 18114 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18115 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18116 new_path="$path" 18117 18118 windows_path="$new_path" 18119 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18120 unix_path=`$CYGPATH -u "$windows_path"` 18121 new_path="$unix_path" 18122 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18123 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18124 new_path="$unix_path" 18125 fi 18126 18127 fi 18128 18129 if test "x$new_path" = x; then 18130 # It's still not found. Now this is an unrecoverable error. 18131 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18132 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18133 has_space=`$ECHO "$complete" | $GREP " "` 18134 if test "x$has_space" != x; then 18135 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18136 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18137 fi 18138 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18139 fi 18140 fi 18141 18142 # Now new_path has a complete unix path to the binary 18143 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18144 # Keep paths in /bin as-is, but remove trailing .exe if any 18145 new_path="${new_path/%.exe/}" 18146 # Do not save /bin paths to all_fixpath_prefixes! 18147 else 18148 # Not in mixed or Windows style, start by that. 18149 new_path=`cmd //c echo $new_path` 18150 18151 input_path="$new_path" 18152 # Check if we need to convert this using DOS-style short mode. If the path 18153 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18154 # take no chances and rewrite it. 18155 # Note: m4 eats our [], so we need to use [ and ] instead. 18156 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18157 if test "x$has_forbidden_chars" != x; then 18158 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18159 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18160 fi 18161 18162 # Output is in $new_path 18163 18164 windows_path="$new_path" 18165 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18166 unix_path=`$CYGPATH -u "$windows_path"` 18167 new_path="$unix_path" 18168 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18169 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18170 new_path="$unix_path" 18171 fi 18172 18173 # remove trailing .exe if any 18174 new_path="${new_path/%.exe/}" 18175 18176 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18177 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18178 fi 18179 18180 else 18181 # We're on a unix platform. Hooray! :) 18182 # First separate the path from the arguments. This will split at the first 18183 # space. 18184 complete="$FOUND_MAKE" 18185 path="${complete%% *}" 18186 tmp="$complete EOL" 18187 arguments="${tmp#* }" 18188 18189 # Cannot rely on the command "which" here since it doesn't always work. 18190 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18191 if test -z "$is_absolute_path"; then 18192 # Path to executable is not absolute. Find it. 18193 IFS_save="$IFS" 18194 IFS=: 18195 for p in $PATH; do 18196 if test -f "$p/$path" && test -x "$p/$path"; then 18197 new_path="$p/$path" 18198 break 18199 fi 18200 done 18201 IFS="$IFS_save" 18202 else 18203 # This is an absolute path, we can use it without further modifications. 18204 new_path="$path" 18205 fi 18206 18207 if test "x$new_path" = x; then 18208 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18209 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18210 has_space=`$ECHO "$complete" | $GREP " "` 18211 if test "x$has_space" != x; then 18212 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18213 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18214 fi 18215 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18216 fi 18217 fi 18218 18219 # Now join together the path and the arguments once again 18220 if test "x$arguments" != xEOL; then 18221 new_complete="$new_path ${arguments% *}" 18222 else 18223 new_complete="$new_path" 18224 fi 18225 18226 if test "x$complete" != "x$new_complete"; then 18227 FOUND_MAKE="$new_complete" 18228 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18229 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18230 fi 18231 fi 18232 18233 fi 18234 fi 18235 fi 18236 fi 18237 18238 18239 if test "x$FOUND_MAKE" = x; then 18240 for ac_prog in make 18241 do 18242 # Extract the first word of "$ac_prog", so it can be a program name with args. 18243 set dummy $ac_prog; ac_word=$2 18244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18245 $as_echo_n "checking for $ac_word... " >&6; } 18246 if ${ac_cv_path_CHECK_MAKE+:} false; then : 18247 $as_echo_n "(cached) " >&6 18248 else 18249 case $CHECK_MAKE in 18250 [\\/]* | ?:[\\/]*) 18251 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 18252 ;; 18253 *) 18254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18255 for as_dir in $PATH 18256 do 18257 IFS=$as_save_IFS 18258 test -z "$as_dir" && as_dir=. 18259 for ac_exec_ext in '' $ac_executable_extensions; do 18260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18261 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 18262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18263 break 2 18264 fi 18265 done 18266 done 18267 IFS=$as_save_IFS 18268 18269 ;; 18270 esac 18271 fi 18272 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 18273 if test -n "$CHECK_MAKE"; then 18274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 18275 $as_echo "$CHECK_MAKE" >&6; } 18276 else 18277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18278 $as_echo "no" >&6; } 18279 fi 18280 18281 18282 test -n "$CHECK_MAKE" && break 18283 done 18284 18285 18286 MAKE_CANDIDATE=""$CHECK_MAKE"" 18287 DESCRIPTION="make in PATH" 18288 18289 # On Cygwin, we require a newer version of make than on other platforms 18290 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18291 MAKE_VERSION_EXPR="-e 4\." 18292 MAKE_REQUIRED_VERSION="4.0" 18293 else 18294 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18295 MAKE_REQUIRED_VERSION="3.81" 18296 fi 18297 18298 if test "x$MAKE_CANDIDATE" != x; then 18299 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18300 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18301 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18302 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18303 if test "x$IS_GNU_MAKE" = x; then 18304 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18305 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18306 else 18307 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18308 if test "x$IS_MODERN_MAKE" = x; then 18309 { $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 18310 $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;} 18311 else 18312 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18314 MAKE_EXPECTED_ENV='cygwin' 18315 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18316 MAKE_EXPECTED_ENV='msys' 18317 else 18318 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18319 fi 18320 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18321 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18322 else 18323 # Not relevant for non-Windows 18324 IS_MAKE_CORRECT_ENV=true 18325 fi 18326 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18327 { $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 18328 $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;} 18329 else 18330 FOUND_MAKE=$MAKE_CANDIDATE 18331 18332 # Only process if variable expands to non-empty 18333 18334 if test "x$FOUND_MAKE" != x; then 18335 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18336 18337 # First separate the path from the arguments. This will split at the first 18338 # space. 18339 complete="$FOUND_MAKE" 18340 path="${complete%% *}" 18341 tmp="$complete EOL" 18342 arguments="${tmp#* }" 18343 18344 # Input might be given as Windows format, start by converting to 18345 # unix format. 18346 new_path=`$CYGPATH -u "$path"` 18347 18348 # Now try to locate executable using which 18349 new_path=`$WHICH "$new_path" 2> /dev/null` 18350 # bat and cmd files are not always considered executable in cygwin causing which 18351 # to not find them 18352 if test "x$new_path" = x \ 18353 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18354 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18355 new_path=`$CYGPATH -u "$path"` 18356 fi 18357 if test "x$new_path" = x; then 18358 # Oops. Which didn't find the executable. 18359 # The splitting of arguments from the executable at a space might have been incorrect, 18360 # since paths with space are more likely in Windows. Give it another try with the whole 18361 # argument. 18362 path="$complete" 18363 arguments="EOL" 18364 new_path=`$CYGPATH -u "$path"` 18365 new_path=`$WHICH "$new_path" 2> /dev/null` 18366 # bat and cmd files are not always considered executable in cygwin causing which 18367 # to not find them 18368 if test "x$new_path" = x \ 18369 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18370 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18371 new_path=`$CYGPATH -u "$path"` 18372 fi 18373 if test "x$new_path" = x; then 18374 # It's still not found. Now this is an unrecoverable error. 18375 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18376 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18377 has_space=`$ECHO "$complete" | $GREP " "` 18378 if test "x$has_space" != x; then 18379 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18380 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18381 fi 18382 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18383 fi 18384 fi 18385 18386 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18387 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18388 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18389 # "foo.exe" is OK but "foo" is an error. 18390 # 18391 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18392 # It is also a way to make sure we got the proper file name for the real test later on. 18393 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18394 if test "x$test_shortpath" = x; then 18395 # Short path failed, file does not exist as specified. 18396 # Try adding .exe or .cmd 18397 if test -f "${new_path}.exe"; then 18398 input_to_shortpath="${new_path}.exe" 18399 elif test -f "${new_path}.cmd"; then 18400 input_to_shortpath="${new_path}.cmd" 18401 else 18402 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18403 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18404 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18405 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18406 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18407 fi 18408 else 18409 input_to_shortpath="$new_path" 18410 fi 18411 18412 # Call helper function which possibly converts this using DOS-style short mode. 18413 # If so, the updated path is stored in $new_path. 18414 new_path="$input_to_shortpath" 18415 18416 input_path="$input_to_shortpath" 18417 # Check if we need to convert this using DOS-style short mode. If the path 18418 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18419 # take no chances and rewrite it. 18420 # Note: m4 eats our [], so we need to use [ and ] instead. 18421 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18422 if test "x$has_forbidden_chars" != x; then 18423 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18424 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18425 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18426 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18427 # Going to short mode and back again did indeed matter. Since short mode is 18428 # case insensitive, let's make it lowercase to improve readability. 18429 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18430 # Now convert it back to Unix-style (cygpath) 18431 input_path=`$CYGPATH -u "$shortmode_path"` 18432 new_path="$input_path" 18433 fi 18434 fi 18435 18436 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18437 if test "x$test_cygdrive_prefix" = x; then 18438 # As a simple fix, exclude /usr/bin since it's not a real path. 18439 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18440 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18441 # a path prefixed by /cygdrive for fixpath to work. 18442 new_path="$CYGWIN_ROOT_PATH$input_path" 18443 fi 18444 fi 18445 18446 # remove trailing .exe if any 18447 new_path="${new_path/%.exe/}" 18448 18449 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18450 18451 # First separate the path from the arguments. This will split at the first 18452 # space. 18453 complete="$FOUND_MAKE" 18454 path="${complete%% *}" 18455 tmp="$complete EOL" 18456 arguments="${tmp#* }" 18457 18458 # Input might be given as Windows format, start by converting to 18459 # unix format. 18460 new_path="$path" 18461 18462 windows_path="$new_path" 18463 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18464 unix_path=`$CYGPATH -u "$windows_path"` 18465 new_path="$unix_path" 18466 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18467 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18468 new_path="$unix_path" 18469 fi 18470 18471 18472 # Now try to locate executable using which 18473 new_path=`$WHICH "$new_path" 2> /dev/null` 18474 18475 if test "x$new_path" = x; then 18476 # Oops. Which didn't find the executable. 18477 # The splitting of arguments from the executable at a space might have been incorrect, 18478 # since paths with space are more likely in Windows. Give it another try with the whole 18479 # argument. 18480 path="$complete" 18481 arguments="EOL" 18482 new_path="$path" 18483 18484 windows_path="$new_path" 18485 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18486 unix_path=`$CYGPATH -u "$windows_path"` 18487 new_path="$unix_path" 18488 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18489 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18490 new_path="$unix_path" 18491 fi 18492 18493 18494 new_path=`$WHICH "$new_path" 2> /dev/null` 18495 # bat and cmd files are not always considered executable in MSYS causing which 18496 # to not find them 18497 if test "x$new_path" = x \ 18498 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18499 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18500 new_path="$path" 18501 18502 windows_path="$new_path" 18503 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18504 unix_path=`$CYGPATH -u "$windows_path"` 18505 new_path="$unix_path" 18506 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18507 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18508 new_path="$unix_path" 18509 fi 18510 18511 fi 18512 18513 if test "x$new_path" = x; then 18514 # It's still not found. Now this is an unrecoverable error. 18515 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18516 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18517 has_space=`$ECHO "$complete" | $GREP " "` 18518 if test "x$has_space" != x; then 18519 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18520 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18521 fi 18522 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18523 fi 18524 fi 18525 18526 # Now new_path has a complete unix path to the binary 18527 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18528 # Keep paths in /bin as-is, but remove trailing .exe if any 18529 new_path="${new_path/%.exe/}" 18530 # Do not save /bin paths to all_fixpath_prefixes! 18531 else 18532 # Not in mixed or Windows style, start by that. 18533 new_path=`cmd //c echo $new_path` 18534 18535 input_path="$new_path" 18536 # Check if we need to convert this using DOS-style short mode. If the path 18537 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18538 # take no chances and rewrite it. 18539 # Note: m4 eats our [], so we need to use [ and ] instead. 18540 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18541 if test "x$has_forbidden_chars" != x; then 18542 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18543 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18544 fi 18545 18546 # Output is in $new_path 18547 18548 windows_path="$new_path" 18549 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18550 unix_path=`$CYGPATH -u "$windows_path"` 18551 new_path="$unix_path" 18552 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18553 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18554 new_path="$unix_path" 18555 fi 18556 18557 # remove trailing .exe if any 18558 new_path="${new_path/%.exe/}" 18559 18560 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18561 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18562 fi 18563 18564 else 18565 # We're on a unix platform. Hooray! :) 18566 # First separate the path from the arguments. This will split at the first 18567 # space. 18568 complete="$FOUND_MAKE" 18569 path="${complete%% *}" 18570 tmp="$complete EOL" 18571 arguments="${tmp#* }" 18572 18573 # Cannot rely on the command "which" here since it doesn't always work. 18574 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18575 if test -z "$is_absolute_path"; then 18576 # Path to executable is not absolute. Find it. 18577 IFS_save="$IFS" 18578 IFS=: 18579 for p in $PATH; do 18580 if test -f "$p/$path" && test -x "$p/$path"; then 18581 new_path="$p/$path" 18582 break 18583 fi 18584 done 18585 IFS="$IFS_save" 18586 else 18587 # This is an absolute path, we can use it without further modifications. 18588 new_path="$path" 18589 fi 18590 18591 if test "x$new_path" = x; then 18592 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18593 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18594 has_space=`$ECHO "$complete" | $GREP " "` 18595 if test "x$has_space" != x; then 18596 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18597 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18598 fi 18599 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18600 fi 18601 fi 18602 18603 # Now join together the path and the arguments once again 18604 if test "x$arguments" != xEOL; then 18605 new_complete="$new_path ${arguments% *}" 18606 else 18607 new_complete="$new_path" 18608 fi 18609 18610 if test "x$complete" != "x$new_complete"; then 18611 FOUND_MAKE="$new_complete" 18612 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18613 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18614 fi 18615 fi 18616 18617 fi 18618 fi 18619 fi 18620 fi 18621 18622 fi 18623 18624 if test "x$FOUND_MAKE" = x; then 18625 if test "x$TOOLCHAIN_PATH" != x; then 18626 # We have a toolchain path, check that as well before giving up. 18627 OLD_PATH=$PATH 18628 PATH=$TOOLCHAIN_PATH:$PATH 18629 for ac_prog in gmake 18630 do 18631 # Extract the first word of "$ac_prog", so it can be a program name with args. 18632 set dummy $ac_prog; ac_word=$2 18633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18634 $as_echo_n "checking for $ac_word... " >&6; } 18635 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18636 $as_echo_n "(cached) " >&6 18637 else 18638 case $CHECK_TOOLSDIR_GMAKE in 18639 [\\/]* | ?:[\\/]*) 18640 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18641 ;; 18642 *) 18643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18644 for as_dir in $PATH 18645 do 18646 IFS=$as_save_IFS 18647 test -z "$as_dir" && as_dir=. 18648 for ac_exec_ext in '' $ac_executable_extensions; do 18649 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18650 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18652 break 2 18653 fi 18654 done 18655 done 18656 IFS=$as_save_IFS 18657 18658 ;; 18659 esac 18660 fi 18661 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18662 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18664 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18665 else 18666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18667 $as_echo "no" >&6; } 18668 fi 18669 18670 18671 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18672 done 18673 18674 18675 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18676 DESCRIPTION="gmake in tools-dir" 18677 18678 # On Cygwin, we require a newer version of make than on other platforms 18679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18680 MAKE_VERSION_EXPR="-e 4\." 18681 MAKE_REQUIRED_VERSION="4.0" 18682 else 18683 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18684 MAKE_REQUIRED_VERSION="3.81" 18685 fi 18686 18687 if test "x$MAKE_CANDIDATE" != x; then 18688 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18689 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18690 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18691 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18692 if test "x$IS_GNU_MAKE" = x; then 18693 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18694 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18695 else 18696 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18697 if test "x$IS_MODERN_MAKE" = x; then 18698 { $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 18699 $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;} 18700 else 18701 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18702 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18703 MAKE_EXPECTED_ENV='cygwin' 18704 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18705 MAKE_EXPECTED_ENV='msys' 18706 else 18707 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18708 fi 18709 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18710 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18711 else 18712 # Not relevant for non-Windows 18713 IS_MAKE_CORRECT_ENV=true 18714 fi 18715 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18716 { $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 18717 $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;} 18718 else 18719 FOUND_MAKE=$MAKE_CANDIDATE 18720 18721 # Only process if variable expands to non-empty 18722 18723 if test "x$FOUND_MAKE" != x; then 18724 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18725 18726 # First separate the path from the arguments. This will split at the first 18727 # space. 18728 complete="$FOUND_MAKE" 18729 path="${complete%% *}" 18730 tmp="$complete EOL" 18731 arguments="${tmp#* }" 18732 18733 # Input might be given as Windows format, start by converting to 18734 # unix format. 18735 new_path=`$CYGPATH -u "$path"` 18736 18737 # Now try to locate executable using which 18738 new_path=`$WHICH "$new_path" 2> /dev/null` 18739 # bat and cmd files are not always considered executable in cygwin causing which 18740 # to not find them 18741 if test "x$new_path" = x \ 18742 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18743 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18744 new_path=`$CYGPATH -u "$path"` 18745 fi 18746 if test "x$new_path" = x; then 18747 # Oops. Which didn't find the executable. 18748 # The splitting of arguments from the executable at a space might have been incorrect, 18749 # since paths with space are more likely in Windows. Give it another try with the whole 18750 # argument. 18751 path="$complete" 18752 arguments="EOL" 18753 new_path=`$CYGPATH -u "$path"` 18754 new_path=`$WHICH "$new_path" 2> /dev/null` 18755 # bat and cmd files are not always considered executable in cygwin causing which 18756 # to not find them 18757 if test "x$new_path" = x \ 18758 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18759 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18760 new_path=`$CYGPATH -u "$path"` 18761 fi 18762 if test "x$new_path" = x; then 18763 # It's still not found. Now this is an unrecoverable error. 18764 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18765 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18766 has_space=`$ECHO "$complete" | $GREP " "` 18767 if test "x$has_space" != x; then 18768 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18769 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18770 fi 18771 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18772 fi 18773 fi 18774 18775 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18776 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18777 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18778 # "foo.exe" is OK but "foo" is an error. 18779 # 18780 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18781 # It is also a way to make sure we got the proper file name for the real test later on. 18782 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18783 if test "x$test_shortpath" = x; then 18784 # Short path failed, file does not exist as specified. 18785 # Try adding .exe or .cmd 18786 if test -f "${new_path}.exe"; then 18787 input_to_shortpath="${new_path}.exe" 18788 elif test -f "${new_path}.cmd"; then 18789 input_to_shortpath="${new_path}.cmd" 18790 else 18791 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18792 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18793 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18794 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18795 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18796 fi 18797 else 18798 input_to_shortpath="$new_path" 18799 fi 18800 18801 # Call helper function which possibly converts this using DOS-style short mode. 18802 # If so, the updated path is stored in $new_path. 18803 new_path="$input_to_shortpath" 18804 18805 input_path="$input_to_shortpath" 18806 # Check if we need to convert this using DOS-style short mode. If the path 18807 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18808 # take no chances and rewrite it. 18809 # Note: m4 eats our [], so we need to use [ and ] instead. 18810 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18811 if test "x$has_forbidden_chars" != x; then 18812 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18813 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18814 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18815 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18816 # Going to short mode and back again did indeed matter. Since short mode is 18817 # case insensitive, let's make it lowercase to improve readability. 18818 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18819 # Now convert it back to Unix-style (cygpath) 18820 input_path=`$CYGPATH -u "$shortmode_path"` 18821 new_path="$input_path" 18822 fi 18823 fi 18824 18825 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18826 if test "x$test_cygdrive_prefix" = x; then 18827 # As a simple fix, exclude /usr/bin since it's not a real path. 18828 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18829 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18830 # a path prefixed by /cygdrive for fixpath to work. 18831 new_path="$CYGWIN_ROOT_PATH$input_path" 18832 fi 18833 fi 18834 18835 # remove trailing .exe if any 18836 new_path="${new_path/%.exe/}" 18837 18838 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18839 18840 # First separate the path from the arguments. This will split at the first 18841 # space. 18842 complete="$FOUND_MAKE" 18843 path="${complete%% *}" 18844 tmp="$complete EOL" 18845 arguments="${tmp#* }" 18846 18847 # Input might be given as Windows format, start by converting to 18848 # unix format. 18849 new_path="$path" 18850 18851 windows_path="$new_path" 18852 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18853 unix_path=`$CYGPATH -u "$windows_path"` 18854 new_path="$unix_path" 18855 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18856 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18857 new_path="$unix_path" 18858 fi 18859 18860 18861 # Now try to locate executable using which 18862 new_path=`$WHICH "$new_path" 2> /dev/null` 18863 18864 if test "x$new_path" = x; then 18865 # Oops. Which didn't find the executable. 18866 # The splitting of arguments from the executable at a space might have been incorrect, 18867 # since paths with space are more likely in Windows. Give it another try with the whole 18868 # argument. 18869 path="$complete" 18870 arguments="EOL" 18871 new_path="$path" 18872 18873 windows_path="$new_path" 18874 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18875 unix_path=`$CYGPATH -u "$windows_path"` 18876 new_path="$unix_path" 18877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18878 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18879 new_path="$unix_path" 18880 fi 18881 18882 18883 new_path=`$WHICH "$new_path" 2> /dev/null` 18884 # bat and cmd files are not always considered executable in MSYS causing which 18885 # to not find them 18886 if test "x$new_path" = x \ 18887 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18888 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18889 new_path="$path" 18890 18891 windows_path="$new_path" 18892 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18893 unix_path=`$CYGPATH -u "$windows_path"` 18894 new_path="$unix_path" 18895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18896 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18897 new_path="$unix_path" 18898 fi 18899 18900 fi 18901 18902 if test "x$new_path" = x; then 18903 # It's still not found. Now this is an unrecoverable error. 18904 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18905 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18906 has_space=`$ECHO "$complete" | $GREP " "` 18907 if test "x$has_space" != x; then 18908 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18909 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18910 fi 18911 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18912 fi 18913 fi 18914 18915 # Now new_path has a complete unix path to the binary 18916 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18917 # Keep paths in /bin as-is, but remove trailing .exe if any 18918 new_path="${new_path/%.exe/}" 18919 # Do not save /bin paths to all_fixpath_prefixes! 18920 else 18921 # Not in mixed or Windows style, start by that. 18922 new_path=`cmd //c echo $new_path` 18923 18924 input_path="$new_path" 18925 # Check if we need to convert this using DOS-style short mode. If the path 18926 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18927 # take no chances and rewrite it. 18928 # Note: m4 eats our [], so we need to use [ and ] instead. 18929 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18930 if test "x$has_forbidden_chars" != x; then 18931 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18932 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18933 fi 18934 18935 # Output is in $new_path 18936 18937 windows_path="$new_path" 18938 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18939 unix_path=`$CYGPATH -u "$windows_path"` 18940 new_path="$unix_path" 18941 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18942 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18943 new_path="$unix_path" 18944 fi 18945 18946 # remove trailing .exe if any 18947 new_path="${new_path/%.exe/}" 18948 18949 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18950 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18951 fi 18952 18953 else 18954 # We're on a unix platform. Hooray! :) 18955 # First separate the path from the arguments. This will split at the first 18956 # space. 18957 complete="$FOUND_MAKE" 18958 path="${complete%% *}" 18959 tmp="$complete EOL" 18960 arguments="${tmp#* }" 18961 18962 # Cannot rely on the command "which" here since it doesn't always work. 18963 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18964 if test -z "$is_absolute_path"; then 18965 # Path to executable is not absolute. Find it. 18966 IFS_save="$IFS" 18967 IFS=: 18968 for p in $PATH; do 18969 if test -f "$p/$path" && test -x "$p/$path"; then 18970 new_path="$p/$path" 18971 break 18972 fi 18973 done 18974 IFS="$IFS_save" 18975 else 18976 # This is an absolute path, we can use it without further modifications. 18977 new_path="$path" 18978 fi 18979 18980 if test "x$new_path" = x; then 18981 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18982 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18983 has_space=`$ECHO "$complete" | $GREP " "` 18984 if test "x$has_space" != x; then 18985 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18986 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18987 fi 18988 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18989 fi 18990 fi 18991 18992 # Now join together the path and the arguments once again 18993 if test "x$arguments" != xEOL; then 18994 new_complete="$new_path ${arguments% *}" 18995 else 18996 new_complete="$new_path" 18997 fi 18998 18999 if test "x$complete" != "x$new_complete"; then 19000 FOUND_MAKE="$new_complete" 19001 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19002 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19003 fi 19004 fi 19005 19006 fi 19007 fi 19008 fi 19009 fi 19010 19011 if test "x$FOUND_MAKE" = x; then 19012 for ac_prog in make 19013 do 19014 # Extract the first word of "$ac_prog", so it can be a program name with args. 19015 set dummy $ac_prog; ac_word=$2 19016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19017 $as_echo_n "checking for $ac_word... " >&6; } 19018 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 19019 $as_echo_n "(cached) " >&6 19020 else 19021 case $CHECK_TOOLSDIR_MAKE in 19022 [\\/]* | ?:[\\/]*) 19023 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 19024 ;; 19025 *) 19026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19027 for as_dir in $PATH 19028 do 19029 IFS=$as_save_IFS 19030 test -z "$as_dir" && as_dir=. 19031 for ac_exec_ext in '' $ac_executable_extensions; do 19032 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19033 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 19034 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19035 break 2 19036 fi 19037 done 19038 done 19039 IFS=$as_save_IFS 19040 19041 ;; 19042 esac 19043 fi 19044 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 19045 if test -n "$CHECK_TOOLSDIR_MAKE"; then 19046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 19047 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 19048 else 19049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19050 $as_echo "no" >&6; } 19051 fi 19052 19053 19054 test -n "$CHECK_TOOLSDIR_MAKE" && break 19055 done 19056 19057 19058 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 19059 DESCRIPTION="make in tools-dir" 19060 19061 # On Cygwin, we require a newer version of make than on other platforms 19062 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19063 MAKE_VERSION_EXPR="-e 4\." 19064 MAKE_REQUIRED_VERSION="4.0" 19065 else 19066 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19067 MAKE_REQUIRED_VERSION="3.81" 19068 fi 19069 19070 if test "x$MAKE_CANDIDATE" != x; then 19071 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19072 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19073 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19074 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19075 if test "x$IS_GNU_MAKE" = x; then 19076 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19077 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19078 else 19079 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19080 if test "x$IS_MODERN_MAKE" = x; then 19081 { $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 19082 $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;} 19083 else 19084 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19085 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19086 MAKE_EXPECTED_ENV='cygwin' 19087 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19088 MAKE_EXPECTED_ENV='msys' 19089 else 19090 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19091 fi 19092 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19093 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19094 else 19095 # Not relevant for non-Windows 19096 IS_MAKE_CORRECT_ENV=true 19097 fi 19098 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19099 { $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 19100 $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;} 19101 else 19102 FOUND_MAKE=$MAKE_CANDIDATE 19103 19104 # Only process if variable expands to non-empty 19105 19106 if test "x$FOUND_MAKE" != x; then 19107 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19108 19109 # First separate the path from the arguments. This will split at the first 19110 # space. 19111 complete="$FOUND_MAKE" 19112 path="${complete%% *}" 19113 tmp="$complete EOL" 19114 arguments="${tmp#* }" 19115 19116 # Input might be given as Windows format, start by converting to 19117 # unix format. 19118 new_path=`$CYGPATH -u "$path"` 19119 19120 # Now try to locate executable using which 19121 new_path=`$WHICH "$new_path" 2> /dev/null` 19122 # bat and cmd files are not always considered executable in cygwin causing which 19123 # to not find them 19124 if test "x$new_path" = x \ 19125 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19126 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19127 new_path=`$CYGPATH -u "$path"` 19128 fi 19129 if test "x$new_path" = x; then 19130 # Oops. Which didn't find the executable. 19131 # The splitting of arguments from the executable at a space might have been incorrect, 19132 # since paths with space are more likely in Windows. Give it another try with the whole 19133 # argument. 19134 path="$complete" 19135 arguments="EOL" 19136 new_path=`$CYGPATH -u "$path"` 19137 new_path=`$WHICH "$new_path" 2> /dev/null` 19138 # bat and cmd files are not always considered executable in cygwin causing which 19139 # to not find them 19140 if test "x$new_path" = x \ 19141 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19142 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19143 new_path=`$CYGPATH -u "$path"` 19144 fi 19145 if test "x$new_path" = x; then 19146 # It's still not found. Now this is an unrecoverable error. 19147 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19148 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19149 has_space=`$ECHO "$complete" | $GREP " "` 19150 if test "x$has_space" != x; then 19151 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19152 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19153 fi 19154 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19155 fi 19156 fi 19157 19158 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19159 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19160 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19161 # "foo.exe" is OK but "foo" is an error. 19162 # 19163 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19164 # It is also a way to make sure we got the proper file name for the real test later on. 19165 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19166 if test "x$test_shortpath" = x; then 19167 # Short path failed, file does not exist as specified. 19168 # Try adding .exe or .cmd 19169 if test -f "${new_path}.exe"; then 19170 input_to_shortpath="${new_path}.exe" 19171 elif test -f "${new_path}.cmd"; then 19172 input_to_shortpath="${new_path}.cmd" 19173 else 19174 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19175 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19176 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19177 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19178 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19179 fi 19180 else 19181 input_to_shortpath="$new_path" 19182 fi 19183 19184 # Call helper function which possibly converts this using DOS-style short mode. 19185 # If so, the updated path is stored in $new_path. 19186 new_path="$input_to_shortpath" 19187 19188 input_path="$input_to_shortpath" 19189 # Check if we need to convert this using DOS-style short mode. If the path 19190 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19191 # take no chances and rewrite it. 19192 # Note: m4 eats our [], so we need to use [ and ] instead. 19193 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19194 if test "x$has_forbidden_chars" != x; then 19195 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19196 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19197 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19198 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19199 # Going to short mode and back again did indeed matter. Since short mode is 19200 # case insensitive, let's make it lowercase to improve readability. 19201 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19202 # Now convert it back to Unix-style (cygpath) 19203 input_path=`$CYGPATH -u "$shortmode_path"` 19204 new_path="$input_path" 19205 fi 19206 fi 19207 19208 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19209 if test "x$test_cygdrive_prefix" = x; then 19210 # As a simple fix, exclude /usr/bin since it's not a real path. 19211 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19212 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19213 # a path prefixed by /cygdrive for fixpath to work. 19214 new_path="$CYGWIN_ROOT_PATH$input_path" 19215 fi 19216 fi 19217 19218 # remove trailing .exe if any 19219 new_path="${new_path/%.exe/}" 19220 19221 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19222 19223 # First separate the path from the arguments. This will split at the first 19224 # space. 19225 complete="$FOUND_MAKE" 19226 path="${complete%% *}" 19227 tmp="$complete EOL" 19228 arguments="${tmp#* }" 19229 19230 # Input might be given as Windows format, start by converting to 19231 # unix format. 19232 new_path="$path" 19233 19234 windows_path="$new_path" 19235 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19236 unix_path=`$CYGPATH -u "$windows_path"` 19237 new_path="$unix_path" 19238 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19239 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19240 new_path="$unix_path" 19241 fi 19242 19243 19244 # Now try to locate executable using which 19245 new_path=`$WHICH "$new_path" 2> /dev/null` 19246 19247 if test "x$new_path" = x; then 19248 # Oops. Which didn't find the executable. 19249 # The splitting of arguments from the executable at a space might have been incorrect, 19250 # since paths with space are more likely in Windows. Give it another try with the whole 19251 # argument. 19252 path="$complete" 19253 arguments="EOL" 19254 new_path="$path" 19255 19256 windows_path="$new_path" 19257 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19258 unix_path=`$CYGPATH -u "$windows_path"` 19259 new_path="$unix_path" 19260 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19261 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19262 new_path="$unix_path" 19263 fi 19264 19265 19266 new_path=`$WHICH "$new_path" 2> /dev/null` 19267 # bat and cmd files are not always considered executable in MSYS causing which 19268 # to not find them 19269 if test "x$new_path" = x \ 19270 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19271 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19272 new_path="$path" 19273 19274 windows_path="$new_path" 19275 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19276 unix_path=`$CYGPATH -u "$windows_path"` 19277 new_path="$unix_path" 19278 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19279 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19280 new_path="$unix_path" 19281 fi 19282 19283 fi 19284 19285 if test "x$new_path" = x; then 19286 # It's still not found. Now this is an unrecoverable error. 19287 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19288 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19289 has_space=`$ECHO "$complete" | $GREP " "` 19290 if test "x$has_space" != x; then 19291 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19292 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19293 fi 19294 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19295 fi 19296 fi 19297 19298 # Now new_path has a complete unix path to the binary 19299 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19300 # Keep paths in /bin as-is, but remove trailing .exe if any 19301 new_path="${new_path/%.exe/}" 19302 # Do not save /bin paths to all_fixpath_prefixes! 19303 else 19304 # Not in mixed or Windows style, start by that. 19305 new_path=`cmd //c echo $new_path` 19306 19307 input_path="$new_path" 19308 # Check if we need to convert this using DOS-style short mode. If the path 19309 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19310 # take no chances and rewrite it. 19311 # Note: m4 eats our [], so we need to use [ and ] instead. 19312 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19313 if test "x$has_forbidden_chars" != x; then 19314 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19315 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19316 fi 19317 19318 # Output is in $new_path 19319 19320 windows_path="$new_path" 19321 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19322 unix_path=`$CYGPATH -u "$windows_path"` 19323 new_path="$unix_path" 19324 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19325 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19326 new_path="$unix_path" 19327 fi 19328 19329 # remove trailing .exe if any 19330 new_path="${new_path/%.exe/}" 19331 19332 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19333 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19334 fi 19335 19336 else 19337 # We're on a unix platform. Hooray! :) 19338 # First separate the path from the arguments. This will split at the first 19339 # space. 19340 complete="$FOUND_MAKE" 19341 path="${complete%% *}" 19342 tmp="$complete EOL" 19343 arguments="${tmp#* }" 19344 19345 # Cannot rely on the command "which" here since it doesn't always work. 19346 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19347 if test -z "$is_absolute_path"; then 19348 # Path to executable is not absolute. Find it. 19349 IFS_save="$IFS" 19350 IFS=: 19351 for p in $PATH; do 19352 if test -f "$p/$path" && test -x "$p/$path"; then 19353 new_path="$p/$path" 19354 break 19355 fi 19356 done 19357 IFS="$IFS_save" 19358 else 19359 # This is an absolute path, we can use it without further modifications. 19360 new_path="$path" 19361 fi 19362 19363 if test "x$new_path" = x; then 19364 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19365 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19366 has_space=`$ECHO "$complete" | $GREP " "` 19367 if test "x$has_space" != x; then 19368 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19369 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19370 fi 19371 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19372 fi 19373 fi 19374 19375 # Now join together the path and the arguments once again 19376 if test "x$arguments" != xEOL; then 19377 new_complete="$new_path ${arguments% *}" 19378 else 19379 new_complete="$new_path" 19380 fi 19381 19382 if test "x$complete" != "x$new_complete"; then 19383 FOUND_MAKE="$new_complete" 19384 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19385 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19386 fi 19387 fi 19388 19389 fi 19390 fi 19391 fi 19392 fi 19393 19394 fi 19395 PATH=$OLD_PATH 19396 fi 19397 fi 19398 19399 if test "x$FOUND_MAKE" = x; then 19400 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 19401 fi 19402 19403 else 19404 # The variable is set, but is it from the command line or the environment? 19405 19406 # Try to remove the string !MAKE! from our list. 19407 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19408 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19409 # If it failed, the variable was not from the command line. Ignore it, 19410 # but warn the user (except for BASH, which is always set by the calling BASH). 19411 if test "xMAKE" != xBASH; then 19412 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19413 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19414 fi 19415 # Try to locate tool using the code snippet 19416 19417 # Try our hardest to locate a correct version of GNU make 19418 for ac_prog in gmake 19419 do 19420 # Extract the first word of "$ac_prog", so it can be a program name with args. 19421 set dummy $ac_prog; ac_word=$2 19422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19423 $as_echo_n "checking for $ac_word... " >&6; } 19424 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19425 $as_echo_n "(cached) " >&6 19426 else 19427 case $CHECK_GMAKE in 19428 [\\/]* | ?:[\\/]*) 19429 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19430 ;; 19431 *) 19432 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19433 for as_dir in $PATH 19434 do 19435 IFS=$as_save_IFS 19436 test -z "$as_dir" && as_dir=. 19437 for ac_exec_ext in '' $ac_executable_extensions; do 19438 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19439 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19440 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19441 break 2 19442 fi 19443 done 19444 done 19445 IFS=$as_save_IFS 19446 19447 ;; 19448 esac 19449 fi 19450 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19451 if test -n "$CHECK_GMAKE"; then 19452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19453 $as_echo "$CHECK_GMAKE" >&6; } 19454 else 19455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19456 $as_echo "no" >&6; } 19457 fi 19458 19459 19460 test -n "$CHECK_GMAKE" && break 19461 done 19462 19463 19464 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19465 DESCRIPTION="gmake in PATH" 19466 19467 # On Cygwin, we require a newer version of make than on other platforms 19468 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19469 MAKE_VERSION_EXPR="-e 4\." 19470 MAKE_REQUIRED_VERSION="4.0" 19471 else 19472 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19473 MAKE_REQUIRED_VERSION="3.81" 19474 fi 19475 19476 if test "x$MAKE_CANDIDATE" != x; then 19477 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19478 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19479 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19480 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19481 if test "x$IS_GNU_MAKE" = x; then 19482 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19483 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19484 else 19485 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19486 if test "x$IS_MODERN_MAKE" = x; then 19487 { $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 19488 $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;} 19489 else 19490 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19491 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19492 MAKE_EXPECTED_ENV='cygwin' 19493 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19494 MAKE_EXPECTED_ENV='msys' 19495 else 19496 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19497 fi 19498 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19499 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19500 else 19501 # Not relevant for non-Windows 19502 IS_MAKE_CORRECT_ENV=true 19503 fi 19504 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19505 { $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 19506 $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;} 19507 else 19508 FOUND_MAKE=$MAKE_CANDIDATE 19509 19510 # Only process if variable expands to non-empty 19511 19512 if test "x$FOUND_MAKE" != x; then 19513 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19514 19515 # First separate the path from the arguments. This will split at the first 19516 # space. 19517 complete="$FOUND_MAKE" 19518 path="${complete%% *}" 19519 tmp="$complete EOL" 19520 arguments="${tmp#* }" 19521 19522 # Input might be given as Windows format, start by converting to 19523 # unix format. 19524 new_path=`$CYGPATH -u "$path"` 19525 19526 # Now try to locate executable using which 19527 new_path=`$WHICH "$new_path" 2> /dev/null` 19528 # bat and cmd files are not always considered executable in cygwin causing which 19529 # to not find them 19530 if test "x$new_path" = x \ 19531 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19532 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19533 new_path=`$CYGPATH -u "$path"` 19534 fi 19535 if test "x$new_path" = x; then 19536 # Oops. Which didn't find the executable. 19537 # The splitting of arguments from the executable at a space might have been incorrect, 19538 # since paths with space are more likely in Windows. Give it another try with the whole 19539 # argument. 19540 path="$complete" 19541 arguments="EOL" 19542 new_path=`$CYGPATH -u "$path"` 19543 new_path=`$WHICH "$new_path" 2> /dev/null` 19544 # bat and cmd files are not always considered executable in cygwin causing which 19545 # to not find them 19546 if test "x$new_path" = x \ 19547 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19548 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19549 new_path=`$CYGPATH -u "$path"` 19550 fi 19551 if test "x$new_path" = x; then 19552 # It's still not found. Now this is an unrecoverable error. 19553 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19554 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19555 has_space=`$ECHO "$complete" | $GREP " "` 19556 if test "x$has_space" != x; then 19557 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19558 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19559 fi 19560 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19561 fi 19562 fi 19563 19564 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19565 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19566 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19567 # "foo.exe" is OK but "foo" is an error. 19568 # 19569 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19570 # It is also a way to make sure we got the proper file name for the real test later on. 19571 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19572 if test "x$test_shortpath" = x; then 19573 # Short path failed, file does not exist as specified. 19574 # Try adding .exe or .cmd 19575 if test -f "${new_path}.exe"; then 19576 input_to_shortpath="${new_path}.exe" 19577 elif test -f "${new_path}.cmd"; then 19578 input_to_shortpath="${new_path}.cmd" 19579 else 19580 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19581 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19582 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19583 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19584 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19585 fi 19586 else 19587 input_to_shortpath="$new_path" 19588 fi 19589 19590 # Call helper function which possibly converts this using DOS-style short mode. 19591 # If so, the updated path is stored in $new_path. 19592 new_path="$input_to_shortpath" 19593 19594 input_path="$input_to_shortpath" 19595 # Check if we need to convert this using DOS-style short mode. If the path 19596 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19597 # take no chances and rewrite it. 19598 # Note: m4 eats our [], so we need to use [ and ] instead. 19599 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19600 if test "x$has_forbidden_chars" != x; then 19601 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19602 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19603 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19604 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19605 # Going to short mode and back again did indeed matter. Since short mode is 19606 # case insensitive, let's make it lowercase to improve readability. 19607 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19608 # Now convert it back to Unix-style (cygpath) 19609 input_path=`$CYGPATH -u "$shortmode_path"` 19610 new_path="$input_path" 19611 fi 19612 fi 19613 19614 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19615 if test "x$test_cygdrive_prefix" = x; then 19616 # As a simple fix, exclude /usr/bin since it's not a real path. 19617 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19618 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19619 # a path prefixed by /cygdrive for fixpath to work. 19620 new_path="$CYGWIN_ROOT_PATH$input_path" 19621 fi 19622 fi 19623 19624 # remove trailing .exe if any 19625 new_path="${new_path/%.exe/}" 19626 19627 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19628 19629 # First separate the path from the arguments. This will split at the first 19630 # space. 19631 complete="$FOUND_MAKE" 19632 path="${complete%% *}" 19633 tmp="$complete EOL" 19634 arguments="${tmp#* }" 19635 19636 # Input might be given as Windows format, start by converting to 19637 # unix format. 19638 new_path="$path" 19639 19640 windows_path="$new_path" 19641 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19642 unix_path=`$CYGPATH -u "$windows_path"` 19643 new_path="$unix_path" 19644 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19645 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19646 new_path="$unix_path" 19647 fi 19648 19649 19650 # Now try to locate executable using which 19651 new_path=`$WHICH "$new_path" 2> /dev/null` 19652 19653 if test "x$new_path" = x; then 19654 # Oops. Which didn't find the executable. 19655 # The splitting of arguments from the executable at a space might have been incorrect, 19656 # since paths with space are more likely in Windows. Give it another try with the whole 19657 # argument. 19658 path="$complete" 19659 arguments="EOL" 19660 new_path="$path" 19661 19662 windows_path="$new_path" 19663 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19664 unix_path=`$CYGPATH -u "$windows_path"` 19665 new_path="$unix_path" 19666 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19667 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19668 new_path="$unix_path" 19669 fi 19670 19671 19672 new_path=`$WHICH "$new_path" 2> /dev/null` 19673 # bat and cmd files are not always considered executable in MSYS causing which 19674 # to not find them 19675 if test "x$new_path" = x \ 19676 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19677 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19678 new_path="$path" 19679 19680 windows_path="$new_path" 19681 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19682 unix_path=`$CYGPATH -u "$windows_path"` 19683 new_path="$unix_path" 19684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19685 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19686 new_path="$unix_path" 19687 fi 19688 19689 fi 19690 19691 if test "x$new_path" = x; then 19692 # It's still not found. Now this is an unrecoverable error. 19693 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19694 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19695 has_space=`$ECHO "$complete" | $GREP " "` 19696 if test "x$has_space" != x; then 19697 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19698 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19699 fi 19700 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19701 fi 19702 fi 19703 19704 # Now new_path has a complete unix path to the binary 19705 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19706 # Keep paths in /bin as-is, but remove trailing .exe if any 19707 new_path="${new_path/%.exe/}" 19708 # Do not save /bin paths to all_fixpath_prefixes! 19709 else 19710 # Not in mixed or Windows style, start by that. 19711 new_path=`cmd //c echo $new_path` 19712 19713 input_path="$new_path" 19714 # Check if we need to convert this using DOS-style short mode. If the path 19715 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19716 # take no chances and rewrite it. 19717 # Note: m4 eats our [], so we need to use [ and ] instead. 19718 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19719 if test "x$has_forbidden_chars" != x; then 19720 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19721 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19722 fi 19723 19724 # Output is in $new_path 19725 19726 windows_path="$new_path" 19727 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19728 unix_path=`$CYGPATH -u "$windows_path"` 19729 new_path="$unix_path" 19730 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19731 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19732 new_path="$unix_path" 19733 fi 19734 19735 # remove trailing .exe if any 19736 new_path="${new_path/%.exe/}" 19737 19738 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19739 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19740 fi 19741 19742 else 19743 # We're on a unix platform. Hooray! :) 19744 # First separate the path from the arguments. This will split at the first 19745 # space. 19746 complete="$FOUND_MAKE" 19747 path="${complete%% *}" 19748 tmp="$complete EOL" 19749 arguments="${tmp#* }" 19750 19751 # Cannot rely on the command "which" here since it doesn't always work. 19752 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19753 if test -z "$is_absolute_path"; then 19754 # Path to executable is not absolute. Find it. 19755 IFS_save="$IFS" 19756 IFS=: 19757 for p in $PATH; do 19758 if test -f "$p/$path" && test -x "$p/$path"; then 19759 new_path="$p/$path" 19760 break 19761 fi 19762 done 19763 IFS="$IFS_save" 19764 else 19765 # This is an absolute path, we can use it without further modifications. 19766 new_path="$path" 19767 fi 19768 19769 if test "x$new_path" = x; then 19770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19771 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19772 has_space=`$ECHO "$complete" | $GREP " "` 19773 if test "x$has_space" != x; then 19774 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19775 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19776 fi 19777 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19778 fi 19779 fi 19780 19781 # Now join together the path and the arguments once again 19782 if test "x$arguments" != xEOL; then 19783 new_complete="$new_path ${arguments% *}" 19784 else 19785 new_complete="$new_path" 19786 fi 19787 19788 if test "x$complete" != "x$new_complete"; then 19789 FOUND_MAKE="$new_complete" 19790 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19791 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19792 fi 19793 fi 19794 19795 fi 19796 fi 19797 fi 19798 fi 19799 19800 19801 if test "x$FOUND_MAKE" = x; then 19802 for ac_prog in make 19803 do 19804 # Extract the first word of "$ac_prog", so it can be a program name with args. 19805 set dummy $ac_prog; ac_word=$2 19806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19807 $as_echo_n "checking for $ac_word... " >&6; } 19808 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19809 $as_echo_n "(cached) " >&6 19810 else 19811 case $CHECK_MAKE in 19812 [\\/]* | ?:[\\/]*) 19813 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19814 ;; 19815 *) 19816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19817 for as_dir in $PATH 19818 do 19819 IFS=$as_save_IFS 19820 test -z "$as_dir" && as_dir=. 19821 for ac_exec_ext in '' $ac_executable_extensions; do 19822 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19823 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19824 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19825 break 2 19826 fi 19827 done 19828 done 19829 IFS=$as_save_IFS 19830 19831 ;; 19832 esac 19833 fi 19834 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19835 if test -n "$CHECK_MAKE"; then 19836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19837 $as_echo "$CHECK_MAKE" >&6; } 19838 else 19839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19840 $as_echo "no" >&6; } 19841 fi 19842 19843 19844 test -n "$CHECK_MAKE" && break 19845 done 19846 19847 19848 MAKE_CANDIDATE=""$CHECK_MAKE"" 19849 DESCRIPTION="make in PATH" 19850 19851 # On Cygwin, we require a newer version of make than on other platforms 19852 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19853 MAKE_VERSION_EXPR="-e 4\." 19854 MAKE_REQUIRED_VERSION="4.0" 19855 else 19856 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19857 MAKE_REQUIRED_VERSION="3.81" 19858 fi 19859 19860 if test "x$MAKE_CANDIDATE" != x; then 19861 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19862 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19863 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19864 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19865 if test "x$IS_GNU_MAKE" = x; then 19866 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19867 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19868 else 19869 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19870 if test "x$IS_MODERN_MAKE" = x; then 19871 { $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 19872 $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;} 19873 else 19874 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19875 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19876 MAKE_EXPECTED_ENV='cygwin' 19877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19878 MAKE_EXPECTED_ENV='msys' 19879 else 19880 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19881 fi 19882 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19883 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19884 else 19885 # Not relevant for non-Windows 19886 IS_MAKE_CORRECT_ENV=true 19887 fi 19888 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19889 { $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 19890 $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;} 19891 else 19892 FOUND_MAKE=$MAKE_CANDIDATE 19893 19894 # Only process if variable expands to non-empty 19895 19896 if test "x$FOUND_MAKE" != x; then 19897 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19898 19899 # First separate the path from the arguments. This will split at the first 19900 # space. 19901 complete="$FOUND_MAKE" 19902 path="${complete%% *}" 19903 tmp="$complete EOL" 19904 arguments="${tmp#* }" 19905 19906 # Input might be given as Windows format, start by converting to 19907 # unix format. 19908 new_path=`$CYGPATH -u "$path"` 19909 19910 # Now try to locate executable using which 19911 new_path=`$WHICH "$new_path" 2> /dev/null` 19912 # bat and cmd files are not always considered executable in cygwin causing which 19913 # to not find them 19914 if test "x$new_path" = x \ 19915 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19916 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19917 new_path=`$CYGPATH -u "$path"` 19918 fi 19919 if test "x$new_path" = x; then 19920 # Oops. Which didn't find the executable. 19921 # The splitting of arguments from the executable at a space might have been incorrect, 19922 # since paths with space are more likely in Windows. Give it another try with the whole 19923 # argument. 19924 path="$complete" 19925 arguments="EOL" 19926 new_path=`$CYGPATH -u "$path"` 19927 new_path=`$WHICH "$new_path" 2> /dev/null` 19928 # bat and cmd files are not always considered executable in cygwin causing which 19929 # to not find them 19930 if test "x$new_path" = x \ 19931 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19932 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19933 new_path=`$CYGPATH -u "$path"` 19934 fi 19935 if test "x$new_path" = x; then 19936 # It's still not found. Now this is an unrecoverable error. 19937 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19938 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19939 has_space=`$ECHO "$complete" | $GREP " "` 19940 if test "x$has_space" != x; then 19941 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19942 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19943 fi 19944 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19945 fi 19946 fi 19947 19948 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19949 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19950 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19951 # "foo.exe" is OK but "foo" is an error. 19952 # 19953 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19954 # It is also a way to make sure we got the proper file name for the real test later on. 19955 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19956 if test "x$test_shortpath" = x; then 19957 # Short path failed, file does not exist as specified. 19958 # Try adding .exe or .cmd 19959 if test -f "${new_path}.exe"; then 19960 input_to_shortpath="${new_path}.exe" 19961 elif test -f "${new_path}.cmd"; then 19962 input_to_shortpath="${new_path}.cmd" 19963 else 19964 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19965 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19966 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19967 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19968 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19969 fi 19970 else 19971 input_to_shortpath="$new_path" 19972 fi 19973 19974 # Call helper function which possibly converts this using DOS-style short mode. 19975 # If so, the updated path is stored in $new_path. 19976 new_path="$input_to_shortpath" 19977 19978 input_path="$input_to_shortpath" 19979 # Check if we need to convert this using DOS-style short mode. If the path 19980 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19981 # take no chances and rewrite it. 19982 # Note: m4 eats our [], so we need to use [ and ] instead. 19983 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19984 if test "x$has_forbidden_chars" != x; then 19985 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19986 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19987 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19988 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19989 # Going to short mode and back again did indeed matter. Since short mode is 19990 # case insensitive, let's make it lowercase to improve readability. 19991 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19992 # Now convert it back to Unix-style (cygpath) 19993 input_path=`$CYGPATH -u "$shortmode_path"` 19994 new_path="$input_path" 19995 fi 19996 fi 19997 19998 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19999 if test "x$test_cygdrive_prefix" = x; then 20000 # As a simple fix, exclude /usr/bin since it's not a real path. 20001 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20002 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20003 # a path prefixed by /cygdrive for fixpath to work. 20004 new_path="$CYGWIN_ROOT_PATH$input_path" 20005 fi 20006 fi 20007 20008 # remove trailing .exe if any 20009 new_path="${new_path/%.exe/}" 20010 20011 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20012 20013 # First separate the path from the arguments. This will split at the first 20014 # space. 20015 complete="$FOUND_MAKE" 20016 path="${complete%% *}" 20017 tmp="$complete EOL" 20018 arguments="${tmp#* }" 20019 20020 # Input might be given as Windows format, start by converting to 20021 # unix format. 20022 new_path="$path" 20023 20024 windows_path="$new_path" 20025 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20026 unix_path=`$CYGPATH -u "$windows_path"` 20027 new_path="$unix_path" 20028 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20029 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20030 new_path="$unix_path" 20031 fi 20032 20033 20034 # Now try to locate executable using which 20035 new_path=`$WHICH "$new_path" 2> /dev/null` 20036 20037 if test "x$new_path" = x; then 20038 # Oops. Which didn't find the executable. 20039 # The splitting of arguments from the executable at a space might have been incorrect, 20040 # since paths with space are more likely in Windows. Give it another try with the whole 20041 # argument. 20042 path="$complete" 20043 arguments="EOL" 20044 new_path="$path" 20045 20046 windows_path="$new_path" 20047 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20048 unix_path=`$CYGPATH -u "$windows_path"` 20049 new_path="$unix_path" 20050 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20051 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20052 new_path="$unix_path" 20053 fi 20054 20055 20056 new_path=`$WHICH "$new_path" 2> /dev/null` 20057 # bat and cmd files are not always considered executable in MSYS causing which 20058 # to not find them 20059 if test "x$new_path" = x \ 20060 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20061 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20062 new_path="$path" 20063 20064 windows_path="$new_path" 20065 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20066 unix_path=`$CYGPATH -u "$windows_path"` 20067 new_path="$unix_path" 20068 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20069 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20070 new_path="$unix_path" 20071 fi 20072 20073 fi 20074 20075 if test "x$new_path" = x; then 20076 # It's still not found. Now this is an unrecoverable error. 20077 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20078 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20079 has_space=`$ECHO "$complete" | $GREP " "` 20080 if test "x$has_space" != x; then 20081 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20082 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20083 fi 20084 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20085 fi 20086 fi 20087 20088 # Now new_path has a complete unix path to the binary 20089 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20090 # Keep paths in /bin as-is, but remove trailing .exe if any 20091 new_path="${new_path/%.exe/}" 20092 # Do not save /bin paths to all_fixpath_prefixes! 20093 else 20094 # Not in mixed or Windows style, start by that. 20095 new_path=`cmd //c echo $new_path` 20096 20097 input_path="$new_path" 20098 # Check if we need to convert this using DOS-style short mode. If the path 20099 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20100 # take no chances and rewrite it. 20101 # Note: m4 eats our [], so we need to use [ and ] instead. 20102 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20103 if test "x$has_forbidden_chars" != x; then 20104 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20105 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20106 fi 20107 20108 # Output is in $new_path 20109 20110 windows_path="$new_path" 20111 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20112 unix_path=`$CYGPATH -u "$windows_path"` 20113 new_path="$unix_path" 20114 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20115 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20116 new_path="$unix_path" 20117 fi 20118 20119 # remove trailing .exe if any 20120 new_path="${new_path/%.exe/}" 20121 20122 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20123 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20124 fi 20125 20126 else 20127 # We're on a unix platform. Hooray! :) 20128 # First separate the path from the arguments. This will split at the first 20129 # space. 20130 complete="$FOUND_MAKE" 20131 path="${complete%% *}" 20132 tmp="$complete EOL" 20133 arguments="${tmp#* }" 20134 20135 # Cannot rely on the command "which" here since it doesn't always work. 20136 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20137 if test -z "$is_absolute_path"; then 20138 # Path to executable is not absolute. Find it. 20139 IFS_save="$IFS" 20140 IFS=: 20141 for p in $PATH; do 20142 if test -f "$p/$path" && test -x "$p/$path"; then 20143 new_path="$p/$path" 20144 break 20145 fi 20146 done 20147 IFS="$IFS_save" 20148 else 20149 # This is an absolute path, we can use it without further modifications. 20150 new_path="$path" 20151 fi 20152 20153 if test "x$new_path" = x; then 20154 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20155 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20156 has_space=`$ECHO "$complete" | $GREP " "` 20157 if test "x$has_space" != x; then 20158 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20159 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20160 fi 20161 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20162 fi 20163 fi 20164 20165 # Now join together the path and the arguments once again 20166 if test "x$arguments" != xEOL; then 20167 new_complete="$new_path ${arguments% *}" 20168 else 20169 new_complete="$new_path" 20170 fi 20171 20172 if test "x$complete" != "x$new_complete"; then 20173 FOUND_MAKE="$new_complete" 20174 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20175 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20176 fi 20177 fi 20178 20179 fi 20180 fi 20181 fi 20182 fi 20183 20184 fi 20185 20186 if test "x$FOUND_MAKE" = x; then 20187 if test "x$TOOLCHAIN_PATH" != x; then 20188 # We have a toolchain path, check that as well before giving up. 20189 OLD_PATH=$PATH 20190 PATH=$TOOLCHAIN_PATH:$PATH 20191 for ac_prog in gmake 20192 do 20193 # Extract the first word of "$ac_prog", so it can be a program name with args. 20194 set dummy $ac_prog; ac_word=$2 20195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20196 $as_echo_n "checking for $ac_word... " >&6; } 20197 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 20198 $as_echo_n "(cached) " >&6 20199 else 20200 case $CHECK_TOOLSDIR_GMAKE in 20201 [\\/]* | ?:[\\/]*) 20202 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 20203 ;; 20204 *) 20205 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20206 for as_dir in $PATH 20207 do 20208 IFS=$as_save_IFS 20209 test -z "$as_dir" && as_dir=. 20210 for ac_exec_ext in '' $ac_executable_extensions; do 20211 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20212 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 20213 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20214 break 2 20215 fi 20216 done 20217 done 20218 IFS=$as_save_IFS 20219 20220 ;; 20221 esac 20222 fi 20223 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 20224 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 20225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 20226 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 20227 else 20228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20229 $as_echo "no" >&6; } 20230 fi 20231 20232 20233 test -n "$CHECK_TOOLSDIR_GMAKE" && break 20234 done 20235 20236 20237 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 20238 DESCRIPTION="gmake in tools-dir" 20239 20240 # On Cygwin, we require a newer version of make than on other platforms 20241 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20242 MAKE_VERSION_EXPR="-e 4\." 20243 MAKE_REQUIRED_VERSION="4.0" 20244 else 20245 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20246 MAKE_REQUIRED_VERSION="3.81" 20247 fi 20248 20249 if test "x$MAKE_CANDIDATE" != x; then 20250 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20251 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20252 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20253 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20254 if test "x$IS_GNU_MAKE" = x; then 20255 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20256 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20257 else 20258 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20259 if test "x$IS_MODERN_MAKE" = x; then 20260 { $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 20261 $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;} 20262 else 20263 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20264 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20265 MAKE_EXPECTED_ENV='cygwin' 20266 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20267 MAKE_EXPECTED_ENV='msys' 20268 else 20269 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20270 fi 20271 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20272 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20273 else 20274 # Not relevant for non-Windows 20275 IS_MAKE_CORRECT_ENV=true 20276 fi 20277 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20278 { $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 20279 $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;} 20280 else 20281 FOUND_MAKE=$MAKE_CANDIDATE 20282 20283 # Only process if variable expands to non-empty 20284 20285 if test "x$FOUND_MAKE" != x; then 20286 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20287 20288 # First separate the path from the arguments. This will split at the first 20289 # space. 20290 complete="$FOUND_MAKE" 20291 path="${complete%% *}" 20292 tmp="$complete EOL" 20293 arguments="${tmp#* }" 20294 20295 # Input might be given as Windows format, start by converting to 20296 # unix format. 20297 new_path=`$CYGPATH -u "$path"` 20298 20299 # Now try to locate executable using which 20300 new_path=`$WHICH "$new_path" 2> /dev/null` 20301 # bat and cmd files are not always considered executable in cygwin causing which 20302 # to not find them 20303 if test "x$new_path" = x \ 20304 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20305 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20306 new_path=`$CYGPATH -u "$path"` 20307 fi 20308 if test "x$new_path" = x; then 20309 # Oops. Which didn't find the executable. 20310 # The splitting of arguments from the executable at a space might have been incorrect, 20311 # since paths with space are more likely in Windows. Give it another try with the whole 20312 # argument. 20313 path="$complete" 20314 arguments="EOL" 20315 new_path=`$CYGPATH -u "$path"` 20316 new_path=`$WHICH "$new_path" 2> /dev/null` 20317 # bat and cmd files are not always considered executable in cygwin causing which 20318 # to not find them 20319 if test "x$new_path" = x \ 20320 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20321 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20322 new_path=`$CYGPATH -u "$path"` 20323 fi 20324 if test "x$new_path" = x; then 20325 # It's still not found. Now this is an unrecoverable error. 20326 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20327 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20328 has_space=`$ECHO "$complete" | $GREP " "` 20329 if test "x$has_space" != x; then 20330 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20331 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20332 fi 20333 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20334 fi 20335 fi 20336 20337 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20338 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20339 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20340 # "foo.exe" is OK but "foo" is an error. 20341 # 20342 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20343 # It is also a way to make sure we got the proper file name for the real test later on. 20344 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20345 if test "x$test_shortpath" = x; then 20346 # Short path failed, file does not exist as specified. 20347 # Try adding .exe or .cmd 20348 if test -f "${new_path}.exe"; then 20349 input_to_shortpath="${new_path}.exe" 20350 elif test -f "${new_path}.cmd"; then 20351 input_to_shortpath="${new_path}.cmd" 20352 else 20353 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20354 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20355 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20356 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20357 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20358 fi 20359 else 20360 input_to_shortpath="$new_path" 20361 fi 20362 20363 # Call helper function which possibly converts this using DOS-style short mode. 20364 # If so, the updated path is stored in $new_path. 20365 new_path="$input_to_shortpath" 20366 20367 input_path="$input_to_shortpath" 20368 # Check if we need to convert this using DOS-style short mode. If the path 20369 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20370 # take no chances and rewrite it. 20371 # Note: m4 eats our [], so we need to use [ and ] instead. 20372 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20373 if test "x$has_forbidden_chars" != x; then 20374 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20375 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20376 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20377 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20378 # Going to short mode and back again did indeed matter. Since short mode is 20379 # case insensitive, let's make it lowercase to improve readability. 20380 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20381 # Now convert it back to Unix-style (cygpath) 20382 input_path=`$CYGPATH -u "$shortmode_path"` 20383 new_path="$input_path" 20384 fi 20385 fi 20386 20387 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20388 if test "x$test_cygdrive_prefix" = x; then 20389 # As a simple fix, exclude /usr/bin since it's not a real path. 20390 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20391 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20392 # a path prefixed by /cygdrive for fixpath to work. 20393 new_path="$CYGWIN_ROOT_PATH$input_path" 20394 fi 20395 fi 20396 20397 # remove trailing .exe if any 20398 new_path="${new_path/%.exe/}" 20399 20400 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20401 20402 # First separate the path from the arguments. This will split at the first 20403 # space. 20404 complete="$FOUND_MAKE" 20405 path="${complete%% *}" 20406 tmp="$complete EOL" 20407 arguments="${tmp#* }" 20408 20409 # Input might be given as Windows format, start by converting to 20410 # unix format. 20411 new_path="$path" 20412 20413 windows_path="$new_path" 20414 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20415 unix_path=`$CYGPATH -u "$windows_path"` 20416 new_path="$unix_path" 20417 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20418 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20419 new_path="$unix_path" 20420 fi 20421 20422 20423 # Now try to locate executable using which 20424 new_path=`$WHICH "$new_path" 2> /dev/null` 20425 20426 if test "x$new_path" = x; then 20427 # Oops. Which didn't find the executable. 20428 # The splitting of arguments from the executable at a space might have been incorrect, 20429 # since paths with space are more likely in Windows. Give it another try with the whole 20430 # argument. 20431 path="$complete" 20432 arguments="EOL" 20433 new_path="$path" 20434 20435 windows_path="$new_path" 20436 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20437 unix_path=`$CYGPATH -u "$windows_path"` 20438 new_path="$unix_path" 20439 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20440 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20441 new_path="$unix_path" 20442 fi 20443 20444 20445 new_path=`$WHICH "$new_path" 2> /dev/null` 20446 # bat and cmd files are not always considered executable in MSYS causing which 20447 # to not find them 20448 if test "x$new_path" = x \ 20449 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20450 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20451 new_path="$path" 20452 20453 windows_path="$new_path" 20454 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20455 unix_path=`$CYGPATH -u "$windows_path"` 20456 new_path="$unix_path" 20457 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20458 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20459 new_path="$unix_path" 20460 fi 20461 20462 fi 20463 20464 if test "x$new_path" = x; then 20465 # It's still not found. Now this is an unrecoverable error. 20466 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20467 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20468 has_space=`$ECHO "$complete" | $GREP " "` 20469 if test "x$has_space" != x; then 20470 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20471 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20472 fi 20473 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20474 fi 20475 fi 20476 20477 # Now new_path has a complete unix path to the binary 20478 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20479 # Keep paths in /bin as-is, but remove trailing .exe if any 20480 new_path="${new_path/%.exe/}" 20481 # Do not save /bin paths to all_fixpath_prefixes! 20482 else 20483 # Not in mixed or Windows style, start by that. 20484 new_path=`cmd //c echo $new_path` 20485 20486 input_path="$new_path" 20487 # Check if we need to convert this using DOS-style short mode. If the path 20488 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20489 # take no chances and rewrite it. 20490 # Note: m4 eats our [], so we need to use [ and ] instead. 20491 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20492 if test "x$has_forbidden_chars" != x; then 20493 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20494 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20495 fi 20496 20497 # Output is in $new_path 20498 20499 windows_path="$new_path" 20500 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20501 unix_path=`$CYGPATH -u "$windows_path"` 20502 new_path="$unix_path" 20503 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20504 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20505 new_path="$unix_path" 20506 fi 20507 20508 # remove trailing .exe if any 20509 new_path="${new_path/%.exe/}" 20510 20511 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20512 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20513 fi 20514 20515 else 20516 # We're on a unix platform. Hooray! :) 20517 # First separate the path from the arguments. This will split at the first 20518 # space. 20519 complete="$FOUND_MAKE" 20520 path="${complete%% *}" 20521 tmp="$complete EOL" 20522 arguments="${tmp#* }" 20523 20524 # Cannot rely on the command "which" here since it doesn't always work. 20525 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20526 if test -z "$is_absolute_path"; then 20527 # Path to executable is not absolute. Find it. 20528 IFS_save="$IFS" 20529 IFS=: 20530 for p in $PATH; do 20531 if test -f "$p/$path" && test -x "$p/$path"; then 20532 new_path="$p/$path" 20533 break 20534 fi 20535 done 20536 IFS="$IFS_save" 20537 else 20538 # This is an absolute path, we can use it without further modifications. 20539 new_path="$path" 20540 fi 20541 20542 if test "x$new_path" = x; then 20543 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20544 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20545 has_space=`$ECHO "$complete" | $GREP " "` 20546 if test "x$has_space" != x; then 20547 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20548 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20549 fi 20550 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20551 fi 20552 fi 20553 20554 # Now join together the path and the arguments once again 20555 if test "x$arguments" != xEOL; then 20556 new_complete="$new_path ${arguments% *}" 20557 else 20558 new_complete="$new_path" 20559 fi 20560 20561 if test "x$complete" != "x$new_complete"; then 20562 FOUND_MAKE="$new_complete" 20563 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20564 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20565 fi 20566 fi 20567 20568 fi 20569 fi 20570 fi 20571 fi 20572 20573 if test "x$FOUND_MAKE" = x; then 20574 for ac_prog in make 20575 do 20576 # Extract the first word of "$ac_prog", so it can be a program name with args. 20577 set dummy $ac_prog; ac_word=$2 20578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20579 $as_echo_n "checking for $ac_word... " >&6; } 20580 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20581 $as_echo_n "(cached) " >&6 20582 else 20583 case $CHECK_TOOLSDIR_MAKE in 20584 [\\/]* | ?:[\\/]*) 20585 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20586 ;; 20587 *) 20588 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20589 for as_dir in $PATH 20590 do 20591 IFS=$as_save_IFS 20592 test -z "$as_dir" && as_dir=. 20593 for ac_exec_ext in '' $ac_executable_extensions; do 20594 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20595 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20596 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20597 break 2 20598 fi 20599 done 20600 done 20601 IFS=$as_save_IFS 20602 20603 ;; 20604 esac 20605 fi 20606 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20607 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20609 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20610 else 20611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20612 $as_echo "no" >&6; } 20613 fi 20614 20615 20616 test -n "$CHECK_TOOLSDIR_MAKE" && break 20617 done 20618 20619 20620 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20621 DESCRIPTION="make in tools-dir" 20622 20623 # On Cygwin, we require a newer version of make than on other platforms 20624 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20625 MAKE_VERSION_EXPR="-e 4\." 20626 MAKE_REQUIRED_VERSION="4.0" 20627 else 20628 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20629 MAKE_REQUIRED_VERSION="3.81" 20630 fi 20631 20632 if test "x$MAKE_CANDIDATE" != x; then 20633 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20634 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20635 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20636 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20637 if test "x$IS_GNU_MAKE" = x; then 20638 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20639 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20640 else 20641 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20642 if test "x$IS_MODERN_MAKE" = x; then 20643 { $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 20644 $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;} 20645 else 20646 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20647 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20648 MAKE_EXPECTED_ENV='cygwin' 20649 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20650 MAKE_EXPECTED_ENV='msys' 20651 else 20652 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20653 fi 20654 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20655 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20656 else 20657 # Not relevant for non-Windows 20658 IS_MAKE_CORRECT_ENV=true 20659 fi 20660 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20661 { $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 20662 $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;} 20663 else 20664 FOUND_MAKE=$MAKE_CANDIDATE 20665 20666 # Only process if variable expands to non-empty 20667 20668 if test "x$FOUND_MAKE" != x; then 20669 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20670 20671 # First separate the path from the arguments. This will split at the first 20672 # space. 20673 complete="$FOUND_MAKE" 20674 path="${complete%% *}" 20675 tmp="$complete EOL" 20676 arguments="${tmp#* }" 20677 20678 # Input might be given as Windows format, start by converting to 20679 # unix format. 20680 new_path=`$CYGPATH -u "$path"` 20681 20682 # Now try to locate executable using which 20683 new_path=`$WHICH "$new_path" 2> /dev/null` 20684 # bat and cmd files are not always considered executable in cygwin causing which 20685 # to not find them 20686 if test "x$new_path" = x \ 20687 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20688 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20689 new_path=`$CYGPATH -u "$path"` 20690 fi 20691 if test "x$new_path" = x; then 20692 # Oops. Which didn't find the executable. 20693 # The splitting of arguments from the executable at a space might have been incorrect, 20694 # since paths with space are more likely in Windows. Give it another try with the whole 20695 # argument. 20696 path="$complete" 20697 arguments="EOL" 20698 new_path=`$CYGPATH -u "$path"` 20699 new_path=`$WHICH "$new_path" 2> /dev/null` 20700 # bat and cmd files are not always considered executable in cygwin causing which 20701 # to not find them 20702 if test "x$new_path" = x \ 20703 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20704 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20705 new_path=`$CYGPATH -u "$path"` 20706 fi 20707 if test "x$new_path" = x; then 20708 # It's still not found. Now this is an unrecoverable error. 20709 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20710 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20711 has_space=`$ECHO "$complete" | $GREP " "` 20712 if test "x$has_space" != x; then 20713 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20714 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20715 fi 20716 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20717 fi 20718 fi 20719 20720 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20721 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20722 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20723 # "foo.exe" is OK but "foo" is an error. 20724 # 20725 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20726 # It is also a way to make sure we got the proper file name for the real test later on. 20727 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20728 if test "x$test_shortpath" = x; then 20729 # Short path failed, file does not exist as specified. 20730 # Try adding .exe or .cmd 20731 if test -f "${new_path}.exe"; then 20732 input_to_shortpath="${new_path}.exe" 20733 elif test -f "${new_path}.cmd"; then 20734 input_to_shortpath="${new_path}.cmd" 20735 else 20736 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20737 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20738 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20739 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20740 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20741 fi 20742 else 20743 input_to_shortpath="$new_path" 20744 fi 20745 20746 # Call helper function which possibly converts this using DOS-style short mode. 20747 # If so, the updated path is stored in $new_path. 20748 new_path="$input_to_shortpath" 20749 20750 input_path="$input_to_shortpath" 20751 # Check if we need to convert this using DOS-style short mode. If the path 20752 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20753 # take no chances and rewrite it. 20754 # Note: m4 eats our [], so we need to use [ and ] instead. 20755 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20756 if test "x$has_forbidden_chars" != x; then 20757 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20758 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20759 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20760 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20761 # Going to short mode and back again did indeed matter. Since short mode is 20762 # case insensitive, let's make it lowercase to improve readability. 20763 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20764 # Now convert it back to Unix-style (cygpath) 20765 input_path=`$CYGPATH -u "$shortmode_path"` 20766 new_path="$input_path" 20767 fi 20768 fi 20769 20770 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20771 if test "x$test_cygdrive_prefix" = x; then 20772 # As a simple fix, exclude /usr/bin since it's not a real path. 20773 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20774 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20775 # a path prefixed by /cygdrive for fixpath to work. 20776 new_path="$CYGWIN_ROOT_PATH$input_path" 20777 fi 20778 fi 20779 20780 # remove trailing .exe if any 20781 new_path="${new_path/%.exe/}" 20782 20783 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20784 20785 # First separate the path from the arguments. This will split at the first 20786 # space. 20787 complete="$FOUND_MAKE" 20788 path="${complete%% *}" 20789 tmp="$complete EOL" 20790 arguments="${tmp#* }" 20791 20792 # Input might be given as Windows format, start by converting to 20793 # unix format. 20794 new_path="$path" 20795 20796 windows_path="$new_path" 20797 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20798 unix_path=`$CYGPATH -u "$windows_path"` 20799 new_path="$unix_path" 20800 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20801 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20802 new_path="$unix_path" 20803 fi 20804 20805 20806 # Now try to locate executable using which 20807 new_path=`$WHICH "$new_path" 2> /dev/null` 20808 20809 if test "x$new_path" = x; then 20810 # Oops. Which didn't find the executable. 20811 # The splitting of arguments from the executable at a space might have been incorrect, 20812 # since paths with space are more likely in Windows. Give it another try with the whole 20813 # argument. 20814 path="$complete" 20815 arguments="EOL" 20816 new_path="$path" 20817 20818 windows_path="$new_path" 20819 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20820 unix_path=`$CYGPATH -u "$windows_path"` 20821 new_path="$unix_path" 20822 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20823 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20824 new_path="$unix_path" 20825 fi 20826 20827 20828 new_path=`$WHICH "$new_path" 2> /dev/null` 20829 # bat and cmd files are not always considered executable in MSYS causing which 20830 # to not find them 20831 if test "x$new_path" = x \ 20832 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20833 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20834 new_path="$path" 20835 20836 windows_path="$new_path" 20837 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20838 unix_path=`$CYGPATH -u "$windows_path"` 20839 new_path="$unix_path" 20840 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20841 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20842 new_path="$unix_path" 20843 fi 20844 20845 fi 20846 20847 if test "x$new_path" = x; then 20848 # It's still not found. Now this is an unrecoverable error. 20849 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20850 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20851 has_space=`$ECHO "$complete" | $GREP " "` 20852 if test "x$has_space" != x; then 20853 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20854 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20855 fi 20856 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20857 fi 20858 fi 20859 20860 # Now new_path has a complete unix path to the binary 20861 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20862 # Keep paths in /bin as-is, but remove trailing .exe if any 20863 new_path="${new_path/%.exe/}" 20864 # Do not save /bin paths to all_fixpath_prefixes! 20865 else 20866 # Not in mixed or Windows style, start by that. 20867 new_path=`cmd //c echo $new_path` 20868 20869 input_path="$new_path" 20870 # Check if we need to convert this using DOS-style short mode. If the path 20871 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20872 # take no chances and rewrite it. 20873 # Note: m4 eats our [], so we need to use [ and ] instead. 20874 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20875 if test "x$has_forbidden_chars" != x; then 20876 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20877 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20878 fi 20879 20880 # Output is in $new_path 20881 20882 windows_path="$new_path" 20883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20884 unix_path=`$CYGPATH -u "$windows_path"` 20885 new_path="$unix_path" 20886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20887 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20888 new_path="$unix_path" 20889 fi 20890 20891 # remove trailing .exe if any 20892 new_path="${new_path/%.exe/}" 20893 20894 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20895 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20896 fi 20897 20898 else 20899 # We're on a unix platform. Hooray! :) 20900 # First separate the path from the arguments. This will split at the first 20901 # space. 20902 complete="$FOUND_MAKE" 20903 path="${complete%% *}" 20904 tmp="$complete EOL" 20905 arguments="${tmp#* }" 20906 20907 # Cannot rely on the command "which" here since it doesn't always work. 20908 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20909 if test -z "$is_absolute_path"; then 20910 # Path to executable is not absolute. Find it. 20911 IFS_save="$IFS" 20912 IFS=: 20913 for p in $PATH; do 20914 if test -f "$p/$path" && test -x "$p/$path"; then 20915 new_path="$p/$path" 20916 break 20917 fi 20918 done 20919 IFS="$IFS_save" 20920 else 20921 # This is an absolute path, we can use it without further modifications. 20922 new_path="$path" 20923 fi 20924 20925 if test "x$new_path" = x; then 20926 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20927 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20928 has_space=`$ECHO "$complete" | $GREP " "` 20929 if test "x$has_space" != x; then 20930 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20931 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20932 fi 20933 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20934 fi 20935 fi 20936 20937 # Now join together the path and the arguments once again 20938 if test "x$arguments" != xEOL; then 20939 new_complete="$new_path ${arguments% *}" 20940 else 20941 new_complete="$new_path" 20942 fi 20943 20944 if test "x$complete" != "x$new_complete"; then 20945 FOUND_MAKE="$new_complete" 20946 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20947 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20948 fi 20949 fi 20950 20951 fi 20952 fi 20953 fi 20954 fi 20955 20956 fi 20957 PATH=$OLD_PATH 20958 fi 20959 fi 20960 20961 if test "x$FOUND_MAKE" = x; then 20962 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 20963 fi 20964 20965 else 20966 # If it succeeded, then it was overridden by the user. We will use it 20967 # for the tool. 20968 20969 # First remove it from the list of overridden variables, so we can test 20970 # for unknown variables in the end. 20971 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20972 20973 # Check if we try to supply an empty value 20974 if test "x$MAKE" = x; then 20975 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20976 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20978 $as_echo_n "checking for MAKE... " >&6; } 20979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20980 $as_echo "disabled" >&6; } 20981 else 20982 # Check if the provided tool contains a complete path. 20983 tool_specified="$MAKE" 20984 tool_basename="${tool_specified##*/}" 20985 if test "x$tool_basename" = "x$tool_specified"; then 20986 # A command without a complete path is provided, search $PATH. 20987 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20988 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20989 # Extract the first word of "$tool_basename", so it can be a program name with args. 20990 set dummy $tool_basename; ac_word=$2 20991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20992 $as_echo_n "checking for $ac_word... " >&6; } 20993 if ${ac_cv_path_MAKE+:} false; then : 20994 $as_echo_n "(cached) " >&6 20995 else 20996 case $MAKE in 20997 [\\/]* | ?:[\\/]*) 20998 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 20999 ;; 21000 *) 21001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21002 for as_dir in $PATH 21003 do 21004 IFS=$as_save_IFS 21005 test -z "$as_dir" && as_dir=. 21006 for ac_exec_ext in '' $ac_executable_extensions; do 21007 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21008 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 21009 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21010 break 2 21011 fi 21012 done 21013 done 21014 IFS=$as_save_IFS 21015 21016 ;; 21017 esac 21018 fi 21019 MAKE=$ac_cv_path_MAKE 21020 if test -n "$MAKE"; then 21021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 21022 $as_echo "$MAKE" >&6; } 21023 else 21024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21025 $as_echo "no" >&6; } 21026 fi 21027 21028 21029 if test "x$MAKE" = x; then 21030 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21031 fi 21032 else 21033 # Otherwise we believe it is a complete path. Use it as it is. 21034 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 21035 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 21036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 21037 $as_echo_n "checking for MAKE... " >&6; } 21038 if test ! -x "$tool_specified"; then 21039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21040 $as_echo "not found" >&6; } 21041 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 21042 fi 21043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21044 $as_echo "$tool_specified" >&6; } 21045 fi 21046 fi 21047 fi 21048 21049 # If MAKE was set by user, verify the version 21050 21051 MAKE_CANDIDATE=""$MAKE"" 21052 DESCRIPTION="user supplied MAKE=$MAKE" 21053 21054 # On Cygwin, we require a newer version of make than on other platforms 21055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21056 MAKE_VERSION_EXPR="-e 4\." 21057 MAKE_REQUIRED_VERSION="4.0" 21058 else 21059 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 21060 MAKE_REQUIRED_VERSION="3.81" 21061 fi 21062 21063 if test "x$MAKE_CANDIDATE" != x; then 21064 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 21065 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 21066 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 21067 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 21068 if test "x$IS_GNU_MAKE" = x; then 21069 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 21070 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 21071 else 21072 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 21073 if test "x$IS_MODERN_MAKE" = x; then 21074 { $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 21075 $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;} 21076 else 21077 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 21078 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21079 MAKE_EXPECTED_ENV='cygwin' 21080 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21081 MAKE_EXPECTED_ENV='msys' 21082 else 21083 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 21084 fi 21085 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 21086 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 21087 else 21088 # Not relevant for non-Windows 21089 IS_MAKE_CORRECT_ENV=true 21090 fi 21091 if test "x$IS_MAKE_CORRECT_ENV" = x; then 21092 { $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 21093 $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;} 21094 else 21095 FOUND_MAKE=$MAKE_CANDIDATE 21096 21097 # Only process if variable expands to non-empty 21098 21099 if test "x$FOUND_MAKE" != x; then 21100 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21101 21102 # First separate the path from the arguments. This will split at the first 21103 # space. 21104 complete="$FOUND_MAKE" 21105 path="${complete%% *}" 21106 tmp="$complete EOL" 21107 arguments="${tmp#* }" 21108 21109 # Input might be given as Windows format, start by converting to 21110 # unix format. 21111 new_path=`$CYGPATH -u "$path"` 21112 21113 # Now try to locate executable using which 21114 new_path=`$WHICH "$new_path" 2> /dev/null` 21115 # bat and cmd files are not always considered executable in cygwin causing which 21116 # to not find them 21117 if test "x$new_path" = x \ 21118 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21119 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21120 new_path=`$CYGPATH -u "$path"` 21121 fi 21122 if test "x$new_path" = x; then 21123 # Oops. Which didn't find the executable. 21124 # The splitting of arguments from the executable at a space might have been incorrect, 21125 # since paths with space are more likely in Windows. Give it another try with the whole 21126 # argument. 21127 path="$complete" 21128 arguments="EOL" 21129 new_path=`$CYGPATH -u "$path"` 21130 new_path=`$WHICH "$new_path" 2> /dev/null` 21131 # bat and cmd files are not always considered executable in cygwin causing which 21132 # to not find them 21133 if test "x$new_path" = x \ 21134 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21135 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21136 new_path=`$CYGPATH -u "$path"` 21137 fi 21138 if test "x$new_path" = x; then 21139 # It's still not found. Now this is an unrecoverable error. 21140 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21141 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21142 has_space=`$ECHO "$complete" | $GREP " "` 21143 if test "x$has_space" != x; then 21144 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21145 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21146 fi 21147 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21148 fi 21149 fi 21150 21151 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21152 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21153 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21154 # "foo.exe" is OK but "foo" is an error. 21155 # 21156 # This test is therefore slightly more accurate than "test -f" to check for file presence. 21157 # It is also a way to make sure we got the proper file name for the real test later on. 21158 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21159 if test "x$test_shortpath" = x; then 21160 # Short path failed, file does not exist as specified. 21161 # Try adding .exe or .cmd 21162 if test -f "${new_path}.exe"; then 21163 input_to_shortpath="${new_path}.exe" 21164 elif test -f "${new_path}.cmd"; then 21165 input_to_shortpath="${new_path}.cmd" 21166 else 21167 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 21168 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 21169 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21170 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21171 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21172 fi 21173 else 21174 input_to_shortpath="$new_path" 21175 fi 21176 21177 # Call helper function which possibly converts this using DOS-style short mode. 21178 # If so, the updated path is stored in $new_path. 21179 new_path="$input_to_shortpath" 21180 21181 input_path="$input_to_shortpath" 21182 # Check if we need to convert this using DOS-style short mode. If the path 21183 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21184 # take no chances and rewrite it. 21185 # Note: m4 eats our [], so we need to use [ and ] instead. 21186 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21187 if test "x$has_forbidden_chars" != x; then 21188 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21189 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21190 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21191 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21192 # Going to short mode and back again did indeed matter. Since short mode is 21193 # case insensitive, let's make it lowercase to improve readability. 21194 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21195 # Now convert it back to Unix-style (cygpath) 21196 input_path=`$CYGPATH -u "$shortmode_path"` 21197 new_path="$input_path" 21198 fi 21199 fi 21200 21201 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21202 if test "x$test_cygdrive_prefix" = x; then 21203 # As a simple fix, exclude /usr/bin since it's not a real path. 21204 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21205 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21206 # a path prefixed by /cygdrive for fixpath to work. 21207 new_path="$CYGWIN_ROOT_PATH$input_path" 21208 fi 21209 fi 21210 21211 # remove trailing .exe if any 21212 new_path="${new_path/%.exe/}" 21213 21214 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21215 21216 # First separate the path from the arguments. This will split at the first 21217 # space. 21218 complete="$FOUND_MAKE" 21219 path="${complete%% *}" 21220 tmp="$complete EOL" 21221 arguments="${tmp#* }" 21222 21223 # Input might be given as Windows format, start by converting to 21224 # unix format. 21225 new_path="$path" 21226 21227 windows_path="$new_path" 21228 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21229 unix_path=`$CYGPATH -u "$windows_path"` 21230 new_path="$unix_path" 21231 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21232 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21233 new_path="$unix_path" 21234 fi 21235 21236 21237 # Now try to locate executable using which 21238 new_path=`$WHICH "$new_path" 2> /dev/null` 21239 21240 if test "x$new_path" = x; then 21241 # Oops. Which didn't find the executable. 21242 # The splitting of arguments from the executable at a space might have been incorrect, 21243 # since paths with space are more likely in Windows. Give it another try with the whole 21244 # argument. 21245 path="$complete" 21246 arguments="EOL" 21247 new_path="$path" 21248 21249 windows_path="$new_path" 21250 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21251 unix_path=`$CYGPATH -u "$windows_path"` 21252 new_path="$unix_path" 21253 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21254 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21255 new_path="$unix_path" 21256 fi 21257 21258 21259 new_path=`$WHICH "$new_path" 2> /dev/null` 21260 # bat and cmd files are not always considered executable in MSYS causing which 21261 # to not find them 21262 if test "x$new_path" = x \ 21263 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21264 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21265 new_path="$path" 21266 21267 windows_path="$new_path" 21268 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21269 unix_path=`$CYGPATH -u "$windows_path"` 21270 new_path="$unix_path" 21271 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21272 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21273 new_path="$unix_path" 21274 fi 21275 21276 fi 21277 21278 if test "x$new_path" = x; then 21279 # It's still not found. Now this is an unrecoverable error. 21280 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21281 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21282 has_space=`$ECHO "$complete" | $GREP " "` 21283 if test "x$has_space" != x; then 21284 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21285 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21286 fi 21287 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21288 fi 21289 fi 21290 21291 # Now new_path has a complete unix path to the binary 21292 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21293 # Keep paths in /bin as-is, but remove trailing .exe if any 21294 new_path="${new_path/%.exe/}" 21295 # Do not save /bin paths to all_fixpath_prefixes! 21296 else 21297 # Not in mixed or Windows style, start by that. 21298 new_path=`cmd //c echo $new_path` 21299 21300 input_path="$new_path" 21301 # Check if we need to convert this using DOS-style short mode. If the path 21302 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21303 # take no chances and rewrite it. 21304 # Note: m4 eats our [], so we need to use [ and ] instead. 21305 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21306 if test "x$has_forbidden_chars" != x; then 21307 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21308 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21309 fi 21310 21311 # Output is in $new_path 21312 21313 windows_path="$new_path" 21314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21315 unix_path=`$CYGPATH -u "$windows_path"` 21316 new_path="$unix_path" 21317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21319 new_path="$unix_path" 21320 fi 21321 21322 # remove trailing .exe if any 21323 new_path="${new_path/%.exe/}" 21324 21325 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21326 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21327 fi 21328 21329 else 21330 # We're on a unix platform. Hooray! :) 21331 # First separate the path from the arguments. This will split at the first 21332 # space. 21333 complete="$FOUND_MAKE" 21334 path="${complete%% *}" 21335 tmp="$complete EOL" 21336 arguments="${tmp#* }" 21337 21338 # Cannot rely on the command "which" here since it doesn't always work. 21339 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21340 if test -z "$is_absolute_path"; then 21341 # Path to executable is not absolute. Find it. 21342 IFS_save="$IFS" 21343 IFS=: 21344 for p in $PATH; do 21345 if test -f "$p/$path" && test -x "$p/$path"; then 21346 new_path="$p/$path" 21347 break 21348 fi 21349 done 21350 IFS="$IFS_save" 21351 else 21352 # This is an absolute path, we can use it without further modifications. 21353 new_path="$path" 21354 fi 21355 21356 if test "x$new_path" = x; then 21357 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21358 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21359 has_space=`$ECHO "$complete" | $GREP " "` 21360 if test "x$has_space" != x; then 21361 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21362 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21363 fi 21364 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21365 fi 21366 fi 21367 21368 # Now join together the path and the arguments once again 21369 if test "x$arguments" != xEOL; then 21370 new_complete="$new_path ${arguments% *}" 21371 else 21372 new_complete="$new_path" 21373 fi 21374 21375 if test "x$complete" != "x$new_complete"; then 21376 FOUND_MAKE="$new_complete" 21377 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21378 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21379 fi 21380 fi 21381 21382 fi 21383 fi 21384 fi 21385 fi 21386 21387 if test "x$FOUND_MAKE" = x; then 21388 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21389 fi 21390 21391 fi 21392 21393 21394 MAKE=$FOUND_MAKE 21395 21396 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21397 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21398 21399 21400 # Check if make supports the output sync option and if so, setup using it. 21401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21402 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21403 if $MAKE --version -O > /dev/null 2>&1; then 21404 OUTPUT_SYNC_SUPPORTED=true 21405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21406 $as_echo "yes" >&6; } 21407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21408 $as_echo_n "checking for output-sync value... " >&6; } 21409 21410 # Check whether --with-output-sync was given. 21411 if test "${with_output_sync+set}" = set; then : 21412 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21413 fi 21414 21415 if test "x$OUTPUT_SYNC" = "x"; then 21416 OUTPUT_SYNC=none 21417 fi 21418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21419 $as_echo "$OUTPUT_SYNC" >&6; } 21420 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21421 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21422 fi 21423 else 21424 OUTPUT_SYNC_SUPPORTED=false 21425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21426 $as_echo "no" >&6; } 21427 fi 21428 21429 21430 21431 21432 21433 21434 # Test if find supports -delete 21435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21436 $as_echo_n "checking if find supports -delete... " >&6; } 21437 FIND_DELETE="-delete" 21438 21439 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21440 21441 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21442 21443 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21444 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21445 # No, it does not. 21446 $RM $DELETEDIR/TestIfFindSupportsDelete 21447 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21448 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21449 FIND_DELETE="-print | $XARGS $RM" 21450 else 21451 FIND_DELETE="-exec $RM \{\} \+" 21452 fi 21453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21454 $as_echo "no" >&6; } 21455 else 21456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21457 $as_echo "yes" >&6; } 21458 fi 21459 $RMDIR $DELETEDIR 21460 21461 21462 21463 # Test which kind of tar was found 21464 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21465 TAR_TYPE="gnu" 21466 elif test "x$($TAR --version | $GREP "bsdtar")" != "x"; then 21467 TAR_TYPE="bsd" 21468 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21469 TAR_TYPE="bsd" 21470 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21471 TAR_TYPE="solaris" 21472 fi 21473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21474 $as_echo_n "checking what type of tar was found... " >&6; } 21475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21476 $as_echo "$TAR_TYPE" >&6; } 21477 21478 TAR_CREATE_FILE_PARAM="" 21479 21480 if test "x$TAR_TYPE" = "xgnu"; then 21481 TAR_INCLUDE_PARAM="T" 21482 TAR_SUPPORTS_TRANSFORM="true" 21483 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21484 # When using gnu tar for Solaris targets, need to use compatibility mode 21485 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21486 fi 21487 else 21488 TAR_INCLUDE_PARAM="I" 21489 TAR_SUPPORTS_TRANSFORM="false" 21490 fi 21491 21492 21493 21494 21495 21496 21497 # Test that grep supports -Fx with a list of pattern which includes null pattern. 21498 # This is a problem for the grep resident on AIX. 21499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly" >&5 21500 $as_echo_n "checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly... " >&6; } 21501 # Multiple subsequent spaces.. 21502 STACK_SPACES='aaa bbb ccc' 21503 # ..converted to subsequent newlines, causes STACK_LIST to be a list with some empty 21504 # patterns in it. 21505 STACK_LIST=${STACK_SPACES// /$'\n'} 21506 NEEDLE_SPACES='ccc bbb aaa' 21507 NEEDLE_LIST=${NEEDLE_SPACES// /$'\n'} 21508 RESULT="$($GREP -Fvx "$STACK_LIST" <<< "$NEEDLE_LIST")" 21509 if test "x$RESULT" == "x"; then 21510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21511 $as_echo "yes" >&6; } 21512 else 21513 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21514 ADDINFO="Please make sure you use GNU grep, usually found at /opt/freeware/bin." 21515 fi 21516 as_fn_error $? "grep does not handle -Fx correctly. ${ADDINFO}" "$LINENO" 5 21517 fi 21518 21519 21520 # These tools might not be installed by default, 21521 # need hint on how to install them. 21522 21523 21524 21525 # Publish this variable in the help. 21526 21527 21528 if [ -z "${UNZIP+x}" ]; then 21529 # The variable is not set by user, try to locate tool using the code snippet 21530 for ac_prog in unzip 21531 do 21532 # Extract the first word of "$ac_prog", so it can be a program name with args. 21533 set dummy $ac_prog; ac_word=$2 21534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21535 $as_echo_n "checking for $ac_word... " >&6; } 21536 if ${ac_cv_path_UNZIP+:} false; then : 21537 $as_echo_n "(cached) " >&6 21538 else 21539 case $UNZIP in 21540 [\\/]* | ?:[\\/]*) 21541 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21542 ;; 21543 *) 21544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21545 for as_dir in $PATH 21546 do 21547 IFS=$as_save_IFS 21548 test -z "$as_dir" && as_dir=. 21549 for ac_exec_ext in '' $ac_executable_extensions; do 21550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21551 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21553 break 2 21554 fi 21555 done 21556 done 21557 IFS=$as_save_IFS 21558 21559 ;; 21560 esac 21561 fi 21562 UNZIP=$ac_cv_path_UNZIP 21563 if test -n "$UNZIP"; then 21564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21565 $as_echo "$UNZIP" >&6; } 21566 else 21567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21568 $as_echo "no" >&6; } 21569 fi 21570 21571 21572 test -n "$UNZIP" && break 21573 done 21574 21575 else 21576 # The variable is set, but is it from the command line or the environment? 21577 21578 # Try to remove the string !UNZIP! from our list. 21579 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21580 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21581 # If it failed, the variable was not from the command line. Ignore it, 21582 # but warn the user (except for BASH, which is always set by the calling BASH). 21583 if test "xUNZIP" != xBASH; then 21584 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21585 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21586 fi 21587 # Try to locate tool using the code snippet 21588 for ac_prog in unzip 21589 do 21590 # Extract the first word of "$ac_prog", so it can be a program name with args. 21591 set dummy $ac_prog; ac_word=$2 21592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21593 $as_echo_n "checking for $ac_word... " >&6; } 21594 if ${ac_cv_path_UNZIP+:} false; then : 21595 $as_echo_n "(cached) " >&6 21596 else 21597 case $UNZIP in 21598 [\\/]* | ?:[\\/]*) 21599 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21600 ;; 21601 *) 21602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21603 for as_dir in $PATH 21604 do 21605 IFS=$as_save_IFS 21606 test -z "$as_dir" && as_dir=. 21607 for ac_exec_ext in '' $ac_executable_extensions; do 21608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21609 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21611 break 2 21612 fi 21613 done 21614 done 21615 IFS=$as_save_IFS 21616 21617 ;; 21618 esac 21619 fi 21620 UNZIP=$ac_cv_path_UNZIP 21621 if test -n "$UNZIP"; then 21622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21623 $as_echo "$UNZIP" >&6; } 21624 else 21625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21626 $as_echo "no" >&6; } 21627 fi 21628 21629 21630 test -n "$UNZIP" && break 21631 done 21632 21633 else 21634 # If it succeeded, then it was overridden by the user. We will use it 21635 # for the tool. 21636 21637 # First remove it from the list of overridden variables, so we can test 21638 # for unknown variables in the end. 21639 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21640 21641 # Check if we try to supply an empty value 21642 if test "x$UNZIP" = x; then 21643 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21644 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21646 $as_echo_n "checking for UNZIP... " >&6; } 21647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21648 $as_echo "disabled" >&6; } 21649 else 21650 # Check if the provided tool contains a complete path. 21651 tool_specified="$UNZIP" 21652 tool_basename="${tool_specified##*/}" 21653 if test "x$tool_basename" = "x$tool_specified"; then 21654 # A command without a complete path is provided, search $PATH. 21655 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21656 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21657 # Extract the first word of "$tool_basename", so it can be a program name with args. 21658 set dummy $tool_basename; ac_word=$2 21659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21660 $as_echo_n "checking for $ac_word... " >&6; } 21661 if ${ac_cv_path_UNZIP+:} false; then : 21662 $as_echo_n "(cached) " >&6 21663 else 21664 case $UNZIP in 21665 [\\/]* | ?:[\\/]*) 21666 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21667 ;; 21668 *) 21669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21670 for as_dir in $PATH 21671 do 21672 IFS=$as_save_IFS 21673 test -z "$as_dir" && as_dir=. 21674 for ac_exec_ext in '' $ac_executable_extensions; do 21675 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21676 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21678 break 2 21679 fi 21680 done 21681 done 21682 IFS=$as_save_IFS 21683 21684 ;; 21685 esac 21686 fi 21687 UNZIP=$ac_cv_path_UNZIP 21688 if test -n "$UNZIP"; then 21689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21690 $as_echo "$UNZIP" >&6; } 21691 else 21692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21693 $as_echo "no" >&6; } 21694 fi 21695 21696 21697 if test "x$UNZIP" = x; then 21698 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21699 fi 21700 else 21701 # Otherwise we believe it is a complete path. Use it as it is. 21702 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21703 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21705 $as_echo_n "checking for UNZIP... " >&6; } 21706 if test ! -x "$tool_specified"; then 21707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21708 $as_echo "not found" >&6; } 21709 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21710 fi 21711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21712 $as_echo "$tool_specified" >&6; } 21713 fi 21714 fi 21715 fi 21716 21717 fi 21718 21719 21720 21721 if test "x$UNZIP" = x; then 21722 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21723 fi 21724 21725 21726 # Since zip uses "ZIP" as a environment variable for passing options, we need 21727 # to name our variable differently, hence ZIPEXE. 21728 21729 21730 21731 # Publish this variable in the help. 21732 21733 21734 if [ -z "${ZIPEXE+x}" ]; then 21735 # The variable is not set by user, try to locate tool using the code snippet 21736 for ac_prog in zip 21737 do 21738 # Extract the first word of "$ac_prog", so it can be a program name with args. 21739 set dummy $ac_prog; ac_word=$2 21740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21741 $as_echo_n "checking for $ac_word... " >&6; } 21742 if ${ac_cv_path_ZIPEXE+:} false; then : 21743 $as_echo_n "(cached) " >&6 21744 else 21745 case $ZIPEXE in 21746 [\\/]* | ?:[\\/]*) 21747 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21748 ;; 21749 *) 21750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21751 for as_dir in $PATH 21752 do 21753 IFS=$as_save_IFS 21754 test -z "$as_dir" && as_dir=. 21755 for ac_exec_ext in '' $ac_executable_extensions; do 21756 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21757 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21758 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21759 break 2 21760 fi 21761 done 21762 done 21763 IFS=$as_save_IFS 21764 21765 ;; 21766 esac 21767 fi 21768 ZIPEXE=$ac_cv_path_ZIPEXE 21769 if test -n "$ZIPEXE"; then 21770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21771 $as_echo "$ZIPEXE" >&6; } 21772 else 21773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21774 $as_echo "no" >&6; } 21775 fi 21776 21777 21778 test -n "$ZIPEXE" && break 21779 done 21780 21781 else 21782 # The variable is set, but is it from the command line or the environment? 21783 21784 # Try to remove the string !ZIPEXE! from our list. 21785 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIPEXE!/} 21786 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21787 # If it failed, the variable was not from the command line. Ignore it, 21788 # but warn the user (except for BASH, which is always set by the calling BASH). 21789 if test "xZIPEXE" != xBASH; then 21790 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&5 21791 $as_echo "$as_me: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&2;} 21792 fi 21793 # Try to locate tool using the code snippet 21794 for ac_prog in zip 21795 do 21796 # Extract the first word of "$ac_prog", so it can be a program name with args. 21797 set dummy $ac_prog; ac_word=$2 21798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21799 $as_echo_n "checking for $ac_word... " >&6; } 21800 if ${ac_cv_path_ZIPEXE+:} false; then : 21801 $as_echo_n "(cached) " >&6 21802 else 21803 case $ZIPEXE in 21804 [\\/]* | ?:[\\/]*) 21805 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21806 ;; 21807 *) 21808 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21809 for as_dir in $PATH 21810 do 21811 IFS=$as_save_IFS 21812 test -z "$as_dir" && as_dir=. 21813 for ac_exec_ext in '' $ac_executable_extensions; do 21814 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21815 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21816 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21817 break 2 21818 fi 21819 done 21820 done 21821 IFS=$as_save_IFS 21822 21823 ;; 21824 esac 21825 fi 21826 ZIPEXE=$ac_cv_path_ZIPEXE 21827 if test -n "$ZIPEXE"; then 21828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21829 $as_echo "$ZIPEXE" >&6; } 21830 else 21831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21832 $as_echo "no" >&6; } 21833 fi 21834 21835 21836 test -n "$ZIPEXE" && break 21837 done 21838 21839 else 21840 # If it succeeded, then it was overridden by the user. We will use it 21841 # for the tool. 21842 21843 # First remove it from the list of overridden variables, so we can test 21844 # for unknown variables in the end. 21845 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21846 21847 # Check if we try to supply an empty value 21848 if test "x$ZIPEXE" = x; then 21849 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIPEXE= (no value)" >&5 21850 $as_echo "$as_me: Setting user supplied tool ZIPEXE= (no value)" >&6;} 21851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21852 $as_echo_n "checking for ZIPEXE... " >&6; } 21853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21854 $as_echo "disabled" >&6; } 21855 else 21856 # Check if the provided tool contains a complete path. 21857 tool_specified="$ZIPEXE" 21858 tool_basename="${tool_specified##*/}" 21859 if test "x$tool_basename" = "x$tool_specified"; then 21860 # A command without a complete path is provided, search $PATH. 21861 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIPEXE=$tool_basename" >&5 21862 $as_echo "$as_me: Will search for user supplied tool ZIPEXE=$tool_basename" >&6;} 21863 # Extract the first word of "$tool_basename", so it can be a program name with args. 21864 set dummy $tool_basename; ac_word=$2 21865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21866 $as_echo_n "checking for $ac_word... " >&6; } 21867 if ${ac_cv_path_ZIPEXE+:} false; then : 21868 $as_echo_n "(cached) " >&6 21869 else 21870 case $ZIPEXE in 21871 [\\/]* | ?:[\\/]*) 21872 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21873 ;; 21874 *) 21875 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21876 for as_dir in $PATH 21877 do 21878 IFS=$as_save_IFS 21879 test -z "$as_dir" && as_dir=. 21880 for ac_exec_ext in '' $ac_executable_extensions; do 21881 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21882 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21883 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21884 break 2 21885 fi 21886 done 21887 done 21888 IFS=$as_save_IFS 21889 21890 ;; 21891 esac 21892 fi 21893 ZIPEXE=$ac_cv_path_ZIPEXE 21894 if test -n "$ZIPEXE"; then 21895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21896 $as_echo "$ZIPEXE" >&6; } 21897 else 21898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21899 $as_echo "no" >&6; } 21900 fi 21901 21902 21903 if test "x$ZIPEXE" = x; then 21904 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21905 fi 21906 else 21907 # Otherwise we believe it is a complete path. Use it as it is. 21908 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIPEXE=$tool_specified" >&5 21909 $as_echo "$as_me: Will use user supplied tool ZIPEXE=$tool_specified" >&6;} 21910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21911 $as_echo_n "checking for ZIPEXE... " >&6; } 21912 if test ! -x "$tool_specified"; then 21913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21914 $as_echo "not found" >&6; } 21915 as_fn_error $? "User supplied tool ZIPEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 21916 fi 21917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21918 $as_echo "$tool_specified" >&6; } 21919 fi 21920 fi 21921 fi 21922 21923 fi 21924 21925 21926 21927 if test "x$ZIPEXE" = x; then 21928 as_fn_error $? "Could not find required tool for ZIPEXE" "$LINENO" 5 21929 fi 21930 21931 21932 21933 # Non-required basic tools 21934 21935 21936 21937 # Publish this variable in the help. 21938 21939 21940 if [ -z "${LDD+x}" ]; then 21941 # The variable is not set by user, try to locate tool using the code snippet 21942 for ac_prog in ldd 21943 do 21944 # Extract the first word of "$ac_prog", so it can be a program name with args. 21945 set dummy $ac_prog; ac_word=$2 21946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21947 $as_echo_n "checking for $ac_word... " >&6; } 21948 if ${ac_cv_path_LDD+:} false; then : 21949 $as_echo_n "(cached) " >&6 21950 else 21951 case $LDD in 21952 [\\/]* | ?:[\\/]*) 21953 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21954 ;; 21955 *) 21956 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21957 for as_dir in $PATH 21958 do 21959 IFS=$as_save_IFS 21960 test -z "$as_dir" && as_dir=. 21961 for ac_exec_ext in '' $ac_executable_extensions; do 21962 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21963 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21964 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21965 break 2 21966 fi 21967 done 21968 done 21969 IFS=$as_save_IFS 21970 21971 ;; 21972 esac 21973 fi 21974 LDD=$ac_cv_path_LDD 21975 if test -n "$LDD"; then 21976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21977 $as_echo "$LDD" >&6; } 21978 else 21979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21980 $as_echo "no" >&6; } 21981 fi 21982 21983 21984 test -n "$LDD" && break 21985 done 21986 21987 else 21988 # The variable is set, but is it from the command line or the environment? 21989 21990 # Try to remove the string !LDD! from our list. 21991 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 21992 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21993 # If it failed, the variable was not from the command line. Ignore it, 21994 # but warn the user (except for BASH, which is always set by the calling BASH). 21995 if test "xLDD" != xBASH; then 21996 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 21997 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 21998 fi 21999 # Try to locate tool using the code snippet 22000 for ac_prog in ldd 22001 do 22002 # Extract the first word of "$ac_prog", so it can be a program name with args. 22003 set dummy $ac_prog; ac_word=$2 22004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22005 $as_echo_n "checking for $ac_word... " >&6; } 22006 if ${ac_cv_path_LDD+:} false; then : 22007 $as_echo_n "(cached) " >&6 22008 else 22009 case $LDD in 22010 [\\/]* | ?:[\\/]*) 22011 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 22012 ;; 22013 *) 22014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22015 for as_dir in $PATH 22016 do 22017 IFS=$as_save_IFS 22018 test -z "$as_dir" && as_dir=. 22019 for ac_exec_ext in '' $ac_executable_extensions; do 22020 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22021 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22023 break 2 22024 fi 22025 done 22026 done 22027 IFS=$as_save_IFS 22028 22029 ;; 22030 esac 22031 fi 22032 LDD=$ac_cv_path_LDD 22033 if test -n "$LDD"; then 22034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22035 $as_echo "$LDD" >&6; } 22036 else 22037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22038 $as_echo "no" >&6; } 22039 fi 22040 22041 22042 test -n "$LDD" && break 22043 done 22044 22045 else 22046 # If it succeeded, then it was overridden by the user. We will use it 22047 # for the tool. 22048 22049 # First remove it from the list of overridden variables, so we can test 22050 # for unknown variables in the end. 22051 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22052 22053 # Check if we try to supply an empty value 22054 if test "x$LDD" = x; then 22055 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 22056 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 22057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22058 $as_echo_n "checking for LDD... " >&6; } 22059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22060 $as_echo "disabled" >&6; } 22061 else 22062 # Check if the provided tool contains a complete path. 22063 tool_specified="$LDD" 22064 tool_basename="${tool_specified##*/}" 22065 if test "x$tool_basename" = "x$tool_specified"; then 22066 # A command without a complete path is provided, search $PATH. 22067 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 22068 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 22069 # Extract the first word of "$tool_basename", so it can be a program name with args. 22070 set dummy $tool_basename; ac_word=$2 22071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22072 $as_echo_n "checking for $ac_word... " >&6; } 22073 if ${ac_cv_path_LDD+:} false; then : 22074 $as_echo_n "(cached) " >&6 22075 else 22076 case $LDD in 22077 [\\/]* | ?:[\\/]*) 22078 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 22079 ;; 22080 *) 22081 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22082 for as_dir in $PATH 22083 do 22084 IFS=$as_save_IFS 22085 test -z "$as_dir" && as_dir=. 22086 for ac_exec_ext in '' $ac_executable_extensions; do 22087 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22088 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22089 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22090 break 2 22091 fi 22092 done 22093 done 22094 IFS=$as_save_IFS 22095 22096 ;; 22097 esac 22098 fi 22099 LDD=$ac_cv_path_LDD 22100 if test -n "$LDD"; then 22101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22102 $as_echo "$LDD" >&6; } 22103 else 22104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22105 $as_echo "no" >&6; } 22106 fi 22107 22108 22109 if test "x$LDD" = x; then 22110 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22111 fi 22112 else 22113 # Otherwise we believe it is a complete path. Use it as it is. 22114 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 22115 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 22116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22117 $as_echo_n "checking for LDD... " >&6; } 22118 if test ! -x "$tool_specified"; then 22119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22120 $as_echo "not found" >&6; } 22121 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 22122 fi 22123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22124 $as_echo "$tool_specified" >&6; } 22125 fi 22126 fi 22127 fi 22128 22129 fi 22130 22131 22132 if test "x$LDD" = "x"; then 22133 # List shared lib dependencies is used for 22134 # debug output and checking for forbidden dependencies. 22135 # We can build without it. 22136 LDD="true" 22137 fi 22138 22139 22140 # Publish this variable in the help. 22141 22142 22143 if [ -z "${OTOOL+x}" ]; then 22144 # The variable is not set by user, try to locate tool using the code snippet 22145 for ac_prog in otool 22146 do 22147 # Extract the first word of "$ac_prog", so it can be a program name with args. 22148 set dummy $ac_prog; ac_word=$2 22149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22150 $as_echo_n "checking for $ac_word... " >&6; } 22151 if ${ac_cv_path_OTOOL+:} false; then : 22152 $as_echo_n "(cached) " >&6 22153 else 22154 case $OTOOL in 22155 [\\/]* | ?:[\\/]*) 22156 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22157 ;; 22158 *) 22159 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22160 for as_dir in $PATH 22161 do 22162 IFS=$as_save_IFS 22163 test -z "$as_dir" && as_dir=. 22164 for ac_exec_ext in '' $ac_executable_extensions; do 22165 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22166 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22167 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22168 break 2 22169 fi 22170 done 22171 done 22172 IFS=$as_save_IFS 22173 22174 ;; 22175 esac 22176 fi 22177 OTOOL=$ac_cv_path_OTOOL 22178 if test -n "$OTOOL"; then 22179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22180 $as_echo "$OTOOL" >&6; } 22181 else 22182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22183 $as_echo "no" >&6; } 22184 fi 22185 22186 22187 test -n "$OTOOL" && break 22188 done 22189 22190 else 22191 # The variable is set, but is it from the command line or the environment? 22192 22193 # Try to remove the string !OTOOL! from our list. 22194 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 22195 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22196 # If it failed, the variable was not from the command line. Ignore it, 22197 # but warn the user (except for BASH, which is always set by the calling BASH). 22198 if test "xOTOOL" != xBASH; then 22199 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 22200 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 22201 fi 22202 # Try to locate tool using the code snippet 22203 for ac_prog in otool 22204 do 22205 # Extract the first word of "$ac_prog", so it can be a program name with args. 22206 set dummy $ac_prog; ac_word=$2 22207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22208 $as_echo_n "checking for $ac_word... " >&6; } 22209 if ${ac_cv_path_OTOOL+:} false; then : 22210 $as_echo_n "(cached) " >&6 22211 else 22212 case $OTOOL in 22213 [\\/]* | ?:[\\/]*) 22214 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22215 ;; 22216 *) 22217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22218 for as_dir in $PATH 22219 do 22220 IFS=$as_save_IFS 22221 test -z "$as_dir" && as_dir=. 22222 for ac_exec_ext in '' $ac_executable_extensions; do 22223 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22224 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22225 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22226 break 2 22227 fi 22228 done 22229 done 22230 IFS=$as_save_IFS 22231 22232 ;; 22233 esac 22234 fi 22235 OTOOL=$ac_cv_path_OTOOL 22236 if test -n "$OTOOL"; then 22237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22238 $as_echo "$OTOOL" >&6; } 22239 else 22240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22241 $as_echo "no" >&6; } 22242 fi 22243 22244 22245 test -n "$OTOOL" && break 22246 done 22247 22248 else 22249 # If it succeeded, then it was overridden by the user. We will use it 22250 # for the tool. 22251 22252 # First remove it from the list of overridden variables, so we can test 22253 # for unknown variables in the end. 22254 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22255 22256 # Check if we try to supply an empty value 22257 if test "x$OTOOL" = x; then 22258 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 22259 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 22260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 22261 $as_echo_n "checking for OTOOL... " >&6; } 22262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22263 $as_echo "disabled" >&6; } 22264 else 22265 # Check if the provided tool contains a complete path. 22266 tool_specified="$OTOOL" 22267 tool_basename="${tool_specified##*/}" 22268 if test "x$tool_basename" = "x$tool_specified"; then 22269 # A command without a complete path is provided, search $PATH. 22270 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 22271 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 22272 # Extract the first word of "$tool_basename", so it can be a program name with args. 22273 set dummy $tool_basename; ac_word=$2 22274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22275 $as_echo_n "checking for $ac_word... " >&6; } 22276 if ${ac_cv_path_OTOOL+:} false; then : 22277 $as_echo_n "(cached) " >&6 22278 else 22279 case $OTOOL in 22280 [\\/]* | ?:[\\/]*) 22281 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22282 ;; 22283 *) 22284 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22285 for as_dir in $PATH 22286 do 22287 IFS=$as_save_IFS 22288 test -z "$as_dir" && as_dir=. 22289 for ac_exec_ext in '' $ac_executable_extensions; do 22290 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22291 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22292 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22293 break 2 22294 fi 22295 done 22296 done 22297 IFS=$as_save_IFS 22298 22299 ;; 22300 esac 22301 fi 22302 OTOOL=$ac_cv_path_OTOOL 22303 if test -n "$OTOOL"; then 22304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22305 $as_echo "$OTOOL" >&6; } 22306 else 22307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22308 $as_echo "no" >&6; } 22309 fi 22310 22311 22312 if test "x$OTOOL" = x; then 22313 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22314 fi 22315 else 22316 # Otherwise we believe it is a complete path. Use it as it is. 22317 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 22318 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 22319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 22320 $as_echo_n "checking for OTOOL... " >&6; } 22321 if test ! -x "$tool_specified"; then 22322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22323 $as_echo "not found" >&6; } 22324 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 22325 fi 22326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22327 $as_echo "$tool_specified" >&6; } 22328 fi 22329 fi 22330 fi 22331 22332 fi 22333 22334 22335 if test "x$OTOOL" = "x"; then 22336 OTOOL="true" 22337 fi 22338 22339 22340 # Publish this variable in the help. 22341 22342 22343 if [ -z "${READELF+x}" ]; then 22344 # The variable is not set by user, try to locate tool using the code snippet 22345 for ac_prog in greadelf readelf 22346 do 22347 # Extract the first word of "$ac_prog", so it can be a program name with args. 22348 set dummy $ac_prog; ac_word=$2 22349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22350 $as_echo_n "checking for $ac_word... " >&6; } 22351 if ${ac_cv_path_READELF+:} false; then : 22352 $as_echo_n "(cached) " >&6 22353 else 22354 case $READELF in 22355 [\\/]* | ?:[\\/]*) 22356 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22357 ;; 22358 *) 22359 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22360 for as_dir in $PATH 22361 do 22362 IFS=$as_save_IFS 22363 test -z "$as_dir" && as_dir=. 22364 for ac_exec_ext in '' $ac_executable_extensions; do 22365 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22366 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22367 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22368 break 2 22369 fi 22370 done 22371 done 22372 IFS=$as_save_IFS 22373 22374 ;; 22375 esac 22376 fi 22377 READELF=$ac_cv_path_READELF 22378 if test -n "$READELF"; then 22379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22380 $as_echo "$READELF" >&6; } 22381 else 22382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22383 $as_echo "no" >&6; } 22384 fi 22385 22386 22387 test -n "$READELF" && break 22388 done 22389 22390 else 22391 # The variable is set, but is it from the command line or the environment? 22392 22393 # Try to remove the string !READELF! from our list. 22394 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22395 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22396 # If it failed, the variable was not from the command line. Ignore it, 22397 # but warn the user (except for BASH, which is always set by the calling BASH). 22398 if test "xREADELF" != xBASH; then 22399 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22400 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22401 fi 22402 # Try to locate tool using the code snippet 22403 for ac_prog in greadelf readelf 22404 do 22405 # Extract the first word of "$ac_prog", so it can be a program name with args. 22406 set dummy $ac_prog; ac_word=$2 22407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22408 $as_echo_n "checking for $ac_word... " >&6; } 22409 if ${ac_cv_path_READELF+:} false; then : 22410 $as_echo_n "(cached) " >&6 22411 else 22412 case $READELF in 22413 [\\/]* | ?:[\\/]*) 22414 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22415 ;; 22416 *) 22417 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22418 for as_dir in $PATH 22419 do 22420 IFS=$as_save_IFS 22421 test -z "$as_dir" && as_dir=. 22422 for ac_exec_ext in '' $ac_executable_extensions; do 22423 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22424 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22425 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22426 break 2 22427 fi 22428 done 22429 done 22430 IFS=$as_save_IFS 22431 22432 ;; 22433 esac 22434 fi 22435 READELF=$ac_cv_path_READELF 22436 if test -n "$READELF"; then 22437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22438 $as_echo "$READELF" >&6; } 22439 else 22440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22441 $as_echo "no" >&6; } 22442 fi 22443 22444 22445 test -n "$READELF" && break 22446 done 22447 22448 else 22449 # If it succeeded, then it was overridden by the user. We will use it 22450 # for the tool. 22451 22452 # First remove it from the list of overridden variables, so we can test 22453 # for unknown variables in the end. 22454 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22455 22456 # Check if we try to supply an empty value 22457 if test "x$READELF" = x; then 22458 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22459 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22461 $as_echo_n "checking for READELF... " >&6; } 22462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22463 $as_echo "disabled" >&6; } 22464 else 22465 # Check if the provided tool contains a complete path. 22466 tool_specified="$READELF" 22467 tool_basename="${tool_specified##*/}" 22468 if test "x$tool_basename" = "x$tool_specified"; then 22469 # A command without a complete path is provided, search $PATH. 22470 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22471 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22472 # Extract the first word of "$tool_basename", so it can be a program name with args. 22473 set dummy $tool_basename; ac_word=$2 22474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22475 $as_echo_n "checking for $ac_word... " >&6; } 22476 if ${ac_cv_path_READELF+:} false; then : 22477 $as_echo_n "(cached) " >&6 22478 else 22479 case $READELF in 22480 [\\/]* | ?:[\\/]*) 22481 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22482 ;; 22483 *) 22484 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22485 for as_dir in $PATH 22486 do 22487 IFS=$as_save_IFS 22488 test -z "$as_dir" && as_dir=. 22489 for ac_exec_ext in '' $ac_executable_extensions; do 22490 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22491 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22492 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22493 break 2 22494 fi 22495 done 22496 done 22497 IFS=$as_save_IFS 22498 22499 ;; 22500 esac 22501 fi 22502 READELF=$ac_cv_path_READELF 22503 if test -n "$READELF"; then 22504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22505 $as_echo "$READELF" >&6; } 22506 else 22507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22508 $as_echo "no" >&6; } 22509 fi 22510 22511 22512 if test "x$READELF" = x; then 22513 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22514 fi 22515 else 22516 # Otherwise we believe it is a complete path. Use it as it is. 22517 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22518 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22520 $as_echo_n "checking for READELF... " >&6; } 22521 if test ! -x "$tool_specified"; then 22522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22523 $as_echo "not found" >&6; } 22524 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22525 fi 22526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22527 $as_echo "$tool_specified" >&6; } 22528 fi 22529 fi 22530 fi 22531 22532 fi 22533 22534 22535 22536 22537 # Publish this variable in the help. 22538 22539 22540 if [ -z "${DOT+x}" ]; then 22541 # The variable is not set by user, try to locate tool using the code snippet 22542 for ac_prog in dot 22543 do 22544 # Extract the first word of "$ac_prog", so it can be a program name with args. 22545 set dummy $ac_prog; ac_word=$2 22546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22547 $as_echo_n "checking for $ac_word... " >&6; } 22548 if ${ac_cv_path_DOT+:} false; then : 22549 $as_echo_n "(cached) " >&6 22550 else 22551 case $DOT in 22552 [\\/]* | ?:[\\/]*) 22553 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22554 ;; 22555 *) 22556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22557 for as_dir in $PATH 22558 do 22559 IFS=$as_save_IFS 22560 test -z "$as_dir" && as_dir=. 22561 for ac_exec_ext in '' $ac_executable_extensions; do 22562 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22563 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22565 break 2 22566 fi 22567 done 22568 done 22569 IFS=$as_save_IFS 22570 22571 ;; 22572 esac 22573 fi 22574 DOT=$ac_cv_path_DOT 22575 if test -n "$DOT"; then 22576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22577 $as_echo "$DOT" >&6; } 22578 else 22579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22580 $as_echo "no" >&6; } 22581 fi 22582 22583 22584 test -n "$DOT" && break 22585 done 22586 22587 else 22588 # The variable is set, but is it from the command line or the environment? 22589 22590 # Try to remove the string !DOT! from our list. 22591 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DOT!/} 22592 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22593 # If it failed, the variable was not from the command line. Ignore it, 22594 # but warn the user (except for BASH, which is always set by the calling BASH). 22595 if test "xDOT" != xBASH; then 22596 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&5 22597 $as_echo "$as_me: WARNING: Ignoring value of DOT from the environment. Use command line variables instead." >&2;} 22598 fi 22599 # Try to locate tool using the code snippet 22600 for ac_prog in dot 22601 do 22602 # Extract the first word of "$ac_prog", so it can be a program name with args. 22603 set dummy $ac_prog; ac_word=$2 22604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22605 $as_echo_n "checking for $ac_word... " >&6; } 22606 if ${ac_cv_path_DOT+:} false; then : 22607 $as_echo_n "(cached) " >&6 22608 else 22609 case $DOT in 22610 [\\/]* | ?:[\\/]*) 22611 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22612 ;; 22613 *) 22614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22615 for as_dir in $PATH 22616 do 22617 IFS=$as_save_IFS 22618 test -z "$as_dir" && as_dir=. 22619 for ac_exec_ext in '' $ac_executable_extensions; do 22620 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22621 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22622 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22623 break 2 22624 fi 22625 done 22626 done 22627 IFS=$as_save_IFS 22628 22629 ;; 22630 esac 22631 fi 22632 DOT=$ac_cv_path_DOT 22633 if test -n "$DOT"; then 22634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22635 $as_echo "$DOT" >&6; } 22636 else 22637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22638 $as_echo "no" >&6; } 22639 fi 22640 22641 22642 test -n "$DOT" && break 22643 done 22644 22645 else 22646 # If it succeeded, then it was overridden by the user. We will use it 22647 # for the tool. 22648 22649 # First remove it from the list of overridden variables, so we can test 22650 # for unknown variables in the end. 22651 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22652 22653 # Check if we try to supply an empty value 22654 if test "x$DOT" = x; then 22655 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DOT= (no value)" >&5 22656 $as_echo "$as_me: Setting user supplied tool DOT= (no value)" >&6;} 22657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 22658 $as_echo_n "checking for DOT... " >&6; } 22659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22660 $as_echo "disabled" >&6; } 22661 else 22662 # Check if the provided tool contains a complete path. 22663 tool_specified="$DOT" 22664 tool_basename="${tool_specified##*/}" 22665 if test "x$tool_basename" = "x$tool_specified"; then 22666 # A command without a complete path is provided, search $PATH. 22667 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DOT=$tool_basename" >&5 22668 $as_echo "$as_me: Will search for user supplied tool DOT=$tool_basename" >&6;} 22669 # Extract the first word of "$tool_basename", so it can be a program name with args. 22670 set dummy $tool_basename; ac_word=$2 22671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22672 $as_echo_n "checking for $ac_word... " >&6; } 22673 if ${ac_cv_path_DOT+:} false; then : 22674 $as_echo_n "(cached) " >&6 22675 else 22676 case $DOT in 22677 [\\/]* | ?:[\\/]*) 22678 ac_cv_path_DOT="$DOT" # Let the user override the test with a path. 22679 ;; 22680 *) 22681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22682 for as_dir in $PATH 22683 do 22684 IFS=$as_save_IFS 22685 test -z "$as_dir" && as_dir=. 22686 for ac_exec_ext in '' $ac_executable_extensions; do 22687 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22688 ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext" 22689 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22690 break 2 22691 fi 22692 done 22693 done 22694 IFS=$as_save_IFS 22695 22696 ;; 22697 esac 22698 fi 22699 DOT=$ac_cv_path_DOT 22700 if test -n "$DOT"; then 22701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5 22702 $as_echo "$DOT" >&6; } 22703 else 22704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22705 $as_echo "no" >&6; } 22706 fi 22707 22708 22709 if test "x$DOT" = x; then 22710 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22711 fi 22712 else 22713 # Otherwise we believe it is a complete path. Use it as it is. 22714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DOT=$tool_specified" >&5 22715 $as_echo "$as_me: Will use user supplied tool DOT=$tool_specified" >&6;} 22716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DOT" >&5 22717 $as_echo_n "checking for DOT... " >&6; } 22718 if test ! -x "$tool_specified"; then 22719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22720 $as_echo "not found" >&6; } 22721 as_fn_error $? "User supplied tool DOT=$tool_specified does not exist or is not executable" "$LINENO" 5 22722 fi 22723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22724 $as_echo "$tool_specified" >&6; } 22725 fi 22726 fi 22727 fi 22728 22729 fi 22730 22731 22732 22733 22734 # Publish this variable in the help. 22735 22736 22737 if [ -z "${HG+x}" ]; then 22738 # The variable is not set by user, try to locate tool using the code snippet 22739 for ac_prog in hg 22740 do 22741 # Extract the first word of "$ac_prog", so it can be a program name with args. 22742 set dummy $ac_prog; ac_word=$2 22743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22744 $as_echo_n "checking for $ac_word... " >&6; } 22745 if ${ac_cv_path_HG+:} false; then : 22746 $as_echo_n "(cached) " >&6 22747 else 22748 case $HG in 22749 [\\/]* | ?:[\\/]*) 22750 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22751 ;; 22752 *) 22753 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22754 for as_dir in $PATH 22755 do 22756 IFS=$as_save_IFS 22757 test -z "$as_dir" && as_dir=. 22758 for ac_exec_ext in '' $ac_executable_extensions; do 22759 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22760 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22761 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22762 break 2 22763 fi 22764 done 22765 done 22766 IFS=$as_save_IFS 22767 22768 ;; 22769 esac 22770 fi 22771 HG=$ac_cv_path_HG 22772 if test -n "$HG"; then 22773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22774 $as_echo "$HG" >&6; } 22775 else 22776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22777 $as_echo "no" >&6; } 22778 fi 22779 22780 22781 test -n "$HG" && break 22782 done 22783 22784 else 22785 # The variable is set, but is it from the command line or the environment? 22786 22787 # Try to remove the string !HG! from our list. 22788 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22789 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22790 # If it failed, the variable was not from the command line. Ignore it, 22791 # but warn the user (except for BASH, which is always set by the calling BASH). 22792 if test "xHG" != xBASH; then 22793 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22794 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22795 fi 22796 # Try to locate tool using the code snippet 22797 for ac_prog in hg 22798 do 22799 # Extract the first word of "$ac_prog", so it can be a program name with args. 22800 set dummy $ac_prog; ac_word=$2 22801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22802 $as_echo_n "checking for $ac_word... " >&6; } 22803 if ${ac_cv_path_HG+:} false; then : 22804 $as_echo_n "(cached) " >&6 22805 else 22806 case $HG in 22807 [\\/]* | ?:[\\/]*) 22808 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22809 ;; 22810 *) 22811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22812 for as_dir in $PATH 22813 do 22814 IFS=$as_save_IFS 22815 test -z "$as_dir" && as_dir=. 22816 for ac_exec_ext in '' $ac_executable_extensions; do 22817 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22818 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22819 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22820 break 2 22821 fi 22822 done 22823 done 22824 IFS=$as_save_IFS 22825 22826 ;; 22827 esac 22828 fi 22829 HG=$ac_cv_path_HG 22830 if test -n "$HG"; then 22831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22832 $as_echo "$HG" >&6; } 22833 else 22834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22835 $as_echo "no" >&6; } 22836 fi 22837 22838 22839 test -n "$HG" && break 22840 done 22841 22842 else 22843 # If it succeeded, then it was overridden by the user. We will use it 22844 # for the tool. 22845 22846 # First remove it from the list of overridden variables, so we can test 22847 # for unknown variables in the end. 22848 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22849 22850 # Check if we try to supply an empty value 22851 if test "x$HG" = x; then 22852 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22853 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22855 $as_echo_n "checking for HG... " >&6; } 22856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22857 $as_echo "disabled" >&6; } 22858 else 22859 # Check if the provided tool contains a complete path. 22860 tool_specified="$HG" 22861 tool_basename="${tool_specified##*/}" 22862 if test "x$tool_basename" = "x$tool_specified"; then 22863 # A command without a complete path is provided, search $PATH. 22864 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22865 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22866 # Extract the first word of "$tool_basename", so it can be a program name with args. 22867 set dummy $tool_basename; ac_word=$2 22868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22869 $as_echo_n "checking for $ac_word... " >&6; } 22870 if ${ac_cv_path_HG+:} false; then : 22871 $as_echo_n "(cached) " >&6 22872 else 22873 case $HG in 22874 [\\/]* | ?:[\\/]*) 22875 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22876 ;; 22877 *) 22878 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22879 for as_dir in $PATH 22880 do 22881 IFS=$as_save_IFS 22882 test -z "$as_dir" && as_dir=. 22883 for ac_exec_ext in '' $ac_executable_extensions; do 22884 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22885 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22886 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22887 break 2 22888 fi 22889 done 22890 done 22891 IFS=$as_save_IFS 22892 22893 ;; 22894 esac 22895 fi 22896 HG=$ac_cv_path_HG 22897 if test -n "$HG"; then 22898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22899 $as_echo "$HG" >&6; } 22900 else 22901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22902 $as_echo "no" >&6; } 22903 fi 22904 22905 22906 if test "x$HG" = x; then 22907 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22908 fi 22909 else 22910 # Otherwise we believe it is a complete path. Use it as it is. 22911 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22912 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22914 $as_echo_n "checking for HG... " >&6; } 22915 if test ! -x "$tool_specified"; then 22916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22917 $as_echo "not found" >&6; } 22918 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22919 fi 22920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22921 $as_echo "$tool_specified" >&6; } 22922 fi 22923 fi 22924 fi 22925 22926 fi 22927 22928 22929 22930 22931 # Publish this variable in the help. 22932 22933 22934 if [ -z "${STAT+x}" ]; then 22935 # The variable is not set by user, try to locate tool using the code snippet 22936 for ac_prog in stat 22937 do 22938 # Extract the first word of "$ac_prog", so it can be a program name with args. 22939 set dummy $ac_prog; ac_word=$2 22940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22941 $as_echo_n "checking for $ac_word... " >&6; } 22942 if ${ac_cv_path_STAT+:} false; then : 22943 $as_echo_n "(cached) " >&6 22944 else 22945 case $STAT in 22946 [\\/]* | ?:[\\/]*) 22947 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22948 ;; 22949 *) 22950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22951 for as_dir in $PATH 22952 do 22953 IFS=$as_save_IFS 22954 test -z "$as_dir" && as_dir=. 22955 for ac_exec_ext in '' $ac_executable_extensions; do 22956 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22957 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22959 break 2 22960 fi 22961 done 22962 done 22963 IFS=$as_save_IFS 22964 22965 ;; 22966 esac 22967 fi 22968 STAT=$ac_cv_path_STAT 22969 if test -n "$STAT"; then 22970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22971 $as_echo "$STAT" >&6; } 22972 else 22973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22974 $as_echo "no" >&6; } 22975 fi 22976 22977 22978 test -n "$STAT" && break 22979 done 22980 22981 else 22982 # The variable is set, but is it from the command line or the environment? 22983 22984 # Try to remove the string !STAT! from our list. 22985 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22986 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22987 # If it failed, the variable was not from the command line. Ignore it, 22988 # but warn the user (except for BASH, which is always set by the calling BASH). 22989 if test "xSTAT" != xBASH; then 22990 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22991 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22992 fi 22993 # Try to locate tool using the code snippet 22994 for ac_prog in stat 22995 do 22996 # Extract the first word of "$ac_prog", so it can be a program name with args. 22997 set dummy $ac_prog; ac_word=$2 22998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22999 $as_echo_n "checking for $ac_word... " >&6; } 23000 if ${ac_cv_path_STAT+:} false; then : 23001 $as_echo_n "(cached) " >&6 23002 else 23003 case $STAT in 23004 [\\/]* | ?:[\\/]*) 23005 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 23006 ;; 23007 *) 23008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23009 for as_dir in $PATH 23010 do 23011 IFS=$as_save_IFS 23012 test -z "$as_dir" && as_dir=. 23013 for ac_exec_ext in '' $ac_executable_extensions; do 23014 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23015 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 23016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23017 break 2 23018 fi 23019 done 23020 done 23021 IFS=$as_save_IFS 23022 23023 ;; 23024 esac 23025 fi 23026 STAT=$ac_cv_path_STAT 23027 if test -n "$STAT"; then 23028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 23029 $as_echo "$STAT" >&6; } 23030 else 23031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23032 $as_echo "no" >&6; } 23033 fi 23034 23035 23036 test -n "$STAT" && break 23037 done 23038 23039 else 23040 # If it succeeded, then it was overridden by the user. We will use it 23041 # for the tool. 23042 23043 # First remove it from the list of overridden variables, so we can test 23044 # for unknown variables in the end. 23045 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23046 23047 # Check if we try to supply an empty value 23048 if test "x$STAT" = x; then 23049 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 23050 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 23051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 23052 $as_echo_n "checking for STAT... " >&6; } 23053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23054 $as_echo "disabled" >&6; } 23055 else 23056 # Check if the provided tool contains a complete path. 23057 tool_specified="$STAT" 23058 tool_basename="${tool_specified##*/}" 23059 if test "x$tool_basename" = "x$tool_specified"; then 23060 # A command without a complete path is provided, search $PATH. 23061 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 23062 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 23063 # Extract the first word of "$tool_basename", so it can be a program name with args. 23064 set dummy $tool_basename; ac_word=$2 23065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23066 $as_echo_n "checking for $ac_word... " >&6; } 23067 if ${ac_cv_path_STAT+:} false; then : 23068 $as_echo_n "(cached) " >&6 23069 else 23070 case $STAT in 23071 [\\/]* | ?:[\\/]*) 23072 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 23073 ;; 23074 *) 23075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23076 for as_dir in $PATH 23077 do 23078 IFS=$as_save_IFS 23079 test -z "$as_dir" && as_dir=. 23080 for ac_exec_ext in '' $ac_executable_extensions; do 23081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23082 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 23083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23084 break 2 23085 fi 23086 done 23087 done 23088 IFS=$as_save_IFS 23089 23090 ;; 23091 esac 23092 fi 23093 STAT=$ac_cv_path_STAT 23094 if test -n "$STAT"; then 23095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 23096 $as_echo "$STAT" >&6; } 23097 else 23098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23099 $as_echo "no" >&6; } 23100 fi 23101 23102 23103 if test "x$STAT" = x; then 23104 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23105 fi 23106 else 23107 # Otherwise we believe it is a complete path. Use it as it is. 23108 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 23109 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 23110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 23111 $as_echo_n "checking for STAT... " >&6; } 23112 if test ! -x "$tool_specified"; then 23113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23114 $as_echo "not found" >&6; } 23115 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 23116 fi 23117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23118 $as_echo "$tool_specified" >&6; } 23119 fi 23120 fi 23121 fi 23122 23123 fi 23124 23125 23126 23127 23128 # Publish this variable in the help. 23129 23130 23131 if [ -z "${TIME+x}" ]; then 23132 # The variable is not set by user, try to locate tool using the code snippet 23133 for ac_prog in time 23134 do 23135 # Extract the first word of "$ac_prog", so it can be a program name with args. 23136 set dummy $ac_prog; ac_word=$2 23137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23138 $as_echo_n "checking for $ac_word... " >&6; } 23139 if ${ac_cv_path_TIME+:} false; then : 23140 $as_echo_n "(cached) " >&6 23141 else 23142 case $TIME in 23143 [\\/]* | ?:[\\/]*) 23144 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23145 ;; 23146 *) 23147 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23148 for as_dir in $PATH 23149 do 23150 IFS=$as_save_IFS 23151 test -z "$as_dir" && as_dir=. 23152 for ac_exec_ext in '' $ac_executable_extensions; do 23153 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23154 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23155 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23156 break 2 23157 fi 23158 done 23159 done 23160 IFS=$as_save_IFS 23161 23162 ;; 23163 esac 23164 fi 23165 TIME=$ac_cv_path_TIME 23166 if test -n "$TIME"; then 23167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23168 $as_echo "$TIME" >&6; } 23169 else 23170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23171 $as_echo "no" >&6; } 23172 fi 23173 23174 23175 test -n "$TIME" && break 23176 done 23177 23178 else 23179 # The variable is set, but is it from the command line or the environment? 23180 23181 # Try to remove the string !TIME! from our list. 23182 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 23183 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23184 # If it failed, the variable was not from the command line. Ignore it, 23185 # but warn the user (except for BASH, which is always set by the calling BASH). 23186 if test "xTIME" != xBASH; then 23187 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 23188 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 23189 fi 23190 # Try to locate tool using the code snippet 23191 for ac_prog in time 23192 do 23193 # Extract the first word of "$ac_prog", so it can be a program name with args. 23194 set dummy $ac_prog; ac_word=$2 23195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23196 $as_echo_n "checking for $ac_word... " >&6; } 23197 if ${ac_cv_path_TIME+:} false; then : 23198 $as_echo_n "(cached) " >&6 23199 else 23200 case $TIME in 23201 [\\/]* | ?:[\\/]*) 23202 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23203 ;; 23204 *) 23205 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23206 for as_dir in $PATH 23207 do 23208 IFS=$as_save_IFS 23209 test -z "$as_dir" && as_dir=. 23210 for ac_exec_ext in '' $ac_executable_extensions; do 23211 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23212 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23213 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23214 break 2 23215 fi 23216 done 23217 done 23218 IFS=$as_save_IFS 23219 23220 ;; 23221 esac 23222 fi 23223 TIME=$ac_cv_path_TIME 23224 if test -n "$TIME"; then 23225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23226 $as_echo "$TIME" >&6; } 23227 else 23228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23229 $as_echo "no" >&6; } 23230 fi 23231 23232 23233 test -n "$TIME" && break 23234 done 23235 23236 else 23237 # If it succeeded, then it was overridden by the user. We will use it 23238 # for the tool. 23239 23240 # First remove it from the list of overridden variables, so we can test 23241 # for unknown variables in the end. 23242 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23243 23244 # Check if we try to supply an empty value 23245 if test "x$TIME" = x; then 23246 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 23247 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 23248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23249 $as_echo_n "checking for TIME... " >&6; } 23250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23251 $as_echo "disabled" >&6; } 23252 else 23253 # Check if the provided tool contains a complete path. 23254 tool_specified="$TIME" 23255 tool_basename="${tool_specified##*/}" 23256 if test "x$tool_basename" = "x$tool_specified"; then 23257 # A command without a complete path is provided, search $PATH. 23258 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 23259 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 23260 # Extract the first word of "$tool_basename", so it can be a program name with args. 23261 set dummy $tool_basename; ac_word=$2 23262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23263 $as_echo_n "checking for $ac_word... " >&6; } 23264 if ${ac_cv_path_TIME+:} false; then : 23265 $as_echo_n "(cached) " >&6 23266 else 23267 case $TIME in 23268 [\\/]* | ?:[\\/]*) 23269 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 23270 ;; 23271 *) 23272 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23273 for as_dir in $PATH 23274 do 23275 IFS=$as_save_IFS 23276 test -z "$as_dir" && as_dir=. 23277 for ac_exec_ext in '' $ac_executable_extensions; do 23278 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23279 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23280 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23281 break 2 23282 fi 23283 done 23284 done 23285 IFS=$as_save_IFS 23286 23287 ;; 23288 esac 23289 fi 23290 TIME=$ac_cv_path_TIME 23291 if test -n "$TIME"; then 23292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23293 $as_echo "$TIME" >&6; } 23294 else 23295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23296 $as_echo "no" >&6; } 23297 fi 23298 23299 23300 if test "x$TIME" = x; then 23301 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23302 fi 23303 else 23304 # Otherwise we believe it is a complete path. Use it as it is. 23305 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 23306 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 23307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23308 $as_echo_n "checking for TIME... " >&6; } 23309 if test ! -x "$tool_specified"; then 23310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23311 $as_echo "not found" >&6; } 23312 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 23313 fi 23314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23315 $as_echo "$tool_specified" >&6; } 23316 fi 23317 fi 23318 fi 23319 23320 fi 23321 23322 23323 23324 23325 # Publish this variable in the help. 23326 23327 23328 if [ -z "${FLOCK+x}" ]; then 23329 # The variable is not set by user, try to locate tool using the code snippet 23330 for ac_prog in flock 23331 do 23332 # Extract the first word of "$ac_prog", so it can be a program name with args. 23333 set dummy $ac_prog; ac_word=$2 23334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23335 $as_echo_n "checking for $ac_word... " >&6; } 23336 if ${ac_cv_path_FLOCK+:} false; then : 23337 $as_echo_n "(cached) " >&6 23338 else 23339 case $FLOCK in 23340 [\\/]* | ?:[\\/]*) 23341 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23342 ;; 23343 *) 23344 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23345 for as_dir in $PATH 23346 do 23347 IFS=$as_save_IFS 23348 test -z "$as_dir" && as_dir=. 23349 for ac_exec_ext in '' $ac_executable_extensions; do 23350 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23351 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23352 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23353 break 2 23354 fi 23355 done 23356 done 23357 IFS=$as_save_IFS 23358 23359 ;; 23360 esac 23361 fi 23362 FLOCK=$ac_cv_path_FLOCK 23363 if test -n "$FLOCK"; then 23364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23365 $as_echo "$FLOCK" >&6; } 23366 else 23367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23368 $as_echo "no" >&6; } 23369 fi 23370 23371 23372 test -n "$FLOCK" && break 23373 done 23374 23375 else 23376 # The variable is set, but is it from the command line or the environment? 23377 23378 # Try to remove the string !FLOCK! from our list. 23379 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FLOCK!/} 23380 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23381 # If it failed, the variable was not from the command line. Ignore it, 23382 # but warn the user (except for BASH, which is always set by the calling BASH). 23383 if test "xFLOCK" != xBASH; then 23384 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&5 23385 $as_echo "$as_me: WARNING: Ignoring value of FLOCK from the environment. Use command line variables instead." >&2;} 23386 fi 23387 # Try to locate tool using the code snippet 23388 for ac_prog in flock 23389 do 23390 # Extract the first word of "$ac_prog", so it can be a program name with args. 23391 set dummy $ac_prog; ac_word=$2 23392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23393 $as_echo_n "checking for $ac_word... " >&6; } 23394 if ${ac_cv_path_FLOCK+:} false; then : 23395 $as_echo_n "(cached) " >&6 23396 else 23397 case $FLOCK in 23398 [\\/]* | ?:[\\/]*) 23399 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23400 ;; 23401 *) 23402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23403 for as_dir in $PATH 23404 do 23405 IFS=$as_save_IFS 23406 test -z "$as_dir" && as_dir=. 23407 for ac_exec_ext in '' $ac_executable_extensions; do 23408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23409 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23411 break 2 23412 fi 23413 done 23414 done 23415 IFS=$as_save_IFS 23416 23417 ;; 23418 esac 23419 fi 23420 FLOCK=$ac_cv_path_FLOCK 23421 if test -n "$FLOCK"; then 23422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23423 $as_echo "$FLOCK" >&6; } 23424 else 23425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23426 $as_echo "no" >&6; } 23427 fi 23428 23429 23430 test -n "$FLOCK" && break 23431 done 23432 23433 else 23434 # If it succeeded, then it was overridden by the user. We will use it 23435 # for the tool. 23436 23437 # First remove it from the list of overridden variables, so we can test 23438 # for unknown variables in the end. 23439 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23440 23441 # Check if we try to supply an empty value 23442 if test "x$FLOCK" = x; then 23443 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FLOCK= (no value)" >&5 23444 $as_echo "$as_me: Setting user supplied tool FLOCK= (no value)" >&6;} 23445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 23446 $as_echo_n "checking for FLOCK... " >&6; } 23447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23448 $as_echo "disabled" >&6; } 23449 else 23450 # Check if the provided tool contains a complete path. 23451 tool_specified="$FLOCK" 23452 tool_basename="${tool_specified##*/}" 23453 if test "x$tool_basename" = "x$tool_specified"; then 23454 # A command without a complete path is provided, search $PATH. 23455 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FLOCK=$tool_basename" >&5 23456 $as_echo "$as_me: Will search for user supplied tool FLOCK=$tool_basename" >&6;} 23457 # Extract the first word of "$tool_basename", so it can be a program name with args. 23458 set dummy $tool_basename; ac_word=$2 23459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23460 $as_echo_n "checking for $ac_word... " >&6; } 23461 if ${ac_cv_path_FLOCK+:} false; then : 23462 $as_echo_n "(cached) " >&6 23463 else 23464 case $FLOCK in 23465 [\\/]* | ?:[\\/]*) 23466 ac_cv_path_FLOCK="$FLOCK" # Let the user override the test with a path. 23467 ;; 23468 *) 23469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23470 for as_dir in $PATH 23471 do 23472 IFS=$as_save_IFS 23473 test -z "$as_dir" && as_dir=. 23474 for ac_exec_ext in '' $ac_executable_extensions; do 23475 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23476 ac_cv_path_FLOCK="$as_dir/$ac_word$ac_exec_ext" 23477 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23478 break 2 23479 fi 23480 done 23481 done 23482 IFS=$as_save_IFS 23483 23484 ;; 23485 esac 23486 fi 23487 FLOCK=$ac_cv_path_FLOCK 23488 if test -n "$FLOCK"; then 23489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLOCK" >&5 23490 $as_echo "$FLOCK" >&6; } 23491 else 23492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23493 $as_echo "no" >&6; } 23494 fi 23495 23496 23497 if test "x$FLOCK" = x; then 23498 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23499 fi 23500 else 23501 # Otherwise we believe it is a complete path. Use it as it is. 23502 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FLOCK=$tool_specified" >&5 23503 $as_echo "$as_me: Will use user supplied tool FLOCK=$tool_specified" >&6;} 23504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FLOCK" >&5 23505 $as_echo_n "checking for FLOCK... " >&6; } 23506 if test ! -x "$tool_specified"; then 23507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23508 $as_echo "not found" >&6; } 23509 as_fn_error $? "User supplied tool FLOCK=$tool_specified does not exist or is not executable" "$LINENO" 5 23510 fi 23511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23512 $as_echo "$tool_specified" >&6; } 23513 fi 23514 fi 23515 fi 23516 23517 fi 23518 23519 23520 # Dtrace is usually found in /usr/sbin on Solaris, but that directory may not 23521 # be in the user path. 23522 23523 23524 # Publish this variable in the help. 23525 23526 23527 if [ -z "${DTRACE+x}" ]; then 23528 # The variable is not set by user, try to locate tool using the code snippet 23529 for ac_prog in dtrace 23530 do 23531 # Extract the first word of "$ac_prog", so it can be a program name with args. 23532 set dummy $ac_prog; ac_word=$2 23533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23534 $as_echo_n "checking for $ac_word... " >&6; } 23535 if ${ac_cv_path_DTRACE+:} false; then : 23536 $as_echo_n "(cached) " >&6 23537 else 23538 case $DTRACE in 23539 [\\/]* | ?:[\\/]*) 23540 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23541 ;; 23542 *) 23543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23544 as_dummy="$PATH:/usr/sbin" 23545 for as_dir in $as_dummy 23546 do 23547 IFS=$as_save_IFS 23548 test -z "$as_dir" && as_dir=. 23549 for ac_exec_ext in '' $ac_executable_extensions; do 23550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23551 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23553 break 2 23554 fi 23555 done 23556 done 23557 IFS=$as_save_IFS 23558 23559 ;; 23560 esac 23561 fi 23562 DTRACE=$ac_cv_path_DTRACE 23563 if test -n "$DTRACE"; then 23564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23565 $as_echo "$DTRACE" >&6; } 23566 else 23567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23568 $as_echo "no" >&6; } 23569 fi 23570 23571 23572 test -n "$DTRACE" && break 23573 done 23574 23575 else 23576 # The variable is set, but is it from the command line or the environment? 23577 23578 # Try to remove the string !DTRACE! from our list. 23579 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 23580 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23581 # If it failed, the variable was not from the command line. Ignore it, 23582 # but warn the user (except for BASH, which is always set by the calling BASH). 23583 if test "xDTRACE" != xBASH; then 23584 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 23585 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 23586 fi 23587 # Try to locate tool using the code snippet 23588 for ac_prog in dtrace 23589 do 23590 # Extract the first word of "$ac_prog", so it can be a program name with args. 23591 set dummy $ac_prog; ac_word=$2 23592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23593 $as_echo_n "checking for $ac_word... " >&6; } 23594 if ${ac_cv_path_DTRACE+:} false; then : 23595 $as_echo_n "(cached) " >&6 23596 else 23597 case $DTRACE in 23598 [\\/]* | ?:[\\/]*) 23599 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23600 ;; 23601 *) 23602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23603 as_dummy="$PATH:/usr/sbin" 23604 for as_dir in $as_dummy 23605 do 23606 IFS=$as_save_IFS 23607 test -z "$as_dir" && as_dir=. 23608 for ac_exec_ext in '' $ac_executable_extensions; do 23609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23610 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23612 break 2 23613 fi 23614 done 23615 done 23616 IFS=$as_save_IFS 23617 23618 ;; 23619 esac 23620 fi 23621 DTRACE=$ac_cv_path_DTRACE 23622 if test -n "$DTRACE"; then 23623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23624 $as_echo "$DTRACE" >&6; } 23625 else 23626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23627 $as_echo "no" >&6; } 23628 fi 23629 23630 23631 test -n "$DTRACE" && break 23632 done 23633 23634 else 23635 # If it succeeded, then it was overridden by the user. We will use it 23636 # for the tool. 23637 23638 # First remove it from the list of overridden variables, so we can test 23639 # for unknown variables in the end. 23640 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23641 23642 # Check if we try to supply an empty value 23643 if test "x$DTRACE" = x; then 23644 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 23645 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 23646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23647 $as_echo_n "checking for DTRACE... " >&6; } 23648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23649 $as_echo "disabled" >&6; } 23650 else 23651 # Check if the provided tool contains a complete path. 23652 tool_specified="$DTRACE" 23653 tool_basename="${tool_specified##*/}" 23654 if test "x$tool_basename" = "x$tool_specified"; then 23655 # A command without a complete path is provided, search $PATH. 23656 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 23657 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 23658 # Extract the first word of "$tool_basename", so it can be a program name with args. 23659 set dummy $tool_basename; ac_word=$2 23660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23661 $as_echo_n "checking for $ac_word... " >&6; } 23662 if ${ac_cv_path_DTRACE+:} false; then : 23663 $as_echo_n "(cached) " >&6 23664 else 23665 case $DTRACE in 23666 [\\/]* | ?:[\\/]*) 23667 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23668 ;; 23669 *) 23670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23671 for as_dir in $PATH 23672 do 23673 IFS=$as_save_IFS 23674 test -z "$as_dir" && as_dir=. 23675 for ac_exec_ext in '' $ac_executable_extensions; do 23676 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23677 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23679 break 2 23680 fi 23681 done 23682 done 23683 IFS=$as_save_IFS 23684 23685 ;; 23686 esac 23687 fi 23688 DTRACE=$ac_cv_path_DTRACE 23689 if test -n "$DTRACE"; then 23690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23691 $as_echo "$DTRACE" >&6; } 23692 else 23693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23694 $as_echo "no" >&6; } 23695 fi 23696 23697 23698 if test "x$DTRACE" = x; then 23699 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23700 fi 23701 else 23702 # Otherwise we believe it is a complete path. Use it as it is. 23703 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 23704 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 23705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23706 $as_echo_n "checking for DTRACE... " >&6; } 23707 if test ! -x "$tool_specified"; then 23708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23709 $as_echo "not found" >&6; } 23710 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 23711 fi 23712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23713 $as_echo "$tool_specified" >&6; } 23714 fi 23715 fi 23716 fi 23717 23718 fi 23719 23720 23721 23722 23723 # Publish this variable in the help. 23724 23725 23726 if [ -z "${PATCH+x}" ]; then 23727 # The variable is not set by user, try to locate tool using the code snippet 23728 for ac_prog in gpatch patch 23729 do 23730 # Extract the first word of "$ac_prog", so it can be a program name with args. 23731 set dummy $ac_prog; ac_word=$2 23732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23733 $as_echo_n "checking for $ac_word... " >&6; } 23734 if ${ac_cv_path_PATCH+:} false; then : 23735 $as_echo_n "(cached) " >&6 23736 else 23737 case $PATCH in 23738 [\\/]* | ?:[\\/]*) 23739 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23740 ;; 23741 *) 23742 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23743 for as_dir in $PATH 23744 do 23745 IFS=$as_save_IFS 23746 test -z "$as_dir" && as_dir=. 23747 for ac_exec_ext in '' $ac_executable_extensions; do 23748 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23749 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23750 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23751 break 2 23752 fi 23753 done 23754 done 23755 IFS=$as_save_IFS 23756 23757 ;; 23758 esac 23759 fi 23760 PATCH=$ac_cv_path_PATCH 23761 if test -n "$PATCH"; then 23762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23763 $as_echo "$PATCH" >&6; } 23764 else 23765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23766 $as_echo "no" >&6; } 23767 fi 23768 23769 23770 test -n "$PATCH" && break 23771 done 23772 23773 else 23774 # The variable is set, but is it from the command line or the environment? 23775 23776 # Try to remove the string !PATCH! from our list. 23777 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23778 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23779 # If it failed, the variable was not from the command line. Ignore it, 23780 # but warn the user (except for BASH, which is always set by the calling BASH). 23781 if test "xPATCH" != xBASH; then 23782 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23783 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23784 fi 23785 # Try to locate tool using the code snippet 23786 for ac_prog in gpatch patch 23787 do 23788 # Extract the first word of "$ac_prog", so it can be a program name with args. 23789 set dummy $ac_prog; ac_word=$2 23790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23791 $as_echo_n "checking for $ac_word... " >&6; } 23792 if ${ac_cv_path_PATCH+:} false; then : 23793 $as_echo_n "(cached) " >&6 23794 else 23795 case $PATCH in 23796 [\\/]* | ?:[\\/]*) 23797 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23798 ;; 23799 *) 23800 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23801 for as_dir in $PATH 23802 do 23803 IFS=$as_save_IFS 23804 test -z "$as_dir" && as_dir=. 23805 for ac_exec_ext in '' $ac_executable_extensions; do 23806 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23807 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23808 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23809 break 2 23810 fi 23811 done 23812 done 23813 IFS=$as_save_IFS 23814 23815 ;; 23816 esac 23817 fi 23818 PATCH=$ac_cv_path_PATCH 23819 if test -n "$PATCH"; then 23820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23821 $as_echo "$PATCH" >&6; } 23822 else 23823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23824 $as_echo "no" >&6; } 23825 fi 23826 23827 23828 test -n "$PATCH" && break 23829 done 23830 23831 else 23832 # If it succeeded, then it was overridden by the user. We will use it 23833 # for the tool. 23834 23835 # First remove it from the list of overridden variables, so we can test 23836 # for unknown variables in the end. 23837 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23838 23839 # Check if we try to supply an empty value 23840 if test "x$PATCH" = x; then 23841 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23842 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23844 $as_echo_n "checking for PATCH... " >&6; } 23845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23846 $as_echo "disabled" >&6; } 23847 else 23848 # Check if the provided tool contains a complete path. 23849 tool_specified="$PATCH" 23850 tool_basename="${tool_specified##*/}" 23851 if test "x$tool_basename" = "x$tool_specified"; then 23852 # A command without a complete path is provided, search $PATH. 23853 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23854 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23855 # Extract the first word of "$tool_basename", so it can be a program name with args. 23856 set dummy $tool_basename; ac_word=$2 23857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23858 $as_echo_n "checking for $ac_word... " >&6; } 23859 if ${ac_cv_path_PATCH+:} false; then : 23860 $as_echo_n "(cached) " >&6 23861 else 23862 case $PATCH in 23863 [\\/]* | ?:[\\/]*) 23864 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23865 ;; 23866 *) 23867 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23868 for as_dir in $PATH 23869 do 23870 IFS=$as_save_IFS 23871 test -z "$as_dir" && as_dir=. 23872 for ac_exec_ext in '' $ac_executable_extensions; do 23873 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23874 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23875 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23876 break 2 23877 fi 23878 done 23879 done 23880 IFS=$as_save_IFS 23881 23882 ;; 23883 esac 23884 fi 23885 PATCH=$ac_cv_path_PATCH 23886 if test -n "$PATCH"; then 23887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23888 $as_echo "$PATCH" >&6; } 23889 else 23890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23891 $as_echo "no" >&6; } 23892 fi 23893 23894 23895 if test "x$PATCH" = x; then 23896 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23897 fi 23898 else 23899 # Otherwise we believe it is a complete path. Use it as it is. 23900 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23901 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23903 $as_echo_n "checking for PATCH... " >&6; } 23904 if test ! -x "$tool_specified"; then 23905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23906 $as_echo "not found" >&6; } 23907 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23908 fi 23909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23910 $as_echo "$tool_specified" >&6; } 23911 fi 23912 fi 23913 fi 23914 23915 fi 23916 23917 23918 # Check if it's GNU time 23919 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23920 if test "x$IS_GNU_TIME" != x; then 23921 IS_GNU_TIME=yes 23922 else 23923 IS_GNU_TIME=no 23924 fi 23925 23926 23927 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23928 23929 23930 23931 # Publish this variable in the help. 23932 23933 23934 if [ -z "${DSYMUTIL+x}" ]; then 23935 # The variable is not set by user, try to locate tool using the code snippet 23936 for ac_prog in dsymutil 23937 do 23938 # Extract the first word of "$ac_prog", so it can be a program name with args. 23939 set dummy $ac_prog; ac_word=$2 23940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23941 $as_echo_n "checking for $ac_word... " >&6; } 23942 if ${ac_cv_path_DSYMUTIL+:} false; then : 23943 $as_echo_n "(cached) " >&6 23944 else 23945 case $DSYMUTIL in 23946 [\\/]* | ?:[\\/]*) 23947 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23948 ;; 23949 *) 23950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23951 for as_dir in $PATH 23952 do 23953 IFS=$as_save_IFS 23954 test -z "$as_dir" && as_dir=. 23955 for ac_exec_ext in '' $ac_executable_extensions; do 23956 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23957 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23959 break 2 23960 fi 23961 done 23962 done 23963 IFS=$as_save_IFS 23964 23965 ;; 23966 esac 23967 fi 23968 DSYMUTIL=$ac_cv_path_DSYMUTIL 23969 if test -n "$DSYMUTIL"; then 23970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23971 $as_echo "$DSYMUTIL" >&6; } 23972 else 23973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23974 $as_echo "no" >&6; } 23975 fi 23976 23977 23978 test -n "$DSYMUTIL" && break 23979 done 23980 23981 else 23982 # The variable is set, but is it from the command line or the environment? 23983 23984 # Try to remove the string !DSYMUTIL! from our list. 23985 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23986 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23987 # If it failed, the variable was not from the command line. Ignore it, 23988 # but warn the user (except for BASH, which is always set by the calling BASH). 23989 if test "xDSYMUTIL" != xBASH; then 23990 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23991 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23992 fi 23993 # Try to locate tool using the code snippet 23994 for ac_prog in dsymutil 23995 do 23996 # Extract the first word of "$ac_prog", so it can be a program name with args. 23997 set dummy $ac_prog; ac_word=$2 23998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23999 $as_echo_n "checking for $ac_word... " >&6; } 24000 if ${ac_cv_path_DSYMUTIL+:} false; then : 24001 $as_echo_n "(cached) " >&6 24002 else 24003 case $DSYMUTIL in 24004 [\\/]* | ?:[\\/]*) 24005 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 24006 ;; 24007 *) 24008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24009 for as_dir in $PATH 24010 do 24011 IFS=$as_save_IFS 24012 test -z "$as_dir" && as_dir=. 24013 for ac_exec_ext in '' $ac_executable_extensions; do 24014 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24015 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 24016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24017 break 2 24018 fi 24019 done 24020 done 24021 IFS=$as_save_IFS 24022 24023 ;; 24024 esac 24025 fi 24026 DSYMUTIL=$ac_cv_path_DSYMUTIL 24027 if test -n "$DSYMUTIL"; then 24028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 24029 $as_echo "$DSYMUTIL" >&6; } 24030 else 24031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24032 $as_echo "no" >&6; } 24033 fi 24034 24035 24036 test -n "$DSYMUTIL" && break 24037 done 24038 24039 else 24040 # If it succeeded, then it was overridden by the user. We will use it 24041 # for the tool. 24042 24043 # First remove it from the list of overridden variables, so we can test 24044 # for unknown variables in the end. 24045 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24046 24047 # Check if we try to supply an empty value 24048 if test "x$DSYMUTIL" = x; then 24049 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 24050 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 24051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 24052 $as_echo_n "checking for DSYMUTIL... " >&6; } 24053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24054 $as_echo "disabled" >&6; } 24055 else 24056 # Check if the provided tool contains a complete path. 24057 tool_specified="$DSYMUTIL" 24058 tool_basename="${tool_specified##*/}" 24059 if test "x$tool_basename" = "x$tool_specified"; then 24060 # A command without a complete path is provided, search $PATH. 24061 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 24062 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 24063 # Extract the first word of "$tool_basename", so it can be a program name with args. 24064 set dummy $tool_basename; ac_word=$2 24065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24066 $as_echo_n "checking for $ac_word... " >&6; } 24067 if ${ac_cv_path_DSYMUTIL+:} false; then : 24068 $as_echo_n "(cached) " >&6 24069 else 24070 case $DSYMUTIL in 24071 [\\/]* | ?:[\\/]*) 24072 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 24073 ;; 24074 *) 24075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24076 for as_dir in $PATH 24077 do 24078 IFS=$as_save_IFS 24079 test -z "$as_dir" && as_dir=. 24080 for ac_exec_ext in '' $ac_executable_extensions; do 24081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24082 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 24083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24084 break 2 24085 fi 24086 done 24087 done 24088 IFS=$as_save_IFS 24089 24090 ;; 24091 esac 24092 fi 24093 DSYMUTIL=$ac_cv_path_DSYMUTIL 24094 if test -n "$DSYMUTIL"; then 24095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 24096 $as_echo "$DSYMUTIL" >&6; } 24097 else 24098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24099 $as_echo "no" >&6; } 24100 fi 24101 24102 24103 if test "x$DSYMUTIL" = x; then 24104 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24105 fi 24106 else 24107 # Otherwise we believe it is a complete path. Use it as it is. 24108 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 24109 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 24110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 24111 $as_echo_n "checking for DSYMUTIL... " >&6; } 24112 if test ! -x "$tool_specified"; then 24113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24114 $as_echo "not found" >&6; } 24115 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 24116 fi 24117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24118 $as_echo "$tool_specified" >&6; } 24119 fi 24120 fi 24121 fi 24122 24123 fi 24124 24125 24126 24127 if test "x$DSYMUTIL" = x; then 24128 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 24129 fi 24130 24131 24132 24133 24134 24135 # Publish this variable in the help. 24136 24137 24138 if [ -z "${XATTR+x}" ]; then 24139 # The variable is not set by user, try to locate tool using the code snippet 24140 for ac_prog in xattr 24141 do 24142 # Extract the first word of "$ac_prog", so it can be a program name with args. 24143 set dummy $ac_prog; ac_word=$2 24144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24145 $as_echo_n "checking for $ac_word... " >&6; } 24146 if ${ac_cv_path_XATTR+:} false; then : 24147 $as_echo_n "(cached) " >&6 24148 else 24149 case $XATTR in 24150 [\\/]* | ?:[\\/]*) 24151 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24152 ;; 24153 *) 24154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24155 for as_dir in $PATH 24156 do 24157 IFS=$as_save_IFS 24158 test -z "$as_dir" && as_dir=. 24159 for ac_exec_ext in '' $ac_executable_extensions; do 24160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24161 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24163 break 2 24164 fi 24165 done 24166 done 24167 IFS=$as_save_IFS 24168 24169 ;; 24170 esac 24171 fi 24172 XATTR=$ac_cv_path_XATTR 24173 if test -n "$XATTR"; then 24174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24175 $as_echo "$XATTR" >&6; } 24176 else 24177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24178 $as_echo "no" >&6; } 24179 fi 24180 24181 24182 test -n "$XATTR" && break 24183 done 24184 24185 else 24186 # The variable is set, but is it from the command line or the environment? 24187 24188 # Try to remove the string !XATTR! from our list. 24189 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 24190 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24191 # If it failed, the variable was not from the command line. Ignore it, 24192 # but warn the user (except for BASH, which is always set by the calling BASH). 24193 if test "xXATTR" != xBASH; then 24194 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 24195 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 24196 fi 24197 # Try to locate tool using the code snippet 24198 for ac_prog in xattr 24199 do 24200 # Extract the first word of "$ac_prog", so it can be a program name with args. 24201 set dummy $ac_prog; ac_word=$2 24202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24203 $as_echo_n "checking for $ac_word... " >&6; } 24204 if ${ac_cv_path_XATTR+:} false; then : 24205 $as_echo_n "(cached) " >&6 24206 else 24207 case $XATTR in 24208 [\\/]* | ?:[\\/]*) 24209 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24210 ;; 24211 *) 24212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24213 for as_dir in $PATH 24214 do 24215 IFS=$as_save_IFS 24216 test -z "$as_dir" && as_dir=. 24217 for ac_exec_ext in '' $ac_executable_extensions; do 24218 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24219 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24220 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24221 break 2 24222 fi 24223 done 24224 done 24225 IFS=$as_save_IFS 24226 24227 ;; 24228 esac 24229 fi 24230 XATTR=$ac_cv_path_XATTR 24231 if test -n "$XATTR"; then 24232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24233 $as_echo "$XATTR" >&6; } 24234 else 24235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24236 $as_echo "no" >&6; } 24237 fi 24238 24239 24240 test -n "$XATTR" && break 24241 done 24242 24243 else 24244 # If it succeeded, then it was overridden by the user. We will use it 24245 # for the tool. 24246 24247 # First remove it from the list of overridden variables, so we can test 24248 # for unknown variables in the end. 24249 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24250 24251 # Check if we try to supply an empty value 24252 if test "x$XATTR" = x; then 24253 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 24254 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 24255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 24256 $as_echo_n "checking for XATTR... " >&6; } 24257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24258 $as_echo "disabled" >&6; } 24259 else 24260 # Check if the provided tool contains a complete path. 24261 tool_specified="$XATTR" 24262 tool_basename="${tool_specified##*/}" 24263 if test "x$tool_basename" = "x$tool_specified"; then 24264 # A command without a complete path is provided, search $PATH. 24265 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 24266 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 24267 # Extract the first word of "$tool_basename", so it can be a program name with args. 24268 set dummy $tool_basename; ac_word=$2 24269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24270 $as_echo_n "checking for $ac_word... " >&6; } 24271 if ${ac_cv_path_XATTR+:} false; then : 24272 $as_echo_n "(cached) " >&6 24273 else 24274 case $XATTR in 24275 [\\/]* | ?:[\\/]*) 24276 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 24277 ;; 24278 *) 24279 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24280 for as_dir in $PATH 24281 do 24282 IFS=$as_save_IFS 24283 test -z "$as_dir" && as_dir=. 24284 for ac_exec_ext in '' $ac_executable_extensions; do 24285 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24286 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 24287 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24288 break 2 24289 fi 24290 done 24291 done 24292 IFS=$as_save_IFS 24293 24294 ;; 24295 esac 24296 fi 24297 XATTR=$ac_cv_path_XATTR 24298 if test -n "$XATTR"; then 24299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 24300 $as_echo "$XATTR" >&6; } 24301 else 24302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24303 $as_echo "no" >&6; } 24304 fi 24305 24306 24307 if test "x$XATTR" = x; then 24308 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24309 fi 24310 else 24311 # Otherwise we believe it is a complete path. Use it as it is. 24312 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 24313 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 24314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 24315 $as_echo_n "checking for XATTR... " >&6; } 24316 if test ! -x "$tool_specified"; then 24317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24318 $as_echo "not found" >&6; } 24319 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 24320 fi 24321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24322 $as_echo "$tool_specified" >&6; } 24323 fi 24324 fi 24325 fi 24326 24327 fi 24328 24329 24330 24331 if test "x$XATTR" = x; then 24332 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 24333 fi 24334 24335 24336 24337 24338 # Publish this variable in the help. 24339 24340 24341 if [ -z "${CODESIGN+x}" ]; then 24342 # The variable is not set by user, try to locate tool using the code snippet 24343 for ac_prog in codesign 24344 do 24345 # Extract the first word of "$ac_prog", so it can be a program name with args. 24346 set dummy $ac_prog; ac_word=$2 24347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24348 $as_echo_n "checking for $ac_word... " >&6; } 24349 if ${ac_cv_path_CODESIGN+:} false; then : 24350 $as_echo_n "(cached) " >&6 24351 else 24352 case $CODESIGN in 24353 [\\/]* | ?:[\\/]*) 24354 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24355 ;; 24356 *) 24357 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24358 for as_dir in $PATH 24359 do 24360 IFS=$as_save_IFS 24361 test -z "$as_dir" && as_dir=. 24362 for ac_exec_ext in '' $ac_executable_extensions; do 24363 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24364 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24365 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24366 break 2 24367 fi 24368 done 24369 done 24370 IFS=$as_save_IFS 24371 24372 ;; 24373 esac 24374 fi 24375 CODESIGN=$ac_cv_path_CODESIGN 24376 if test -n "$CODESIGN"; then 24377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24378 $as_echo "$CODESIGN" >&6; } 24379 else 24380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24381 $as_echo "no" >&6; } 24382 fi 24383 24384 24385 test -n "$CODESIGN" && break 24386 done 24387 24388 else 24389 # The variable is set, but is it from the command line or the environment? 24390 24391 # Try to remove the string !CODESIGN! from our list. 24392 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 24393 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24394 # If it failed, the variable was not from the command line. Ignore it, 24395 # but warn the user (except for BASH, which is always set by the calling BASH). 24396 if test "xCODESIGN" != xBASH; then 24397 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 24398 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 24399 fi 24400 # Try to locate tool using the code snippet 24401 for ac_prog in codesign 24402 do 24403 # Extract the first word of "$ac_prog", so it can be a program name with args. 24404 set dummy $ac_prog; ac_word=$2 24405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24406 $as_echo_n "checking for $ac_word... " >&6; } 24407 if ${ac_cv_path_CODESIGN+:} false; then : 24408 $as_echo_n "(cached) " >&6 24409 else 24410 case $CODESIGN in 24411 [\\/]* | ?:[\\/]*) 24412 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24413 ;; 24414 *) 24415 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24416 for as_dir in $PATH 24417 do 24418 IFS=$as_save_IFS 24419 test -z "$as_dir" && as_dir=. 24420 for ac_exec_ext in '' $ac_executable_extensions; do 24421 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24422 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24423 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24424 break 2 24425 fi 24426 done 24427 done 24428 IFS=$as_save_IFS 24429 24430 ;; 24431 esac 24432 fi 24433 CODESIGN=$ac_cv_path_CODESIGN 24434 if test -n "$CODESIGN"; then 24435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24436 $as_echo "$CODESIGN" >&6; } 24437 else 24438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24439 $as_echo "no" >&6; } 24440 fi 24441 24442 24443 test -n "$CODESIGN" && break 24444 done 24445 24446 else 24447 # If it succeeded, then it was overridden by the user. We will use it 24448 # for the tool. 24449 24450 # First remove it from the list of overridden variables, so we can test 24451 # for unknown variables in the end. 24452 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24453 24454 # Check if we try to supply an empty value 24455 if test "x$CODESIGN" = x; then 24456 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 24457 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 24458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24459 $as_echo_n "checking for CODESIGN... " >&6; } 24460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24461 $as_echo "disabled" >&6; } 24462 else 24463 # Check if the provided tool contains a complete path. 24464 tool_specified="$CODESIGN" 24465 tool_basename="${tool_specified##*/}" 24466 if test "x$tool_basename" = "x$tool_specified"; then 24467 # A command without a complete path is provided, search $PATH. 24468 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 24469 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 24470 # Extract the first word of "$tool_basename", so it can be a program name with args. 24471 set dummy $tool_basename; ac_word=$2 24472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24473 $as_echo_n "checking for $ac_word... " >&6; } 24474 if ${ac_cv_path_CODESIGN+:} false; then : 24475 $as_echo_n "(cached) " >&6 24476 else 24477 case $CODESIGN in 24478 [\\/]* | ?:[\\/]*) 24479 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24480 ;; 24481 *) 24482 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24483 for as_dir in $PATH 24484 do 24485 IFS=$as_save_IFS 24486 test -z "$as_dir" && as_dir=. 24487 for ac_exec_ext in '' $ac_executable_extensions; do 24488 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24489 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24491 break 2 24492 fi 24493 done 24494 done 24495 IFS=$as_save_IFS 24496 24497 ;; 24498 esac 24499 fi 24500 CODESIGN=$ac_cv_path_CODESIGN 24501 if test -n "$CODESIGN"; then 24502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24503 $as_echo "$CODESIGN" >&6; } 24504 else 24505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24506 $as_echo "no" >&6; } 24507 fi 24508 24509 24510 if test "x$CODESIGN" = x; then 24511 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24512 fi 24513 else 24514 # Otherwise we believe it is a complete path. Use it as it is. 24515 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 24516 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 24517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24518 $as_echo_n "checking for CODESIGN... " >&6; } 24519 if test ! -x "$tool_specified"; then 24520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24521 $as_echo "not found" >&6; } 24522 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 24523 fi 24524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24525 $as_echo "$tool_specified" >&6; } 24526 fi 24527 fi 24528 fi 24529 24530 fi 24531 24532 24533 if test "x$CODESIGN" != "x"; then 24534 # Verify that the openjdk_codesign certificate is present 24535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 24536 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 24537 $RM codesign-testfile 24538 $TOUCH codesign-testfile 24539 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 24540 $RM codesign-testfile 24541 if test "x$CODESIGN" = x; then 24542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24543 $as_echo "no" >&6; } 24544 else 24545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24546 $as_echo "yes" >&6; } 24547 fi 24548 fi 24549 24550 24551 24552 # Publish this variable in the help. 24553 24554 24555 if [ -z "${SETFILE+x}" ]; then 24556 # The variable is not set by user, try to locate tool using the code snippet 24557 for ac_prog in SetFile 24558 do 24559 # Extract the first word of "$ac_prog", so it can be a program name with args. 24560 set dummy $ac_prog; ac_word=$2 24561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24562 $as_echo_n "checking for $ac_word... " >&6; } 24563 if ${ac_cv_path_SETFILE+:} false; then : 24564 $as_echo_n "(cached) " >&6 24565 else 24566 case $SETFILE in 24567 [\\/]* | ?:[\\/]*) 24568 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24569 ;; 24570 *) 24571 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24572 for as_dir in $PATH 24573 do 24574 IFS=$as_save_IFS 24575 test -z "$as_dir" && as_dir=. 24576 for ac_exec_ext in '' $ac_executable_extensions; do 24577 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24578 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24579 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24580 break 2 24581 fi 24582 done 24583 done 24584 IFS=$as_save_IFS 24585 24586 ;; 24587 esac 24588 fi 24589 SETFILE=$ac_cv_path_SETFILE 24590 if test -n "$SETFILE"; then 24591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24592 $as_echo "$SETFILE" >&6; } 24593 else 24594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24595 $as_echo "no" >&6; } 24596 fi 24597 24598 24599 test -n "$SETFILE" && break 24600 done 24601 24602 else 24603 # The variable is set, but is it from the command line or the environment? 24604 24605 # Try to remove the string !SETFILE! from our list. 24606 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 24607 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24608 # If it failed, the variable was not from the command line. Ignore it, 24609 # but warn the user (except for BASH, which is always set by the calling BASH). 24610 if test "xSETFILE" != xBASH; then 24611 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 24612 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 24613 fi 24614 # Try to locate tool using the code snippet 24615 for ac_prog in SetFile 24616 do 24617 # Extract the first word of "$ac_prog", so it can be a program name with args. 24618 set dummy $ac_prog; ac_word=$2 24619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24620 $as_echo_n "checking for $ac_word... " >&6; } 24621 if ${ac_cv_path_SETFILE+:} false; then : 24622 $as_echo_n "(cached) " >&6 24623 else 24624 case $SETFILE in 24625 [\\/]* | ?:[\\/]*) 24626 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24627 ;; 24628 *) 24629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24630 for as_dir in $PATH 24631 do 24632 IFS=$as_save_IFS 24633 test -z "$as_dir" && as_dir=. 24634 for ac_exec_ext in '' $ac_executable_extensions; do 24635 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24636 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24638 break 2 24639 fi 24640 done 24641 done 24642 IFS=$as_save_IFS 24643 24644 ;; 24645 esac 24646 fi 24647 SETFILE=$ac_cv_path_SETFILE 24648 if test -n "$SETFILE"; then 24649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24650 $as_echo "$SETFILE" >&6; } 24651 else 24652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24653 $as_echo "no" >&6; } 24654 fi 24655 24656 24657 test -n "$SETFILE" && break 24658 done 24659 24660 else 24661 # If it succeeded, then it was overridden by the user. We will use it 24662 # for the tool. 24663 24664 # First remove it from the list of overridden variables, so we can test 24665 # for unknown variables in the end. 24666 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24667 24668 # Check if we try to supply an empty value 24669 if test "x$SETFILE" = x; then 24670 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 24671 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 24672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24673 $as_echo_n "checking for SETFILE... " >&6; } 24674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24675 $as_echo "disabled" >&6; } 24676 else 24677 # Check if the provided tool contains a complete path. 24678 tool_specified="$SETFILE" 24679 tool_basename="${tool_specified##*/}" 24680 if test "x$tool_basename" = "x$tool_specified"; then 24681 # A command without a complete path is provided, search $PATH. 24682 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 24683 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 24684 # Extract the first word of "$tool_basename", so it can be a program name with args. 24685 set dummy $tool_basename; ac_word=$2 24686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24687 $as_echo_n "checking for $ac_word... " >&6; } 24688 if ${ac_cv_path_SETFILE+:} false; then : 24689 $as_echo_n "(cached) " >&6 24690 else 24691 case $SETFILE in 24692 [\\/]* | ?:[\\/]*) 24693 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24694 ;; 24695 *) 24696 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24697 for as_dir in $PATH 24698 do 24699 IFS=$as_save_IFS 24700 test -z "$as_dir" && as_dir=. 24701 for ac_exec_ext in '' $ac_executable_extensions; do 24702 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24703 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24704 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24705 break 2 24706 fi 24707 done 24708 done 24709 IFS=$as_save_IFS 24710 24711 ;; 24712 esac 24713 fi 24714 SETFILE=$ac_cv_path_SETFILE 24715 if test -n "$SETFILE"; then 24716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24717 $as_echo "$SETFILE" >&6; } 24718 else 24719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24720 $as_echo "no" >&6; } 24721 fi 24722 24723 24724 if test "x$SETFILE" = x; then 24725 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24726 fi 24727 else 24728 # Otherwise we believe it is a complete path. Use it as it is. 24729 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 24730 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 24731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24732 $as_echo_n "checking for SETFILE... " >&6; } 24733 if test ! -x "$tool_specified"; then 24734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24735 $as_echo "not found" >&6; } 24736 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 24737 fi 24738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24739 $as_echo "$tool_specified" >&6; } 24740 fi 24741 fi 24742 fi 24743 24744 fi 24745 24746 24747 24748 if test "x$SETFILE" = x; then 24749 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 24750 fi 24751 24752 24753 fi 24754 24755 24756 # Check bash version 24757 # Extra [ ] to stop m4 mangling 24758 BASH_VER=`$BASH --version | $SED -n -e 's/^.*bash.*ersion *\([0-9.]*\).*$/\1/ p'` 24759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking bash version" >&5 24760 $as_echo_n "checking bash version... " >&6; } 24761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH_VER" >&5 24762 $as_echo "$BASH_VER" >&6; } 24763 24764 BASH_MAJOR=`$ECHO $BASH_VER | $CUT -d . -f 1` 24765 BASH_MINOR=`$ECHO $BASH_VER | $CUT -d . -f 2` 24766 if test $BASH_MAJOR -lt 3 || (test $BASH_MAJOR -eq 3 && test $BASH_MINOR -lt 2); then 24767 as_fn_error $? "bash version 3.2 or better is required" "$LINENO" 5 24768 fi 24769 24770 # Test if bash supports pipefail. 24771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24772 $as_echo_n "checking if bash supports pipefail... " >&6; } 24773 if ${BASH} -c 'set -o pipefail'; then 24774 BASH_ARGS="$BASH_ARGS -o pipefail" 24775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24776 $as_echo "yes" >&6; } 24777 else 24778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24779 $as_echo "no" >&6; } 24780 fi 24781 24782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24783 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24784 if ${BASH} -e -c 'true'; then 24785 BASH_ARGS="$BASH_ARGS -e" 24786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24787 $as_echo "yes" >&6; } 24788 else 24789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24790 $as_echo "no" >&6; } 24791 fi 24792 24793 24794 24795 24796 # Check if pkg-config is available. 24797 24798 24799 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24800 if test -n "$ac_tool_prefix"; then 24801 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24802 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24804 $as_echo_n "checking for $ac_word... " >&6; } 24805 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24806 $as_echo_n "(cached) " >&6 24807 else 24808 case $PKG_CONFIG in 24809 [\\/]* | ?:[\\/]*) 24810 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24811 ;; 24812 *) 24813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24814 for as_dir in $PATH 24815 do 24816 IFS=$as_save_IFS 24817 test -z "$as_dir" && as_dir=. 24818 for ac_exec_ext in '' $ac_executable_extensions; do 24819 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24820 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24821 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24822 break 2 24823 fi 24824 done 24825 done 24826 IFS=$as_save_IFS 24827 24828 ;; 24829 esac 24830 fi 24831 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24832 if test -n "$PKG_CONFIG"; then 24833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24834 $as_echo "$PKG_CONFIG" >&6; } 24835 else 24836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24837 $as_echo "no" >&6; } 24838 fi 24839 24840 24841 fi 24842 if test -z "$ac_cv_path_PKG_CONFIG"; then 24843 ac_pt_PKG_CONFIG=$PKG_CONFIG 24844 # Extract the first word of "pkg-config", so it can be a program name with args. 24845 set dummy pkg-config; ac_word=$2 24846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24847 $as_echo_n "checking for $ac_word... " >&6; } 24848 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24849 $as_echo_n "(cached) " >&6 24850 else 24851 case $ac_pt_PKG_CONFIG in 24852 [\\/]* | ?:[\\/]*) 24853 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24854 ;; 24855 *) 24856 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24857 for as_dir in $PATH 24858 do 24859 IFS=$as_save_IFS 24860 test -z "$as_dir" && as_dir=. 24861 for ac_exec_ext in '' $ac_executable_extensions; do 24862 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24863 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24864 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24865 break 2 24866 fi 24867 done 24868 done 24869 IFS=$as_save_IFS 24870 24871 ;; 24872 esac 24873 fi 24874 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24875 if test -n "$ac_pt_PKG_CONFIG"; then 24876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24877 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24878 else 24879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24880 $as_echo "no" >&6; } 24881 fi 24882 24883 if test "x$ac_pt_PKG_CONFIG" = x; then 24884 PKG_CONFIG="" 24885 else 24886 case $cross_compiling:$ac_tool_warned in 24887 yes:) 24888 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24889 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24890 ac_tool_warned=yes ;; 24891 esac 24892 PKG_CONFIG=$ac_pt_PKG_CONFIG 24893 fi 24894 else 24895 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24896 fi 24897 24898 fi 24899 if test -n "$PKG_CONFIG"; then 24900 _pkg_min_version=0.9.0 24901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24902 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24903 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24905 $as_echo "yes" >&6; } 24906 else 24907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24908 $as_echo "no" >&6; } 24909 PKG_CONFIG="" 24910 fi 24911 24912 fi 24913 24914 # After basic tools have been setup, we can check build os specific details. 24915 24916 ############################################################################### 24917 24918 # Note that this is the build platform OS version! 24919 24920 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24921 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24922 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24923 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24924 24925 24926 24927 24928 24929 # Misc basic settings 24930 24931 24932 # Check whether --with-default-make-target was given. 24933 if test "${with_default_make_target+set}" = set; then : 24934 withval=$with_default_make_target; 24935 fi 24936 24937 if test "x$with_default_make_target" = "x" \ 24938 || test "x$with_default_make_target" = "xyes"; then 24939 DEFAULT_MAKE_TARGET="exploded-image" 24940 elif test "x$with_default_make_target" = "xno"; then 24941 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24942 else 24943 DEFAULT_MAKE_TARGET="$with_default_make_target" 24944 fi 24945 24946 24947 24948 24949 ############################################################################### 24950 # 24951 # Determine OpenJDK variants, options and version numbers. 24952 # 24953 ############################################################################### 24954 24955 # We need build & target for this. 24956 24957 # Should we build a JDK without a graphical UI? 24958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headless only" >&5 24959 $as_echo_n "checking headless only... " >&6; } 24960 # Check whether --enable-headless-only was given. 24961 if test "${enable_headless_only+set}" = set; then : 24962 enableval=$enable_headless_only; 24963 fi 24964 24965 24966 if test "x$enable_headless_only" = "xyes"; then 24967 ENABLE_HEADLESS_ONLY="true" 24968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24969 $as_echo "yes" >&6; } 24970 elif test "x$enable_headless_only" = "xno"; then 24971 ENABLE_HEADLESS_ONLY="false" 24972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24973 $as_echo "no" >&6; } 24974 elif test "x$enable_headless_only" = "x"; then 24975 ENABLE_HEADLESS_ONLY="false" 24976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24977 $as_echo "no" >&6; } 24978 else 24979 as_fn_error $? "--enable-headless-only can only take yes or no" "$LINENO" 5 24980 fi 24981 24982 24983 24984 # Should we build the complete docs, or just a lightweight version? 24985 # Check whether --enable-full-docs was given. 24986 if test "${enable_full_docs+set}" = set; then : 24987 enableval=$enable_full_docs; 24988 fi 24989 24990 24991 # Verify dependencies 24992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for graphviz dot" >&5 24993 $as_echo_n "checking for graphviz dot... " >&6; } 24994 if test "x$DOT" != "x"; then 24995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24996 $as_echo "yes" >&6; } 24997 else 24998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 24999 $as_echo "no, cannot generate full docs" >&6; } 25000 FULL_DOCS_DEP_MISSING=true 25001 fi 25002 25003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pandoc" >&5 25004 $as_echo_n "checking for pandoc... " >&6; } 25005 if test "x$PANDOC" != "x"; then 25006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25007 $as_echo "yes" >&6; } 25008 else 25009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, cannot generate full docs" >&5 25010 $as_echo "no, cannot generate full docs" >&6; } 25011 FULL_DOCS_DEP_MISSING=true 25012 fi 25013 25014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking full docs" >&5 25015 $as_echo_n "checking full docs... " >&6; } 25016 if test "x$enable_full_docs" = xyes; then 25017 if test "x$FULL_DOCS_DEP_MISSING" = "xtrue"; then 25018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 25019 $as_echo "no, missing dependencies" >&6; } 25020 25021 # Print a helpful message on how to acquire the necessary build dependency. 25022 # dot is the help tag: freetype, cups, alsa etc 25023 MISSING_DEPENDENCY=dot 25024 25025 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25026 cygwin_help $MISSING_DEPENDENCY 25027 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25028 msys_help $MISSING_DEPENDENCY 25029 else 25030 PKGHANDLER_COMMAND= 25031 25032 case $PKGHANDLER in 25033 apt-get) 25034 apt_help $MISSING_DEPENDENCY ;; 25035 yum) 25036 yum_help $MISSING_DEPENDENCY ;; 25037 brew) 25038 brew_help $MISSING_DEPENDENCY ;; 25039 port) 25040 port_help $MISSING_DEPENDENCY ;; 25041 pkgutil) 25042 pkgutil_help $MISSING_DEPENDENCY ;; 25043 pkgadd) 25044 pkgadd_help $MISSING_DEPENDENCY ;; 25045 esac 25046 25047 if test "x$PKGHANDLER_COMMAND" != x; then 25048 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 25049 fi 25050 fi 25051 25052 as_fn_error $? "Cannot enable full docs with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 25053 else 25054 ENABLE_FULL_DOCS=true 25055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 25056 $as_echo "yes, forced" >&6; } 25057 fi 25058 elif test "x$enable_full_docs" = xno; then 25059 ENABLE_FULL_DOCS=false 25060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 25061 $as_echo "no, forced" >&6; } 25062 elif test "x$enable_full_docs" = x; then 25063 # Check for prerequisites 25064 if test "x$FULL_DOCS_DEP_MISSING" = xtrue; then 25065 ENABLE_FULL_DOCS=false 25066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 25067 $as_echo "no, missing dependencies" >&6; } 25068 else 25069 ENABLE_FULL_DOCS=true 25070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 25071 $as_echo "yes, dependencies present" >&6; } 25072 fi 25073 else 25074 as_fn_error $? "--enable-full-docs can only take yes or no" "$LINENO" 5 25075 fi 25076 25077 25078 25079 # Choose cacerts source file 25080 25081 # Check whether --with-cacerts-file was given. 25082 if test "${with_cacerts_file+set}" = set; then : 25083 withval=$with_cacerts_file; 25084 fi 25085 25086 if test "x$with_cacerts_file" != x; then 25087 CACERTS_FILE=$with_cacerts_file 25088 fi 25089 25090 25091 # Enable or disable unlimited crypto 25092 # Check whether --enable-unlimited-crypto was given. 25093 if test "${enable_unlimited_crypto+set}" = set; then : 25094 enableval=$enable_unlimited_crypto; 25095 else 25096 enable_unlimited_crypto=yes 25097 fi 25098 25099 if test "x$enable_unlimited_crypto" = "xyes"; then 25100 UNLIMITED_CRYPTO=true 25101 else 25102 UNLIMITED_CRYPTO=false 25103 fi 25104 25105 25106 # Should we build the serviceability agent (SA)? 25107 INCLUDE_SA=true 25108 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 25109 INCLUDE_SA=false 25110 fi 25111 if test "x$OPENJDK_TARGET_OS" = xaix ; then 25112 INCLUDE_SA=false 25113 fi 25114 25115 25116 # Compress jars 25117 COMPRESS_JARS=false 25118 25119 25120 25121 # Setup default copyright year. Mostly overridden when building close to a new year. 25122 25123 # Check whether --with-copyright-year was given. 25124 if test "${with_copyright_year+set}" = set; then : 25125 withval=$with_copyright_year; 25126 fi 25127 25128 if test "x$with_copyright_year" = xyes; then 25129 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 25130 elif test "x$with_copyright_year" != x; then 25131 COPYRIGHT_YEAR="$with_copyright_year" 25132 else 25133 COPYRIGHT_YEAR=`$DATE +'%Y'` 25134 fi 25135 25136 25137 25138 # Check whether --enable-keep-packaged-modules was given. 25139 if test "${enable_keep_packaged_modules+set}" = set; then : 25140 enableval=$enable_keep_packaged_modules; 25141 fi 25142 25143 25144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 25145 $as_echo_n "checking if packaged modules are kept... " >&6; } 25146 if test "x$enable_keep_packaged_modules" = "xyes"; then 25147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25148 $as_echo "yes" >&6; } 25149 JLINK_KEEP_PACKAGED_MODULES=true 25150 elif test "x$enable_keep_packaged_modules" = "xno"; then 25151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25152 $as_echo "no" >&6; } 25153 JLINK_KEEP_PACKAGED_MODULES=false 25154 elif test "x$enable_keep_packaged_modules" = "x"; then 25155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 25156 $as_echo "yes (default)" >&6; } 25157 JLINK_KEEP_PACKAGED_MODULES=true 25158 else 25159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: error" >&5 25160 $as_echo "error" >&6; } 25161 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 25162 fi 25163 25164 25165 25166 25167 # Warn user that old version arguments are deprecated. 25168 25169 25170 # Check whether --with-milestone was given. 25171 if test "${with_milestone+set}" = set; then : 25172 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 25173 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 25174 fi 25175 25176 25177 25178 25179 # Check whether --with-update-version was given. 25180 if test "${with_update_version+set}" = set; then : 25181 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 25182 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 25183 fi 25184 25185 25186 25187 25188 # Check whether --with-user-release-suffix was given. 25189 if test "${with_user_release_suffix+set}" = set; then : 25190 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 25191 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 25192 fi 25193 25194 25195 25196 25197 # Check whether --with-build-number was given. 25198 if test "${with_build_number+set}" = set; then : 25199 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 25200 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 25201 fi 25202 25203 25204 25205 # Source the version numbers file 25206 . $AUTOCONF_DIR/version-numbers 25207 25208 # Some non-version number information is set in that file 25209 25210 25211 25212 25213 25214 25215 25216 25217 25218 # Override version from arguments 25219 25220 # If --with-version-string is set, process it first. It is possible to 25221 # override parts with more specific flags, since these are processed later. 25222 25223 # Check whether --with-version-string was given. 25224 if test "${with_version_string+set}" = set; then : 25225 withval=$with_version_string; 25226 fi 25227 25228 if test "x$with_version_string" = xyes; then 25229 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 25230 elif test "x$with_version_string" != x; then 25231 # Additional [] needed to keep m4 from mangling shell constructs. 25232 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 25233 VERSION_MAJOR=${BASH_REMATCH[1]} 25234 VERSION_MINOR=${BASH_REMATCH[3]} 25235 VERSION_SECURITY=${BASH_REMATCH[5]} 25236 VERSION_PATCH=${BASH_REMATCH[7]} 25237 VERSION_PRE=${BASH_REMATCH[9]} 25238 version_plus_separator=${BASH_REMATCH[11]} 25239 VERSION_BUILD=${BASH_REMATCH[12]} 25240 VERSION_OPT=${BASH_REMATCH[14]} 25241 # Unspecified numerical fields are interpreted as 0. 25242 if test "x$VERSION_MINOR" = x; then 25243 VERSION_MINOR=0 25244 fi 25245 if test "x$VERSION_SECURITY" = x; then 25246 VERSION_SECURITY=0 25247 fi 25248 if test "x$VERSION_PATCH" = x; then 25249 VERSION_PATCH=0 25250 fi 25251 if test "x$version_plus_separator" != x \ 25252 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 25253 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 25254 fi 25255 # Stop the version part process from setting default values. 25256 # We still allow them to explicitly override though. 25257 NO_DEFAULT_VERSION_PARTS=true 25258 else 25259 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 25260 fi 25261 fi 25262 25263 25264 # Check whether --with-version-pre was given. 25265 if test "${with_version_pre+set}" = set; then : 25266 withval=$with_version_pre; with_version_pre_present=true 25267 else 25268 with_version_pre_present=false 25269 fi 25270 25271 25272 if test "x$with_version_pre_present" = xtrue; then 25273 if test "x$with_version_pre" = xyes; then 25274 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 25275 elif test "x$with_version_pre" = xno; then 25276 # Interpret --without-* as empty string instead of the literal "no" 25277 VERSION_PRE= 25278 else 25279 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 25280 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 25281 if test "x$VERSION_PRE" != "x$with_version_pre"; then 25282 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 25283 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 25284 fi 25285 fi 25286 else 25287 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25288 # Default is to use "internal" as pre 25289 VERSION_PRE="internal" 25290 fi 25291 fi 25292 25293 25294 # Check whether --with-version-opt was given. 25295 if test "${with_version_opt+set}" = set; then : 25296 withval=$with_version_opt; with_version_opt_present=true 25297 else 25298 with_version_opt_present=false 25299 fi 25300 25301 25302 if test "x$with_version_opt_present" = xtrue; then 25303 if test "x$with_version_opt" = xyes; then 25304 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 25305 elif test "x$with_version_opt" = xno; then 25306 # Interpret --without-* as empty string instead of the literal "no" 25307 VERSION_OPT= 25308 else 25309 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 25310 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 25311 if test "x$VERSION_OPT" != "x$with_version_opt"; then 25312 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 25313 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 25314 fi 25315 fi 25316 else 25317 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25318 # Default is to calculate a string like this 'adhoc.<username>.<base dir name>' 25319 # Outer [ ] to quote m4. 25320 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 25321 VERSION_OPT="adhoc.$USERNAME.$basedirname" 25322 fi 25323 fi 25324 25325 25326 # Check whether --with-version-build was given. 25327 if test "${with_version_build+set}" = set; then : 25328 withval=$with_version_build; with_version_build_present=true 25329 else 25330 with_version_build_present=false 25331 fi 25332 25333 25334 if test "x$with_version_build_present" = xtrue; then 25335 if test "x$with_version_build" = xyes; then 25336 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 25337 elif test "x$with_version_build" = xno; then 25338 # Interpret --without-* as empty string instead of the literal "no" 25339 VERSION_BUILD= 25340 elif test "x$with_version_build" = x; then 25341 VERSION_BUILD= 25342 else 25343 25344 # Additional [] needed to keep m4 from mangling shell constructs. 25345 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25346 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 25347 fi 25348 # Extract the version number without leading zeros. 25349 cleaned_value=${BASH_REMATCH[1]} 25350 if test "x$cleaned_value" = x; then 25351 # Special case for zero 25352 cleaned_value=${BASH_REMATCH[2]} 25353 fi 25354 25355 if test $cleaned_value -gt 255; then 25356 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 25357 fi 25358 if test "x$cleaned_value" != "x$with_version_build"; then 25359 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 25360 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 25361 fi 25362 VERSION_BUILD=$cleaned_value 25363 25364 fi 25365 else 25366 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25367 # Default is to not have a build number. 25368 VERSION_BUILD="" 25369 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 25370 VERSION_BUILD=0 25371 fi 25372 fi 25373 25374 25375 # Check whether --with-version-major was given. 25376 if test "${with_version_major+set}" = set; then : 25377 withval=$with_version_major; with_version_major_present=true 25378 else 25379 with_version_major_present=false 25380 fi 25381 25382 25383 if test "x$with_version_major_present" = xtrue; then 25384 if test "x$with_version_major" = xyes; then 25385 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 25386 else 25387 25388 # Additional [] needed to keep m4 from mangling shell constructs. 25389 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25390 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 25391 fi 25392 # Extract the version number without leading zeros. 25393 cleaned_value=${BASH_REMATCH[1]} 25394 if test "x$cleaned_value" = x; then 25395 # Special case for zero 25396 cleaned_value=${BASH_REMATCH[2]} 25397 fi 25398 25399 if test $cleaned_value -gt 255; then 25400 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 25401 fi 25402 if test "x$cleaned_value" != "x$with_version_major"; then 25403 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 25404 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 25405 fi 25406 VERSION_MAJOR=$cleaned_value 25407 25408 fi 25409 else 25410 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25411 # Default is to get value from version-numbers 25412 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 25413 fi 25414 fi 25415 25416 25417 # Check whether --with-version-minor was given. 25418 if test "${with_version_minor+set}" = set; then : 25419 withval=$with_version_minor; with_version_minor_present=true 25420 else 25421 with_version_minor_present=false 25422 fi 25423 25424 25425 if test "x$with_version_minor_present" = xtrue; then 25426 if test "x$with_version_minor" = xyes; then 25427 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 25428 elif test "x$with_version_minor" = xno; then 25429 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25430 VERSION_MINOR=0 25431 elif test "x$with_version_minor" = x; then 25432 VERSION_MINOR=0 25433 else 25434 25435 # Additional [] needed to keep m4 from mangling shell constructs. 25436 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25437 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 25438 fi 25439 # Extract the version number without leading zeros. 25440 cleaned_value=${BASH_REMATCH[1]} 25441 if test "x$cleaned_value" = x; then 25442 # Special case for zero 25443 cleaned_value=${BASH_REMATCH[2]} 25444 fi 25445 25446 if test $cleaned_value -gt 255; then 25447 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 25448 fi 25449 if test "x$cleaned_value" != "x$with_version_minor"; then 25450 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 25451 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 25452 fi 25453 VERSION_MINOR=$cleaned_value 25454 25455 fi 25456 else 25457 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25458 # Default is 0, if unspecified 25459 VERSION_MINOR=$DEFAULT_VERSION_MINOR 25460 fi 25461 fi 25462 25463 25464 # Check whether --with-version-security was given. 25465 if test "${with_version_security+set}" = set; then : 25466 withval=$with_version_security; with_version_security_present=true 25467 else 25468 with_version_security_present=false 25469 fi 25470 25471 25472 if test "x$with_version_security_present" = xtrue; then 25473 if test "x$with_version_security" = xyes; then 25474 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 25475 elif test "x$with_version_security" = xno; then 25476 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25477 VERSION_SECURITY=0 25478 elif test "x$with_version_security" = x; then 25479 VERSION_SECURITY=0 25480 else 25481 25482 # Additional [] needed to keep m4 from mangling shell constructs. 25483 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25484 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 25485 fi 25486 # Extract the version number without leading zeros. 25487 cleaned_value=${BASH_REMATCH[1]} 25488 if test "x$cleaned_value" = x; then 25489 # Special case for zero 25490 cleaned_value=${BASH_REMATCH[2]} 25491 fi 25492 25493 if test $cleaned_value -gt 255; then 25494 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 25495 fi 25496 if test "x$cleaned_value" != "x$with_version_security"; then 25497 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 25498 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 25499 fi 25500 VERSION_SECURITY=$cleaned_value 25501 25502 fi 25503 else 25504 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25505 # Default is 0, if unspecified 25506 VERSION_SECURITY=$DEFAULT_VERSION_SECURITY 25507 fi 25508 fi 25509 25510 25511 # Check whether --with-version-patch was given. 25512 if test "${with_version_patch+set}" = set; then : 25513 withval=$with_version_patch; with_version_patch_present=true 25514 else 25515 with_version_patch_present=false 25516 fi 25517 25518 25519 if test "x$with_version_patch_present" = xtrue; then 25520 if test "x$with_version_patch" = xyes; then 25521 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 25522 elif test "x$with_version_patch" = xno; then 25523 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 25524 VERSION_PATCH=0 25525 elif test "x$with_version_patch" = x; then 25526 VERSION_PATCH=0 25527 else 25528 25529 # Additional [] needed to keep m4 from mangling shell constructs. 25530 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 25531 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 25532 fi 25533 # Extract the version number without leading zeros. 25534 cleaned_value=${BASH_REMATCH[1]} 25535 if test "x$cleaned_value" = x; then 25536 # Special case for zero 25537 cleaned_value=${BASH_REMATCH[2]} 25538 fi 25539 25540 if test $cleaned_value -gt 255; then 25541 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 25542 fi 25543 if test "x$cleaned_value" != "x$with_version_patch"; then 25544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 25545 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 25546 fi 25547 VERSION_PATCH=$cleaned_value 25548 25549 fi 25550 else 25551 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 25552 # Default is 0, if unspecified 25553 VERSION_PATCH=$DEFAULT_VERSION_PATCH 25554 fi 25555 fi 25556 25557 # Calculate derived version properties 25558 25559 # Set VERSION_IS_GA based on if VERSION_PRE has a value 25560 if test "x$VERSION_PRE" = x; then 25561 VERSION_IS_GA=true 25562 else 25563 VERSION_IS_GA=false 25564 fi 25565 25566 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 25567 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 25568 25569 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 25570 # Strip trailing zeroes from stripped_version_number 25571 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 25572 VERSION_NUMBER=$stripped_version_number 25573 25574 # The complete version string, with additional build information 25575 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 25576 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25577 else 25578 # If either build or opt is set, we need a + separator 25579 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 25580 fi 25581 25582 # The short version string, just VERSION_NUMBER and PRE, if present. 25583 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25584 25585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 25586 $as_echo_n "checking for version string... " >&6; } 25587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 25588 $as_echo "$VERSION_STRING" >&6; } 25589 25590 25591 25592 25593 25594 25595 25596 25597 25598 25599 25600 25601 25602 25603 25604 ############################################################################### 25605 # 25606 # Setup BootJDK, used to bootstrap the build. 25607 # 25608 ############################################################################### 25609 25610 25611 BOOT_JDK_FOUND=no 25612 25613 # Check whether --with-boot-jdk was given. 25614 if test "${with_boot_jdk+set}" = set; then : 25615 withval=$with_boot_jdk; 25616 fi 25617 25618 25619 # We look for the Boot JDK through various means, going from more certain to 25620 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 25621 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 25622 # must check if this is indeed valid; otherwise we'll continue looking. 25623 25624 # Test: Is bootjdk explicitly set by command line arguments? 25625 25626 if test "x$BOOT_JDK_FOUND" = xno; then 25627 # Now execute the test 25628 25629 if test "x$with_boot_jdk" != x; then 25630 BOOT_JDK=$with_boot_jdk 25631 BOOT_JDK_FOUND=maybe 25632 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 25633 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 25634 fi 25635 25636 25637 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25638 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25639 # Do we have a bin/java? 25640 if test ! -x "$BOOT_JDK/bin/java"; then 25641 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25642 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25643 BOOT_JDK_FOUND=no 25644 else 25645 # Do we have a bin/javac? 25646 if test ! -x "$BOOT_JDK/bin/javac"; then 25647 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25648 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25649 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25650 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25651 BOOT_JDK_FOUND=no 25652 else 25653 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25654 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25655 25656 # Extra M4 quote needed to protect [] in grep expression. 25657 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25658 if test "x$FOUND_CORRECT_VERSION" = x; then 25659 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25660 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25661 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25662 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25663 BOOT_JDK_FOUND=no 25664 else 25665 # We're done! :-) 25666 BOOT_JDK_FOUND=yes 25667 25668 # Only process if variable expands to non-empty 25669 25670 if test "x$BOOT_JDK" != x; then 25671 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25672 25673 # Input might be given as Windows format, start by converting to 25674 # unix format. 25675 path="$BOOT_JDK" 25676 new_path=`$CYGPATH -u "$path"` 25677 25678 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25679 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25680 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25681 # "foo.exe" is OK but "foo" is an error. 25682 # 25683 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25684 # It is also a way to make sure we got the proper file name for the real test later on. 25685 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25686 if test "x$test_shortpath" = x; then 25687 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25688 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25689 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25690 fi 25691 25692 # Call helper function which possibly converts this using DOS-style short mode. 25693 # If so, the updated path is stored in $new_path. 25694 25695 input_path="$new_path" 25696 # Check if we need to convert this using DOS-style short mode. If the path 25697 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25698 # take no chances and rewrite it. 25699 # Note: m4 eats our [], so we need to use [ and ] instead. 25700 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25701 if test "x$has_forbidden_chars" != x; then 25702 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25703 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25704 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25705 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25706 # Going to short mode and back again did indeed matter. Since short mode is 25707 # case insensitive, let's make it lowercase to improve readability. 25708 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25709 # Now convert it back to Unix-style (cygpath) 25710 input_path=`$CYGPATH -u "$shortmode_path"` 25711 new_path="$input_path" 25712 fi 25713 fi 25714 25715 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25716 if test "x$test_cygdrive_prefix" = x; then 25717 # As a simple fix, exclude /usr/bin since it's not a real path. 25718 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25719 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25720 # a path prefixed by /cygdrive for fixpath to work. 25721 new_path="$CYGWIN_ROOT_PATH$input_path" 25722 fi 25723 fi 25724 25725 25726 if test "x$path" != "x$new_path"; then 25727 BOOT_JDK="$new_path" 25728 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25729 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25730 fi 25731 25732 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25733 25734 path="$BOOT_JDK" 25735 has_colon=`$ECHO $path | $GREP ^.:` 25736 new_path="$path" 25737 if test "x$has_colon" = x; then 25738 # Not in mixed or Windows style, start by that. 25739 new_path=`cmd //c echo $path` 25740 fi 25741 25742 25743 input_path="$new_path" 25744 # Check if we need to convert this using DOS-style short mode. If the path 25745 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25746 # take no chances and rewrite it. 25747 # Note: m4 eats our [], so we need to use [ and ] instead. 25748 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25749 if test "x$has_forbidden_chars" != x; then 25750 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25751 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25752 fi 25753 25754 25755 windows_path="$new_path" 25756 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25757 unix_path=`$CYGPATH -u "$windows_path"` 25758 new_path="$unix_path" 25759 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25760 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25761 new_path="$unix_path" 25762 fi 25763 25764 if test "x$path" != "x$new_path"; then 25765 BOOT_JDK="$new_path" 25766 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25767 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25768 fi 25769 25770 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25771 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25772 25773 else 25774 # We're on a unix platform. Hooray! :) 25775 path="$BOOT_JDK" 25776 has_space=`$ECHO "$path" | $GREP " "` 25777 if test "x$has_space" != x; then 25778 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25779 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25780 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25781 fi 25782 25783 # Use eval to expand a potential ~ 25784 eval path="$path" 25785 if test ! -f "$path" && test ! -d "$path"; then 25786 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25787 fi 25788 25789 if test -d "$path"; then 25790 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25791 else 25792 dir="`$DIRNAME "$path"`" 25793 base="`$BASENAME "$path"`" 25794 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25795 fi 25796 fi 25797 fi 25798 25799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25800 $as_echo_n "checking for Boot JDK... " >&6; } 25801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25802 $as_echo "$BOOT_JDK" >&6; } 25803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25804 $as_echo_n "checking Boot JDK version... " >&6; } 25805 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25807 $as_echo "$BOOT_JDK_VERSION" >&6; } 25808 fi # end check jdk version 25809 fi # end check javac 25810 fi # end check java 25811 fi # end check boot jdk found 25812 fi 25813 25814 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 25815 # Having specified an argument which is incorrect will produce an instant failure; 25816 # we should not go on looking 25817 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 25818 fi 25819 25820 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 25821 25822 if test "x$BOOT_JDK_FOUND" = xno; then 25823 # Now execute the test 25824 25825 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 25826 # First check at user selected default 25827 25828 if test "x$BOOT_JDK_FOUND" = xno; then 25829 # Now execute the test 25830 25831 if test -x /usr/libexec/java_home; then 25832 BOOT_JDK=`/usr/libexec/java_home ` 25833 BOOT_JDK_FOUND=maybe 25834 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 25835 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 25836 fi 25837 25838 25839 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25840 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25841 # Do we have a bin/java? 25842 if test ! -x "$BOOT_JDK/bin/java"; then 25843 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25844 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25845 BOOT_JDK_FOUND=no 25846 else 25847 # Do we have a bin/javac? 25848 if test ! -x "$BOOT_JDK/bin/javac"; then 25849 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25850 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25851 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25852 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25853 BOOT_JDK_FOUND=no 25854 else 25855 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25856 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25857 25858 # Extra M4 quote needed to protect [] in grep expression. 25859 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25860 if test "x$FOUND_CORRECT_VERSION" = x; then 25861 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25862 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25863 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25864 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25865 BOOT_JDK_FOUND=no 25866 else 25867 # We're done! :-) 25868 BOOT_JDK_FOUND=yes 25869 25870 # Only process if variable expands to non-empty 25871 25872 if test "x$BOOT_JDK" != x; then 25873 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25874 25875 # Input might be given as Windows format, start by converting to 25876 # unix format. 25877 path="$BOOT_JDK" 25878 new_path=`$CYGPATH -u "$path"` 25879 25880 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25881 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25882 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25883 # "foo.exe" is OK but "foo" is an error. 25884 # 25885 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25886 # It is also a way to make sure we got the proper file name for the real test later on. 25887 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25888 if test "x$test_shortpath" = x; then 25889 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25890 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25891 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25892 fi 25893 25894 # Call helper function which possibly converts this using DOS-style short mode. 25895 # If so, the updated path is stored in $new_path. 25896 25897 input_path="$new_path" 25898 # Check if we need to convert this using DOS-style short mode. If the path 25899 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25900 # take no chances and rewrite it. 25901 # Note: m4 eats our [], so we need to use [ and ] instead. 25902 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25903 if test "x$has_forbidden_chars" != x; then 25904 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25905 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25906 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25907 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25908 # Going to short mode and back again did indeed matter. Since short mode is 25909 # case insensitive, let's make it lowercase to improve readability. 25910 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25911 # Now convert it back to Unix-style (cygpath) 25912 input_path=`$CYGPATH -u "$shortmode_path"` 25913 new_path="$input_path" 25914 fi 25915 fi 25916 25917 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25918 if test "x$test_cygdrive_prefix" = x; then 25919 # As a simple fix, exclude /usr/bin since it's not a real path. 25920 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25921 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25922 # a path prefixed by /cygdrive for fixpath to work. 25923 new_path="$CYGWIN_ROOT_PATH$input_path" 25924 fi 25925 fi 25926 25927 25928 if test "x$path" != "x$new_path"; then 25929 BOOT_JDK="$new_path" 25930 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25931 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25932 fi 25933 25934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25935 25936 path="$BOOT_JDK" 25937 has_colon=`$ECHO $path | $GREP ^.:` 25938 new_path="$path" 25939 if test "x$has_colon" = x; then 25940 # Not in mixed or Windows style, start by that. 25941 new_path=`cmd //c echo $path` 25942 fi 25943 25944 25945 input_path="$new_path" 25946 # Check if we need to convert this using DOS-style short mode. If the path 25947 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25948 # take no chances and rewrite it. 25949 # Note: m4 eats our [], so we need to use [ and ] instead. 25950 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25951 if test "x$has_forbidden_chars" != x; then 25952 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25953 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25954 fi 25955 25956 25957 windows_path="$new_path" 25958 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25959 unix_path=`$CYGPATH -u "$windows_path"` 25960 new_path="$unix_path" 25961 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25962 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25963 new_path="$unix_path" 25964 fi 25965 25966 if test "x$path" != "x$new_path"; then 25967 BOOT_JDK="$new_path" 25968 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25969 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25970 fi 25971 25972 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25973 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25974 25975 else 25976 # We're on a unix platform. Hooray! :) 25977 path="$BOOT_JDK" 25978 has_space=`$ECHO "$path" | $GREP " "` 25979 if test "x$has_space" != x; then 25980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25981 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25982 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25983 fi 25984 25985 # Use eval to expand a potential ~ 25986 eval path="$path" 25987 if test ! -f "$path" && test ! -d "$path"; then 25988 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25989 fi 25990 25991 if test -d "$path"; then 25992 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25993 else 25994 dir="`$DIRNAME "$path"`" 25995 base="`$BASENAME "$path"`" 25996 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25997 fi 25998 fi 25999 fi 26000 26001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26002 $as_echo_n "checking for Boot JDK... " >&6; } 26003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26004 $as_echo "$BOOT_JDK" >&6; } 26005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26006 $as_echo_n "checking Boot JDK version... " >&6; } 26007 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26009 $as_echo "$BOOT_JDK_VERSION" >&6; } 26010 fi # end check jdk version 26011 fi # end check javac 26012 fi # end check java 26013 fi # end check boot jdk found 26014 fi 26015 26016 # If that did not work out (e.g. too old), try explicit versions instead 26017 26018 if test "x$BOOT_JDK_FOUND" = xno; then 26019 # Now execute the test 26020 26021 if test -x /usr/libexec/java_home; then 26022 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 26023 BOOT_JDK_FOUND=maybe 26024 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 26025 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 26026 fi 26027 26028 26029 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26030 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26031 # Do we have a bin/java? 26032 if test ! -x "$BOOT_JDK/bin/java"; then 26033 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26034 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26035 BOOT_JDK_FOUND=no 26036 else 26037 # Do we have a bin/javac? 26038 if test ! -x "$BOOT_JDK/bin/javac"; then 26039 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26040 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26041 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26042 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26043 BOOT_JDK_FOUND=no 26044 else 26045 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26046 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26047 26048 # Extra M4 quote needed to protect [] in grep expression. 26049 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26050 if test "x$FOUND_CORRECT_VERSION" = x; then 26051 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26052 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26053 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26054 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26055 BOOT_JDK_FOUND=no 26056 else 26057 # We're done! :-) 26058 BOOT_JDK_FOUND=yes 26059 26060 # Only process if variable expands to non-empty 26061 26062 if test "x$BOOT_JDK" != x; then 26063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26064 26065 # Input might be given as Windows format, start by converting to 26066 # unix format. 26067 path="$BOOT_JDK" 26068 new_path=`$CYGPATH -u "$path"` 26069 26070 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26071 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26072 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26073 # "foo.exe" is OK but "foo" is an error. 26074 # 26075 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26076 # It is also a way to make sure we got the proper file name for the real test later on. 26077 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26078 if test "x$test_shortpath" = x; then 26079 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26080 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26081 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26082 fi 26083 26084 # Call helper function which possibly converts this using DOS-style short mode. 26085 # If so, the updated path is stored in $new_path. 26086 26087 input_path="$new_path" 26088 # Check if we need to convert this using DOS-style short mode. If the path 26089 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26090 # take no chances and rewrite it. 26091 # Note: m4 eats our [], so we need to use [ and ] instead. 26092 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26093 if test "x$has_forbidden_chars" != x; then 26094 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26095 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26096 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26097 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26098 # Going to short mode and back again did indeed matter. Since short mode is 26099 # case insensitive, let's make it lowercase to improve readability. 26100 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26101 # Now convert it back to Unix-style (cygpath) 26102 input_path=`$CYGPATH -u "$shortmode_path"` 26103 new_path="$input_path" 26104 fi 26105 fi 26106 26107 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26108 if test "x$test_cygdrive_prefix" = x; then 26109 # As a simple fix, exclude /usr/bin since it's not a real path. 26110 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26111 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26112 # a path prefixed by /cygdrive for fixpath to work. 26113 new_path="$CYGWIN_ROOT_PATH$input_path" 26114 fi 26115 fi 26116 26117 26118 if test "x$path" != "x$new_path"; then 26119 BOOT_JDK="$new_path" 26120 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26121 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26122 fi 26123 26124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26125 26126 path="$BOOT_JDK" 26127 has_colon=`$ECHO $path | $GREP ^.:` 26128 new_path="$path" 26129 if test "x$has_colon" = x; then 26130 # Not in mixed or Windows style, start by that. 26131 new_path=`cmd //c echo $path` 26132 fi 26133 26134 26135 input_path="$new_path" 26136 # Check if we need to convert this using DOS-style short mode. If the path 26137 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26138 # take no chances and rewrite it. 26139 # Note: m4 eats our [], so we need to use [ and ] instead. 26140 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26141 if test "x$has_forbidden_chars" != x; then 26142 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26143 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26144 fi 26145 26146 26147 windows_path="$new_path" 26148 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26149 unix_path=`$CYGPATH -u "$windows_path"` 26150 new_path="$unix_path" 26151 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26152 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26153 new_path="$unix_path" 26154 fi 26155 26156 if test "x$path" != "x$new_path"; then 26157 BOOT_JDK="$new_path" 26158 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26159 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26160 fi 26161 26162 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26163 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26164 26165 else 26166 # We're on a unix platform. Hooray! :) 26167 path="$BOOT_JDK" 26168 has_space=`$ECHO "$path" | $GREP " "` 26169 if test "x$has_space" != x; then 26170 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26171 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26172 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26173 fi 26174 26175 # Use eval to expand a potential ~ 26176 eval path="$path" 26177 if test ! -f "$path" && test ! -d "$path"; then 26178 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26179 fi 26180 26181 if test -d "$path"; then 26182 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26183 else 26184 dir="`$DIRNAME "$path"`" 26185 base="`$BASENAME "$path"`" 26186 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26187 fi 26188 fi 26189 fi 26190 26191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26192 $as_echo_n "checking for Boot JDK... " >&6; } 26193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26194 $as_echo "$BOOT_JDK" >&6; } 26195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26196 $as_echo_n "checking Boot JDK version... " >&6; } 26197 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26199 $as_echo "$BOOT_JDK_VERSION" >&6; } 26200 fi # end check jdk version 26201 fi # end check javac 26202 fi # end check java 26203 fi # end check boot jdk found 26204 fi 26205 26206 26207 if test "x$BOOT_JDK_FOUND" = xno; then 26208 # Now execute the test 26209 26210 if test -x /usr/libexec/java_home; then 26211 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 26212 BOOT_JDK_FOUND=maybe 26213 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 26214 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 26215 fi 26216 26217 26218 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26219 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26220 # Do we have a bin/java? 26221 if test ! -x "$BOOT_JDK/bin/java"; then 26222 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26223 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26224 BOOT_JDK_FOUND=no 26225 else 26226 # Do we have a bin/javac? 26227 if test ! -x "$BOOT_JDK/bin/javac"; then 26228 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26229 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26230 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26231 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26232 BOOT_JDK_FOUND=no 26233 else 26234 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26235 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26236 26237 # Extra M4 quote needed to protect [] in grep expression. 26238 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26239 if test "x$FOUND_CORRECT_VERSION" = x; then 26240 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26241 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26242 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26243 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26244 BOOT_JDK_FOUND=no 26245 else 26246 # We're done! :-) 26247 BOOT_JDK_FOUND=yes 26248 26249 # Only process if variable expands to non-empty 26250 26251 if test "x$BOOT_JDK" != x; then 26252 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26253 26254 # Input might be given as Windows format, start by converting to 26255 # unix format. 26256 path="$BOOT_JDK" 26257 new_path=`$CYGPATH -u "$path"` 26258 26259 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26260 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26261 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26262 # "foo.exe" is OK but "foo" is an error. 26263 # 26264 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26265 # It is also a way to make sure we got the proper file name for the real test later on. 26266 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26267 if test "x$test_shortpath" = x; then 26268 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26269 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26270 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26271 fi 26272 26273 # Call helper function which possibly converts this using DOS-style short mode. 26274 # If so, the updated path is stored in $new_path. 26275 26276 input_path="$new_path" 26277 # Check if we need to convert this using DOS-style short mode. If the path 26278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26279 # take no chances and rewrite it. 26280 # Note: m4 eats our [], so we need to use [ and ] instead. 26281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26282 if test "x$has_forbidden_chars" != x; then 26283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26284 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26285 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26286 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26287 # Going to short mode and back again did indeed matter. Since short mode is 26288 # case insensitive, let's make it lowercase to improve readability. 26289 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26290 # Now convert it back to Unix-style (cygpath) 26291 input_path=`$CYGPATH -u "$shortmode_path"` 26292 new_path="$input_path" 26293 fi 26294 fi 26295 26296 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26297 if test "x$test_cygdrive_prefix" = x; then 26298 # As a simple fix, exclude /usr/bin since it's not a real path. 26299 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26300 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26301 # a path prefixed by /cygdrive for fixpath to work. 26302 new_path="$CYGWIN_ROOT_PATH$input_path" 26303 fi 26304 fi 26305 26306 26307 if test "x$path" != "x$new_path"; then 26308 BOOT_JDK="$new_path" 26309 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26310 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26311 fi 26312 26313 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26314 26315 path="$BOOT_JDK" 26316 has_colon=`$ECHO $path | $GREP ^.:` 26317 new_path="$path" 26318 if test "x$has_colon" = x; then 26319 # Not in mixed or Windows style, start by that. 26320 new_path=`cmd //c echo $path` 26321 fi 26322 26323 26324 input_path="$new_path" 26325 # Check if we need to convert this using DOS-style short mode. If the path 26326 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26327 # take no chances and rewrite it. 26328 # Note: m4 eats our [], so we need to use [ and ] instead. 26329 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26330 if test "x$has_forbidden_chars" != x; then 26331 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26332 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26333 fi 26334 26335 26336 windows_path="$new_path" 26337 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26338 unix_path=`$CYGPATH -u "$windows_path"` 26339 new_path="$unix_path" 26340 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26341 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26342 new_path="$unix_path" 26343 fi 26344 26345 if test "x$path" != "x$new_path"; then 26346 BOOT_JDK="$new_path" 26347 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26348 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26349 fi 26350 26351 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26352 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26353 26354 else 26355 # We're on a unix platform. Hooray! :) 26356 path="$BOOT_JDK" 26357 has_space=`$ECHO "$path" | $GREP " "` 26358 if test "x$has_space" != x; then 26359 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26360 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26361 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26362 fi 26363 26364 # Use eval to expand a potential ~ 26365 eval path="$path" 26366 if test ! -f "$path" && test ! -d "$path"; then 26367 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26368 fi 26369 26370 if test -d "$path"; then 26371 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26372 else 26373 dir="`$DIRNAME "$path"`" 26374 base="`$BASENAME "$path"`" 26375 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26376 fi 26377 fi 26378 fi 26379 26380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26381 $as_echo_n "checking for Boot JDK... " >&6; } 26382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26383 $as_echo "$BOOT_JDK" >&6; } 26384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26385 $as_echo_n "checking Boot JDK version... " >&6; } 26386 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26388 $as_echo "$BOOT_JDK_VERSION" >&6; } 26389 fi # end check jdk version 26390 fi # end check javac 26391 fi # end check java 26392 fi # end check boot jdk found 26393 fi 26394 26395 26396 if test "x$BOOT_JDK_FOUND" = xno; then 26397 # Now execute the test 26398 26399 if test -x /usr/libexec/java_home; then 26400 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 26401 BOOT_JDK_FOUND=maybe 26402 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 26403 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 26404 fi 26405 26406 26407 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26408 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26409 # Do we have a bin/java? 26410 if test ! -x "$BOOT_JDK/bin/java"; then 26411 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26412 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26413 BOOT_JDK_FOUND=no 26414 else 26415 # Do we have a bin/javac? 26416 if test ! -x "$BOOT_JDK/bin/javac"; then 26417 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26418 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26419 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26420 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26421 BOOT_JDK_FOUND=no 26422 else 26423 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26424 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26425 26426 # Extra M4 quote needed to protect [] in grep expression. 26427 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26428 if test "x$FOUND_CORRECT_VERSION" = x; then 26429 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26430 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26431 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26432 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26433 BOOT_JDK_FOUND=no 26434 else 26435 # We're done! :-) 26436 BOOT_JDK_FOUND=yes 26437 26438 # Only process if variable expands to non-empty 26439 26440 if test "x$BOOT_JDK" != x; then 26441 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26442 26443 # Input might be given as Windows format, start by converting to 26444 # unix format. 26445 path="$BOOT_JDK" 26446 new_path=`$CYGPATH -u "$path"` 26447 26448 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26449 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26450 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26451 # "foo.exe" is OK but "foo" is an error. 26452 # 26453 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26454 # It is also a way to make sure we got the proper file name for the real test later on. 26455 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26456 if test "x$test_shortpath" = x; then 26457 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26458 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26459 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26460 fi 26461 26462 # Call helper function which possibly converts this using DOS-style short mode. 26463 # If so, the updated path is stored in $new_path. 26464 26465 input_path="$new_path" 26466 # Check if we need to convert this using DOS-style short mode. If the path 26467 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26468 # take no chances and rewrite it. 26469 # Note: m4 eats our [], so we need to use [ and ] instead. 26470 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26471 if test "x$has_forbidden_chars" != x; then 26472 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26473 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26474 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26475 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26476 # Going to short mode and back again did indeed matter. Since short mode is 26477 # case insensitive, let's make it lowercase to improve readability. 26478 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26479 # Now convert it back to Unix-style (cygpath) 26480 input_path=`$CYGPATH -u "$shortmode_path"` 26481 new_path="$input_path" 26482 fi 26483 fi 26484 26485 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26486 if test "x$test_cygdrive_prefix" = x; then 26487 # As a simple fix, exclude /usr/bin since it's not a real path. 26488 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26489 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26490 # a path prefixed by /cygdrive for fixpath to work. 26491 new_path="$CYGWIN_ROOT_PATH$input_path" 26492 fi 26493 fi 26494 26495 26496 if test "x$path" != "x$new_path"; then 26497 BOOT_JDK="$new_path" 26498 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26499 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26500 fi 26501 26502 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26503 26504 path="$BOOT_JDK" 26505 has_colon=`$ECHO $path | $GREP ^.:` 26506 new_path="$path" 26507 if test "x$has_colon" = x; then 26508 # Not in mixed or Windows style, start by that. 26509 new_path=`cmd //c echo $path` 26510 fi 26511 26512 26513 input_path="$new_path" 26514 # Check if we need to convert this using DOS-style short mode. If the path 26515 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26516 # take no chances and rewrite it. 26517 # Note: m4 eats our [], so we need to use [ and ] instead. 26518 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26519 if test "x$has_forbidden_chars" != x; then 26520 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26521 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26522 fi 26523 26524 26525 windows_path="$new_path" 26526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26527 unix_path=`$CYGPATH -u "$windows_path"` 26528 new_path="$unix_path" 26529 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26530 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26531 new_path="$unix_path" 26532 fi 26533 26534 if test "x$path" != "x$new_path"; then 26535 BOOT_JDK="$new_path" 26536 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26537 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26538 fi 26539 26540 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26541 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26542 26543 else 26544 # We're on a unix platform. Hooray! :) 26545 path="$BOOT_JDK" 26546 has_space=`$ECHO "$path" | $GREP " "` 26547 if test "x$has_space" != x; then 26548 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26549 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26550 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26551 fi 26552 26553 # Use eval to expand a potential ~ 26554 eval path="$path" 26555 if test ! -f "$path" && test ! -d "$path"; then 26556 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26557 fi 26558 26559 if test -d "$path"; then 26560 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26561 else 26562 dir="`$DIRNAME "$path"`" 26563 base="`$BASENAME "$path"`" 26564 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26565 fi 26566 fi 26567 fi 26568 26569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26570 $as_echo_n "checking for Boot JDK... " >&6; } 26571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26572 $as_echo "$BOOT_JDK" >&6; } 26573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26574 $as_echo_n "checking Boot JDK version... " >&6; } 26575 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26577 $as_echo "$BOOT_JDK_VERSION" >&6; } 26578 fi # end check jdk version 26579 fi # end check javac 26580 fi # end check java 26581 fi # end check boot jdk found 26582 fi 26583 26584 fi 26585 26586 26587 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26588 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26589 # Do we have a bin/java? 26590 if test ! -x "$BOOT_JDK/bin/java"; then 26591 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26592 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26593 BOOT_JDK_FOUND=no 26594 else 26595 # Do we have a bin/javac? 26596 if test ! -x "$BOOT_JDK/bin/javac"; then 26597 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26598 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26599 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26600 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26601 BOOT_JDK_FOUND=no 26602 else 26603 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26604 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26605 26606 # Extra M4 quote needed to protect [] in grep expression. 26607 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26608 if test "x$FOUND_CORRECT_VERSION" = x; then 26609 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26610 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26611 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26612 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26613 BOOT_JDK_FOUND=no 26614 else 26615 # We're done! :-) 26616 BOOT_JDK_FOUND=yes 26617 26618 # Only process if variable expands to non-empty 26619 26620 if test "x$BOOT_JDK" != x; then 26621 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26622 26623 # Input might be given as Windows format, start by converting to 26624 # unix format. 26625 path="$BOOT_JDK" 26626 new_path=`$CYGPATH -u "$path"` 26627 26628 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26629 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26630 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26631 # "foo.exe" is OK but "foo" is an error. 26632 # 26633 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26634 # It is also a way to make sure we got the proper file name for the real test later on. 26635 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26636 if test "x$test_shortpath" = x; then 26637 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26638 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26639 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26640 fi 26641 26642 # Call helper function which possibly converts this using DOS-style short mode. 26643 # If so, the updated path is stored in $new_path. 26644 26645 input_path="$new_path" 26646 # Check if we need to convert this using DOS-style short mode. If the path 26647 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26648 # take no chances and rewrite it. 26649 # Note: m4 eats our [], so we need to use [ and ] instead. 26650 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26651 if test "x$has_forbidden_chars" != x; then 26652 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26653 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26654 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26655 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26656 # Going to short mode and back again did indeed matter. Since short mode is 26657 # case insensitive, let's make it lowercase to improve readability. 26658 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26659 # Now convert it back to Unix-style (cygpath) 26660 input_path=`$CYGPATH -u "$shortmode_path"` 26661 new_path="$input_path" 26662 fi 26663 fi 26664 26665 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26666 if test "x$test_cygdrive_prefix" = x; then 26667 # As a simple fix, exclude /usr/bin since it's not a real path. 26668 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26669 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26670 # a path prefixed by /cygdrive for fixpath to work. 26671 new_path="$CYGWIN_ROOT_PATH$input_path" 26672 fi 26673 fi 26674 26675 26676 if test "x$path" != "x$new_path"; then 26677 BOOT_JDK="$new_path" 26678 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26679 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26680 fi 26681 26682 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26683 26684 path="$BOOT_JDK" 26685 has_colon=`$ECHO $path | $GREP ^.:` 26686 new_path="$path" 26687 if test "x$has_colon" = x; then 26688 # Not in mixed or Windows style, start by that. 26689 new_path=`cmd //c echo $path` 26690 fi 26691 26692 26693 input_path="$new_path" 26694 # Check if we need to convert this using DOS-style short mode. If the path 26695 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26696 # take no chances and rewrite it. 26697 # Note: m4 eats our [], so we need to use [ and ] instead. 26698 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26699 if test "x$has_forbidden_chars" != x; then 26700 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26701 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26702 fi 26703 26704 26705 windows_path="$new_path" 26706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26707 unix_path=`$CYGPATH -u "$windows_path"` 26708 new_path="$unix_path" 26709 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26710 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26711 new_path="$unix_path" 26712 fi 26713 26714 if test "x$path" != "x$new_path"; then 26715 BOOT_JDK="$new_path" 26716 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26717 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26718 fi 26719 26720 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26721 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26722 26723 else 26724 # We're on a unix platform. Hooray! :) 26725 path="$BOOT_JDK" 26726 has_space=`$ECHO "$path" | $GREP " "` 26727 if test "x$has_space" != x; then 26728 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26729 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26730 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26731 fi 26732 26733 # Use eval to expand a potential ~ 26734 eval path="$path" 26735 if test ! -f "$path" && test ! -d "$path"; then 26736 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26737 fi 26738 26739 if test -d "$path"; then 26740 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26741 else 26742 dir="`$DIRNAME "$path"`" 26743 base="`$BASENAME "$path"`" 26744 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26745 fi 26746 fi 26747 fi 26748 26749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26750 $as_echo_n "checking for Boot JDK... " >&6; } 26751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26752 $as_echo "$BOOT_JDK" >&6; } 26753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26754 $as_echo_n "checking Boot JDK version... " >&6; } 26755 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26757 $as_echo "$BOOT_JDK_VERSION" >&6; } 26758 fi # end check jdk version 26759 fi # end check javac 26760 fi # end check java 26761 fi # end check boot jdk found 26762 fi 26763 26764 26765 # Test: Is $JAVA_HOME set? 26766 26767 if test "x$BOOT_JDK_FOUND" = xno; then 26768 # Now execute the test 26769 26770 if test "x$JAVA_HOME" != x; then 26771 JAVA_HOME_PROCESSED="$JAVA_HOME" 26772 26773 # Only process if variable expands to non-empty 26774 26775 if test "x$JAVA_HOME_PROCESSED" != x; then 26776 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26777 26778 # Input might be given as Windows format, start by converting to 26779 # unix format. 26780 path="$JAVA_HOME_PROCESSED" 26781 new_path=`$CYGPATH -u "$path"` 26782 26783 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26784 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26785 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26786 # "foo.exe" is OK but "foo" is an error. 26787 # 26788 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26789 # It is also a way to make sure we got the proper file name for the real test later on. 26790 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26791 if test "x$test_shortpath" = x; then 26792 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26793 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26794 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 26795 fi 26796 26797 # Call helper function which possibly converts this using DOS-style short mode. 26798 # If so, the updated path is stored in $new_path. 26799 26800 input_path="$new_path" 26801 # Check if we need to convert this using DOS-style short mode. If the path 26802 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26803 # take no chances and rewrite it. 26804 # Note: m4 eats our [], so we need to use [ and ] instead. 26805 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26806 if test "x$has_forbidden_chars" != x; then 26807 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26808 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26809 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26810 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26811 # Going to short mode and back again did indeed matter. Since short mode is 26812 # case insensitive, let's make it lowercase to improve readability. 26813 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26814 # Now convert it back to Unix-style (cygpath) 26815 input_path=`$CYGPATH -u "$shortmode_path"` 26816 new_path="$input_path" 26817 fi 26818 fi 26819 26820 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26821 if test "x$test_cygdrive_prefix" = x; then 26822 # As a simple fix, exclude /usr/bin since it's not a real path. 26823 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26824 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26825 # a path prefixed by /cygdrive for fixpath to work. 26826 new_path="$CYGWIN_ROOT_PATH$input_path" 26827 fi 26828 fi 26829 26830 26831 if test "x$path" != "x$new_path"; then 26832 JAVA_HOME_PROCESSED="$new_path" 26833 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26834 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26835 fi 26836 26837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26838 26839 path="$JAVA_HOME_PROCESSED" 26840 has_colon=`$ECHO $path | $GREP ^.:` 26841 new_path="$path" 26842 if test "x$has_colon" = x; then 26843 # Not in mixed or Windows style, start by that. 26844 new_path=`cmd //c echo $path` 26845 fi 26846 26847 26848 input_path="$new_path" 26849 # Check if we need to convert this using DOS-style short mode. If the path 26850 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26851 # take no chances and rewrite it. 26852 # Note: m4 eats our [], so we need to use [ and ] instead. 26853 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26854 if test "x$has_forbidden_chars" != x; then 26855 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26856 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26857 fi 26858 26859 26860 windows_path="$new_path" 26861 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26862 unix_path=`$CYGPATH -u "$windows_path"` 26863 new_path="$unix_path" 26864 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26865 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26866 new_path="$unix_path" 26867 fi 26868 26869 if test "x$path" != "x$new_path"; then 26870 JAVA_HOME_PROCESSED="$new_path" 26871 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26872 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26873 fi 26874 26875 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26876 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26877 26878 else 26879 # We're on a unix platform. Hooray! :) 26880 path="$JAVA_HOME_PROCESSED" 26881 has_space=`$ECHO "$path" | $GREP " "` 26882 if test "x$has_space" != x; then 26883 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26884 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26885 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26886 fi 26887 26888 # Use eval to expand a potential ~ 26889 eval path="$path" 26890 if test ! -f "$path" && test ! -d "$path"; then 26891 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26892 fi 26893 26894 if test -d "$path"; then 26895 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26896 else 26897 dir="`$DIRNAME "$path"`" 26898 base="`$BASENAME "$path"`" 26899 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26900 fi 26901 fi 26902 fi 26903 26904 if test ! -d "$JAVA_HOME_PROCESSED"; then 26905 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26906 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26907 else 26908 # Aha, the user has set a JAVA_HOME 26909 # let us use that as the Boot JDK. 26910 BOOT_JDK="$JAVA_HOME_PROCESSED" 26911 BOOT_JDK_FOUND=maybe 26912 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26913 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26914 fi 26915 fi 26916 26917 26918 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26919 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26920 # Do we have a bin/java? 26921 if test ! -x "$BOOT_JDK/bin/java"; then 26922 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26923 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26924 BOOT_JDK_FOUND=no 26925 else 26926 # Do we have a bin/javac? 26927 if test ! -x "$BOOT_JDK/bin/javac"; then 26928 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26929 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26930 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26931 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26932 BOOT_JDK_FOUND=no 26933 else 26934 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26935 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26936 26937 # Extra M4 quote needed to protect [] in grep expression. 26938 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26939 if test "x$FOUND_CORRECT_VERSION" = x; then 26940 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26941 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26942 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26943 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26944 BOOT_JDK_FOUND=no 26945 else 26946 # We're done! :-) 26947 BOOT_JDK_FOUND=yes 26948 26949 # Only process if variable expands to non-empty 26950 26951 if test "x$BOOT_JDK" != x; then 26952 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26953 26954 # Input might be given as Windows format, start by converting to 26955 # unix format. 26956 path="$BOOT_JDK" 26957 new_path=`$CYGPATH -u "$path"` 26958 26959 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26960 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26961 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26962 # "foo.exe" is OK but "foo" is an error. 26963 # 26964 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26965 # It is also a way to make sure we got the proper file name for the real test later on. 26966 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26967 if test "x$test_shortpath" = x; then 26968 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26969 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26970 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26971 fi 26972 26973 # Call helper function which possibly converts this using DOS-style short mode. 26974 # If so, the updated path is stored in $new_path. 26975 26976 input_path="$new_path" 26977 # Check if we need to convert this using DOS-style short mode. If the path 26978 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26979 # take no chances and rewrite it. 26980 # Note: m4 eats our [], so we need to use [ and ] instead. 26981 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26982 if test "x$has_forbidden_chars" != x; then 26983 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26984 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26985 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26986 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26987 # Going to short mode and back again did indeed matter. Since short mode is 26988 # case insensitive, let's make it lowercase to improve readability. 26989 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26990 # Now convert it back to Unix-style (cygpath) 26991 input_path=`$CYGPATH -u "$shortmode_path"` 26992 new_path="$input_path" 26993 fi 26994 fi 26995 26996 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26997 if test "x$test_cygdrive_prefix" = x; then 26998 # As a simple fix, exclude /usr/bin since it's not a real path. 26999 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27000 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27001 # a path prefixed by /cygdrive for fixpath to work. 27002 new_path="$CYGWIN_ROOT_PATH$input_path" 27003 fi 27004 fi 27005 27006 27007 if test "x$path" != "x$new_path"; then 27008 BOOT_JDK="$new_path" 27009 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27010 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27011 fi 27012 27013 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27014 27015 path="$BOOT_JDK" 27016 has_colon=`$ECHO $path | $GREP ^.:` 27017 new_path="$path" 27018 if test "x$has_colon" = x; then 27019 # Not in mixed or Windows style, start by that. 27020 new_path=`cmd //c echo $path` 27021 fi 27022 27023 27024 input_path="$new_path" 27025 # Check if we need to convert this using DOS-style short mode. If the path 27026 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27027 # take no chances and rewrite it. 27028 # Note: m4 eats our [], so we need to use [ and ] instead. 27029 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27030 if test "x$has_forbidden_chars" != x; then 27031 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27032 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27033 fi 27034 27035 27036 windows_path="$new_path" 27037 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27038 unix_path=`$CYGPATH -u "$windows_path"` 27039 new_path="$unix_path" 27040 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27041 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27042 new_path="$unix_path" 27043 fi 27044 27045 if test "x$path" != "x$new_path"; then 27046 BOOT_JDK="$new_path" 27047 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27048 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27049 fi 27050 27051 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27052 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27053 27054 else 27055 # We're on a unix platform. Hooray! :) 27056 path="$BOOT_JDK" 27057 has_space=`$ECHO "$path" | $GREP " "` 27058 if test "x$has_space" != x; then 27059 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27060 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27061 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27062 fi 27063 27064 # Use eval to expand a potential ~ 27065 eval path="$path" 27066 if test ! -f "$path" && test ! -d "$path"; then 27067 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27068 fi 27069 27070 if test -d "$path"; then 27071 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27072 else 27073 dir="`$DIRNAME "$path"`" 27074 base="`$BASENAME "$path"`" 27075 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27076 fi 27077 fi 27078 fi 27079 27080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27081 $as_echo_n "checking for Boot JDK... " >&6; } 27082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27083 $as_echo "$BOOT_JDK" >&6; } 27084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27085 $as_echo_n "checking Boot JDK version... " >&6; } 27086 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27088 $as_echo "$BOOT_JDK_VERSION" >&6; } 27089 fi # end check jdk version 27090 fi # end check javac 27091 fi # end check java 27092 fi # end check boot jdk found 27093 fi 27094 27095 27096 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 27097 27098 if test "x$BOOT_JDK_FOUND" = xno; then 27099 # Now execute the test 27100 27101 # Extract the first word of "javac", so it can be a program name with args. 27102 set dummy javac; ac_word=$2 27103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27104 $as_echo_n "checking for $ac_word... " >&6; } 27105 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 27106 $as_echo_n "(cached) " >&6 27107 else 27108 case $JAVAC_CHECK in 27109 [\\/]* | ?:[\\/]*) 27110 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 27111 ;; 27112 *) 27113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27114 for as_dir in $PATH 27115 do 27116 IFS=$as_save_IFS 27117 test -z "$as_dir" && as_dir=. 27118 for ac_exec_ext in '' $ac_executable_extensions; do 27119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 27120 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 27121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27122 break 2 27123 fi 27124 done 27125 done 27126 IFS=$as_save_IFS 27127 27128 ;; 27129 esac 27130 fi 27131 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 27132 if test -n "$JAVAC_CHECK"; then 27133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 27134 $as_echo "$JAVAC_CHECK" >&6; } 27135 else 27136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27137 $as_echo "no" >&6; } 27138 fi 27139 27140 27141 # Extract the first word of "java", so it can be a program name with args. 27142 set dummy java; ac_word=$2 27143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27144 $as_echo_n "checking for $ac_word... " >&6; } 27145 if ${ac_cv_path_JAVA_CHECK+:} false; then : 27146 $as_echo_n "(cached) " >&6 27147 else 27148 case $JAVA_CHECK in 27149 [\\/]* | ?:[\\/]*) 27150 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 27151 ;; 27152 *) 27153 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27154 for as_dir in $PATH 27155 do 27156 IFS=$as_save_IFS 27157 test -z "$as_dir" && as_dir=. 27158 for ac_exec_ext in '' $ac_executable_extensions; do 27159 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 27160 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 27161 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27162 break 2 27163 fi 27164 done 27165 done 27166 IFS=$as_save_IFS 27167 27168 ;; 27169 esac 27170 fi 27171 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 27172 if test -n "$JAVA_CHECK"; then 27173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 27174 $as_echo "$JAVA_CHECK" >&6; } 27175 else 27176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27177 $as_echo "no" >&6; } 27178 fi 27179 27180 27181 BINARY="$JAVAC_CHECK" 27182 if test "x$JAVAC_CHECK" = x; then 27183 BINARY="$JAVA_CHECK" 27184 fi 27185 if test "x$BINARY" != x; then 27186 # So there is a java(c) binary, it might be part of a JDK. 27187 # Lets find the JDK/JRE directory by following symbolic links. 27188 # Linux/GNU systems often have links from /usr/bin/java to 27189 # /etc/alternatives/java to the real JDK binary. 27190 27191 if test "x$OPENJDK_BUILD_OS" != xwindows; then 27192 # Follow a chain of symbolic links. Use readlink 27193 # where it exists, else fall back to horribly 27194 # complicated shell code. 27195 if test "x$READLINK_TESTED" != yes; then 27196 # On MacOSX there is a readlink tool with a different 27197 # purpose than the GNU readlink tool. Check the found readlink. 27198 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 27199 if test "x$ISGNU" = x; then 27200 # A readlink that we do not know how to use. 27201 # Are there other non-GNU readlinks out there? 27202 READLINK_TESTED=yes 27203 READLINK= 27204 fi 27205 fi 27206 27207 if test "x$READLINK" != x; then 27208 BINARY=`$READLINK -f $BINARY` 27209 else 27210 # Save the current directory for restoring afterwards 27211 STARTDIR=$PWD 27212 COUNTER=0 27213 sym_link_dir=`$DIRNAME $BINARY` 27214 sym_link_file=`$BASENAME $BINARY` 27215 cd $sym_link_dir 27216 # Use -P flag to resolve symlinks in directories. 27217 cd `$THEPWDCMD -P` 27218 sym_link_dir=`$THEPWDCMD -P` 27219 # Resolve file symlinks 27220 while test $COUNTER -lt 20; do 27221 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 27222 if test "x$ISLINK" == x; then 27223 # This is not a symbolic link! We are done! 27224 break 27225 fi 27226 # Again resolve directory symlinks since the target of the just found 27227 # link could be in a different directory 27228 cd `$DIRNAME $ISLINK` 27229 sym_link_dir=`$THEPWDCMD -P` 27230 sym_link_file=`$BASENAME $ISLINK` 27231 let COUNTER=COUNTER+1 27232 done 27233 cd $STARTDIR 27234 BINARY=$sym_link_dir/$sym_link_file 27235 fi 27236 fi 27237 27238 BOOT_JDK=`dirname "$BINARY"` 27239 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 27240 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 27241 # Looks like we found ourselves an JDK 27242 BOOT_JDK_FOUND=maybe 27243 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 27244 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 27245 fi 27246 fi 27247 27248 27249 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27250 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27251 # Do we have a bin/java? 27252 if test ! -x "$BOOT_JDK/bin/java"; then 27253 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27254 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27255 BOOT_JDK_FOUND=no 27256 else 27257 # Do we have a bin/javac? 27258 if test ! -x "$BOOT_JDK/bin/javac"; then 27259 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27260 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27261 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27262 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27263 BOOT_JDK_FOUND=no 27264 else 27265 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27266 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27267 27268 # Extra M4 quote needed to protect [] in grep expression. 27269 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27270 if test "x$FOUND_CORRECT_VERSION" = x; then 27271 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27272 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27273 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27274 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27275 BOOT_JDK_FOUND=no 27276 else 27277 # We're done! :-) 27278 BOOT_JDK_FOUND=yes 27279 27280 # Only process if variable expands to non-empty 27281 27282 if test "x$BOOT_JDK" != x; then 27283 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27284 27285 # Input might be given as Windows format, start by converting to 27286 # unix format. 27287 path="$BOOT_JDK" 27288 new_path=`$CYGPATH -u "$path"` 27289 27290 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27291 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27292 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27293 # "foo.exe" is OK but "foo" is an error. 27294 # 27295 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27296 # It is also a way to make sure we got the proper file name for the real test later on. 27297 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27298 if test "x$test_shortpath" = x; then 27299 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27300 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27301 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27302 fi 27303 27304 # Call helper function which possibly converts this using DOS-style short mode. 27305 # If so, the updated path is stored in $new_path. 27306 27307 input_path="$new_path" 27308 # Check if we need to convert this using DOS-style short mode. If the path 27309 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27310 # take no chances and rewrite it. 27311 # Note: m4 eats our [], so we need to use [ and ] instead. 27312 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27313 if test "x$has_forbidden_chars" != x; then 27314 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27315 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27316 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27317 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27318 # Going to short mode and back again did indeed matter. Since short mode is 27319 # case insensitive, let's make it lowercase to improve readability. 27320 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27321 # Now convert it back to Unix-style (cygpath) 27322 input_path=`$CYGPATH -u "$shortmode_path"` 27323 new_path="$input_path" 27324 fi 27325 fi 27326 27327 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27328 if test "x$test_cygdrive_prefix" = x; then 27329 # As a simple fix, exclude /usr/bin since it's not a real path. 27330 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27331 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27332 # a path prefixed by /cygdrive for fixpath to work. 27333 new_path="$CYGWIN_ROOT_PATH$input_path" 27334 fi 27335 fi 27336 27337 27338 if test "x$path" != "x$new_path"; then 27339 BOOT_JDK="$new_path" 27340 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27341 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27342 fi 27343 27344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27345 27346 path="$BOOT_JDK" 27347 has_colon=`$ECHO $path | $GREP ^.:` 27348 new_path="$path" 27349 if test "x$has_colon" = x; then 27350 # Not in mixed or Windows style, start by that. 27351 new_path=`cmd //c echo $path` 27352 fi 27353 27354 27355 input_path="$new_path" 27356 # Check if we need to convert this using DOS-style short mode. If the path 27357 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27358 # take no chances and rewrite it. 27359 # Note: m4 eats our [], so we need to use [ and ] instead. 27360 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27361 if test "x$has_forbidden_chars" != x; then 27362 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27363 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27364 fi 27365 27366 27367 windows_path="$new_path" 27368 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27369 unix_path=`$CYGPATH -u "$windows_path"` 27370 new_path="$unix_path" 27371 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27372 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27373 new_path="$unix_path" 27374 fi 27375 27376 if test "x$path" != "x$new_path"; then 27377 BOOT_JDK="$new_path" 27378 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27379 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27380 fi 27381 27382 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27383 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27384 27385 else 27386 # We're on a unix platform. Hooray! :) 27387 path="$BOOT_JDK" 27388 has_space=`$ECHO "$path" | $GREP " "` 27389 if test "x$has_space" != x; then 27390 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27391 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27392 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27393 fi 27394 27395 # Use eval to expand a potential ~ 27396 eval path="$path" 27397 if test ! -f "$path" && test ! -d "$path"; then 27398 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27399 fi 27400 27401 if test -d "$path"; then 27402 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27403 else 27404 dir="`$DIRNAME "$path"`" 27405 base="`$BASENAME "$path"`" 27406 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27407 fi 27408 fi 27409 fi 27410 27411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27412 $as_echo_n "checking for Boot JDK... " >&6; } 27413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27414 $as_echo "$BOOT_JDK" >&6; } 27415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27416 $as_echo_n "checking Boot JDK version... " >&6; } 27417 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27419 $as_echo "$BOOT_JDK_VERSION" >&6; } 27420 fi # end check jdk version 27421 fi # end check javac 27422 fi # end check java 27423 fi # end check boot jdk found 27424 fi 27425 27426 27427 # Test: Is there a JDK installed in default, well-known locations? 27428 27429 if test "x$BOOT_JDK_FOUND" = xno; then 27430 # Now execute the test 27431 27432 if test "x$OPENJDK_TARGET_OS" = xwindows; then 27433 27434 if test "x$BOOT_JDK_FOUND" = xno; then 27435 # Now execute the test 27436 27437 if test "x$ProgramW6432" != x; then 27438 VIRTUAL_DIR="$ProgramW6432/Java" 27439 27440 windows_path="$VIRTUAL_DIR" 27441 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27442 unix_path=`$CYGPATH -u "$windows_path"` 27443 VIRTUAL_DIR="$unix_path" 27444 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27445 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27446 VIRTUAL_DIR="$unix_path" 27447 fi 27448 27449 27450 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27451 BOOT_JDK_SUFFIX="" 27452 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27453 if test "x$ALL_JDKS_FOUND" != x; then 27454 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27455 27456 if test "x$BOOT_JDK_FOUND" = xno; then 27457 # Now execute the test 27458 27459 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27460 if test -d "$BOOT_JDK"; then 27461 BOOT_JDK_FOUND=maybe 27462 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27463 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27464 fi 27465 27466 27467 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27468 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27469 # Do we have a bin/java? 27470 if test ! -x "$BOOT_JDK/bin/java"; then 27471 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27472 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27473 BOOT_JDK_FOUND=no 27474 else 27475 # Do we have a bin/javac? 27476 if test ! -x "$BOOT_JDK/bin/javac"; then 27477 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27478 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27479 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27480 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27481 BOOT_JDK_FOUND=no 27482 else 27483 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27484 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27485 27486 # Extra M4 quote needed to protect [] in grep expression. 27487 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27488 if test "x$FOUND_CORRECT_VERSION" = x; then 27489 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27490 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27491 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27492 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27493 BOOT_JDK_FOUND=no 27494 else 27495 # We're done! :-) 27496 BOOT_JDK_FOUND=yes 27497 27498 # Only process if variable expands to non-empty 27499 27500 if test "x$BOOT_JDK" != x; then 27501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27502 27503 # Input might be given as Windows format, start by converting to 27504 # unix format. 27505 path="$BOOT_JDK" 27506 new_path=`$CYGPATH -u "$path"` 27507 27508 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27509 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27510 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27511 # "foo.exe" is OK but "foo" is an error. 27512 # 27513 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27514 # It is also a way to make sure we got the proper file name for the real test later on. 27515 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27516 if test "x$test_shortpath" = x; then 27517 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27518 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27519 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27520 fi 27521 27522 # Call helper function which possibly converts this using DOS-style short mode. 27523 # If so, the updated path is stored in $new_path. 27524 27525 input_path="$new_path" 27526 # Check if we need to convert this using DOS-style short mode. If the path 27527 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27528 # take no chances and rewrite it. 27529 # Note: m4 eats our [], so we need to use [ and ] instead. 27530 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27531 if test "x$has_forbidden_chars" != x; then 27532 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27533 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27534 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27535 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27536 # Going to short mode and back again did indeed matter. Since short mode is 27537 # case insensitive, let's make it lowercase to improve readability. 27538 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27539 # Now convert it back to Unix-style (cygpath) 27540 input_path=`$CYGPATH -u "$shortmode_path"` 27541 new_path="$input_path" 27542 fi 27543 fi 27544 27545 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27546 if test "x$test_cygdrive_prefix" = x; then 27547 # As a simple fix, exclude /usr/bin since it's not a real path. 27548 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27549 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27550 # a path prefixed by /cygdrive for fixpath to work. 27551 new_path="$CYGWIN_ROOT_PATH$input_path" 27552 fi 27553 fi 27554 27555 27556 if test "x$path" != "x$new_path"; then 27557 BOOT_JDK="$new_path" 27558 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27559 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27560 fi 27561 27562 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27563 27564 path="$BOOT_JDK" 27565 has_colon=`$ECHO $path | $GREP ^.:` 27566 new_path="$path" 27567 if test "x$has_colon" = x; then 27568 # Not in mixed or Windows style, start by that. 27569 new_path=`cmd //c echo $path` 27570 fi 27571 27572 27573 input_path="$new_path" 27574 # Check if we need to convert this using DOS-style short mode. If the path 27575 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27576 # take no chances and rewrite it. 27577 # Note: m4 eats our [], so we need to use [ and ] instead. 27578 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27579 if test "x$has_forbidden_chars" != x; then 27580 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27581 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27582 fi 27583 27584 27585 windows_path="$new_path" 27586 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27587 unix_path=`$CYGPATH -u "$windows_path"` 27588 new_path="$unix_path" 27589 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27590 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27591 new_path="$unix_path" 27592 fi 27593 27594 if test "x$path" != "x$new_path"; then 27595 BOOT_JDK="$new_path" 27596 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27597 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27598 fi 27599 27600 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27601 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27602 27603 else 27604 # We're on a unix platform. Hooray! :) 27605 path="$BOOT_JDK" 27606 has_space=`$ECHO "$path" | $GREP " "` 27607 if test "x$has_space" != x; then 27608 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27609 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27610 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27611 fi 27612 27613 # Use eval to expand a potential ~ 27614 eval path="$path" 27615 if test ! -f "$path" && test ! -d "$path"; then 27616 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27617 fi 27618 27619 if test -d "$path"; then 27620 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27621 else 27622 dir="`$DIRNAME "$path"`" 27623 base="`$BASENAME "$path"`" 27624 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27625 fi 27626 fi 27627 fi 27628 27629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27630 $as_echo_n "checking for Boot JDK... " >&6; } 27631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27632 $as_echo "$BOOT_JDK" >&6; } 27633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27634 $as_echo_n "checking Boot JDK version... " >&6; } 27635 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27637 $as_echo "$BOOT_JDK_VERSION" >&6; } 27638 fi # end check jdk version 27639 fi # end check javac 27640 fi # end check java 27641 fi # end check boot jdk found 27642 fi 27643 27644 done 27645 fi 27646 27647 fi 27648 27649 27650 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27651 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27652 # Do we have a bin/java? 27653 if test ! -x "$BOOT_JDK/bin/java"; then 27654 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27655 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27656 BOOT_JDK_FOUND=no 27657 else 27658 # Do we have a bin/javac? 27659 if test ! -x "$BOOT_JDK/bin/javac"; then 27660 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27661 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27662 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27663 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27664 BOOT_JDK_FOUND=no 27665 else 27666 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27667 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27668 27669 # Extra M4 quote needed to protect [] in grep expression. 27670 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27671 if test "x$FOUND_CORRECT_VERSION" = x; then 27672 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27673 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27674 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27675 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27676 BOOT_JDK_FOUND=no 27677 else 27678 # We're done! :-) 27679 BOOT_JDK_FOUND=yes 27680 27681 # Only process if variable expands to non-empty 27682 27683 if test "x$BOOT_JDK" != x; then 27684 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27685 27686 # Input might be given as Windows format, start by converting to 27687 # unix format. 27688 path="$BOOT_JDK" 27689 new_path=`$CYGPATH -u "$path"` 27690 27691 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27692 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27693 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27694 # "foo.exe" is OK but "foo" is an error. 27695 # 27696 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27697 # It is also a way to make sure we got the proper file name for the real test later on. 27698 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27699 if test "x$test_shortpath" = x; then 27700 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27701 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27702 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27703 fi 27704 27705 # Call helper function which possibly converts this using DOS-style short mode. 27706 # If so, the updated path is stored in $new_path. 27707 27708 input_path="$new_path" 27709 # Check if we need to convert this using DOS-style short mode. If the path 27710 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27711 # take no chances and rewrite it. 27712 # Note: m4 eats our [], so we need to use [ and ] instead. 27713 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27714 if test "x$has_forbidden_chars" != x; then 27715 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27716 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27717 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27718 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27719 # Going to short mode and back again did indeed matter. Since short mode is 27720 # case insensitive, let's make it lowercase to improve readability. 27721 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27722 # Now convert it back to Unix-style (cygpath) 27723 input_path=`$CYGPATH -u "$shortmode_path"` 27724 new_path="$input_path" 27725 fi 27726 fi 27727 27728 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27729 if test "x$test_cygdrive_prefix" = x; then 27730 # As a simple fix, exclude /usr/bin since it's not a real path. 27731 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27732 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27733 # a path prefixed by /cygdrive for fixpath to work. 27734 new_path="$CYGWIN_ROOT_PATH$input_path" 27735 fi 27736 fi 27737 27738 27739 if test "x$path" != "x$new_path"; then 27740 BOOT_JDK="$new_path" 27741 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27742 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27743 fi 27744 27745 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27746 27747 path="$BOOT_JDK" 27748 has_colon=`$ECHO $path | $GREP ^.:` 27749 new_path="$path" 27750 if test "x$has_colon" = x; then 27751 # Not in mixed or Windows style, start by that. 27752 new_path=`cmd //c echo $path` 27753 fi 27754 27755 27756 input_path="$new_path" 27757 # Check if we need to convert this using DOS-style short mode. If the path 27758 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27759 # take no chances and rewrite it. 27760 # Note: m4 eats our [], so we need to use [ and ] instead. 27761 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27762 if test "x$has_forbidden_chars" != x; then 27763 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27764 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27765 fi 27766 27767 27768 windows_path="$new_path" 27769 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27770 unix_path=`$CYGPATH -u "$windows_path"` 27771 new_path="$unix_path" 27772 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27773 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27774 new_path="$unix_path" 27775 fi 27776 27777 if test "x$path" != "x$new_path"; then 27778 BOOT_JDK="$new_path" 27779 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27780 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27781 fi 27782 27783 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27784 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27785 27786 else 27787 # We're on a unix platform. Hooray! :) 27788 path="$BOOT_JDK" 27789 has_space=`$ECHO "$path" | $GREP " "` 27790 if test "x$has_space" != x; then 27791 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27792 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27793 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27794 fi 27795 27796 # Use eval to expand a potential ~ 27797 eval path="$path" 27798 if test ! -f "$path" && test ! -d "$path"; then 27799 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27800 fi 27801 27802 if test -d "$path"; then 27803 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27804 else 27805 dir="`$DIRNAME "$path"`" 27806 base="`$BASENAME "$path"`" 27807 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27808 fi 27809 fi 27810 fi 27811 27812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27813 $as_echo_n "checking for Boot JDK... " >&6; } 27814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27815 $as_echo "$BOOT_JDK" >&6; } 27816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27817 $as_echo_n "checking Boot JDK version... " >&6; } 27818 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27820 $as_echo "$BOOT_JDK_VERSION" >&6; } 27821 fi # end check jdk version 27822 fi # end check javac 27823 fi # end check java 27824 fi # end check boot jdk found 27825 fi 27826 27827 27828 if test "x$BOOT_JDK_FOUND" = xno; then 27829 # Now execute the test 27830 27831 if test "x$PROGRAMW6432" != x; then 27832 VIRTUAL_DIR="$PROGRAMW6432/Java" 27833 27834 windows_path="$VIRTUAL_DIR" 27835 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27836 unix_path=`$CYGPATH -u "$windows_path"` 27837 VIRTUAL_DIR="$unix_path" 27838 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27839 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27840 VIRTUAL_DIR="$unix_path" 27841 fi 27842 27843 27844 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27845 BOOT_JDK_SUFFIX="" 27846 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27847 if test "x$ALL_JDKS_FOUND" != x; then 27848 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27849 27850 if test "x$BOOT_JDK_FOUND" = xno; then 27851 # Now execute the test 27852 27853 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27854 if test -d "$BOOT_JDK"; then 27855 BOOT_JDK_FOUND=maybe 27856 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27857 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27858 fi 27859 27860 27861 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27862 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27863 # Do we have a bin/java? 27864 if test ! -x "$BOOT_JDK/bin/java"; then 27865 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27866 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27867 BOOT_JDK_FOUND=no 27868 else 27869 # Do we have a bin/javac? 27870 if test ! -x "$BOOT_JDK/bin/javac"; then 27871 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27872 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27873 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27874 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27875 BOOT_JDK_FOUND=no 27876 else 27877 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27878 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27879 27880 # Extra M4 quote needed to protect [] in grep expression. 27881 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27882 if test "x$FOUND_CORRECT_VERSION" = x; then 27883 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27884 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27885 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27886 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27887 BOOT_JDK_FOUND=no 27888 else 27889 # We're done! :-) 27890 BOOT_JDK_FOUND=yes 27891 27892 # Only process if variable expands to non-empty 27893 27894 if test "x$BOOT_JDK" != x; then 27895 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27896 27897 # Input might be given as Windows format, start by converting to 27898 # unix format. 27899 path="$BOOT_JDK" 27900 new_path=`$CYGPATH -u "$path"` 27901 27902 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27903 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27904 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27905 # "foo.exe" is OK but "foo" is an error. 27906 # 27907 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27908 # It is also a way to make sure we got the proper file name for the real test later on. 27909 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27910 if test "x$test_shortpath" = x; then 27911 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27912 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27913 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27914 fi 27915 27916 # Call helper function which possibly converts this using DOS-style short mode. 27917 # If so, the updated path is stored in $new_path. 27918 27919 input_path="$new_path" 27920 # Check if we need to convert this using DOS-style short mode. If the path 27921 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27922 # take no chances and rewrite it. 27923 # Note: m4 eats our [], so we need to use [ and ] instead. 27924 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27925 if test "x$has_forbidden_chars" != x; then 27926 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27927 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27928 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27929 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27930 # Going to short mode and back again did indeed matter. Since short mode is 27931 # case insensitive, let's make it lowercase to improve readability. 27932 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27933 # Now convert it back to Unix-style (cygpath) 27934 input_path=`$CYGPATH -u "$shortmode_path"` 27935 new_path="$input_path" 27936 fi 27937 fi 27938 27939 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27940 if test "x$test_cygdrive_prefix" = x; then 27941 # As a simple fix, exclude /usr/bin since it's not a real path. 27942 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27943 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27944 # a path prefixed by /cygdrive for fixpath to work. 27945 new_path="$CYGWIN_ROOT_PATH$input_path" 27946 fi 27947 fi 27948 27949 27950 if test "x$path" != "x$new_path"; then 27951 BOOT_JDK="$new_path" 27952 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27953 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27954 fi 27955 27956 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27957 27958 path="$BOOT_JDK" 27959 has_colon=`$ECHO $path | $GREP ^.:` 27960 new_path="$path" 27961 if test "x$has_colon" = x; then 27962 # Not in mixed or Windows style, start by that. 27963 new_path=`cmd //c echo $path` 27964 fi 27965 27966 27967 input_path="$new_path" 27968 # Check if we need to convert this using DOS-style short mode. If the path 27969 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27970 # take no chances and rewrite it. 27971 # Note: m4 eats our [], so we need to use [ and ] instead. 27972 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27973 if test "x$has_forbidden_chars" != x; then 27974 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27975 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27976 fi 27977 27978 27979 windows_path="$new_path" 27980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27981 unix_path=`$CYGPATH -u "$windows_path"` 27982 new_path="$unix_path" 27983 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27984 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27985 new_path="$unix_path" 27986 fi 27987 27988 if test "x$path" != "x$new_path"; then 27989 BOOT_JDK="$new_path" 27990 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27991 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27992 fi 27993 27994 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27995 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27996 27997 else 27998 # We're on a unix platform. Hooray! :) 27999 path="$BOOT_JDK" 28000 has_space=`$ECHO "$path" | $GREP " "` 28001 if test "x$has_space" != x; then 28002 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28003 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28004 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28005 fi 28006 28007 # Use eval to expand a potential ~ 28008 eval path="$path" 28009 if test ! -f "$path" && test ! -d "$path"; then 28010 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28011 fi 28012 28013 if test -d "$path"; then 28014 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28015 else 28016 dir="`$DIRNAME "$path"`" 28017 base="`$BASENAME "$path"`" 28018 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28019 fi 28020 fi 28021 fi 28022 28023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28024 $as_echo_n "checking for Boot JDK... " >&6; } 28025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28026 $as_echo "$BOOT_JDK" >&6; } 28027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28028 $as_echo_n "checking Boot JDK version... " >&6; } 28029 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28031 $as_echo "$BOOT_JDK_VERSION" >&6; } 28032 fi # end check jdk version 28033 fi # end check javac 28034 fi # end check java 28035 fi # end check boot jdk found 28036 fi 28037 28038 done 28039 fi 28040 28041 fi 28042 28043 28044 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28045 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28046 # Do we have a bin/java? 28047 if test ! -x "$BOOT_JDK/bin/java"; then 28048 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28049 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28050 BOOT_JDK_FOUND=no 28051 else 28052 # Do we have a bin/javac? 28053 if test ! -x "$BOOT_JDK/bin/javac"; then 28054 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28055 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28056 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28057 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28058 BOOT_JDK_FOUND=no 28059 else 28060 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28061 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28062 28063 # Extra M4 quote needed to protect [] in grep expression. 28064 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28065 if test "x$FOUND_CORRECT_VERSION" = x; then 28066 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28067 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28068 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28069 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28070 BOOT_JDK_FOUND=no 28071 else 28072 # We're done! :-) 28073 BOOT_JDK_FOUND=yes 28074 28075 # Only process if variable expands to non-empty 28076 28077 if test "x$BOOT_JDK" != x; then 28078 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28079 28080 # Input might be given as Windows format, start by converting to 28081 # unix format. 28082 path="$BOOT_JDK" 28083 new_path=`$CYGPATH -u "$path"` 28084 28085 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28086 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28087 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28088 # "foo.exe" is OK but "foo" is an error. 28089 # 28090 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28091 # It is also a way to make sure we got the proper file name for the real test later on. 28092 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28093 if test "x$test_shortpath" = x; then 28094 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28095 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28096 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28097 fi 28098 28099 # Call helper function which possibly converts this using DOS-style short mode. 28100 # If so, the updated path is stored in $new_path. 28101 28102 input_path="$new_path" 28103 # Check if we need to convert this using DOS-style short mode. If the path 28104 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28105 # take no chances and rewrite it. 28106 # Note: m4 eats our [], so we need to use [ and ] instead. 28107 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28108 if test "x$has_forbidden_chars" != x; then 28109 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28110 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28111 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28112 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28113 # Going to short mode and back again did indeed matter. Since short mode is 28114 # case insensitive, let's make it lowercase to improve readability. 28115 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28116 # Now convert it back to Unix-style (cygpath) 28117 input_path=`$CYGPATH -u "$shortmode_path"` 28118 new_path="$input_path" 28119 fi 28120 fi 28121 28122 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28123 if test "x$test_cygdrive_prefix" = x; then 28124 # As a simple fix, exclude /usr/bin since it's not a real path. 28125 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28126 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28127 # a path prefixed by /cygdrive for fixpath to work. 28128 new_path="$CYGWIN_ROOT_PATH$input_path" 28129 fi 28130 fi 28131 28132 28133 if test "x$path" != "x$new_path"; then 28134 BOOT_JDK="$new_path" 28135 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28136 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28137 fi 28138 28139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28140 28141 path="$BOOT_JDK" 28142 has_colon=`$ECHO $path | $GREP ^.:` 28143 new_path="$path" 28144 if test "x$has_colon" = x; then 28145 # Not in mixed or Windows style, start by that. 28146 new_path=`cmd //c echo $path` 28147 fi 28148 28149 28150 input_path="$new_path" 28151 # Check if we need to convert this using DOS-style short mode. If the path 28152 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28153 # take no chances and rewrite it. 28154 # Note: m4 eats our [], so we need to use [ and ] instead. 28155 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28156 if test "x$has_forbidden_chars" != x; then 28157 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28158 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28159 fi 28160 28161 28162 windows_path="$new_path" 28163 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28164 unix_path=`$CYGPATH -u "$windows_path"` 28165 new_path="$unix_path" 28166 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28167 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28168 new_path="$unix_path" 28169 fi 28170 28171 if test "x$path" != "x$new_path"; then 28172 BOOT_JDK="$new_path" 28173 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28174 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28175 fi 28176 28177 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28178 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28179 28180 else 28181 # We're on a unix platform. Hooray! :) 28182 path="$BOOT_JDK" 28183 has_space=`$ECHO "$path" | $GREP " "` 28184 if test "x$has_space" != x; then 28185 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28186 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28187 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28188 fi 28189 28190 # Use eval to expand a potential ~ 28191 eval path="$path" 28192 if test ! -f "$path" && test ! -d "$path"; then 28193 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28194 fi 28195 28196 if test -d "$path"; then 28197 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28198 else 28199 dir="`$DIRNAME "$path"`" 28200 base="`$BASENAME "$path"`" 28201 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28202 fi 28203 fi 28204 fi 28205 28206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28207 $as_echo_n "checking for Boot JDK... " >&6; } 28208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28209 $as_echo "$BOOT_JDK" >&6; } 28210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28211 $as_echo_n "checking Boot JDK version... " >&6; } 28212 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28214 $as_echo "$BOOT_JDK_VERSION" >&6; } 28215 fi # end check jdk version 28216 fi # end check javac 28217 fi # end check java 28218 fi # end check boot jdk found 28219 fi 28220 28221 28222 if test "x$BOOT_JDK_FOUND" = xno; then 28223 # Now execute the test 28224 28225 if test "x$PROGRAMFILES" != x; then 28226 VIRTUAL_DIR="$PROGRAMFILES/Java" 28227 28228 windows_path="$VIRTUAL_DIR" 28229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28230 unix_path=`$CYGPATH -u "$windows_path"` 28231 VIRTUAL_DIR="$unix_path" 28232 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28233 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28234 VIRTUAL_DIR="$unix_path" 28235 fi 28236 28237 28238 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28239 BOOT_JDK_SUFFIX="" 28240 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28241 if test "x$ALL_JDKS_FOUND" != x; then 28242 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28243 28244 if test "x$BOOT_JDK_FOUND" = xno; then 28245 # Now execute the test 28246 28247 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28248 if test -d "$BOOT_JDK"; then 28249 BOOT_JDK_FOUND=maybe 28250 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28251 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28252 fi 28253 28254 28255 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28256 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28257 # Do we have a bin/java? 28258 if test ! -x "$BOOT_JDK/bin/java"; then 28259 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28260 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28261 BOOT_JDK_FOUND=no 28262 else 28263 # Do we have a bin/javac? 28264 if test ! -x "$BOOT_JDK/bin/javac"; then 28265 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28266 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28267 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28268 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28269 BOOT_JDK_FOUND=no 28270 else 28271 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28272 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28273 28274 # Extra M4 quote needed to protect [] in grep expression. 28275 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28276 if test "x$FOUND_CORRECT_VERSION" = x; then 28277 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28278 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28279 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28280 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28281 BOOT_JDK_FOUND=no 28282 else 28283 # We're done! :-) 28284 BOOT_JDK_FOUND=yes 28285 28286 # Only process if variable expands to non-empty 28287 28288 if test "x$BOOT_JDK" != x; then 28289 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28290 28291 # Input might be given as Windows format, start by converting to 28292 # unix format. 28293 path="$BOOT_JDK" 28294 new_path=`$CYGPATH -u "$path"` 28295 28296 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28297 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28298 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28299 # "foo.exe" is OK but "foo" is an error. 28300 # 28301 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28302 # It is also a way to make sure we got the proper file name for the real test later on. 28303 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28304 if test "x$test_shortpath" = x; then 28305 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28306 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28307 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28308 fi 28309 28310 # Call helper function which possibly converts this using DOS-style short mode. 28311 # If so, the updated path is stored in $new_path. 28312 28313 input_path="$new_path" 28314 # Check if we need to convert this using DOS-style short mode. If the path 28315 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28316 # take no chances and rewrite it. 28317 # Note: m4 eats our [], so we need to use [ and ] instead. 28318 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28319 if test "x$has_forbidden_chars" != x; then 28320 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28321 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28322 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28323 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28324 # Going to short mode and back again did indeed matter. Since short mode is 28325 # case insensitive, let's make it lowercase to improve readability. 28326 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28327 # Now convert it back to Unix-style (cygpath) 28328 input_path=`$CYGPATH -u "$shortmode_path"` 28329 new_path="$input_path" 28330 fi 28331 fi 28332 28333 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28334 if test "x$test_cygdrive_prefix" = x; then 28335 # As a simple fix, exclude /usr/bin since it's not a real path. 28336 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28337 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28338 # a path prefixed by /cygdrive for fixpath to work. 28339 new_path="$CYGWIN_ROOT_PATH$input_path" 28340 fi 28341 fi 28342 28343 28344 if test "x$path" != "x$new_path"; then 28345 BOOT_JDK="$new_path" 28346 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28347 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28348 fi 28349 28350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28351 28352 path="$BOOT_JDK" 28353 has_colon=`$ECHO $path | $GREP ^.:` 28354 new_path="$path" 28355 if test "x$has_colon" = x; then 28356 # Not in mixed or Windows style, start by that. 28357 new_path=`cmd //c echo $path` 28358 fi 28359 28360 28361 input_path="$new_path" 28362 # Check if we need to convert this using DOS-style short mode. If the path 28363 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28364 # take no chances and rewrite it. 28365 # Note: m4 eats our [], so we need to use [ and ] instead. 28366 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28367 if test "x$has_forbidden_chars" != x; then 28368 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28369 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28370 fi 28371 28372 28373 windows_path="$new_path" 28374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28375 unix_path=`$CYGPATH -u "$windows_path"` 28376 new_path="$unix_path" 28377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28379 new_path="$unix_path" 28380 fi 28381 28382 if test "x$path" != "x$new_path"; then 28383 BOOT_JDK="$new_path" 28384 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28385 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28386 fi 28387 28388 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28389 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28390 28391 else 28392 # We're on a unix platform. Hooray! :) 28393 path="$BOOT_JDK" 28394 has_space=`$ECHO "$path" | $GREP " "` 28395 if test "x$has_space" != x; then 28396 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28397 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28398 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28399 fi 28400 28401 # Use eval to expand a potential ~ 28402 eval path="$path" 28403 if test ! -f "$path" && test ! -d "$path"; then 28404 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28405 fi 28406 28407 if test -d "$path"; then 28408 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28409 else 28410 dir="`$DIRNAME "$path"`" 28411 base="`$BASENAME "$path"`" 28412 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28413 fi 28414 fi 28415 fi 28416 28417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28418 $as_echo_n "checking for Boot JDK... " >&6; } 28419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28420 $as_echo "$BOOT_JDK" >&6; } 28421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28422 $as_echo_n "checking Boot JDK version... " >&6; } 28423 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28425 $as_echo "$BOOT_JDK_VERSION" >&6; } 28426 fi # end check jdk version 28427 fi # end check javac 28428 fi # end check java 28429 fi # end check boot jdk found 28430 fi 28431 28432 done 28433 fi 28434 28435 fi 28436 28437 28438 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28439 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28440 # Do we have a bin/java? 28441 if test ! -x "$BOOT_JDK/bin/java"; then 28442 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28443 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28444 BOOT_JDK_FOUND=no 28445 else 28446 # Do we have a bin/javac? 28447 if test ! -x "$BOOT_JDK/bin/javac"; then 28448 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28449 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28450 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28451 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28452 BOOT_JDK_FOUND=no 28453 else 28454 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28455 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28456 28457 # Extra M4 quote needed to protect [] in grep expression. 28458 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28459 if test "x$FOUND_CORRECT_VERSION" = x; then 28460 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28461 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28462 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28463 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28464 BOOT_JDK_FOUND=no 28465 else 28466 # We're done! :-) 28467 BOOT_JDK_FOUND=yes 28468 28469 # Only process if variable expands to non-empty 28470 28471 if test "x$BOOT_JDK" != x; then 28472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28473 28474 # Input might be given as Windows format, start by converting to 28475 # unix format. 28476 path="$BOOT_JDK" 28477 new_path=`$CYGPATH -u "$path"` 28478 28479 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28480 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28481 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28482 # "foo.exe" is OK but "foo" is an error. 28483 # 28484 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28485 # It is also a way to make sure we got the proper file name for the real test later on. 28486 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28487 if test "x$test_shortpath" = x; then 28488 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28489 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28490 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28491 fi 28492 28493 # Call helper function which possibly converts this using DOS-style short mode. 28494 # If so, the updated path is stored in $new_path. 28495 28496 input_path="$new_path" 28497 # Check if we need to convert this using DOS-style short mode. If the path 28498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28499 # take no chances and rewrite it. 28500 # Note: m4 eats our [], so we need to use [ and ] instead. 28501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28502 if test "x$has_forbidden_chars" != x; then 28503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28504 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28505 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28506 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28507 # Going to short mode and back again did indeed matter. Since short mode is 28508 # case insensitive, let's make it lowercase to improve readability. 28509 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28510 # Now convert it back to Unix-style (cygpath) 28511 input_path=`$CYGPATH -u "$shortmode_path"` 28512 new_path="$input_path" 28513 fi 28514 fi 28515 28516 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28517 if test "x$test_cygdrive_prefix" = x; then 28518 # As a simple fix, exclude /usr/bin since it's not a real path. 28519 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28520 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28521 # a path prefixed by /cygdrive for fixpath to work. 28522 new_path="$CYGWIN_ROOT_PATH$input_path" 28523 fi 28524 fi 28525 28526 28527 if test "x$path" != "x$new_path"; then 28528 BOOT_JDK="$new_path" 28529 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28530 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28531 fi 28532 28533 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28534 28535 path="$BOOT_JDK" 28536 has_colon=`$ECHO $path | $GREP ^.:` 28537 new_path="$path" 28538 if test "x$has_colon" = x; then 28539 # Not in mixed or Windows style, start by that. 28540 new_path=`cmd //c echo $path` 28541 fi 28542 28543 28544 input_path="$new_path" 28545 # Check if we need to convert this using DOS-style short mode. If the path 28546 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28547 # take no chances and rewrite it. 28548 # Note: m4 eats our [], so we need to use [ and ] instead. 28549 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28550 if test "x$has_forbidden_chars" != x; then 28551 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28552 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28553 fi 28554 28555 28556 windows_path="$new_path" 28557 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28558 unix_path=`$CYGPATH -u "$windows_path"` 28559 new_path="$unix_path" 28560 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28561 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28562 new_path="$unix_path" 28563 fi 28564 28565 if test "x$path" != "x$new_path"; then 28566 BOOT_JDK="$new_path" 28567 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28568 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28569 fi 28570 28571 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28572 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28573 28574 else 28575 # We're on a unix platform. Hooray! :) 28576 path="$BOOT_JDK" 28577 has_space=`$ECHO "$path" | $GREP " "` 28578 if test "x$has_space" != x; then 28579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28580 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28581 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28582 fi 28583 28584 # Use eval to expand a potential ~ 28585 eval path="$path" 28586 if test ! -f "$path" && test ! -d "$path"; then 28587 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28588 fi 28589 28590 if test -d "$path"; then 28591 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28592 else 28593 dir="`$DIRNAME "$path"`" 28594 base="`$BASENAME "$path"`" 28595 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28596 fi 28597 fi 28598 fi 28599 28600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28601 $as_echo_n "checking for Boot JDK... " >&6; } 28602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28603 $as_echo "$BOOT_JDK" >&6; } 28604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28605 $as_echo_n "checking Boot JDK version... " >&6; } 28606 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28608 $as_echo "$BOOT_JDK_VERSION" >&6; } 28609 fi # end check jdk version 28610 fi # end check javac 28611 fi # end check java 28612 fi # end check boot jdk found 28613 fi 28614 28615 28616 if test "x$BOOT_JDK_FOUND" = xno; then 28617 # Now execute the test 28618 28619 if test "x$ProgramFiles" != x; then 28620 VIRTUAL_DIR="$ProgramFiles/Java" 28621 28622 windows_path="$VIRTUAL_DIR" 28623 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28624 unix_path=`$CYGPATH -u "$windows_path"` 28625 VIRTUAL_DIR="$unix_path" 28626 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28627 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28628 VIRTUAL_DIR="$unix_path" 28629 fi 28630 28631 28632 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28633 BOOT_JDK_SUFFIX="" 28634 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28635 if test "x$ALL_JDKS_FOUND" != x; then 28636 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28637 28638 if test "x$BOOT_JDK_FOUND" = xno; then 28639 # Now execute the test 28640 28641 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28642 if test -d "$BOOT_JDK"; then 28643 BOOT_JDK_FOUND=maybe 28644 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28645 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28646 fi 28647 28648 28649 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28650 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28651 # Do we have a bin/java? 28652 if test ! -x "$BOOT_JDK/bin/java"; then 28653 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28654 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28655 BOOT_JDK_FOUND=no 28656 else 28657 # Do we have a bin/javac? 28658 if test ! -x "$BOOT_JDK/bin/javac"; then 28659 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28660 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28661 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28662 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28663 BOOT_JDK_FOUND=no 28664 else 28665 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28666 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28667 28668 # Extra M4 quote needed to protect [] in grep expression. 28669 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28670 if test "x$FOUND_CORRECT_VERSION" = x; then 28671 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28672 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28673 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28674 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28675 BOOT_JDK_FOUND=no 28676 else 28677 # We're done! :-) 28678 BOOT_JDK_FOUND=yes 28679 28680 # Only process if variable expands to non-empty 28681 28682 if test "x$BOOT_JDK" != x; then 28683 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28684 28685 # Input might be given as Windows format, start by converting to 28686 # unix format. 28687 path="$BOOT_JDK" 28688 new_path=`$CYGPATH -u "$path"` 28689 28690 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28691 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28692 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28693 # "foo.exe" is OK but "foo" is an error. 28694 # 28695 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28696 # It is also a way to make sure we got the proper file name for the real test later on. 28697 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28698 if test "x$test_shortpath" = x; then 28699 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28700 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28701 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28702 fi 28703 28704 # Call helper function which possibly converts this using DOS-style short mode. 28705 # If so, the updated path is stored in $new_path. 28706 28707 input_path="$new_path" 28708 # Check if we need to convert this using DOS-style short mode. If the path 28709 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28710 # take no chances and rewrite it. 28711 # Note: m4 eats our [], so we need to use [ and ] instead. 28712 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28713 if test "x$has_forbidden_chars" != x; then 28714 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28715 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28716 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28717 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28718 # Going to short mode and back again did indeed matter. Since short mode is 28719 # case insensitive, let's make it lowercase to improve readability. 28720 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28721 # Now convert it back to Unix-style (cygpath) 28722 input_path=`$CYGPATH -u "$shortmode_path"` 28723 new_path="$input_path" 28724 fi 28725 fi 28726 28727 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28728 if test "x$test_cygdrive_prefix" = x; then 28729 # As a simple fix, exclude /usr/bin since it's not a real path. 28730 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28731 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28732 # a path prefixed by /cygdrive for fixpath to work. 28733 new_path="$CYGWIN_ROOT_PATH$input_path" 28734 fi 28735 fi 28736 28737 28738 if test "x$path" != "x$new_path"; then 28739 BOOT_JDK="$new_path" 28740 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28741 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28742 fi 28743 28744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28745 28746 path="$BOOT_JDK" 28747 has_colon=`$ECHO $path | $GREP ^.:` 28748 new_path="$path" 28749 if test "x$has_colon" = x; then 28750 # Not in mixed or Windows style, start by that. 28751 new_path=`cmd //c echo $path` 28752 fi 28753 28754 28755 input_path="$new_path" 28756 # Check if we need to convert this using DOS-style short mode. If the path 28757 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28758 # take no chances and rewrite it. 28759 # Note: m4 eats our [], so we need to use [ and ] instead. 28760 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28761 if test "x$has_forbidden_chars" != x; then 28762 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28763 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28764 fi 28765 28766 28767 windows_path="$new_path" 28768 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28769 unix_path=`$CYGPATH -u "$windows_path"` 28770 new_path="$unix_path" 28771 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28772 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28773 new_path="$unix_path" 28774 fi 28775 28776 if test "x$path" != "x$new_path"; then 28777 BOOT_JDK="$new_path" 28778 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28779 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28780 fi 28781 28782 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28783 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28784 28785 else 28786 # We're on a unix platform. Hooray! :) 28787 path="$BOOT_JDK" 28788 has_space=`$ECHO "$path" | $GREP " "` 28789 if test "x$has_space" != x; then 28790 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28791 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28792 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28793 fi 28794 28795 # Use eval to expand a potential ~ 28796 eval path="$path" 28797 if test ! -f "$path" && test ! -d "$path"; then 28798 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28799 fi 28800 28801 if test -d "$path"; then 28802 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28803 else 28804 dir="`$DIRNAME "$path"`" 28805 base="`$BASENAME "$path"`" 28806 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28807 fi 28808 fi 28809 fi 28810 28811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28812 $as_echo_n "checking for Boot JDK... " >&6; } 28813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28814 $as_echo "$BOOT_JDK" >&6; } 28815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28816 $as_echo_n "checking Boot JDK version... " >&6; } 28817 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28819 $as_echo "$BOOT_JDK_VERSION" >&6; } 28820 fi # end check jdk version 28821 fi # end check javac 28822 fi # end check java 28823 fi # end check boot jdk found 28824 fi 28825 28826 done 28827 fi 28828 28829 fi 28830 28831 28832 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28833 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28834 # Do we have a bin/java? 28835 if test ! -x "$BOOT_JDK/bin/java"; then 28836 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28837 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28838 BOOT_JDK_FOUND=no 28839 else 28840 # Do we have a bin/javac? 28841 if test ! -x "$BOOT_JDK/bin/javac"; then 28842 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28843 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28844 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28845 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28846 BOOT_JDK_FOUND=no 28847 else 28848 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28849 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28850 28851 # Extra M4 quote needed to protect [] in grep expression. 28852 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28853 if test "x$FOUND_CORRECT_VERSION" = x; then 28854 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28855 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28856 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28857 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28858 BOOT_JDK_FOUND=no 28859 else 28860 # We're done! :-) 28861 BOOT_JDK_FOUND=yes 28862 28863 # Only process if variable expands to non-empty 28864 28865 if test "x$BOOT_JDK" != x; then 28866 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28867 28868 # Input might be given as Windows format, start by converting to 28869 # unix format. 28870 path="$BOOT_JDK" 28871 new_path=`$CYGPATH -u "$path"` 28872 28873 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28874 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28875 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28876 # "foo.exe" is OK but "foo" is an error. 28877 # 28878 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28879 # It is also a way to make sure we got the proper file name for the real test later on. 28880 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28881 if test "x$test_shortpath" = x; then 28882 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28883 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28884 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28885 fi 28886 28887 # Call helper function which possibly converts this using DOS-style short mode. 28888 # If so, the updated path is stored in $new_path. 28889 28890 input_path="$new_path" 28891 # Check if we need to convert this using DOS-style short mode. If the path 28892 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28893 # take no chances and rewrite it. 28894 # Note: m4 eats our [], so we need to use [ and ] instead. 28895 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28896 if test "x$has_forbidden_chars" != x; then 28897 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28898 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28899 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28900 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28901 # Going to short mode and back again did indeed matter. Since short mode is 28902 # case insensitive, let's make it lowercase to improve readability. 28903 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28904 # Now convert it back to Unix-style (cygpath) 28905 input_path=`$CYGPATH -u "$shortmode_path"` 28906 new_path="$input_path" 28907 fi 28908 fi 28909 28910 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28911 if test "x$test_cygdrive_prefix" = x; then 28912 # As a simple fix, exclude /usr/bin since it's not a real path. 28913 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28914 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28915 # a path prefixed by /cygdrive for fixpath to work. 28916 new_path="$CYGWIN_ROOT_PATH$input_path" 28917 fi 28918 fi 28919 28920 28921 if test "x$path" != "x$new_path"; then 28922 BOOT_JDK="$new_path" 28923 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28924 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28925 fi 28926 28927 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28928 28929 path="$BOOT_JDK" 28930 has_colon=`$ECHO $path | $GREP ^.:` 28931 new_path="$path" 28932 if test "x$has_colon" = x; then 28933 # Not in mixed or Windows style, start by that. 28934 new_path=`cmd //c echo $path` 28935 fi 28936 28937 28938 input_path="$new_path" 28939 # Check if we need to convert this using DOS-style short mode. If the path 28940 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28941 # take no chances and rewrite it. 28942 # Note: m4 eats our [], so we need to use [ and ] instead. 28943 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28944 if test "x$has_forbidden_chars" != x; then 28945 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28946 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28947 fi 28948 28949 28950 windows_path="$new_path" 28951 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28952 unix_path=`$CYGPATH -u "$windows_path"` 28953 new_path="$unix_path" 28954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28955 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28956 new_path="$unix_path" 28957 fi 28958 28959 if test "x$path" != "x$new_path"; then 28960 BOOT_JDK="$new_path" 28961 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28962 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28963 fi 28964 28965 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28966 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28967 28968 else 28969 # We're on a unix platform. Hooray! :) 28970 path="$BOOT_JDK" 28971 has_space=`$ECHO "$path" | $GREP " "` 28972 if test "x$has_space" != x; then 28973 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28974 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28975 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28976 fi 28977 28978 # Use eval to expand a potential ~ 28979 eval path="$path" 28980 if test ! -f "$path" && test ! -d "$path"; then 28981 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28982 fi 28983 28984 if test -d "$path"; then 28985 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28986 else 28987 dir="`$DIRNAME "$path"`" 28988 base="`$BASENAME "$path"`" 28989 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28990 fi 28991 fi 28992 fi 28993 28994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28995 $as_echo_n "checking for Boot JDK... " >&6; } 28996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28997 $as_echo "$BOOT_JDK" >&6; } 28998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28999 $as_echo_n "checking Boot JDK version... " >&6; } 29000 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29002 $as_echo "$BOOT_JDK_VERSION" >&6; } 29003 fi # end check jdk version 29004 fi # end check javac 29005 fi # end check java 29006 fi # end check boot jdk found 29007 fi 29008 29009 29010 if test "x$BOOT_JDK_FOUND" = xno; then 29011 # Now execute the test 29012 29013 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 29014 BOOT_JDK_SUFFIX="" 29015 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29016 if test "x$ALL_JDKS_FOUND" != x; then 29017 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29018 29019 if test "x$BOOT_JDK_FOUND" = xno; then 29020 # Now execute the test 29021 29022 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29023 if test -d "$BOOT_JDK"; then 29024 BOOT_JDK_FOUND=maybe 29025 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29026 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29027 fi 29028 29029 29030 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29031 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29032 # Do we have a bin/java? 29033 if test ! -x "$BOOT_JDK/bin/java"; then 29034 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29035 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29036 BOOT_JDK_FOUND=no 29037 else 29038 # Do we have a bin/javac? 29039 if test ! -x "$BOOT_JDK/bin/javac"; then 29040 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29041 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29042 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29043 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29044 BOOT_JDK_FOUND=no 29045 else 29046 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29047 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29048 29049 # Extra M4 quote needed to protect [] in grep expression. 29050 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29051 if test "x$FOUND_CORRECT_VERSION" = x; then 29052 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29053 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29054 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29055 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29056 BOOT_JDK_FOUND=no 29057 else 29058 # We're done! :-) 29059 BOOT_JDK_FOUND=yes 29060 29061 # Only process if variable expands to non-empty 29062 29063 if test "x$BOOT_JDK" != x; then 29064 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29065 29066 # Input might be given as Windows format, start by converting to 29067 # unix format. 29068 path="$BOOT_JDK" 29069 new_path=`$CYGPATH -u "$path"` 29070 29071 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29072 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29073 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29074 # "foo.exe" is OK but "foo" is an error. 29075 # 29076 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29077 # It is also a way to make sure we got the proper file name for the real test later on. 29078 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29079 if test "x$test_shortpath" = x; then 29080 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29081 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29082 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29083 fi 29084 29085 # Call helper function which possibly converts this using DOS-style short mode. 29086 # If so, the updated path is stored in $new_path. 29087 29088 input_path="$new_path" 29089 # Check if we need to convert this using DOS-style short mode. If the path 29090 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29091 # take no chances and rewrite it. 29092 # Note: m4 eats our [], so we need to use [ and ] instead. 29093 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29094 if test "x$has_forbidden_chars" != x; then 29095 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29096 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29097 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29098 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29099 # Going to short mode and back again did indeed matter. Since short mode is 29100 # case insensitive, let's make it lowercase to improve readability. 29101 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29102 # Now convert it back to Unix-style (cygpath) 29103 input_path=`$CYGPATH -u "$shortmode_path"` 29104 new_path="$input_path" 29105 fi 29106 fi 29107 29108 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29109 if test "x$test_cygdrive_prefix" = x; then 29110 # As a simple fix, exclude /usr/bin since it's not a real path. 29111 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29112 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29113 # a path prefixed by /cygdrive for fixpath to work. 29114 new_path="$CYGWIN_ROOT_PATH$input_path" 29115 fi 29116 fi 29117 29118 29119 if test "x$path" != "x$new_path"; then 29120 BOOT_JDK="$new_path" 29121 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29122 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29123 fi 29124 29125 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29126 29127 path="$BOOT_JDK" 29128 has_colon=`$ECHO $path | $GREP ^.:` 29129 new_path="$path" 29130 if test "x$has_colon" = x; then 29131 # Not in mixed or Windows style, start by that. 29132 new_path=`cmd //c echo $path` 29133 fi 29134 29135 29136 input_path="$new_path" 29137 # Check if we need to convert this using DOS-style short mode. If the path 29138 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29139 # take no chances and rewrite it. 29140 # Note: m4 eats our [], so we need to use [ and ] instead. 29141 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29142 if test "x$has_forbidden_chars" != x; then 29143 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29144 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29145 fi 29146 29147 29148 windows_path="$new_path" 29149 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29150 unix_path=`$CYGPATH -u "$windows_path"` 29151 new_path="$unix_path" 29152 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29153 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29154 new_path="$unix_path" 29155 fi 29156 29157 if test "x$path" != "x$new_path"; then 29158 BOOT_JDK="$new_path" 29159 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29160 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29161 fi 29162 29163 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29164 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29165 29166 else 29167 # We're on a unix platform. Hooray! :) 29168 path="$BOOT_JDK" 29169 has_space=`$ECHO "$path" | $GREP " "` 29170 if test "x$has_space" != x; then 29171 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29172 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29173 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29174 fi 29175 29176 # Use eval to expand a potential ~ 29177 eval path="$path" 29178 if test ! -f "$path" && test ! -d "$path"; then 29179 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29180 fi 29181 29182 if test -d "$path"; then 29183 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29184 else 29185 dir="`$DIRNAME "$path"`" 29186 base="`$BASENAME "$path"`" 29187 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29188 fi 29189 fi 29190 fi 29191 29192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29193 $as_echo_n "checking for Boot JDK... " >&6; } 29194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29195 $as_echo "$BOOT_JDK" >&6; } 29196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29197 $as_echo_n "checking Boot JDK version... " >&6; } 29198 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29200 $as_echo "$BOOT_JDK_VERSION" >&6; } 29201 fi # end check jdk version 29202 fi # end check javac 29203 fi # end check java 29204 fi # end check boot jdk found 29205 fi 29206 29207 done 29208 fi 29209 29210 29211 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29212 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29213 # Do we have a bin/java? 29214 if test ! -x "$BOOT_JDK/bin/java"; then 29215 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29216 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29217 BOOT_JDK_FOUND=no 29218 else 29219 # Do we have a bin/javac? 29220 if test ! -x "$BOOT_JDK/bin/javac"; then 29221 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29222 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29223 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29224 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29225 BOOT_JDK_FOUND=no 29226 else 29227 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29228 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29229 29230 # Extra M4 quote needed to protect [] in grep expression. 29231 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29232 if test "x$FOUND_CORRECT_VERSION" = x; then 29233 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29234 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29235 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29236 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29237 BOOT_JDK_FOUND=no 29238 else 29239 # We're done! :-) 29240 BOOT_JDK_FOUND=yes 29241 29242 # Only process if variable expands to non-empty 29243 29244 if test "x$BOOT_JDK" != x; then 29245 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29246 29247 # Input might be given as Windows format, start by converting to 29248 # unix format. 29249 path="$BOOT_JDK" 29250 new_path=`$CYGPATH -u "$path"` 29251 29252 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29253 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29254 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29255 # "foo.exe" is OK but "foo" is an error. 29256 # 29257 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29258 # It is also a way to make sure we got the proper file name for the real test later on. 29259 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29260 if test "x$test_shortpath" = x; then 29261 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29262 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29263 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29264 fi 29265 29266 # Call helper function which possibly converts this using DOS-style short mode. 29267 # If so, the updated path is stored in $new_path. 29268 29269 input_path="$new_path" 29270 # Check if we need to convert this using DOS-style short mode. If the path 29271 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29272 # take no chances and rewrite it. 29273 # Note: m4 eats our [], so we need to use [ and ] instead. 29274 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29275 if test "x$has_forbidden_chars" != x; then 29276 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29277 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29278 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29279 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29280 # Going to short mode and back again did indeed matter. Since short mode is 29281 # case insensitive, let's make it lowercase to improve readability. 29282 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29283 # Now convert it back to Unix-style (cygpath) 29284 input_path=`$CYGPATH -u "$shortmode_path"` 29285 new_path="$input_path" 29286 fi 29287 fi 29288 29289 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29290 if test "x$test_cygdrive_prefix" = x; then 29291 # As a simple fix, exclude /usr/bin since it's not a real path. 29292 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29293 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29294 # a path prefixed by /cygdrive for fixpath to work. 29295 new_path="$CYGWIN_ROOT_PATH$input_path" 29296 fi 29297 fi 29298 29299 29300 if test "x$path" != "x$new_path"; then 29301 BOOT_JDK="$new_path" 29302 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29303 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29304 fi 29305 29306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29307 29308 path="$BOOT_JDK" 29309 has_colon=`$ECHO $path | $GREP ^.:` 29310 new_path="$path" 29311 if test "x$has_colon" = x; then 29312 # Not in mixed or Windows style, start by that. 29313 new_path=`cmd //c echo $path` 29314 fi 29315 29316 29317 input_path="$new_path" 29318 # Check if we need to convert this using DOS-style short mode. If the path 29319 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29320 # take no chances and rewrite it. 29321 # Note: m4 eats our [], so we need to use [ and ] instead. 29322 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29323 if test "x$has_forbidden_chars" != x; then 29324 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29325 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29326 fi 29327 29328 29329 windows_path="$new_path" 29330 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29331 unix_path=`$CYGPATH -u "$windows_path"` 29332 new_path="$unix_path" 29333 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29334 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29335 new_path="$unix_path" 29336 fi 29337 29338 if test "x$path" != "x$new_path"; then 29339 BOOT_JDK="$new_path" 29340 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29341 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29342 fi 29343 29344 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29345 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29346 29347 else 29348 # We're on a unix platform. Hooray! :) 29349 path="$BOOT_JDK" 29350 has_space=`$ECHO "$path" | $GREP " "` 29351 if test "x$has_space" != x; then 29352 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29353 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29354 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29355 fi 29356 29357 # Use eval to expand a potential ~ 29358 eval path="$path" 29359 if test ! -f "$path" && test ! -d "$path"; then 29360 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29361 fi 29362 29363 if test -d "$path"; then 29364 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29365 else 29366 dir="`$DIRNAME "$path"`" 29367 base="`$BASENAME "$path"`" 29368 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29369 fi 29370 fi 29371 fi 29372 29373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29374 $as_echo_n "checking for Boot JDK... " >&6; } 29375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29376 $as_echo "$BOOT_JDK" >&6; } 29377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29378 $as_echo_n "checking Boot JDK version... " >&6; } 29379 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29381 $as_echo "$BOOT_JDK_VERSION" >&6; } 29382 fi # end check jdk version 29383 fi # end check javac 29384 fi # end check java 29385 fi # end check boot jdk found 29386 fi 29387 29388 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 29389 29390 if test "x$BOOT_JDK_FOUND" = xno; then 29391 # Now execute the test 29392 29393 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 29394 BOOT_JDK_SUFFIX="/Contents/Home" 29395 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29396 if test "x$ALL_JDKS_FOUND" != x; then 29397 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29398 29399 if test "x$BOOT_JDK_FOUND" = xno; then 29400 # Now execute the test 29401 29402 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29403 if test -d "$BOOT_JDK"; then 29404 BOOT_JDK_FOUND=maybe 29405 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29406 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29407 fi 29408 29409 29410 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29411 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29412 # Do we have a bin/java? 29413 if test ! -x "$BOOT_JDK/bin/java"; then 29414 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29415 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29416 BOOT_JDK_FOUND=no 29417 else 29418 # Do we have a bin/javac? 29419 if test ! -x "$BOOT_JDK/bin/javac"; then 29420 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29421 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29422 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29423 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29424 BOOT_JDK_FOUND=no 29425 else 29426 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29427 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29428 29429 # Extra M4 quote needed to protect [] in grep expression. 29430 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29431 if test "x$FOUND_CORRECT_VERSION" = x; then 29432 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29433 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29434 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29435 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29436 BOOT_JDK_FOUND=no 29437 else 29438 # We're done! :-) 29439 BOOT_JDK_FOUND=yes 29440 29441 # Only process if variable expands to non-empty 29442 29443 if test "x$BOOT_JDK" != x; then 29444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29445 29446 # Input might be given as Windows format, start by converting to 29447 # unix format. 29448 path="$BOOT_JDK" 29449 new_path=`$CYGPATH -u "$path"` 29450 29451 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29452 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29453 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29454 # "foo.exe" is OK but "foo" is an error. 29455 # 29456 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29457 # It is also a way to make sure we got the proper file name for the real test later on. 29458 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29459 if test "x$test_shortpath" = x; then 29460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29461 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29462 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29463 fi 29464 29465 # Call helper function which possibly converts this using DOS-style short mode. 29466 # If so, the updated path is stored in $new_path. 29467 29468 input_path="$new_path" 29469 # Check if we need to convert this using DOS-style short mode. If the path 29470 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29471 # take no chances and rewrite it. 29472 # Note: m4 eats our [], so we need to use [ and ] instead. 29473 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29474 if test "x$has_forbidden_chars" != x; then 29475 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29476 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29477 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29478 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29479 # Going to short mode and back again did indeed matter. Since short mode is 29480 # case insensitive, let's make it lowercase to improve readability. 29481 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29482 # Now convert it back to Unix-style (cygpath) 29483 input_path=`$CYGPATH -u "$shortmode_path"` 29484 new_path="$input_path" 29485 fi 29486 fi 29487 29488 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29489 if test "x$test_cygdrive_prefix" = x; then 29490 # As a simple fix, exclude /usr/bin since it's not a real path. 29491 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29492 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29493 # a path prefixed by /cygdrive for fixpath to work. 29494 new_path="$CYGWIN_ROOT_PATH$input_path" 29495 fi 29496 fi 29497 29498 29499 if test "x$path" != "x$new_path"; then 29500 BOOT_JDK="$new_path" 29501 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29502 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29503 fi 29504 29505 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29506 29507 path="$BOOT_JDK" 29508 has_colon=`$ECHO $path | $GREP ^.:` 29509 new_path="$path" 29510 if test "x$has_colon" = x; then 29511 # Not in mixed or Windows style, start by that. 29512 new_path=`cmd //c echo $path` 29513 fi 29514 29515 29516 input_path="$new_path" 29517 # Check if we need to convert this using DOS-style short mode. If the path 29518 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29519 # take no chances and rewrite it. 29520 # Note: m4 eats our [], so we need to use [ and ] instead. 29521 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29522 if test "x$has_forbidden_chars" != x; then 29523 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29524 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29525 fi 29526 29527 29528 windows_path="$new_path" 29529 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29530 unix_path=`$CYGPATH -u "$windows_path"` 29531 new_path="$unix_path" 29532 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29533 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29534 new_path="$unix_path" 29535 fi 29536 29537 if test "x$path" != "x$new_path"; then 29538 BOOT_JDK="$new_path" 29539 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29540 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29541 fi 29542 29543 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29544 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29545 29546 else 29547 # We're on a unix platform. Hooray! :) 29548 path="$BOOT_JDK" 29549 has_space=`$ECHO "$path" | $GREP " "` 29550 if test "x$has_space" != x; then 29551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29552 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29553 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29554 fi 29555 29556 # Use eval to expand a potential ~ 29557 eval path="$path" 29558 if test ! -f "$path" && test ! -d "$path"; then 29559 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29560 fi 29561 29562 if test -d "$path"; then 29563 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29564 else 29565 dir="`$DIRNAME "$path"`" 29566 base="`$BASENAME "$path"`" 29567 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29568 fi 29569 fi 29570 fi 29571 29572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29573 $as_echo_n "checking for Boot JDK... " >&6; } 29574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29575 $as_echo "$BOOT_JDK" >&6; } 29576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29577 $as_echo_n "checking Boot JDK version... " >&6; } 29578 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29580 $as_echo "$BOOT_JDK_VERSION" >&6; } 29581 fi # end check jdk version 29582 fi # end check javac 29583 fi # end check java 29584 fi # end check boot jdk found 29585 fi 29586 29587 done 29588 fi 29589 29590 29591 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29592 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29593 # Do we have a bin/java? 29594 if test ! -x "$BOOT_JDK/bin/java"; then 29595 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29596 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29597 BOOT_JDK_FOUND=no 29598 else 29599 # Do we have a bin/javac? 29600 if test ! -x "$BOOT_JDK/bin/javac"; then 29601 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29602 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29603 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29604 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29605 BOOT_JDK_FOUND=no 29606 else 29607 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29608 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29609 29610 # Extra M4 quote needed to protect [] in grep expression. 29611 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29612 if test "x$FOUND_CORRECT_VERSION" = x; then 29613 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29614 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29615 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29616 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29617 BOOT_JDK_FOUND=no 29618 else 29619 # We're done! :-) 29620 BOOT_JDK_FOUND=yes 29621 29622 # Only process if variable expands to non-empty 29623 29624 if test "x$BOOT_JDK" != x; then 29625 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29626 29627 # Input might be given as Windows format, start by converting to 29628 # unix format. 29629 path="$BOOT_JDK" 29630 new_path=`$CYGPATH -u "$path"` 29631 29632 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29633 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29634 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29635 # "foo.exe" is OK but "foo" is an error. 29636 # 29637 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29638 # It is also a way to make sure we got the proper file name for the real test later on. 29639 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29640 if test "x$test_shortpath" = x; then 29641 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29642 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29643 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29644 fi 29645 29646 # Call helper function which possibly converts this using DOS-style short mode. 29647 # If so, the updated path is stored in $new_path. 29648 29649 input_path="$new_path" 29650 # Check if we need to convert this using DOS-style short mode. If the path 29651 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29652 # take no chances and rewrite it. 29653 # Note: m4 eats our [], so we need to use [ and ] instead. 29654 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29655 if test "x$has_forbidden_chars" != x; then 29656 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29657 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29658 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29659 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29660 # Going to short mode and back again did indeed matter. Since short mode is 29661 # case insensitive, let's make it lowercase to improve readability. 29662 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29663 # Now convert it back to Unix-style (cygpath) 29664 input_path=`$CYGPATH -u "$shortmode_path"` 29665 new_path="$input_path" 29666 fi 29667 fi 29668 29669 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29670 if test "x$test_cygdrive_prefix" = x; then 29671 # As a simple fix, exclude /usr/bin since it's not a real path. 29672 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29673 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29674 # a path prefixed by /cygdrive for fixpath to work. 29675 new_path="$CYGWIN_ROOT_PATH$input_path" 29676 fi 29677 fi 29678 29679 29680 if test "x$path" != "x$new_path"; then 29681 BOOT_JDK="$new_path" 29682 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29683 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29684 fi 29685 29686 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29687 29688 path="$BOOT_JDK" 29689 has_colon=`$ECHO $path | $GREP ^.:` 29690 new_path="$path" 29691 if test "x$has_colon" = x; then 29692 # Not in mixed or Windows style, start by that. 29693 new_path=`cmd //c echo $path` 29694 fi 29695 29696 29697 input_path="$new_path" 29698 # Check if we need to convert this using DOS-style short mode. If the path 29699 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29700 # take no chances and rewrite it. 29701 # Note: m4 eats our [], so we need to use [ and ] instead. 29702 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29703 if test "x$has_forbidden_chars" != x; then 29704 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29705 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29706 fi 29707 29708 29709 windows_path="$new_path" 29710 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29711 unix_path=`$CYGPATH -u "$windows_path"` 29712 new_path="$unix_path" 29713 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29714 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29715 new_path="$unix_path" 29716 fi 29717 29718 if test "x$path" != "x$new_path"; then 29719 BOOT_JDK="$new_path" 29720 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29721 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29722 fi 29723 29724 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29725 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29726 29727 else 29728 # We're on a unix platform. Hooray! :) 29729 path="$BOOT_JDK" 29730 has_space=`$ECHO "$path" | $GREP " "` 29731 if test "x$has_space" != x; then 29732 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29733 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29734 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29735 fi 29736 29737 # Use eval to expand a potential ~ 29738 eval path="$path" 29739 if test ! -f "$path" && test ! -d "$path"; then 29740 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29741 fi 29742 29743 if test -d "$path"; then 29744 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29745 else 29746 dir="`$DIRNAME "$path"`" 29747 base="`$BASENAME "$path"`" 29748 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29749 fi 29750 fi 29751 fi 29752 29753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29754 $as_echo_n "checking for Boot JDK... " >&6; } 29755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29756 $as_echo "$BOOT_JDK" >&6; } 29757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29758 $as_echo_n "checking Boot JDK version... " >&6; } 29759 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29761 $as_echo "$BOOT_JDK_VERSION" >&6; } 29762 fi # end check jdk version 29763 fi # end check javac 29764 fi # end check java 29765 fi # end check boot jdk found 29766 fi 29767 29768 29769 if test "x$BOOT_JDK_FOUND" = xno; then 29770 # Now execute the test 29771 29772 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 29773 BOOT_JDK_SUFFIX="/Contents/Home" 29774 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29775 if test "x$ALL_JDKS_FOUND" != x; then 29776 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29777 29778 if test "x$BOOT_JDK_FOUND" = xno; then 29779 # Now execute the test 29780 29781 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29782 if test -d "$BOOT_JDK"; then 29783 BOOT_JDK_FOUND=maybe 29784 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29785 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29786 fi 29787 29788 29789 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29790 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29791 # Do we have a bin/java? 29792 if test ! -x "$BOOT_JDK/bin/java"; then 29793 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29794 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29795 BOOT_JDK_FOUND=no 29796 else 29797 # Do we have a bin/javac? 29798 if test ! -x "$BOOT_JDK/bin/javac"; then 29799 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29800 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29801 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29802 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29803 BOOT_JDK_FOUND=no 29804 else 29805 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29806 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29807 29808 # Extra M4 quote needed to protect [] in grep expression. 29809 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29810 if test "x$FOUND_CORRECT_VERSION" = x; then 29811 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29812 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29813 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29814 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29815 BOOT_JDK_FOUND=no 29816 else 29817 # We're done! :-) 29818 BOOT_JDK_FOUND=yes 29819 29820 # Only process if variable expands to non-empty 29821 29822 if test "x$BOOT_JDK" != x; then 29823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29824 29825 # Input might be given as Windows format, start by converting to 29826 # unix format. 29827 path="$BOOT_JDK" 29828 new_path=`$CYGPATH -u "$path"` 29829 29830 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29831 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29832 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29833 # "foo.exe" is OK but "foo" is an error. 29834 # 29835 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29836 # It is also a way to make sure we got the proper file name for the real test later on. 29837 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29838 if test "x$test_shortpath" = x; then 29839 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29840 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29841 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29842 fi 29843 29844 # Call helper function which possibly converts this using DOS-style short mode. 29845 # If so, the updated path is stored in $new_path. 29846 29847 input_path="$new_path" 29848 # Check if we need to convert this using DOS-style short mode. If the path 29849 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29850 # take no chances and rewrite it. 29851 # Note: m4 eats our [], so we need to use [ and ] instead. 29852 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29853 if test "x$has_forbidden_chars" != x; then 29854 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29855 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29856 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29857 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29858 # Going to short mode and back again did indeed matter. Since short mode is 29859 # case insensitive, let's make it lowercase to improve readability. 29860 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29861 # Now convert it back to Unix-style (cygpath) 29862 input_path=`$CYGPATH -u "$shortmode_path"` 29863 new_path="$input_path" 29864 fi 29865 fi 29866 29867 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29868 if test "x$test_cygdrive_prefix" = x; then 29869 # As a simple fix, exclude /usr/bin since it's not a real path. 29870 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29871 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29872 # a path prefixed by /cygdrive for fixpath to work. 29873 new_path="$CYGWIN_ROOT_PATH$input_path" 29874 fi 29875 fi 29876 29877 29878 if test "x$path" != "x$new_path"; then 29879 BOOT_JDK="$new_path" 29880 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29881 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29882 fi 29883 29884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29885 29886 path="$BOOT_JDK" 29887 has_colon=`$ECHO $path | $GREP ^.:` 29888 new_path="$path" 29889 if test "x$has_colon" = x; then 29890 # Not in mixed or Windows style, start by that. 29891 new_path=`cmd //c echo $path` 29892 fi 29893 29894 29895 input_path="$new_path" 29896 # Check if we need to convert this using DOS-style short mode. If the path 29897 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29898 # take no chances and rewrite it. 29899 # Note: m4 eats our [], so we need to use [ and ] instead. 29900 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29901 if test "x$has_forbidden_chars" != x; then 29902 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29903 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29904 fi 29905 29906 29907 windows_path="$new_path" 29908 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29909 unix_path=`$CYGPATH -u "$windows_path"` 29910 new_path="$unix_path" 29911 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29912 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29913 new_path="$unix_path" 29914 fi 29915 29916 if test "x$path" != "x$new_path"; then 29917 BOOT_JDK="$new_path" 29918 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29919 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29920 fi 29921 29922 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29923 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29924 29925 else 29926 # We're on a unix platform. Hooray! :) 29927 path="$BOOT_JDK" 29928 has_space=`$ECHO "$path" | $GREP " "` 29929 if test "x$has_space" != x; then 29930 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29931 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29932 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29933 fi 29934 29935 # Use eval to expand a potential ~ 29936 eval path="$path" 29937 if test ! -f "$path" && test ! -d "$path"; then 29938 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29939 fi 29940 29941 if test -d "$path"; then 29942 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29943 else 29944 dir="`$DIRNAME "$path"`" 29945 base="`$BASENAME "$path"`" 29946 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29947 fi 29948 fi 29949 fi 29950 29951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29952 $as_echo_n "checking for Boot JDK... " >&6; } 29953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29954 $as_echo "$BOOT_JDK" >&6; } 29955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29956 $as_echo_n "checking Boot JDK version... " >&6; } 29957 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29959 $as_echo "$BOOT_JDK_VERSION" >&6; } 29960 fi # end check jdk version 29961 fi # end check javac 29962 fi # end check java 29963 fi # end check boot jdk found 29964 fi 29965 29966 done 29967 fi 29968 29969 29970 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29971 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29972 # Do we have a bin/java? 29973 if test ! -x "$BOOT_JDK/bin/java"; then 29974 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29975 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29976 BOOT_JDK_FOUND=no 29977 else 29978 # Do we have a bin/javac? 29979 if test ! -x "$BOOT_JDK/bin/javac"; then 29980 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29981 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29982 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29983 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29984 BOOT_JDK_FOUND=no 29985 else 29986 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29987 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29988 29989 # Extra M4 quote needed to protect [] in grep expression. 29990 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29991 if test "x$FOUND_CORRECT_VERSION" = x; then 29992 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29993 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29994 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29995 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29996 BOOT_JDK_FOUND=no 29997 else 29998 # We're done! :-) 29999 BOOT_JDK_FOUND=yes 30000 30001 # Only process if variable expands to non-empty 30002 30003 if test "x$BOOT_JDK" != x; then 30004 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30005 30006 # Input might be given as Windows format, start by converting to 30007 # unix format. 30008 path="$BOOT_JDK" 30009 new_path=`$CYGPATH -u "$path"` 30010 30011 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30012 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30013 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30014 # "foo.exe" is OK but "foo" is an error. 30015 # 30016 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30017 # It is also a way to make sure we got the proper file name for the real test later on. 30018 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30019 if test "x$test_shortpath" = x; then 30020 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30021 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30022 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30023 fi 30024 30025 # Call helper function which possibly converts this using DOS-style short mode. 30026 # If so, the updated path is stored in $new_path. 30027 30028 input_path="$new_path" 30029 # Check if we need to convert this using DOS-style short mode. If the path 30030 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30031 # take no chances and rewrite it. 30032 # Note: m4 eats our [], so we need to use [ and ] instead. 30033 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30034 if test "x$has_forbidden_chars" != x; then 30035 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30036 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30037 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30038 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30039 # Going to short mode and back again did indeed matter. Since short mode is 30040 # case insensitive, let's make it lowercase to improve readability. 30041 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30042 # Now convert it back to Unix-style (cygpath) 30043 input_path=`$CYGPATH -u "$shortmode_path"` 30044 new_path="$input_path" 30045 fi 30046 fi 30047 30048 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30049 if test "x$test_cygdrive_prefix" = x; then 30050 # As a simple fix, exclude /usr/bin since it's not a real path. 30051 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30052 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30053 # a path prefixed by /cygdrive for fixpath to work. 30054 new_path="$CYGWIN_ROOT_PATH$input_path" 30055 fi 30056 fi 30057 30058 30059 if test "x$path" != "x$new_path"; then 30060 BOOT_JDK="$new_path" 30061 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30062 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30063 fi 30064 30065 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30066 30067 path="$BOOT_JDK" 30068 has_colon=`$ECHO $path | $GREP ^.:` 30069 new_path="$path" 30070 if test "x$has_colon" = x; then 30071 # Not in mixed or Windows style, start by that. 30072 new_path=`cmd //c echo $path` 30073 fi 30074 30075 30076 input_path="$new_path" 30077 # Check if we need to convert this using DOS-style short mode. If the path 30078 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30079 # take no chances and rewrite it. 30080 # Note: m4 eats our [], so we need to use [ and ] instead. 30081 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30082 if test "x$has_forbidden_chars" != x; then 30083 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30084 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30085 fi 30086 30087 30088 windows_path="$new_path" 30089 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30090 unix_path=`$CYGPATH -u "$windows_path"` 30091 new_path="$unix_path" 30092 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30093 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30094 new_path="$unix_path" 30095 fi 30096 30097 if test "x$path" != "x$new_path"; then 30098 BOOT_JDK="$new_path" 30099 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30100 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30101 fi 30102 30103 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30104 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30105 30106 else 30107 # We're on a unix platform. Hooray! :) 30108 path="$BOOT_JDK" 30109 has_space=`$ECHO "$path" | $GREP " "` 30110 if test "x$has_space" != x; then 30111 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30112 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30113 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30114 fi 30115 30116 # Use eval to expand a potential ~ 30117 eval path="$path" 30118 if test ! -f "$path" && test ! -d "$path"; then 30119 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30120 fi 30121 30122 if test -d "$path"; then 30123 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30124 else 30125 dir="`$DIRNAME "$path"`" 30126 base="`$BASENAME "$path"`" 30127 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30128 fi 30129 fi 30130 fi 30131 30132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30133 $as_echo_n "checking for Boot JDK... " >&6; } 30134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30135 $as_echo "$BOOT_JDK" >&6; } 30136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30137 $as_echo_n "checking Boot JDK version... " >&6; } 30138 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30140 $as_echo "$BOOT_JDK_VERSION" >&6; } 30141 fi # end check jdk version 30142 fi # end check javac 30143 fi # end check java 30144 fi # end check boot jdk found 30145 fi 30146 30147 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 30148 30149 if test "x$BOOT_JDK_FOUND" = xno; then 30150 # Now execute the test 30151 30152 BOOT_JDK_PREFIX="/usr/lib/jvm" 30153 BOOT_JDK_SUFFIX="" 30154 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 30155 if test "x$ALL_JDKS_FOUND" != x; then 30156 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 30157 30158 if test "x$BOOT_JDK_FOUND" = xno; then 30159 # Now execute the test 30160 30161 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 30162 if test -d "$BOOT_JDK"; then 30163 BOOT_JDK_FOUND=maybe 30164 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 30165 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 30166 fi 30167 30168 30169 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30170 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30171 # Do we have a bin/java? 30172 if test ! -x "$BOOT_JDK/bin/java"; then 30173 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30174 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30175 BOOT_JDK_FOUND=no 30176 else 30177 # Do we have a bin/javac? 30178 if test ! -x "$BOOT_JDK/bin/javac"; then 30179 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30180 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30181 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30182 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30183 BOOT_JDK_FOUND=no 30184 else 30185 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30186 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30187 30188 # Extra M4 quote needed to protect [] in grep expression. 30189 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 30190 if test "x$FOUND_CORRECT_VERSION" = x; then 30191 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30192 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30193 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 30194 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 30195 BOOT_JDK_FOUND=no 30196 else 30197 # We're done! :-) 30198 BOOT_JDK_FOUND=yes 30199 30200 # Only process if variable expands to non-empty 30201 30202 if test "x$BOOT_JDK" != x; then 30203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30204 30205 # Input might be given as Windows format, start by converting to 30206 # unix format. 30207 path="$BOOT_JDK" 30208 new_path=`$CYGPATH -u "$path"` 30209 30210 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30211 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30212 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30213 # "foo.exe" is OK but "foo" is an error. 30214 # 30215 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30216 # It is also a way to make sure we got the proper file name for the real test later on. 30217 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30218 if test "x$test_shortpath" = x; then 30219 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30220 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30221 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30222 fi 30223 30224 # Call helper function which possibly converts this using DOS-style short mode. 30225 # If so, the updated path is stored in $new_path. 30226 30227 input_path="$new_path" 30228 # Check if we need to convert this using DOS-style short mode. If the path 30229 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30230 # take no chances and rewrite it. 30231 # Note: m4 eats our [], so we need to use [ and ] instead. 30232 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30233 if test "x$has_forbidden_chars" != x; then 30234 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30235 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30236 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30237 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30238 # Going to short mode and back again did indeed matter. Since short mode is 30239 # case insensitive, let's make it lowercase to improve readability. 30240 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30241 # Now convert it back to Unix-style (cygpath) 30242 input_path=`$CYGPATH -u "$shortmode_path"` 30243 new_path="$input_path" 30244 fi 30245 fi 30246 30247 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30248 if test "x$test_cygdrive_prefix" = x; then 30249 # As a simple fix, exclude /usr/bin since it's not a real path. 30250 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30251 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30252 # a path prefixed by /cygdrive for fixpath to work. 30253 new_path="$CYGWIN_ROOT_PATH$input_path" 30254 fi 30255 fi 30256 30257 30258 if test "x$path" != "x$new_path"; then 30259 BOOT_JDK="$new_path" 30260 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30261 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30262 fi 30263 30264 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30265 30266 path="$BOOT_JDK" 30267 has_colon=`$ECHO $path | $GREP ^.:` 30268 new_path="$path" 30269 if test "x$has_colon" = x; then 30270 # Not in mixed or Windows style, start by that. 30271 new_path=`cmd //c echo $path` 30272 fi 30273 30274 30275 input_path="$new_path" 30276 # Check if we need to convert this using DOS-style short mode. If the path 30277 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30278 # take no chances and rewrite it. 30279 # Note: m4 eats our [], so we need to use [ and ] instead. 30280 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30281 if test "x$has_forbidden_chars" != x; then 30282 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30283 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30284 fi 30285 30286 30287 windows_path="$new_path" 30288 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30289 unix_path=`$CYGPATH -u "$windows_path"` 30290 new_path="$unix_path" 30291 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30292 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30293 new_path="$unix_path" 30294 fi 30295 30296 if test "x$path" != "x$new_path"; then 30297 BOOT_JDK="$new_path" 30298 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30299 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30300 fi 30301 30302 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30303 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30304 30305 else 30306 # We're on a unix platform. Hooray! :) 30307 path="$BOOT_JDK" 30308 has_space=`$ECHO "$path" | $GREP " "` 30309 if test "x$has_space" != x; then 30310 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30311 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30312 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30313 fi 30314 30315 # Use eval to expand a potential ~ 30316 eval path="$path" 30317 if test ! -f "$path" && test ! -d "$path"; then 30318 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30319 fi 30320 30321 if test -d "$path"; then 30322 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30323 else 30324 dir="`$DIRNAME "$path"`" 30325 base="`$BASENAME "$path"`" 30326 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30327 fi 30328 fi 30329 fi 30330 30331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30332 $as_echo_n "checking for Boot JDK... " >&6; } 30333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30334 $as_echo "$BOOT_JDK" >&6; } 30335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30336 $as_echo_n "checking Boot JDK version... " >&6; } 30337 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30339 $as_echo "$BOOT_JDK_VERSION" >&6; } 30340 fi # end check jdk version 30341 fi # end check javac 30342 fi # end check java 30343 fi # end check boot jdk found 30344 fi 30345 30346 done 30347 fi 30348 30349 30350 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30351 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30352 # Do we have a bin/java? 30353 if test ! -x "$BOOT_JDK/bin/java"; then 30354 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30355 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30356 BOOT_JDK_FOUND=no 30357 else 30358 # Do we have a bin/javac? 30359 if test ! -x "$BOOT_JDK/bin/javac"; then 30360 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30361 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30362 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30363 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30364 BOOT_JDK_FOUND=no 30365 else 30366 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30367 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30368 30369 # Extra M4 quote needed to protect [] in grep expression. 30370 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 30371 if test "x$FOUND_CORRECT_VERSION" = x; then 30372 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30373 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30374 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 30375 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 30376 BOOT_JDK_FOUND=no 30377 else 30378 # We're done! :-) 30379 BOOT_JDK_FOUND=yes 30380 30381 # Only process if variable expands to non-empty 30382 30383 if test "x$BOOT_JDK" != x; then 30384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30385 30386 # Input might be given as Windows format, start by converting to 30387 # unix format. 30388 path="$BOOT_JDK" 30389 new_path=`$CYGPATH -u "$path"` 30390 30391 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30392 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30393 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30394 # "foo.exe" is OK but "foo" is an error. 30395 # 30396 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30397 # It is also a way to make sure we got the proper file name for the real test later on. 30398 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30399 if test "x$test_shortpath" = x; then 30400 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30401 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30402 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30403 fi 30404 30405 # Call helper function which possibly converts this using DOS-style short mode. 30406 # If so, the updated path is stored in $new_path. 30407 30408 input_path="$new_path" 30409 # Check if we need to convert this using DOS-style short mode. If the path 30410 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30411 # take no chances and rewrite it. 30412 # Note: m4 eats our [], so we need to use [ and ] instead. 30413 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30414 if test "x$has_forbidden_chars" != x; then 30415 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30416 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30417 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30418 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30419 # Going to short mode and back again did indeed matter. Since short mode is 30420 # case insensitive, let's make it lowercase to improve readability. 30421 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30422 # Now convert it back to Unix-style (cygpath) 30423 input_path=`$CYGPATH -u "$shortmode_path"` 30424 new_path="$input_path" 30425 fi 30426 fi 30427 30428 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30429 if test "x$test_cygdrive_prefix" = x; then 30430 # As a simple fix, exclude /usr/bin since it's not a real path. 30431 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30432 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30433 # a path prefixed by /cygdrive for fixpath to work. 30434 new_path="$CYGWIN_ROOT_PATH$input_path" 30435 fi 30436 fi 30437 30438 30439 if test "x$path" != "x$new_path"; then 30440 BOOT_JDK="$new_path" 30441 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30442 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30443 fi 30444 30445 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30446 30447 path="$BOOT_JDK" 30448 has_colon=`$ECHO $path | $GREP ^.:` 30449 new_path="$path" 30450 if test "x$has_colon" = x; then 30451 # Not in mixed or Windows style, start by that. 30452 new_path=`cmd //c echo $path` 30453 fi 30454 30455 30456 input_path="$new_path" 30457 # Check if we need to convert this using DOS-style short mode. If the path 30458 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30459 # take no chances and rewrite it. 30460 # Note: m4 eats our [], so we need to use [ and ] instead. 30461 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30462 if test "x$has_forbidden_chars" != x; then 30463 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30464 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30465 fi 30466 30467 30468 windows_path="$new_path" 30469 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30470 unix_path=`$CYGPATH -u "$windows_path"` 30471 new_path="$unix_path" 30472 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30473 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30474 new_path="$unix_path" 30475 fi 30476 30477 if test "x$path" != "x$new_path"; then 30478 BOOT_JDK="$new_path" 30479 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30480 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30481 fi 30482 30483 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30484 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30485 30486 else 30487 # We're on a unix platform. Hooray! :) 30488 path="$BOOT_JDK" 30489 has_space=`$ECHO "$path" | $GREP " "` 30490 if test "x$has_space" != x; then 30491 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30492 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30493 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30494 fi 30495 30496 # Use eval to expand a potential ~ 30497 eval path="$path" 30498 if test ! -f "$path" && test ! -d "$path"; then 30499 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30500 fi 30501 30502 if test -d "$path"; then 30503 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30504 else 30505 dir="`$DIRNAME "$path"`" 30506 base="`$BASENAME "$path"`" 30507 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30508 fi 30509 fi 30510 fi 30511 30512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30513 $as_echo_n "checking for Boot JDK... " >&6; } 30514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30515 $as_echo "$BOOT_JDK" >&6; } 30516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30517 $as_echo_n "checking Boot JDK version... " >&6; } 30518 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30520 $as_echo "$BOOT_JDK_VERSION" >&6; } 30521 fi # end check jdk version 30522 fi # end check javac 30523 fi # end check java 30524 fi # end check boot jdk found 30525 fi 30526 30527 fi 30528 30529 30530 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30531 if test "x$BOOT_JDK_FOUND" = xmaybe; then 30532 # Do we have a bin/java? 30533 if test ! -x "$BOOT_JDK/bin/java"; then 30534 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 30535 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 30536 BOOT_JDK_FOUND=no 30537 else 30538 # Do we have a bin/javac? 30539 if test ! -x "$BOOT_JDK/bin/javac"; then 30540 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 30541 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 30542 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 30543 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 30544 BOOT_JDK_FOUND=no 30545 else 30546 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30547 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30548 30549 # Extra M4 quote needed to protect [] in grep expression. 30550 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 30551 if test "x$FOUND_CORRECT_VERSION" = x; then 30552 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 30553 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 30554 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 30555 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 30556 BOOT_JDK_FOUND=no 30557 else 30558 # We're done! :-) 30559 BOOT_JDK_FOUND=yes 30560 30561 # Only process if variable expands to non-empty 30562 30563 if test "x$BOOT_JDK" != x; then 30564 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30565 30566 # Input might be given as Windows format, start by converting to 30567 # unix format. 30568 path="$BOOT_JDK" 30569 new_path=`$CYGPATH -u "$path"` 30570 30571 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30572 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30573 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30574 # "foo.exe" is OK but "foo" is an error. 30575 # 30576 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30577 # It is also a way to make sure we got the proper file name for the real test later on. 30578 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30579 if test "x$test_shortpath" = x; then 30580 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30581 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30582 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30583 fi 30584 30585 # Call helper function which possibly converts this using DOS-style short mode. 30586 # If so, the updated path is stored in $new_path. 30587 30588 input_path="$new_path" 30589 # Check if we need to convert this using DOS-style short mode. If the path 30590 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30591 # take no chances and rewrite it. 30592 # Note: m4 eats our [], so we need to use [ and ] instead. 30593 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30594 if test "x$has_forbidden_chars" != x; then 30595 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30596 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30597 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30598 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30599 # Going to short mode and back again did indeed matter. Since short mode is 30600 # case insensitive, let's make it lowercase to improve readability. 30601 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30602 # Now convert it back to Unix-style (cygpath) 30603 input_path=`$CYGPATH -u "$shortmode_path"` 30604 new_path="$input_path" 30605 fi 30606 fi 30607 30608 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30609 if test "x$test_cygdrive_prefix" = x; then 30610 # As a simple fix, exclude /usr/bin since it's not a real path. 30611 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30612 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30613 # a path prefixed by /cygdrive for fixpath to work. 30614 new_path="$CYGWIN_ROOT_PATH$input_path" 30615 fi 30616 fi 30617 30618 30619 if test "x$path" != "x$new_path"; then 30620 BOOT_JDK="$new_path" 30621 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30622 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30623 fi 30624 30625 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30626 30627 path="$BOOT_JDK" 30628 has_colon=`$ECHO $path | $GREP ^.:` 30629 new_path="$path" 30630 if test "x$has_colon" = x; then 30631 # Not in mixed or Windows style, start by that. 30632 new_path=`cmd //c echo $path` 30633 fi 30634 30635 30636 input_path="$new_path" 30637 # Check if we need to convert this using DOS-style short mode. If the path 30638 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30639 # take no chances and rewrite it. 30640 # Note: m4 eats our [], so we need to use [ and ] instead. 30641 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30642 if test "x$has_forbidden_chars" != x; then 30643 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30644 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30645 fi 30646 30647 30648 windows_path="$new_path" 30649 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30650 unix_path=`$CYGPATH -u "$windows_path"` 30651 new_path="$unix_path" 30652 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30653 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30654 new_path="$unix_path" 30655 fi 30656 30657 if test "x$path" != "x$new_path"; then 30658 BOOT_JDK="$new_path" 30659 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30660 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30661 fi 30662 30663 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30664 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30665 30666 else 30667 # We're on a unix platform. Hooray! :) 30668 path="$BOOT_JDK" 30669 has_space=`$ECHO "$path" | $GREP " "` 30670 if test "x$has_space" != x; then 30671 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30672 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30673 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30674 fi 30675 30676 # Use eval to expand a potential ~ 30677 eval path="$path" 30678 if test ! -f "$path" && test ! -d "$path"; then 30679 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30680 fi 30681 30682 if test -d "$path"; then 30683 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30684 else 30685 dir="`$DIRNAME "$path"`" 30686 base="`$BASENAME "$path"`" 30687 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30688 fi 30689 fi 30690 fi 30691 30692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30693 $as_echo_n "checking for Boot JDK... " >&6; } 30694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30695 $as_echo "$BOOT_JDK" >&6; } 30696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30697 $as_echo_n "checking Boot JDK version... " >&6; } 30698 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30700 $as_echo "$BOOT_JDK_VERSION" >&6; } 30701 fi # end check jdk version 30702 fi # end check javac 30703 fi # end check java 30704 fi # end check boot jdk found 30705 fi 30706 30707 30708 # If we haven't found anything yet, we've truly lost. Give up. 30709 if test "x$BOOT_JDK_FOUND" = xno; then 30710 30711 # Print a helpful message on how to acquire the necessary build dependency. 30712 # openjdk is the help tag: freetype, cups, alsa etc 30713 MISSING_DEPENDENCY=openjdk 30714 30715 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30716 cygwin_help $MISSING_DEPENDENCY 30717 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30718 msys_help $MISSING_DEPENDENCY 30719 else 30720 PKGHANDLER_COMMAND= 30721 30722 case $PKGHANDLER in 30723 apt-get) 30724 apt_help $MISSING_DEPENDENCY ;; 30725 yum) 30726 yum_help $MISSING_DEPENDENCY ;; 30727 brew) 30728 brew_help $MISSING_DEPENDENCY ;; 30729 port) 30730 port_help $MISSING_DEPENDENCY ;; 30731 pkgutil) 30732 pkgutil_help $MISSING_DEPENDENCY ;; 30733 pkgadd) 30734 pkgadd_help $MISSING_DEPENDENCY ;; 30735 esac 30736 30737 if test "x$PKGHANDLER_COMMAND" != x; then 30738 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30739 fi 30740 fi 30741 30742 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 30743 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 30744 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitly setting --with-boot-jdk" >&5 30745 $as_echo "$as_me: This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30746 as_fn_error $? "Cannot continue" "$LINENO" 5 30747 fi 30748 30749 30750 30751 # Setup tools from the Boot JDK. 30752 30753 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30754 30755 # Publish this variable in the help. 30756 30757 30758 if [ -z "${JAVA+x}" ]; then 30759 # The variable is not set by user, try to locate tool using the code snippet 30760 30761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30762 $as_echo_n "checking for java in Boot JDK... " >&6; } 30763 JAVA=$BOOT_JDK/bin/java 30764 if test ! -x $JAVA; then 30765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30766 $as_echo "not found" >&6; } 30767 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30768 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30769 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30770 fi 30771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30772 $as_echo "ok" >&6; } 30773 30774 30775 else 30776 # The variable is set, but is it from the command line or the environment? 30777 30778 # Try to remove the string !JAVA! from our list. 30779 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 30780 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30781 # If it failed, the variable was not from the command line. Ignore it, 30782 # but warn the user (except for BASH, which is always set by the calling BASH). 30783 if test "xJAVA" != xBASH; then 30784 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 30785 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 30786 fi 30787 # Try to locate tool using the code snippet 30788 30789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30790 $as_echo_n "checking for java in Boot JDK... " >&6; } 30791 JAVA=$BOOT_JDK/bin/java 30792 if test ! -x $JAVA; then 30793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30794 $as_echo "not found" >&6; } 30795 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30796 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30797 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30798 fi 30799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30800 $as_echo "ok" >&6; } 30801 30802 30803 else 30804 # If it succeeded, then it was overridden by the user. We will use it 30805 # for the tool. 30806 30807 # First remove it from the list of overridden variables, so we can test 30808 # for unknown variables in the end. 30809 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30810 30811 # Check if we try to supply an empty value 30812 if test "x$JAVA" = x; then 30813 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 30814 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 30815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30816 $as_echo_n "checking for JAVA... " >&6; } 30817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30818 $as_echo "disabled" >&6; } 30819 else 30820 # Check if the provided tool contains a complete path. 30821 tool_specified="$JAVA" 30822 tool_basename="${tool_specified##*/}" 30823 if test "x$tool_basename" = "x$tool_specified"; then 30824 # A command without a complete path is provided, search $PATH. 30825 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 30826 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 30827 # Extract the first word of "$tool_basename", so it can be a program name with args. 30828 set dummy $tool_basename; ac_word=$2 30829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30830 $as_echo_n "checking for $ac_word... " >&6; } 30831 if ${ac_cv_path_JAVA+:} false; then : 30832 $as_echo_n "(cached) " >&6 30833 else 30834 case $JAVA in 30835 [\\/]* | ?:[\\/]*) 30836 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 30837 ;; 30838 *) 30839 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30840 for as_dir in $PATH 30841 do 30842 IFS=$as_save_IFS 30843 test -z "$as_dir" && as_dir=. 30844 for ac_exec_ext in '' $ac_executable_extensions; do 30845 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30846 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 30847 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30848 break 2 30849 fi 30850 done 30851 done 30852 IFS=$as_save_IFS 30853 30854 ;; 30855 esac 30856 fi 30857 JAVA=$ac_cv_path_JAVA 30858 if test -n "$JAVA"; then 30859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 30860 $as_echo "$JAVA" >&6; } 30861 else 30862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30863 $as_echo "no" >&6; } 30864 fi 30865 30866 30867 if test "x$JAVA" = x; then 30868 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30869 fi 30870 else 30871 # Otherwise we believe it is a complete path. Use it as it is. 30872 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30873 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30875 $as_echo_n "checking for JAVA... " >&6; } 30876 if test ! -x "$tool_specified"; then 30877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30878 $as_echo "not found" >&6; } 30879 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30880 fi 30881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30882 $as_echo "$tool_specified" >&6; } 30883 fi 30884 fi 30885 fi 30886 30887 fi 30888 30889 30890 30891 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30892 30893 # Publish this variable in the help. 30894 30895 30896 if [ -z "${JAVAC+x}" ]; then 30897 # The variable is not set by user, try to locate tool using the code snippet 30898 30899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30900 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30901 JAVAC=$BOOT_JDK/bin/javac 30902 if test ! -x $JAVAC; then 30903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30904 $as_echo "not found" >&6; } 30905 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30906 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30907 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30908 fi 30909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30910 $as_echo "ok" >&6; } 30911 30912 30913 else 30914 # The variable is set, but is it from the command line or the environment? 30915 30916 # Try to remove the string !JAVAC! from our list. 30917 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30918 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30919 # If it failed, the variable was not from the command line. Ignore it, 30920 # but warn the user (except for BASH, which is always set by the calling BASH). 30921 if test "xJAVAC" != xBASH; then 30922 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30923 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30924 fi 30925 # Try to locate tool using the code snippet 30926 30927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30928 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30929 JAVAC=$BOOT_JDK/bin/javac 30930 if test ! -x $JAVAC; then 30931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30932 $as_echo "not found" >&6; } 30933 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30934 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30935 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30936 fi 30937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30938 $as_echo "ok" >&6; } 30939 30940 30941 else 30942 # If it succeeded, then it was overridden by the user. We will use it 30943 # for the tool. 30944 30945 # First remove it from the list of overridden variables, so we can test 30946 # for unknown variables in the end. 30947 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30948 30949 # Check if we try to supply an empty value 30950 if test "x$JAVAC" = x; then 30951 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30952 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30954 $as_echo_n "checking for JAVAC... " >&6; } 30955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30956 $as_echo "disabled" >&6; } 30957 else 30958 # Check if the provided tool contains a complete path. 30959 tool_specified="$JAVAC" 30960 tool_basename="${tool_specified##*/}" 30961 if test "x$tool_basename" = "x$tool_specified"; then 30962 # A command without a complete path is provided, search $PATH. 30963 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30964 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30965 # Extract the first word of "$tool_basename", so it can be a program name with args. 30966 set dummy $tool_basename; ac_word=$2 30967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30968 $as_echo_n "checking for $ac_word... " >&6; } 30969 if ${ac_cv_path_JAVAC+:} false; then : 30970 $as_echo_n "(cached) " >&6 30971 else 30972 case $JAVAC in 30973 [\\/]* | ?:[\\/]*) 30974 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30975 ;; 30976 *) 30977 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30978 for as_dir in $PATH 30979 do 30980 IFS=$as_save_IFS 30981 test -z "$as_dir" && as_dir=. 30982 for ac_exec_ext in '' $ac_executable_extensions; do 30983 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30984 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30985 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30986 break 2 30987 fi 30988 done 30989 done 30990 IFS=$as_save_IFS 30991 30992 ;; 30993 esac 30994 fi 30995 JAVAC=$ac_cv_path_JAVAC 30996 if test -n "$JAVAC"; then 30997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 30998 $as_echo "$JAVAC" >&6; } 30999 else 31000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31001 $as_echo "no" >&6; } 31002 fi 31003 31004 31005 if test "x$JAVAC" = x; then 31006 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31007 fi 31008 else 31009 # Otherwise we believe it is a complete path. Use it as it is. 31010 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 31011 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 31012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 31013 $as_echo_n "checking for JAVAC... " >&6; } 31014 if test ! -x "$tool_specified"; then 31015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31016 $as_echo "not found" >&6; } 31017 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 31018 fi 31019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31020 $as_echo "$tool_specified" >&6; } 31021 fi 31022 fi 31023 fi 31024 31025 fi 31026 31027 31028 31029 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31030 31031 # Publish this variable in the help. 31032 31033 31034 if [ -z "${JAVAH+x}" ]; then 31035 # The variable is not set by user, try to locate tool using the code snippet 31036 31037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 31038 $as_echo_n "checking for javah in Boot JDK... " >&6; } 31039 JAVAH=$BOOT_JDK/bin/javah 31040 if test ! -x $JAVAH; then 31041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31042 $as_echo "not found" >&6; } 31043 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31044 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31045 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 31046 fi 31047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31048 $as_echo "ok" >&6; } 31049 31050 31051 else 31052 # The variable is set, but is it from the command line or the environment? 31053 31054 # Try to remove the string !JAVAH! from our list. 31055 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 31056 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31057 # If it failed, the variable was not from the command line. Ignore it, 31058 # but warn the user (except for BASH, which is always set by the calling BASH). 31059 if test "xJAVAH" != xBASH; then 31060 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 31061 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 31062 fi 31063 # Try to locate tool using the code snippet 31064 31065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 31066 $as_echo_n "checking for javah in Boot JDK... " >&6; } 31067 JAVAH=$BOOT_JDK/bin/javah 31068 if test ! -x $JAVAH; then 31069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31070 $as_echo "not found" >&6; } 31071 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31072 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31073 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 31074 fi 31075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31076 $as_echo "ok" >&6; } 31077 31078 31079 else 31080 # If it succeeded, then it was overridden by the user. We will use it 31081 # for the tool. 31082 31083 # First remove it from the list of overridden variables, so we can test 31084 # for unknown variables in the end. 31085 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31086 31087 # Check if we try to supply an empty value 31088 if test "x$JAVAH" = x; then 31089 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 31090 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 31091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 31092 $as_echo_n "checking for JAVAH... " >&6; } 31093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31094 $as_echo "disabled" >&6; } 31095 else 31096 # Check if the provided tool contains a complete path. 31097 tool_specified="$JAVAH" 31098 tool_basename="${tool_specified##*/}" 31099 if test "x$tool_basename" = "x$tool_specified"; then 31100 # A command without a complete path is provided, search $PATH. 31101 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 31102 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 31103 # Extract the first word of "$tool_basename", so it can be a program name with args. 31104 set dummy $tool_basename; ac_word=$2 31105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31106 $as_echo_n "checking for $ac_word... " >&6; } 31107 if ${ac_cv_path_JAVAH+:} false; then : 31108 $as_echo_n "(cached) " >&6 31109 else 31110 case $JAVAH in 31111 [\\/]* | ?:[\\/]*) 31112 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 31113 ;; 31114 *) 31115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31116 for as_dir in $PATH 31117 do 31118 IFS=$as_save_IFS 31119 test -z "$as_dir" && as_dir=. 31120 for ac_exec_ext in '' $ac_executable_extensions; do 31121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31122 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 31123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31124 break 2 31125 fi 31126 done 31127 done 31128 IFS=$as_save_IFS 31129 31130 ;; 31131 esac 31132 fi 31133 JAVAH=$ac_cv_path_JAVAH 31134 if test -n "$JAVAH"; then 31135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 31136 $as_echo "$JAVAH" >&6; } 31137 else 31138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31139 $as_echo "no" >&6; } 31140 fi 31141 31142 31143 if test "x$JAVAH" = x; then 31144 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31145 fi 31146 else 31147 # Otherwise we believe it is a complete path. Use it as it is. 31148 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 31149 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 31150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 31151 $as_echo_n "checking for JAVAH... " >&6; } 31152 if test ! -x "$tool_specified"; then 31153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31154 $as_echo "not found" >&6; } 31155 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 31156 fi 31157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31158 $as_echo "$tool_specified" >&6; } 31159 fi 31160 fi 31161 fi 31162 31163 fi 31164 31165 31166 31167 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31168 31169 # Publish this variable in the help. 31170 31171 31172 if [ -z "${JAR+x}" ]; then 31173 # The variable is not set by user, try to locate tool using the code snippet 31174 31175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 31176 $as_echo_n "checking for jar in Boot JDK... " >&6; } 31177 JAR=$BOOT_JDK/bin/jar 31178 if test ! -x $JAR; then 31179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31180 $as_echo "not found" >&6; } 31181 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31182 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31183 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 31184 fi 31185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31186 $as_echo "ok" >&6; } 31187 31188 31189 else 31190 # The variable is set, but is it from the command line or the environment? 31191 31192 # Try to remove the string !JAR! from our list. 31193 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 31194 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31195 # If it failed, the variable was not from the command line. Ignore it, 31196 # but warn the user (except for BASH, which is always set by the calling BASH). 31197 if test "xJAR" != xBASH; then 31198 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 31199 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 31200 fi 31201 # Try to locate tool using the code snippet 31202 31203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 31204 $as_echo_n "checking for jar in Boot JDK... " >&6; } 31205 JAR=$BOOT_JDK/bin/jar 31206 if test ! -x $JAR; then 31207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31208 $as_echo "not found" >&6; } 31209 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31210 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31211 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 31212 fi 31213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31214 $as_echo "ok" >&6; } 31215 31216 31217 else 31218 # If it succeeded, then it was overridden by the user. We will use it 31219 # for the tool. 31220 31221 # First remove it from the list of overridden variables, so we can test 31222 # for unknown variables in the end. 31223 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31224 31225 # Check if we try to supply an empty value 31226 if test "x$JAR" = x; then 31227 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 31228 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 31229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 31230 $as_echo_n "checking for JAR... " >&6; } 31231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31232 $as_echo "disabled" >&6; } 31233 else 31234 # Check if the provided tool contains a complete path. 31235 tool_specified="$JAR" 31236 tool_basename="${tool_specified##*/}" 31237 if test "x$tool_basename" = "x$tool_specified"; then 31238 # A command without a complete path is provided, search $PATH. 31239 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 31240 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 31241 # Extract the first word of "$tool_basename", so it can be a program name with args. 31242 set dummy $tool_basename; ac_word=$2 31243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31244 $as_echo_n "checking for $ac_word... " >&6; } 31245 if ${ac_cv_path_JAR+:} false; then : 31246 $as_echo_n "(cached) " >&6 31247 else 31248 case $JAR in 31249 [\\/]* | ?:[\\/]*) 31250 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 31251 ;; 31252 *) 31253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31254 for as_dir in $PATH 31255 do 31256 IFS=$as_save_IFS 31257 test -z "$as_dir" && as_dir=. 31258 for ac_exec_ext in '' $ac_executable_extensions; do 31259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31260 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 31261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31262 break 2 31263 fi 31264 done 31265 done 31266 IFS=$as_save_IFS 31267 31268 ;; 31269 esac 31270 fi 31271 JAR=$ac_cv_path_JAR 31272 if test -n "$JAR"; then 31273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 31274 $as_echo "$JAR" >&6; } 31275 else 31276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31277 $as_echo "no" >&6; } 31278 fi 31279 31280 31281 if test "x$JAR" = x; then 31282 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31283 fi 31284 else 31285 # Otherwise we believe it is a complete path. Use it as it is. 31286 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 31287 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 31288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 31289 $as_echo_n "checking for JAR... " >&6; } 31290 if test ! -x "$tool_specified"; then 31291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31292 $as_echo "not found" >&6; } 31293 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 31294 fi 31295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31296 $as_echo "$tool_specified" >&6; } 31297 fi 31298 fi 31299 fi 31300 31301 fi 31302 31303 31304 31305 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 31306 31307 # Publish this variable in the help. 31308 31309 31310 if [ -z "${JARSIGNER+x}" ]; then 31311 # The variable is not set by user, try to locate tool using the code snippet 31312 31313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 31314 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 31315 JARSIGNER=$BOOT_JDK/bin/jarsigner 31316 if test ! -x $JARSIGNER; then 31317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31318 $as_echo "not found" >&6; } 31319 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31320 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31321 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 31322 fi 31323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31324 $as_echo "ok" >&6; } 31325 31326 31327 else 31328 # The variable is set, but is it from the command line or the environment? 31329 31330 # Try to remove the string !JARSIGNER! from our list. 31331 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 31332 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 31333 # If it failed, the variable was not from the command line. Ignore it, 31334 # but warn the user (except for BASH, which is always set by the calling BASH). 31335 if test "xJARSIGNER" != xBASH; then 31336 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 31337 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 31338 fi 31339 # Try to locate tool using the code snippet 31340 31341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 31342 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 31343 JARSIGNER=$BOOT_JDK/bin/jarsigner 31344 if test ! -x $JARSIGNER; then 31345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31346 $as_echo "not found" >&6; } 31347 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 31348 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 31349 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 31350 fi 31351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31352 $as_echo "ok" >&6; } 31353 31354 31355 else 31356 # If it succeeded, then it was overridden by the user. We will use it 31357 # for the tool. 31358 31359 # First remove it from the list of overridden variables, so we can test 31360 # for unknown variables in the end. 31361 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 31362 31363 # Check if we try to supply an empty value 31364 if test "x$JARSIGNER" = x; then 31365 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 31366 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 31367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 31368 $as_echo_n "checking for JARSIGNER... " >&6; } 31369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 31370 $as_echo "disabled" >&6; } 31371 else 31372 # Check if the provided tool contains a complete path. 31373 tool_specified="$JARSIGNER" 31374 tool_basename="${tool_specified##*/}" 31375 if test "x$tool_basename" = "x$tool_specified"; then 31376 # A command without a complete path is provided, search $PATH. 31377 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 31378 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 31379 # Extract the first word of "$tool_basename", so it can be a program name with args. 31380 set dummy $tool_basename; ac_word=$2 31381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31382 $as_echo_n "checking for $ac_word... " >&6; } 31383 if ${ac_cv_path_JARSIGNER+:} false; then : 31384 $as_echo_n "(cached) " >&6 31385 else 31386 case $JARSIGNER in 31387 [\\/]* | ?:[\\/]*) 31388 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 31389 ;; 31390 *) 31391 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31392 for as_dir in $PATH 31393 do 31394 IFS=$as_save_IFS 31395 test -z "$as_dir" && as_dir=. 31396 for ac_exec_ext in '' $ac_executable_extensions; do 31397 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31398 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 31399 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31400 break 2 31401 fi 31402 done 31403 done 31404 IFS=$as_save_IFS 31405 31406 ;; 31407 esac 31408 fi 31409 JARSIGNER=$ac_cv_path_JARSIGNER 31410 if test -n "$JARSIGNER"; then 31411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 31412 $as_echo "$JARSIGNER" >&6; } 31413 else 31414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31415 $as_echo "no" >&6; } 31416 fi 31417 31418 31419 if test "x$JARSIGNER" = x; then 31420 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 31421 fi 31422 else 31423 # Otherwise we believe it is a complete path. Use it as it is. 31424 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 31425 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 31426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 31427 $as_echo_n "checking for JARSIGNER... " >&6; } 31428 if test ! -x "$tool_specified"; then 31429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31430 $as_echo "not found" >&6; } 31431 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 31432 fi 31433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 31434 $as_echo "$tool_specified" >&6; } 31435 fi 31436 fi 31437 fi 31438 31439 fi 31440 31441 31442 31443 # Finally, set some other options... 31444 31445 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 31446 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 31447 31448 31449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK supports modules" >&5 31450 $as_echo_n "checking if Boot JDK supports modules... " >&6; } 31451 if "$JAVA" --list-modules > /dev/null 2>&1; then 31452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31453 $as_echo "yes" >&6; } 31454 BOOT_JDK_MODULAR="true" 31455 else 31456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31457 $as_echo "no" >&6; } 31458 BOOT_JDK_MODULAR="false" 31459 fi 31460 31461 31462 31463 31464 # Check if the boot jdk is 32 or 64 bit 31465 if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then 31466 BOOT_JDK_BITS="64" 31467 else 31468 BOOT_JDK_BITS="32" 31469 fi 31470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 31471 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 31472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 31473 $as_echo "$BOOT_JDK_BITS" >&6; } 31474 31475 31476 31477 # Check whether --with-build-jdk was given. 31478 if test "${with_build_jdk+set}" = set; then : 31479 withval=$with_build_jdk; 31480 fi 31481 31482 31483 CREATE_BUILDJDK=false 31484 EXTERNAL_BUILDJDK=false 31485 BUILD_JDK_FOUND="no" 31486 if test "x$with_build_jdk" != "x"; then 31487 31488 if test "x$BUILD_JDK_FOUND" = xno; then 31489 # Execute the test 31490 31491 if test "x$with_build_jdk" != x; then 31492 BUILD_JDK=$with_build_jdk 31493 BUILD_JDK_FOUND=maybe 31494 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 31495 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 31496 fi 31497 31498 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 31499 if test "x$BUILD_JDK_FOUND" = xmaybe; then 31500 # Do we have a bin/java? 31501 if test ! -x "$BUILD_JDK/bin/java"; then 31502 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 31503 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 31504 BUILD_JDK_FOUND=no 31505 elif test ! -x "$BUILD_JDK/bin/jlink"; then 31506 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 31507 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 31508 BUILD_JDK_FOUND=no 31509 elif test ! -x "$BUILD_JDK/bin/jmod"; then 31510 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 31511 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 31512 BUILD_JDK_FOUND=no 31513 elif test ! -x "$BUILD_JDK/bin/javac"; then 31514 # Do we have a bin/javac? 31515 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 31516 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 31517 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 31518 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 31519 BUILD_JDK_FOUND=no 31520 else 31521 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 31522 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 31523 31524 # Extra M4 quote needed to protect [] in grep expression. 31525 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"'` 31526 if test "x$FOUND_CORRECT_VERSION" = x; then 31527 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 31528 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 31529 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 9)" >&5 31530 $as_echo "$as_me: (Your Build JDK must be version 9)" >&6;} 31531 BUILD_JDK_FOUND=no 31532 else 31533 # We're done! 31534 BUILD_JDK_FOUND=yes 31535 31536 # Only process if variable expands to non-empty 31537 31538 if test "x$BUILD_JDK" != x; then 31539 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31540 31541 # Input might be given as Windows format, start by converting to 31542 # unix format. 31543 path="$BUILD_JDK" 31544 new_path=`$CYGPATH -u "$path"` 31545 31546 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31547 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31548 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31549 # "foo.exe" is OK but "foo" is an error. 31550 # 31551 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31552 # It is also a way to make sure we got the proper file name for the real test later on. 31553 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31554 if test "x$test_shortpath" = x; then 31555 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31556 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31557 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 31558 fi 31559 31560 # Call helper function which possibly converts this using DOS-style short mode. 31561 # If so, the updated path is stored in $new_path. 31562 31563 input_path="$new_path" 31564 # Check if we need to convert this using DOS-style short mode. If the path 31565 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31566 # take no chances and rewrite it. 31567 # Note: m4 eats our [], so we need to use [ and ] instead. 31568 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31569 if test "x$has_forbidden_chars" != x; then 31570 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31571 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31572 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31573 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31574 # Going to short mode and back again did indeed matter. Since short mode is 31575 # case insensitive, let's make it lowercase to improve readability. 31576 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31577 # Now convert it back to Unix-style (cygpath) 31578 input_path=`$CYGPATH -u "$shortmode_path"` 31579 new_path="$input_path" 31580 fi 31581 fi 31582 31583 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31584 if test "x$test_cygdrive_prefix" = x; then 31585 # As a simple fix, exclude /usr/bin since it's not a real path. 31586 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31587 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31588 # a path prefixed by /cygdrive for fixpath to work. 31589 new_path="$CYGWIN_ROOT_PATH$input_path" 31590 fi 31591 fi 31592 31593 31594 if test "x$path" != "x$new_path"; then 31595 BUILD_JDK="$new_path" 31596 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31597 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31598 fi 31599 31600 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31601 31602 path="$BUILD_JDK" 31603 has_colon=`$ECHO $path | $GREP ^.:` 31604 new_path="$path" 31605 if test "x$has_colon" = x; then 31606 # Not in mixed or Windows style, start by that. 31607 new_path=`cmd //c echo $path` 31608 fi 31609 31610 31611 input_path="$new_path" 31612 # Check if we need to convert this using DOS-style short mode. If the path 31613 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31614 # take no chances and rewrite it. 31615 # Note: m4 eats our [], so we need to use [ and ] instead. 31616 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31617 if test "x$has_forbidden_chars" != x; then 31618 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31619 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31620 fi 31621 31622 31623 windows_path="$new_path" 31624 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31625 unix_path=`$CYGPATH -u "$windows_path"` 31626 new_path="$unix_path" 31627 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31628 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31629 new_path="$unix_path" 31630 fi 31631 31632 if test "x$path" != "x$new_path"; then 31633 BUILD_JDK="$new_path" 31634 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31635 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31636 fi 31637 31638 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31639 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31640 31641 else 31642 # We're on a unix platform. Hooray! :) 31643 path="$BUILD_JDK" 31644 has_space=`$ECHO "$path" | $GREP " "` 31645 if test "x$has_space" != x; then 31646 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31647 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31648 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31649 fi 31650 31651 # Use eval to expand a potential ~ 31652 eval path="$path" 31653 if test ! -f "$path" && test ! -d "$path"; then 31654 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 31655 fi 31656 31657 if test -d "$path"; then 31658 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 31659 else 31660 dir="`$DIRNAME "$path"`" 31661 base="`$BASENAME "$path"`" 31662 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 31663 fi 31664 fi 31665 fi 31666 31667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31668 $as_echo_n "checking for Build JDK... " >&6; } 31669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 31670 $as_echo "$BUILD_JDK" >&6; } 31671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 31672 $as_echo_n "checking Build JDK version... " >&6; } 31673 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 31674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 31675 $as_echo "$BUILD_JDK_VERSION" >&6; } 31676 fi # end check jdk version 31677 fi # end check java 31678 fi # end check build jdk found 31679 fi 31680 31681 EXTERNAL_BUILDJDK=true 31682 else 31683 if test "x$COMPILE_TYPE" = "xcross"; then 31684 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 31685 BUILD_JDK_FOUND=yes 31686 CREATE_BUILDJDK=true 31687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31688 $as_echo_n "checking for Build JDK... " >&6; } 31689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 31690 $as_echo "yes, will build it for the host platform" >&6; } 31691 else 31692 BUILD_JDK="\$(JDK_OUTPUTDIR)" 31693 BUILD_JDK_FOUND=yes 31694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31695 $as_echo_n "checking for Build JDK... " >&6; } 31696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 31697 $as_echo "yes, will use output dir" >&6; } 31698 fi 31699 fi 31700 31701 JMOD="$BUILD_JDK/bin/jmod" 31702 JLINK="$BUILD_JDK/bin/jlink" 31703 31704 31705 31706 if test "x$BUILD_JDK_FOUND" != "xyes"; then 31707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31708 $as_echo_n "checking for Build JDK... " >&6; } 31709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31710 $as_echo "no" >&6; } 31711 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 31712 fi 31713 31714 31715 31716 31717 31718 31719 ############################################################################### 31720 # 31721 # Configure the sources to use. We can add or override individual directories. 31722 # 31723 ############################################################################### 31724 31725 31726 BUILD_OUTPUT="$OUTPUT_ROOT" 31727 31728 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 31729 31730 # Where are the sources. 31731 31732 31733 31734 31735 # Check whether --with-import-modules was given. 31736 if test "${with_import_modules+set}" = set; then : 31737 withval=$with_import_modules; 31738 fi 31739 31740 31741 if test "x$with_import_modules" != x \ 31742 && test "x$with_import_modules" != "xno"; then 31743 if test -d "$with_import_modules"; then 31744 IMPORT_MODULES_TOPDIR="$with_import_modules" 31745 31746 # Only process if variable expands to non-empty 31747 31748 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31749 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31750 31751 # Input might be given as Windows format, start by converting to 31752 # unix format. 31753 path="$IMPORT_MODULES_TOPDIR" 31754 new_path=`$CYGPATH -u "$path"` 31755 31756 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31757 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31758 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31759 # "foo.exe" is OK but "foo" is an error. 31760 # 31761 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31762 # It is also a way to make sure we got the proper file name for the real test later on. 31763 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31764 if test "x$test_shortpath" = x; then 31765 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31766 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31767 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31768 fi 31769 31770 # Call helper function which possibly converts this using DOS-style short mode. 31771 # If so, the updated path is stored in $new_path. 31772 31773 input_path="$new_path" 31774 # Check if we need to convert this using DOS-style short mode. If the path 31775 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31776 # take no chances and rewrite it. 31777 # Note: m4 eats our [], so we need to use [ and ] instead. 31778 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31779 if test "x$has_forbidden_chars" != x; then 31780 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31781 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31782 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31783 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31784 # Going to short mode and back again did indeed matter. Since short mode is 31785 # case insensitive, let's make it lowercase to improve readability. 31786 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31787 # Now convert it back to Unix-style (cygpath) 31788 input_path=`$CYGPATH -u "$shortmode_path"` 31789 new_path="$input_path" 31790 fi 31791 fi 31792 31793 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31794 if test "x$test_cygdrive_prefix" = x; then 31795 # As a simple fix, exclude /usr/bin since it's not a real path. 31796 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31797 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31798 # a path prefixed by /cygdrive for fixpath to work. 31799 new_path="$CYGWIN_ROOT_PATH$input_path" 31800 fi 31801 fi 31802 31803 31804 if test "x$path" != "x$new_path"; then 31805 IMPORT_MODULES_TOPDIR="$new_path" 31806 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31807 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31808 fi 31809 31810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31811 31812 path="$IMPORT_MODULES_TOPDIR" 31813 has_colon=`$ECHO $path | $GREP ^.:` 31814 new_path="$path" 31815 if test "x$has_colon" = x; then 31816 # Not in mixed or Windows style, start by that. 31817 new_path=`cmd //c echo $path` 31818 fi 31819 31820 31821 input_path="$new_path" 31822 # Check if we need to convert this using DOS-style short mode. If the path 31823 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31824 # take no chances and rewrite it. 31825 # Note: m4 eats our [], so we need to use [ and ] instead. 31826 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31827 if test "x$has_forbidden_chars" != x; then 31828 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31829 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31830 fi 31831 31832 31833 windows_path="$new_path" 31834 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31835 unix_path=`$CYGPATH -u "$windows_path"` 31836 new_path="$unix_path" 31837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31838 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31839 new_path="$unix_path" 31840 fi 31841 31842 if test "x$path" != "x$new_path"; then 31843 IMPORT_MODULES_TOPDIR="$new_path" 31844 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31845 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31846 fi 31847 31848 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31849 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31850 31851 else 31852 # We're on a unix platform. Hooray! :) 31853 path="$IMPORT_MODULES_TOPDIR" 31854 has_space=`$ECHO "$path" | $GREP " "` 31855 if test "x$has_space" != x; then 31856 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31857 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31858 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31859 fi 31860 31861 # Use eval to expand a potential ~ 31862 eval path="$path" 31863 if test ! -f "$path" && test ! -d "$path"; then 31864 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31865 fi 31866 31867 if test -d "$path"; then 31868 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31869 else 31870 dir="`$DIRNAME "$path"`" 31871 base="`$BASENAME "$path"`" 31872 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31873 fi 31874 fi 31875 fi 31876 31877 elif test -e "$with_import_modules"; then 31878 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31879 $RM -rf "$IMPORT_MODULES_TOPDIR" 31880 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31881 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31882 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31883 fi 31884 else 31885 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31886 fi 31887 fi 31888 31889 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31890 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31891 fi 31892 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31893 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31894 fi 31895 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31896 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31897 fi 31898 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31899 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31900 fi 31901 if test -d "$IMPORT_MODULES_TOPDIR/modules_legal"; then 31902 IMPORT_MODULES_LEGAL="$IMPORT_MODULES_TOPDIR/modules_legal" 31903 fi 31904 if test -d "$IMPORT_MODULES_TOPDIR/modules_man"; then 31905 IMPORT_MODULES_MAN="$IMPORT_MODULES_TOPDIR/modules_man" 31906 fi 31907 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31908 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31909 fi 31910 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31911 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31912 fi 31913 31914 31915 31916 31917 31918 31919 31920 31921 31922 31923 31924 ############################################################################### 31925 # 31926 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31927 # native code. 31928 # 31929 ############################################################################### 31930 31931 # See if we are doing a complete static build or not 31932 31933 # Check whether --enable-static-build was given. 31934 if test "${enable_static_build+set}" = set; then : 31935 enableval=$enable_static_build; 31936 fi 31937 31938 STATIC_BUILD=false 31939 if test "x$enable_static_build" = "xyes"; then 31940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31941 $as_echo_n "checking if static build is enabled... " >&6; } 31942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31943 $as_echo "yes" >&6; } 31944 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 31945 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 31946 fi 31947 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 31948 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31949 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31950 STATIC_BUILD=true 31951 elif test "x$enable_static_build" = "xno"; then 31952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31953 $as_echo_n "checking if static build is enabled... " >&6; } 31954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31955 $as_echo "no" >&6; } 31956 elif test "x$enable_static_build" != "x"; then 31957 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 31958 fi 31959 31960 31961 31962 31963 # First determine the toolchain type (compiler family) 31964 31965 31966 # Check whether --with-toolchain-type was given. 31967 if test "${with_toolchain_type+set}" = set; then : 31968 withval=$with_toolchain_type; 31969 fi 31970 31971 31972 # Use indirect variable referencing 31973 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 31974 VALID_TOOLCHAINS=${!toolchain_var_name} 31975 31976 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31977 if test -n "$XCODEBUILD"; then 31978 # On Mac OS X, default toolchain to clang after Xcode 5 31979 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 31980 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 31981 if test $? -ne 0; then 31982 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 31983 fi 31984 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 31985 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 31986 $CUT -f 1 -d .` 31987 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 31988 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 31989 if test $XCODE_MAJOR_VERSION -ge 5; then 31990 DEFAULT_TOOLCHAIN="clang" 31991 else 31992 DEFAULT_TOOLCHAIN="gcc" 31993 fi 31994 else 31995 # If Xcode is not installed, but the command line tools are 31996 # then we can't run xcodebuild. On these systems we should 31997 # default to clang 31998 DEFAULT_TOOLCHAIN="clang" 31999 fi 32000 else 32001 # First toolchain type in the list is the default 32002 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 32003 fi 32004 32005 if test "x$with_toolchain_type" = xlist; then 32006 # List all toolchains 32007 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 32008 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 32009 for toolchain in $VALID_TOOLCHAINS; do 32010 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 32011 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 32012 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 32013 done 32014 32015 exit 0 32016 elif test "x$with_toolchain_type" != x; then 32017 # User override; check that it is valid 32018 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 32019 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 32020 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 32021 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 32022 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 32023 as_fn_error $? "Cannot continue." "$LINENO" 5 32024 fi 32025 TOOLCHAIN_TYPE=$with_toolchain_type 32026 else 32027 # No flag given, use default 32028 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 32029 fi 32030 32031 32032 TOOLCHAIN_CC_BINARY_clang="clang" 32033 TOOLCHAIN_CC_BINARY_gcc="gcc" 32034 TOOLCHAIN_CC_BINARY_microsoft="cl" 32035 TOOLCHAIN_CC_BINARY_solstudio="cc" 32036 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 32037 32038 TOOLCHAIN_CXX_BINARY_clang="clang++" 32039 TOOLCHAIN_CXX_BINARY_gcc="g++" 32040 TOOLCHAIN_CXX_BINARY_microsoft="cl" 32041 TOOLCHAIN_CXX_BINARY_solstudio="CC" 32042 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 32043 32044 # Use indirect variable referencing 32045 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 32046 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 32047 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 32048 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 32049 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 32050 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 32051 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 32052 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 32053 32054 32055 # Define filename patterns 32056 if test "x$OPENJDK_TARGET_OS" = xwindows; then 32057 LIBRARY_PREFIX= 32058 SHARED_LIBRARY_SUFFIX='.dll' 32059 STATIC_LIBRARY_SUFFIX='.lib' 32060 SHARED_LIBRARY='$1.dll' 32061 STATIC_LIBRARY='$1.lib' 32062 OBJ_SUFFIX='.obj' 32063 EXE_SUFFIX='.exe' 32064 else 32065 LIBRARY_PREFIX=lib 32066 SHARED_LIBRARY_SUFFIX='.so' 32067 STATIC_LIBRARY_SUFFIX='.a' 32068 SHARED_LIBRARY='lib$1.so' 32069 STATIC_LIBRARY='lib$1.a' 32070 OBJ_SUFFIX='.o' 32071 EXE_SUFFIX='' 32072 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32073 # For full static builds, we're overloading the SHARED_LIBRARY 32074 # variables in order to limit the amount of changes required. 32075 # It would be better to remove SHARED and just use LIBRARY and 32076 # LIBRARY_SUFFIX for libraries that can be built either 32077 # shared or static and use STATIC_* for libraries that are 32078 # always built statically. 32079 if test "x$STATIC_BUILD" = xtrue; then 32080 SHARED_LIBRARY='lib$1.a' 32081 SHARED_LIBRARY_SUFFIX='.a' 32082 else 32083 SHARED_LIBRARY='lib$1.dylib' 32084 SHARED_LIBRARY_SUFFIX='.dylib' 32085 fi 32086 fi 32087 fi 32088 32089 32090 32091 32092 32093 32094 32095 32096 32097 32098 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 32099 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 32100 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 32101 else 32102 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 32103 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 32104 fi 32105 32106 32107 # User supplied flags should be used when configure detects compilers 32108 32109 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 32110 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 32111 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 32112 fi 32113 32114 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 32115 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 32116 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 32117 fi 32118 32119 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 32120 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 32121 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 32122 fi 32123 32124 32125 # Check whether --with-extra-cflags was given. 32126 if test "${with_extra_cflags+set}" = set; then : 32127 withval=$with_extra_cflags; 32128 fi 32129 32130 32131 32132 # Check whether --with-extra-cxxflags was given. 32133 if test "${with_extra_cxxflags+set}" = set; then : 32134 withval=$with_extra_cxxflags; 32135 fi 32136 32137 32138 32139 # Check whether --with-extra-ldflags was given. 32140 if test "${with_extra_ldflags+set}" = set; then : 32141 withval=$with_extra_ldflags; 32142 fi 32143 32144 32145 EXTRA_CFLAGS="$with_extra_cflags" 32146 EXTRA_CXXFLAGS="$with_extra_cxxflags" 32147 EXTRA_LDFLAGS="$with_extra_ldflags" 32148 32149 32150 32151 32152 32153 # The global CFLAGS and LDLAGS variables are used by configure tests and 32154 # should include the extra parameters 32155 CFLAGS="$EXTRA_CFLAGS" 32156 CXXFLAGS="$EXTRA_CXXFLAGS" 32157 LDFLAGS="$EXTRA_LDFLAGS" 32158 CPPFLAGS="" 32159 32160 # The sysroot cflags are needed for configure to be able to run the compilers 32161 32162 if test "x$SYSROOT" != "x"; then 32163 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 32164 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 32165 # Solaris Studio does not have a concept of sysroot. Instead we must 32166 # make sure the default include and lib dirs are appended to each 32167 # compile and link command line. Must also add -I-xbuiltin to enable 32168 # inlining of system functions and intrinsics. 32169 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 32170 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 32171 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 32172 fi 32173 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 32174 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 32175 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 32176 elif test "x$TOOLCHAIN_TYPE" = xclang; then 32177 SYSROOT_CFLAGS="-isysroot $SYSROOT" 32178 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 32179 fi 32180 # The global CFLAGS and LDFLAGS variables need these for configure to function 32181 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 32182 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 32183 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 32184 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 32185 fi 32186 32187 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32188 # We also need -iframework<path>/System/Library/Frameworks 32189 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 32190 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 32191 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 32192 # set this here so it doesn't have to be peppered throughout the forest 32193 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 32194 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 32195 fi 32196 32197 32198 32199 32200 32201 # Then detect the actual binaries needed 32202 32203 # FIXME: Is this needed? 32204 ac_ext=cpp 32205 ac_cpp='$CXXCPP $CPPFLAGS' 32206 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32207 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32208 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32209 32210 32211 # Store the CFLAGS etc passed to the configure script. 32212 ORG_CFLAGS="$CFLAGS" 32213 ORG_CXXFLAGS="$CXXFLAGS" 32214 32215 # autoconf magic only relies on PATH, so update it if tools dir is specified 32216 OLD_PATH="$PATH" 32217 32218 # On Windows, we need to detect the visual studio installation first. 32219 # This will change the PATH, but we need to keep that new PATH even 32220 # after toolchain detection is done, since the compiler (on x86) uses 32221 # it for DLL resolution in runtime. 32222 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 32223 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 32224 32225 # Store path to cygwin link.exe to help excluding it when searching for 32226 # VS linker. This must be done before changing the PATH when looking for VS. 32227 # Extract the first word of "link", so it can be a program name with args. 32228 set dummy link; ac_word=$2 32229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32230 $as_echo_n "checking for $ac_word... " >&6; } 32231 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 32232 $as_echo_n "(cached) " >&6 32233 else 32234 case $CYGWIN_LINK in 32235 [\\/]* | ?:[\\/]*) 32236 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 32237 ;; 32238 *) 32239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32240 for as_dir in $PATH 32241 do 32242 IFS=$as_save_IFS 32243 test -z "$as_dir" && as_dir=. 32244 for ac_exec_ext in '' $ac_executable_extensions; do 32245 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32246 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 32247 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32248 break 2 32249 fi 32250 done 32251 done 32252 IFS=$as_save_IFS 32253 32254 ;; 32255 esac 32256 fi 32257 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 32258 if test -n "$CYGWIN_LINK"; then 32259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 32260 $as_echo "$CYGWIN_LINK" >&6; } 32261 else 32262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32263 $as_echo "no" >&6; } 32264 fi 32265 32266 32267 if test "x$CYGWIN_LINK" != x; then 32268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 32269 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 32270 "$CYGWIN_LINK" --version > /dev/null 32271 if test $? -eq 0 ; then 32272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32273 $as_echo "yes" >&6; } 32274 else 32275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32276 $as_echo "no" >&6; } 32277 # This might be the VS linker. Don't exclude it later on. 32278 CYGWIN_LINK="" 32279 fi 32280 fi 32281 32282 # First-hand choice is to locate and run the vsvars bat file. 32283 32284 32285 # Check whether --with-toolchain-version was given. 32286 if test "${with_toolchain_version+set}" = set; then : 32287 withval=$with_toolchain_version; 32288 fi 32289 32290 32291 if test "x$with_toolchain_version" = xlist; then 32292 # List all toolchains 32293 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 32294 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 32295 for version in $VALID_VS_VERSIONS; do 32296 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 32297 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 32298 done 32299 32300 exit 0 32301 elif test "x$DEVKIT_VS_VERSION" != x; then 32302 VS_VERSION=$DEVKIT_VS_VERSION 32303 TOOLCHAIN_VERSION=$VS_VERSION 32304 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32305 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32306 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32307 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32308 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32309 VS_PATH="$TOOLCHAIN_PATH:$PATH" 32310 32311 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 32312 # can still be exported as INCLUDE for compiler invocations without 32313 # SYSROOT_CFLAGS 32314 OLDIFS="$IFS" 32315 IFS=";" 32316 for i in $DEVKIT_VS_INCLUDE; do 32317 ipath=$i 32318 32319 unix_path="$ipath" 32320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32321 windows_path=`$CYGPATH -m "$unix_path"` 32322 ipath="$windows_path" 32323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32324 windows_path=`cmd //c echo $unix_path` 32325 ipath="$windows_path" 32326 fi 32327 32328 VS_INCLUDE="$VS_INCLUDE;$ipath" 32329 done 32330 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 32331 # as LIB for compiler invocations without SYSROOT_LDFLAGS 32332 for i in $DEVKIT_VS_LIB; do 32333 libpath=$i 32334 32335 unix_path="$libpath" 32336 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32337 windows_path=`$CYGPATH -m "$unix_path"` 32338 libpath="$windows_path" 32339 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32340 windows_path=`cmd //c echo $unix_path` 32341 libpath="$windows_path" 32342 fi 32343 32344 VS_LIB="$VS_LIB;$libpath" 32345 done 32346 IFS="$OLDIFS" 32347 32348 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 32349 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 32350 32351 elif test "x$with_toolchain_version" != x; then 32352 # User override; check that it is valid 32353 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 32354 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 32355 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 32356 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 32357 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 32358 as_fn_error $? "Cannot continue." "$LINENO" 5 32359 fi 32360 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 32361 else 32362 # No flag given, use default 32363 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 32364 fi 32365 32366 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 32367 32368 VS_VERSION="$VS_VERSION" 32369 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 32370 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 32371 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 32372 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 32373 32374 # When using --with-tools-dir, assume it points to the correct and default 32375 # version of Visual Studio or that --with-toolchain-version was also set. 32376 if test "x$with_tools_dir" != x; then 32377 32378 if test "x$VS_ENV_CMD" = x; then 32379 VS_VERSION="${VS_VERSION}" 32380 VS_BASE="$with_tools_dir/../.." 32381 METHOD="--with-tools-dir" 32382 32383 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32384 VCVARSFILE="vc/bin/vcvars32.bat" 32385 else 32386 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32387 fi 32388 32389 32390 windows_path="$VS_BASE" 32391 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32392 unix_path=`$CYGPATH -u "$windows_path"` 32393 VS_BASE="$unix_path" 32394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32395 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32396 VS_BASE="$unix_path" 32397 fi 32398 32399 if test -d "$VS_BASE"; then 32400 if test -f "$VS_BASE/$VCVARSFILE"; then 32401 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32402 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32403 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32404 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32405 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32406 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32407 else 32408 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32409 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32410 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32411 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32412 fi 32413 fi 32414 fi 32415 32416 32417 if test "x$VS_ENV_CMD" = x; then 32418 VS_VERSION="${VS_VERSION}" 32419 VS_BASE="$with_tools_dir/../../.." 32420 METHOD="--with-tools-dir" 32421 32422 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32423 VCVARSFILE="vc/bin/vcvars32.bat" 32424 else 32425 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32426 fi 32427 32428 32429 windows_path="$VS_BASE" 32430 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32431 unix_path=`$CYGPATH -u "$windows_path"` 32432 VS_BASE="$unix_path" 32433 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32434 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32435 VS_BASE="$unix_path" 32436 fi 32437 32438 if test -d "$VS_BASE"; then 32439 if test -f "$VS_BASE/$VCVARSFILE"; then 32440 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32441 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32442 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32443 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32444 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32445 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32446 else 32447 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32448 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32449 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32450 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32451 fi 32452 fi 32453 fi 32454 32455 if test "x$VS_ENV_CMD" = x; then 32456 # Having specified an argument which is incorrect will produce an instant failure; 32457 # we should not go on looking 32458 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 32459 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 32460 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 32461 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 32462 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 32463 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 32464 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 32465 fi 32466 fi 32467 32468 VS_ENV_CMD="" 32469 VS_ENV_ARGS="" 32470 32471 if test "x$VS_COMNTOOLS" != x; then 32472 32473 if test "x$VS_ENV_CMD" = x; then 32474 VS_VERSION="${VS_VERSION}" 32475 VS_BASE="$VS_COMNTOOLS/../.." 32476 METHOD="$VS_COMNTOOLS_VAR variable" 32477 32478 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32479 VCVARSFILE="vc/bin/vcvars32.bat" 32480 else 32481 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32482 fi 32483 32484 32485 windows_path="$VS_BASE" 32486 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32487 unix_path=`$CYGPATH -u "$windows_path"` 32488 VS_BASE="$unix_path" 32489 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32490 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32491 VS_BASE="$unix_path" 32492 fi 32493 32494 if test -d "$VS_BASE"; then 32495 if test -f "$VS_BASE/$VCVARSFILE"; then 32496 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32497 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32498 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32499 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32500 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32501 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32502 else 32503 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32504 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32505 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32506 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32507 fi 32508 fi 32509 fi 32510 32511 fi 32512 if test "x$PROGRAMFILES" != x; then 32513 32514 if test "x$VS_ENV_CMD" = x; then 32515 VS_VERSION="${VS_VERSION}" 32516 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 32517 METHOD="well-known name" 32518 32519 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32520 VCVARSFILE="vc/bin/vcvars32.bat" 32521 else 32522 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32523 fi 32524 32525 32526 windows_path="$VS_BASE" 32527 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32528 unix_path=`$CYGPATH -u "$windows_path"` 32529 VS_BASE="$unix_path" 32530 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32531 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32532 VS_BASE="$unix_path" 32533 fi 32534 32535 if test -d "$VS_BASE"; then 32536 if test -f "$VS_BASE/$VCVARSFILE"; then 32537 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32538 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32539 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32540 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32541 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32542 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32543 else 32544 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32545 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32546 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32547 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32548 fi 32549 fi 32550 fi 32551 32552 fi 32553 # Work around the insanely named ProgramFiles(x86) env variable 32554 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 32555 if test "x$PROGRAMFILES_X86" != x; then 32556 32557 if test "x$VS_ENV_CMD" = x; then 32558 VS_VERSION="${VS_VERSION}" 32559 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 32560 METHOD="well-known name" 32561 32562 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32563 VCVARSFILE="vc/bin/vcvars32.bat" 32564 else 32565 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32566 fi 32567 32568 32569 windows_path="$VS_BASE" 32570 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32571 unix_path=`$CYGPATH -u "$windows_path"` 32572 VS_BASE="$unix_path" 32573 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32574 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32575 VS_BASE="$unix_path" 32576 fi 32577 32578 if test -d "$VS_BASE"; then 32579 if test -f "$VS_BASE/$VCVARSFILE"; then 32580 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32581 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32582 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32583 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32584 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32585 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32586 else 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 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32590 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32591 fi 32592 fi 32593 fi 32594 32595 fi 32596 32597 if test "x$VS_ENV_CMD" = x; then 32598 VS_VERSION="${VS_VERSION}" 32599 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 32600 METHOD="well-known name" 32601 32602 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32603 VCVARSFILE="vc/bin/vcvars32.bat" 32604 else 32605 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32606 fi 32607 32608 32609 windows_path="$VS_BASE" 32610 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32611 unix_path=`$CYGPATH -u "$windows_path"` 32612 VS_BASE="$unix_path" 32613 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32614 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32615 VS_BASE="$unix_path" 32616 fi 32617 32618 if test -d "$VS_BASE"; then 32619 if test -f "$VS_BASE/$VCVARSFILE"; then 32620 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32621 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32622 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32623 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32624 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32625 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32626 else 32627 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32628 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32629 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32630 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32631 fi 32632 fi 32633 fi 32634 32635 32636 if test "x$VS_ENV_CMD" = x; then 32637 VS_VERSION="${VS_VERSION}" 32638 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 32639 METHOD="well-known name" 32640 32641 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32642 VCVARSFILE="vc/bin/vcvars32.bat" 32643 else 32644 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32645 fi 32646 32647 32648 windows_path="$VS_BASE" 32649 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32650 unix_path=`$CYGPATH -u "$windows_path"` 32651 VS_BASE="$unix_path" 32652 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32653 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32654 VS_BASE="$unix_path" 32655 fi 32656 32657 if test -d "$VS_BASE"; then 32658 if test -f "$VS_BASE/$VCVARSFILE"; then 32659 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32660 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32661 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32662 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32663 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32664 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32665 else 32666 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32667 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32668 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32669 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32670 fi 32671 fi 32672 fi 32673 32674 32675 if test "x$SDK_INSTALL_DIR" != x; then 32676 if test "x$ProgramW6432" != x; then 32677 32678 if test "x$VS_ENV_CMD" = x; then 32679 VS_VERSION="${VS_VERSION}" 32680 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 32681 METHOD="well-known name" 32682 32683 windows_path="$WIN_SDK_BASE" 32684 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32685 unix_path=`$CYGPATH -u "$windows_path"` 32686 WIN_SDK_BASE="$unix_path" 32687 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32688 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32689 WIN_SDK_BASE="$unix_path" 32690 fi 32691 32692 if test -d "$WIN_SDK_BASE"; then 32693 # There have been cases of partial or broken SDK installations. A missing 32694 # lib dir is not going to work. 32695 if test ! -d "$WIN_SDK_BASE/lib"; then 32696 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32697 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32698 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32699 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32700 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32701 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32702 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32703 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32704 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32705 VS_ENV_ARGS="/x86" 32706 else 32707 VS_ENV_ARGS="/x64" 32708 fi 32709 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32710 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32711 # TODO: improve detection for other versions of SDK 32712 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32713 else 32714 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32715 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32716 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32717 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32718 fi 32719 fi 32720 fi 32721 32722 fi 32723 if test "x$PROGRAMW6432" != x; then 32724 32725 if test "x$VS_ENV_CMD" = x; then 32726 VS_VERSION="${VS_VERSION}" 32727 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32728 METHOD="well-known name" 32729 32730 windows_path="$WIN_SDK_BASE" 32731 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32732 unix_path=`$CYGPATH -u "$windows_path"` 32733 WIN_SDK_BASE="$unix_path" 32734 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32735 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32736 WIN_SDK_BASE="$unix_path" 32737 fi 32738 32739 if test -d "$WIN_SDK_BASE"; then 32740 # There have been cases of partial or broken SDK installations. A missing 32741 # lib dir is not going to work. 32742 if test ! -d "$WIN_SDK_BASE/lib"; then 32743 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32744 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32745 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32746 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32747 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32748 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32749 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32750 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32751 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32752 VS_ENV_ARGS="/x86" 32753 else 32754 VS_ENV_ARGS="/x64" 32755 fi 32756 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32757 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32758 # TODO: improve detection for other versions of SDK 32759 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32760 else 32761 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32762 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32763 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32764 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32765 fi 32766 fi 32767 fi 32768 32769 fi 32770 if test "x$PROGRAMFILES" != x; then 32771 32772 if test "x$VS_ENV_CMD" = x; then 32773 VS_VERSION="${VS_VERSION}" 32774 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32775 METHOD="well-known name" 32776 32777 windows_path="$WIN_SDK_BASE" 32778 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32779 unix_path=`$CYGPATH -u "$windows_path"` 32780 WIN_SDK_BASE="$unix_path" 32781 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32782 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32783 WIN_SDK_BASE="$unix_path" 32784 fi 32785 32786 if test -d "$WIN_SDK_BASE"; then 32787 # There have been cases of partial or broken SDK installations. A missing 32788 # lib dir is not going to work. 32789 if test ! -d "$WIN_SDK_BASE/lib"; then 32790 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32791 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32792 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32793 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32794 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32795 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32796 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32797 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32798 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32799 VS_ENV_ARGS="/x86" 32800 else 32801 VS_ENV_ARGS="/x64" 32802 fi 32803 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32804 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32805 # TODO: improve detection for other versions of SDK 32806 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32807 else 32808 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32809 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32810 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32811 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32812 fi 32813 fi 32814 fi 32815 32816 fi 32817 32818 if test "x$VS_ENV_CMD" = x; then 32819 VS_VERSION="${VS_VERSION}" 32820 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32821 METHOD="well-known name" 32822 32823 windows_path="$WIN_SDK_BASE" 32824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32825 unix_path=`$CYGPATH -u "$windows_path"` 32826 WIN_SDK_BASE="$unix_path" 32827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32828 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32829 WIN_SDK_BASE="$unix_path" 32830 fi 32831 32832 if test -d "$WIN_SDK_BASE"; then 32833 # There have been cases of partial or broken SDK installations. A missing 32834 # lib dir is not going to work. 32835 if test ! -d "$WIN_SDK_BASE/lib"; then 32836 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32837 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32838 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32839 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32840 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32841 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32842 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32843 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32844 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32845 VS_ENV_ARGS="/x86" 32846 else 32847 VS_ENV_ARGS="/x64" 32848 fi 32849 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32850 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32851 # TODO: improve detection for other versions of SDK 32852 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32853 else 32854 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32855 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32856 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32857 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32858 fi 32859 fi 32860 fi 32861 32862 32863 if test "x$VS_ENV_CMD" = x; then 32864 VS_VERSION="${VS_VERSION}" 32865 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32866 METHOD="well-known name" 32867 32868 windows_path="$WIN_SDK_BASE" 32869 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32870 unix_path=`$CYGPATH -u "$windows_path"` 32871 WIN_SDK_BASE="$unix_path" 32872 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32873 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32874 WIN_SDK_BASE="$unix_path" 32875 fi 32876 32877 if test -d "$WIN_SDK_BASE"; then 32878 # There have been cases of partial or broken SDK installations. A missing 32879 # lib dir is not going to work. 32880 if test ! -d "$WIN_SDK_BASE/lib"; then 32881 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32882 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32883 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32884 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32885 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; 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 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32889 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32890 VS_ENV_ARGS="/x86" 32891 else 32892 VS_ENV_ARGS="/x64" 32893 fi 32894 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32895 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32896 # TODO: improve detection for other versions of SDK 32897 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32898 else 32899 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32900 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32901 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32902 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32903 fi 32904 fi 32905 fi 32906 32907 fi 32908 32909 if test "x$VS_ENV_CMD" != x; then 32910 TOOLCHAIN_VERSION=$VS_VERSION 32911 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32912 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32913 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32914 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32915 # The rest of the variables are already evaled while probing 32916 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32917 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32918 break 32919 fi 32920 done 32921 32922 32923 # If we have a devkit, skip all of the below. 32924 if test "x$DEVKIT_VS_VERSION" = x; then 32925 if test "x$VS_ENV_CMD" != x; then 32926 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32927 32928 # Only process if variable expands to non-empty 32929 32930 if test "x$VS_ENV_CMD" != x; then 32931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32932 32933 # First separate the path from the arguments. This will split at the first 32934 # space. 32935 complete="$VS_ENV_CMD" 32936 path="${complete%% *}" 32937 tmp="$complete EOL" 32938 arguments="${tmp#* }" 32939 32940 # Input might be given as Windows format, start by converting to 32941 # unix format. 32942 new_path=`$CYGPATH -u "$path"` 32943 32944 # Now try to locate executable using which 32945 new_path=`$WHICH "$new_path" 2> /dev/null` 32946 # bat and cmd files are not always considered executable in cygwin causing which 32947 # to not find them 32948 if test "x$new_path" = x \ 32949 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32950 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32951 new_path=`$CYGPATH -u "$path"` 32952 fi 32953 if test "x$new_path" = x; then 32954 # Oops. Which didn't find the executable. 32955 # The splitting of arguments from the executable at a space might have been incorrect, 32956 # since paths with space are more likely in Windows. Give it another try with the whole 32957 # argument. 32958 path="$complete" 32959 arguments="EOL" 32960 new_path=`$CYGPATH -u "$path"` 32961 new_path=`$WHICH "$new_path" 2> /dev/null` 32962 # bat and cmd files are not always considered executable in cygwin causing which 32963 # to not find them 32964 if test "x$new_path" = x \ 32965 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32966 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32967 new_path=`$CYGPATH -u "$path"` 32968 fi 32969 if test "x$new_path" = x; then 32970 # It's still not found. Now this is an unrecoverable error. 32971 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32972 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32973 has_space=`$ECHO "$complete" | $GREP " "` 32974 if test "x$has_space" != x; then 32975 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32976 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32977 fi 32978 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32979 fi 32980 fi 32981 32982 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32983 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32984 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32985 # "foo.exe" is OK but "foo" is an error. 32986 # 32987 # This test is therefore slightly more accurate than "test -f" to check for file presence. 32988 # It is also a way to make sure we got the proper file name for the real test later on. 32989 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32990 if test "x$test_shortpath" = x; then 32991 # Short path failed, file does not exist as specified. 32992 # Try adding .exe or .cmd 32993 if test -f "${new_path}.exe"; then 32994 input_to_shortpath="${new_path}.exe" 32995 elif test -f "${new_path}.cmd"; then 32996 input_to_shortpath="${new_path}.cmd" 32997 else 32998 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 32999 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 33000 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33001 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33002 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33003 fi 33004 else 33005 input_to_shortpath="$new_path" 33006 fi 33007 33008 # Call helper function which possibly converts this using DOS-style short mode. 33009 # If so, the updated path is stored in $new_path. 33010 new_path="$input_to_shortpath" 33011 33012 input_path="$input_to_shortpath" 33013 # Check if we need to convert this using DOS-style short mode. If the path 33014 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33015 # take no chances and rewrite it. 33016 # Note: m4 eats our [], so we need to use [ and ] instead. 33017 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33018 if test "x$has_forbidden_chars" != x; then 33019 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33020 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33021 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33022 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33023 # Going to short mode and back again did indeed matter. Since short mode is 33024 # case insensitive, let's make it lowercase to improve readability. 33025 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33026 # Now convert it back to Unix-style (cygpath) 33027 input_path=`$CYGPATH -u "$shortmode_path"` 33028 new_path="$input_path" 33029 fi 33030 fi 33031 33032 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33033 if test "x$test_cygdrive_prefix" = x; then 33034 # As a simple fix, exclude /usr/bin since it's not a real path. 33035 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33036 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33037 # a path prefixed by /cygdrive for fixpath to work. 33038 new_path="$CYGWIN_ROOT_PATH$input_path" 33039 fi 33040 fi 33041 33042 # remove trailing .exe if any 33043 new_path="${new_path/%.exe/}" 33044 33045 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33046 33047 # First separate the path from the arguments. This will split at the first 33048 # space. 33049 complete="$VS_ENV_CMD" 33050 path="${complete%% *}" 33051 tmp="$complete EOL" 33052 arguments="${tmp#* }" 33053 33054 # Input might be given as Windows format, start by converting to 33055 # unix format. 33056 new_path="$path" 33057 33058 windows_path="$new_path" 33059 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33060 unix_path=`$CYGPATH -u "$windows_path"` 33061 new_path="$unix_path" 33062 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33063 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33064 new_path="$unix_path" 33065 fi 33066 33067 33068 # Now try to locate executable using which 33069 new_path=`$WHICH "$new_path" 2> /dev/null` 33070 33071 if test "x$new_path" = x; then 33072 # Oops. Which didn't find the executable. 33073 # The splitting of arguments from the executable at a space might have been incorrect, 33074 # since paths with space are more likely in Windows. Give it another try with the whole 33075 # argument. 33076 path="$complete" 33077 arguments="EOL" 33078 new_path="$path" 33079 33080 windows_path="$new_path" 33081 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33082 unix_path=`$CYGPATH -u "$windows_path"` 33083 new_path="$unix_path" 33084 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33085 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33086 new_path="$unix_path" 33087 fi 33088 33089 33090 new_path=`$WHICH "$new_path" 2> /dev/null` 33091 # bat and cmd files are not always considered executable in MSYS causing which 33092 # to not find them 33093 if test "x$new_path" = x \ 33094 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33095 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33096 new_path="$path" 33097 33098 windows_path="$new_path" 33099 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33100 unix_path=`$CYGPATH -u "$windows_path"` 33101 new_path="$unix_path" 33102 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33103 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33104 new_path="$unix_path" 33105 fi 33106 33107 fi 33108 33109 if test "x$new_path" = x; then 33110 # It's still not found. Now this is an unrecoverable error. 33111 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33112 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33113 has_space=`$ECHO "$complete" | $GREP " "` 33114 if test "x$has_space" != x; then 33115 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33116 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33117 fi 33118 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33119 fi 33120 fi 33121 33122 # Now new_path has a complete unix path to the binary 33123 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33124 # Keep paths in /bin as-is, but remove trailing .exe if any 33125 new_path="${new_path/%.exe/}" 33126 # Do not save /bin paths to all_fixpath_prefixes! 33127 else 33128 # Not in mixed or Windows style, start by that. 33129 new_path=`cmd //c echo $new_path` 33130 33131 input_path="$new_path" 33132 # Check if we need to convert this using DOS-style short mode. If the path 33133 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33134 # take no chances and rewrite it. 33135 # Note: m4 eats our [], so we need to use [ and ] instead. 33136 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33137 if test "x$has_forbidden_chars" != x; then 33138 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33139 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33140 fi 33141 33142 # Output is in $new_path 33143 33144 windows_path="$new_path" 33145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33146 unix_path=`$CYGPATH -u "$windows_path"` 33147 new_path="$unix_path" 33148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33149 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33150 new_path="$unix_path" 33151 fi 33152 33153 # remove trailing .exe if any 33154 new_path="${new_path/%.exe/}" 33155 33156 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33157 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33158 fi 33159 33160 else 33161 # We're on a unix platform. Hooray! :) 33162 # First separate the path from the arguments. This will split at the first 33163 # space. 33164 complete="$VS_ENV_CMD" 33165 path="${complete%% *}" 33166 tmp="$complete EOL" 33167 arguments="${tmp#* }" 33168 33169 # Cannot rely on the command "which" here since it doesn't always work. 33170 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33171 if test -z "$is_absolute_path"; then 33172 # Path to executable is not absolute. Find it. 33173 IFS_save="$IFS" 33174 IFS=: 33175 for p in $PATH; do 33176 if test -f "$p/$path" && test -x "$p/$path"; then 33177 new_path="$p/$path" 33178 break 33179 fi 33180 done 33181 IFS="$IFS_save" 33182 else 33183 # This is an absolute path, we can use it without further modifications. 33184 new_path="$path" 33185 fi 33186 33187 if test "x$new_path" = x; then 33188 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 33189 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 33190 has_space=`$ECHO "$complete" | $GREP " "` 33191 if test "x$has_space" != x; then 33192 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33193 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33194 fi 33195 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 33196 fi 33197 fi 33198 33199 # Now join together the path and the arguments once again 33200 if test "x$arguments" != xEOL; then 33201 new_complete="$new_path ${arguments% *}" 33202 else 33203 new_complete="$new_path" 33204 fi 33205 33206 if test "x$complete" != "x$new_complete"; then 33207 VS_ENV_CMD="$new_complete" 33208 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 33209 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 33210 fi 33211 fi 33212 33213 33214 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 33215 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 33216 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 33217 33218 # We need to create a couple of temporary files. 33219 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 33220 $MKDIR -p $VS_ENV_TMP_DIR 33221 33222 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 33223 # Instead create a shell script which will set the relevant variables when run. 33224 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 33225 33226 unix_path="$WINPATH_VS_ENV_CMD" 33227 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33228 windows_path=`$CYGPATH -m "$unix_path"` 33229 WINPATH_VS_ENV_CMD="$windows_path" 33230 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33231 windows_path=`cmd //c echo $unix_path` 33232 WINPATH_VS_ENV_CMD="$windows_path" 33233 fi 33234 33235 WINPATH_BASH="$BASH" 33236 33237 unix_path="$WINPATH_BASH" 33238 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33239 windows_path=`$CYGPATH -m "$unix_path"` 33240 WINPATH_BASH="$windows_path" 33241 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33242 windows_path=`cmd //c echo $unix_path` 33243 WINPATH_BASH="$windows_path" 33244 fi 33245 33246 33247 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 33248 # script (executable by bash) that will setup the important variables. 33249 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 33250 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 33251 # This will end up something like: 33252 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 33253 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 33254 # These will end up something like: 33255 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 33256 # The trailing space for everyone except PATH is no typo, but is needed due 33257 # to trailing \ in the Windows paths. These will be stripped later. 33258 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 33259 >> $EXTRACT_VC_ENV_BAT_FILE 33260 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 33261 >> $EXTRACT_VC_ENV_BAT_FILE 33262 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 33263 >> $EXTRACT_VC_ENV_BAT_FILE 33264 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 33265 >> $EXTRACT_VC_ENV_BAT_FILE 33266 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 33267 >> $EXTRACT_VC_ENV_BAT_FILE 33268 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 33269 >> $EXTRACT_VC_ENV_BAT_FILE 33270 33271 # Now execute the newly created bat file. 33272 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 33273 # Change directory so we don't need to mess with Windows paths in redirects. 33274 cd $VS_ENV_TMP_DIR 33275 cmd /c extract-vs-env.bat | $CAT 33276 cd $CURDIR 33277 33278 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 33279 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 33280 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 33281 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33282 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33283 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33284 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33285 as_fn_error $? "Cannot continue" "$LINENO" 5 33286 fi 33287 33288 # Now set all paths and other env variables. This will allow the rest of 33289 # the configure script to find and run the compiler in the proper way. 33290 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 33291 $as_echo "$as_me: Setting extracted environment variables" >&6;} 33292 . $VS_ENV_TMP_DIR/set-vs-env.sh 33293 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 33294 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 33295 else 33296 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 33297 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 33298 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 33299 fi 33300 fi 33301 33302 # At this point, we should have correct variables in the environment, or we can't continue. 33303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 33304 $as_echo_n "checking for Visual Studio variables... " >&6; } 33305 33306 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 33307 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 33308 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 33309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 33310 $as_echo "present but broken" >&6; } 33311 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 33312 else 33313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 33314 $as_echo "ok" >&6; } 33315 # Remove any trailing "\" ";" and " " from the variables. 33316 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 33317 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 33318 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 33319 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 33320 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 33321 # Remove any paths containing # (typically F#) as that messes up make. This 33322 # is needed if visual studio was installed with F# support. 33323 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 33324 33325 33326 33327 33328 33329 # Convert VS_INCLUDE into SYSROOT_CFLAGS 33330 OLDIFS="$IFS" 33331 IFS=";" 33332 for i in $VS_INCLUDE; do 33333 ipath=$i 33334 # Only process non-empty elements 33335 if test "x$ipath" != x; then 33336 IFS="$OLDIFS" 33337 # Check that directory exists before calling fixup_path 33338 testpath=$ipath 33339 33340 windows_path="$testpath" 33341 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33342 unix_path=`$CYGPATH -u "$windows_path"` 33343 testpath="$unix_path" 33344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33345 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33346 testpath="$unix_path" 33347 fi 33348 33349 if test -d "$testpath"; then 33350 33351 # Only process if variable expands to non-empty 33352 33353 if test "x$ipath" != x; then 33354 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33355 33356 # Input might be given as Windows format, start by converting to 33357 # unix format. 33358 path="$ipath" 33359 new_path=`$CYGPATH -u "$path"` 33360 33361 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33362 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33363 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33364 # "foo.exe" is OK but "foo" is an error. 33365 # 33366 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33367 # It is also a way to make sure we got the proper file name for the real test later on. 33368 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33369 if test "x$test_shortpath" = x; then 33370 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33371 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33372 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 33373 fi 33374 33375 # Call helper function which possibly converts this using DOS-style short mode. 33376 # If so, the updated path is stored in $new_path. 33377 33378 input_path="$new_path" 33379 # Check if we need to convert this using DOS-style short mode. If the path 33380 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33381 # take no chances and rewrite it. 33382 # Note: m4 eats our [], so we need to use [ and ] instead. 33383 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33384 if test "x$has_forbidden_chars" != x; then 33385 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33386 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33387 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33388 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33389 # Going to short mode and back again did indeed matter. Since short mode is 33390 # case insensitive, let's make it lowercase to improve readability. 33391 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33392 # Now convert it back to Unix-style (cygpath) 33393 input_path=`$CYGPATH -u "$shortmode_path"` 33394 new_path="$input_path" 33395 fi 33396 fi 33397 33398 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33399 if test "x$test_cygdrive_prefix" = x; then 33400 # As a simple fix, exclude /usr/bin since it's not a real path. 33401 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33402 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33403 # a path prefixed by /cygdrive for fixpath to work. 33404 new_path="$CYGWIN_ROOT_PATH$input_path" 33405 fi 33406 fi 33407 33408 33409 if test "x$path" != "x$new_path"; then 33410 ipath="$new_path" 33411 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33412 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33413 fi 33414 33415 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33416 33417 path="$ipath" 33418 has_colon=`$ECHO $path | $GREP ^.:` 33419 new_path="$path" 33420 if test "x$has_colon" = x; then 33421 # Not in mixed or Windows style, start by that. 33422 new_path=`cmd //c echo $path` 33423 fi 33424 33425 33426 input_path="$new_path" 33427 # Check if we need to convert this using DOS-style short mode. If the path 33428 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33429 # take no chances and rewrite it. 33430 # Note: m4 eats our [], so we need to use [ and ] instead. 33431 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33432 if test "x$has_forbidden_chars" != x; then 33433 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33434 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33435 fi 33436 33437 33438 windows_path="$new_path" 33439 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33440 unix_path=`$CYGPATH -u "$windows_path"` 33441 new_path="$unix_path" 33442 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33443 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33444 new_path="$unix_path" 33445 fi 33446 33447 if test "x$path" != "x$new_path"; then 33448 ipath="$new_path" 33449 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33450 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33451 fi 33452 33453 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33454 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33455 33456 else 33457 # We're on a unix platform. Hooray! :) 33458 path="$ipath" 33459 has_space=`$ECHO "$path" | $GREP " "` 33460 if test "x$has_space" != x; then 33461 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33462 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33463 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33464 fi 33465 33466 # Use eval to expand a potential ~ 33467 eval path="$path" 33468 if test ! -f "$path" && test ! -d "$path"; then 33469 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 33470 fi 33471 33472 if test -d "$path"; then 33473 ipath="`cd "$path"; $THEPWDCMD -L`" 33474 else 33475 dir="`$DIRNAME "$path"`" 33476 base="`$BASENAME "$path"`" 33477 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 33478 fi 33479 fi 33480 fi 33481 33482 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 33483 fi 33484 IFS=";" 33485 fi 33486 done 33487 # Convert VS_LIB into SYSROOT_LDFLAGS 33488 for i in $VS_LIB; do 33489 libpath=$i 33490 # Only process non-empty elements 33491 if test "x$libpath" != x; then 33492 IFS="$OLDIFS" 33493 # Check that directory exists before calling fixup_path 33494 testpath=$libpath 33495 33496 windows_path="$testpath" 33497 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33498 unix_path=`$CYGPATH -u "$windows_path"` 33499 testpath="$unix_path" 33500 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33501 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33502 testpath="$unix_path" 33503 fi 33504 33505 if test -d "$testpath"; then 33506 33507 # Only process if variable expands to non-empty 33508 33509 if test "x$libpath" != x; then 33510 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33511 33512 # Input might be given as Windows format, start by converting to 33513 # unix format. 33514 path="$libpath" 33515 new_path=`$CYGPATH -u "$path"` 33516 33517 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33518 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33519 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33520 # "foo.exe" is OK but "foo" is an error. 33521 # 33522 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33523 # It is also a way to make sure we got the proper file name for the real test later on. 33524 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33525 if test "x$test_shortpath" = x; then 33526 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33527 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33528 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 33529 fi 33530 33531 # Call helper function which possibly converts this using DOS-style short mode. 33532 # If so, the updated path is stored in $new_path. 33533 33534 input_path="$new_path" 33535 # Check if we need to convert this using DOS-style short mode. If the path 33536 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33537 # take no chances and rewrite it. 33538 # Note: m4 eats our [], so we need to use [ and ] instead. 33539 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33540 if test "x$has_forbidden_chars" != x; then 33541 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33542 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33543 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33544 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33545 # Going to short mode and back again did indeed matter. Since short mode is 33546 # case insensitive, let's make it lowercase to improve readability. 33547 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33548 # Now convert it back to Unix-style (cygpath) 33549 input_path=`$CYGPATH -u "$shortmode_path"` 33550 new_path="$input_path" 33551 fi 33552 fi 33553 33554 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33555 if test "x$test_cygdrive_prefix" = x; then 33556 # As a simple fix, exclude /usr/bin since it's not a real path. 33557 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33558 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33559 # a path prefixed by /cygdrive for fixpath to work. 33560 new_path="$CYGWIN_ROOT_PATH$input_path" 33561 fi 33562 fi 33563 33564 33565 if test "x$path" != "x$new_path"; then 33566 libpath="$new_path" 33567 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33568 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33569 fi 33570 33571 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33572 33573 path="$libpath" 33574 has_colon=`$ECHO $path | $GREP ^.:` 33575 new_path="$path" 33576 if test "x$has_colon" = x; then 33577 # Not in mixed or Windows style, start by that. 33578 new_path=`cmd //c echo $path` 33579 fi 33580 33581 33582 input_path="$new_path" 33583 # Check if we need to convert this using DOS-style short mode. If the path 33584 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33585 # take no chances and rewrite it. 33586 # Note: m4 eats our [], so we need to use [ and ] instead. 33587 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33588 if test "x$has_forbidden_chars" != x; then 33589 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33590 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33591 fi 33592 33593 33594 windows_path="$new_path" 33595 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33596 unix_path=`$CYGPATH -u "$windows_path"` 33597 new_path="$unix_path" 33598 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33599 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33600 new_path="$unix_path" 33601 fi 33602 33603 if test "x$path" != "x$new_path"; then 33604 libpath="$new_path" 33605 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33606 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33607 fi 33608 33609 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33610 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33611 33612 else 33613 # We're on a unix platform. Hooray! :) 33614 path="$libpath" 33615 has_space=`$ECHO "$path" | $GREP " "` 33616 if test "x$has_space" != x; then 33617 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33618 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33619 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33620 fi 33621 33622 # Use eval to expand a potential ~ 33623 eval path="$path" 33624 if test ! -f "$path" && test ! -d "$path"; then 33625 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 33626 fi 33627 33628 if test -d "$path"; then 33629 libpath="`cd "$path"; $THEPWDCMD -L`" 33630 else 33631 dir="`$DIRNAME "$path"`" 33632 base="`$BASENAME "$path"`" 33633 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 33634 fi 33635 fi 33636 fi 33637 33638 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 33639 fi 33640 IFS=";" 33641 fi 33642 done 33643 IFS="$OLDIFS" 33644 fi 33645 else 33646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 33647 $as_echo "not found" >&6; } 33648 33649 if test "x$VS_ENV_CMD" = x; then 33650 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 33651 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 33652 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 33653 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 33654 else 33655 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 33656 $as_echo "$as_me: Running the extraction script failed." >&6;} 33657 fi 33658 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33659 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33660 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33661 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33662 as_fn_error $? "Cannot continue" "$LINENO" 5 33663 fi 33664 33665 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 33666 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 33667 PATH="$VS_PATH" 33668 # The microsoft toolchain also requires INCLUDE and LIB to be set. 33669 export INCLUDE="$VS_INCLUDE" 33670 export LIB="$VS_LIB" 33671 else 33672 if test "x$XCODE_VERSION_OUTPUT" != x; then 33673 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 33674 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 33675 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 33676 else 33677 # Currently we do not define this for other toolchains. This might change as the need arise. 33678 TOOLCHAIN_VERSION= 33679 fi 33680 fi 33681 33682 33683 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 33684 # override all other locations. 33685 if test "x$TOOLCHAIN_PATH" != x; then 33686 PATH=$TOOLCHAIN_PATH:$PATH 33687 fi 33688 33689 33690 # 33691 # Setup the compilers (CC and CXX) 33692 # 33693 33694 COMPILER_NAME=C 33695 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 33696 33697 if test "x$CC" != x; then 33698 # User has supplied compiler name already, always let that override. 33699 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 33700 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 33701 if test "x`basename $CC`" = "x$CC"; then 33702 # A command without a complete path is provided, search $PATH. 33703 33704 for ac_prog in $CC 33705 do 33706 # Extract the first word of "$ac_prog", so it can be a program name with args. 33707 set dummy $ac_prog; ac_word=$2 33708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33709 $as_echo_n "checking for $ac_word... " >&6; } 33710 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33711 $as_echo_n "(cached) " >&6 33712 else 33713 case $POTENTIAL_CC in 33714 [\\/]* | ?:[\\/]*) 33715 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33716 ;; 33717 *) 33718 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33719 for as_dir in $PATH 33720 do 33721 IFS=$as_save_IFS 33722 test -z "$as_dir" && as_dir=. 33723 for ac_exec_ext in '' $ac_executable_extensions; do 33724 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33725 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33726 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33727 break 2 33728 fi 33729 done 33730 done 33731 IFS=$as_save_IFS 33732 33733 ;; 33734 esac 33735 fi 33736 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33737 if test -n "$POTENTIAL_CC"; then 33738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33739 $as_echo "$POTENTIAL_CC" >&6; } 33740 else 33741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33742 $as_echo "no" >&6; } 33743 fi 33744 33745 33746 test -n "$POTENTIAL_CC" && break 33747 done 33748 33749 if test "x$POTENTIAL_CC" != x; then 33750 CC=$POTENTIAL_CC 33751 else 33752 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33753 fi 33754 else 33755 # Otherwise it might already be a complete path 33756 if test ! -x "$CC"; then 33757 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33758 fi 33759 fi 33760 else 33761 # No user supplied value. Locate compiler ourselves. 33762 33763 # If we are cross compiling, assume cross compilation tools follows the 33764 # cross compilation standard where they are prefixed with the autoconf 33765 # standard name for the target. For example the binary 33766 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33767 # If we are not cross compiling, then the default compiler name will be 33768 # used. 33769 33770 CC= 33771 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33772 # before checking the rest of the PATH. 33773 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33774 # step, this should not be necessary. 33775 if test -n "$TOOLCHAIN_PATH"; then 33776 PATH_save="$PATH" 33777 PATH="$TOOLCHAIN_PATH" 33778 if test -n "$ac_tool_prefix"; then 33779 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33780 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33782 $as_echo_n "checking for $ac_word... " >&6; } 33783 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33784 $as_echo_n "(cached) " >&6 33785 else 33786 case $TOOLCHAIN_PATH_CC in 33787 [\\/]* | ?:[\\/]*) 33788 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33789 ;; 33790 *) 33791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33792 for as_dir in $PATH 33793 do 33794 IFS=$as_save_IFS 33795 test -z "$as_dir" && as_dir=. 33796 for ac_exec_ext in '' $ac_executable_extensions; do 33797 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33798 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33799 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33800 break 2 33801 fi 33802 done 33803 done 33804 IFS=$as_save_IFS 33805 33806 ;; 33807 esac 33808 fi 33809 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33810 if test -n "$TOOLCHAIN_PATH_CC"; then 33811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33812 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33813 else 33814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33815 $as_echo "no" >&6; } 33816 fi 33817 33818 33819 fi 33820 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CC"; then 33821 ac_pt_TOOLCHAIN_PATH_CC=$TOOLCHAIN_PATH_CC 33822 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33823 set dummy $SEARCH_LIST; ac_word=$2 33824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33825 $as_echo_n "checking for $ac_word... " >&6; } 33826 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC+:} false; then : 33827 $as_echo_n "(cached) " >&6 33828 else 33829 case $ac_pt_TOOLCHAIN_PATH_CC in 33830 [\\/]* | ?:[\\/]*) 33831 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$ac_pt_TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33832 ;; 33833 *) 33834 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33835 for as_dir in $PATH 33836 do 33837 IFS=$as_save_IFS 33838 test -z "$as_dir" && as_dir=. 33839 for ac_exec_ext in '' $ac_executable_extensions; do 33840 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33841 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33842 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33843 break 2 33844 fi 33845 done 33846 done 33847 IFS=$as_save_IFS 33848 33849 ;; 33850 esac 33851 fi 33852 ac_pt_TOOLCHAIN_PATH_CC=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC 33853 if test -n "$ac_pt_TOOLCHAIN_PATH_CC"; then 33854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CC" >&5 33855 $as_echo "$ac_pt_TOOLCHAIN_PATH_CC" >&6; } 33856 else 33857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33858 $as_echo "no" >&6; } 33859 fi 33860 33861 if test "x$ac_pt_TOOLCHAIN_PATH_CC" = x; then 33862 TOOLCHAIN_PATH_CC="" 33863 else 33864 case $cross_compiling:$ac_tool_warned in 33865 yes:) 33866 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33867 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33868 ac_tool_warned=yes ;; 33869 esac 33870 TOOLCHAIN_PATH_CC=$ac_pt_TOOLCHAIN_PATH_CC 33871 fi 33872 else 33873 TOOLCHAIN_PATH_CC="$ac_cv_path_TOOLCHAIN_PATH_CC" 33874 fi 33875 33876 CC=$TOOLCHAIN_PATH_CC 33877 PATH="$PATH_save" 33878 fi 33879 33880 # AC_PATH_TOOL can't be run multiple times with the same variable, 33881 # so create a new name for this run. 33882 if test "x$CC" = x; then 33883 if test -n "$ac_tool_prefix"; then 33884 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33885 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33887 $as_echo_n "checking for $ac_word... " >&6; } 33888 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33889 $as_echo_n "(cached) " >&6 33890 else 33891 case $POTENTIAL_CC in 33892 [\\/]* | ?:[\\/]*) 33893 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33894 ;; 33895 *) 33896 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33897 for as_dir in $PATH 33898 do 33899 IFS=$as_save_IFS 33900 test -z "$as_dir" && as_dir=. 33901 for ac_exec_ext in '' $ac_executable_extensions; do 33902 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33903 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33904 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33905 break 2 33906 fi 33907 done 33908 done 33909 IFS=$as_save_IFS 33910 33911 ;; 33912 esac 33913 fi 33914 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33915 if test -n "$POTENTIAL_CC"; then 33916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33917 $as_echo "$POTENTIAL_CC" >&6; } 33918 else 33919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33920 $as_echo "no" >&6; } 33921 fi 33922 33923 33924 fi 33925 if test -z "$ac_cv_path_POTENTIAL_CC"; then 33926 ac_pt_POTENTIAL_CC=$POTENTIAL_CC 33927 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33928 set dummy $SEARCH_LIST; ac_word=$2 33929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33930 $as_echo_n "checking for $ac_word... " >&6; } 33931 if ${ac_cv_path_ac_pt_POTENTIAL_CC+:} false; then : 33932 $as_echo_n "(cached) " >&6 33933 else 33934 case $ac_pt_POTENTIAL_CC in 33935 [\\/]* | ?:[\\/]*) 33936 ac_cv_path_ac_pt_POTENTIAL_CC="$ac_pt_POTENTIAL_CC" # Let the user override the test with a path. 33937 ;; 33938 *) 33939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33940 for as_dir in $PATH 33941 do 33942 IFS=$as_save_IFS 33943 test -z "$as_dir" && as_dir=. 33944 for ac_exec_ext in '' $ac_executable_extensions; do 33945 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33946 ac_cv_path_ac_pt_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33947 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33948 break 2 33949 fi 33950 done 33951 done 33952 IFS=$as_save_IFS 33953 33954 ;; 33955 esac 33956 fi 33957 ac_pt_POTENTIAL_CC=$ac_cv_path_ac_pt_POTENTIAL_CC 33958 if test -n "$ac_pt_POTENTIAL_CC"; then 33959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CC" >&5 33960 $as_echo "$ac_pt_POTENTIAL_CC" >&6; } 33961 else 33962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33963 $as_echo "no" >&6; } 33964 fi 33965 33966 if test "x$ac_pt_POTENTIAL_CC" = x; then 33967 POTENTIAL_CC="" 33968 else 33969 case $cross_compiling:$ac_tool_warned in 33970 yes:) 33971 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33972 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33973 ac_tool_warned=yes ;; 33974 esac 33975 POTENTIAL_CC=$ac_pt_POTENTIAL_CC 33976 fi 33977 else 33978 POTENTIAL_CC="$ac_cv_path_POTENTIAL_CC" 33979 fi 33980 33981 CC=$POTENTIAL_CC 33982 fi 33983 33984 if test "x$CC" = x; then 33985 33986 # Print a helpful message on how to acquire the necessary build dependency. 33987 # devkit is the help tag: freetype, cups, alsa etc 33988 MISSING_DEPENDENCY=devkit 33989 33990 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33991 cygwin_help $MISSING_DEPENDENCY 33992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33993 msys_help $MISSING_DEPENDENCY 33994 else 33995 PKGHANDLER_COMMAND= 33996 33997 case $PKGHANDLER in 33998 apt-get) 33999 apt_help $MISSING_DEPENDENCY ;; 34000 yum) 34001 yum_help $MISSING_DEPENDENCY ;; 34002 brew) 34003 brew_help $MISSING_DEPENDENCY ;; 34004 port) 34005 port_help $MISSING_DEPENDENCY ;; 34006 pkgutil) 34007 pkgutil_help $MISSING_DEPENDENCY ;; 34008 pkgadd) 34009 pkgadd_help $MISSING_DEPENDENCY ;; 34010 esac 34011 34012 if test "x$PKGHANDLER_COMMAND" != x; then 34013 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34014 fi 34015 fi 34016 34017 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34018 fi 34019 fi 34020 34021 # Now we have a compiler binary in CC. Make sure it's okay. 34022 34023 # Only process if variable expands to non-empty 34024 34025 if test "x$CC" != x; then 34026 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34027 34028 # First separate the path from the arguments. This will split at the first 34029 # space. 34030 complete="$CC" 34031 path="${complete%% *}" 34032 tmp="$complete EOL" 34033 arguments="${tmp#* }" 34034 34035 # Input might be given as Windows format, start by converting to 34036 # unix format. 34037 new_path=`$CYGPATH -u "$path"` 34038 34039 # Now try to locate executable using which 34040 new_path=`$WHICH "$new_path" 2> /dev/null` 34041 # bat and cmd files are not always considered executable in cygwin causing which 34042 # to not find them 34043 if test "x$new_path" = x \ 34044 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34045 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34046 new_path=`$CYGPATH -u "$path"` 34047 fi 34048 if test "x$new_path" = x; then 34049 # Oops. Which didn't find the executable. 34050 # The splitting of arguments from the executable at a space might have been incorrect, 34051 # since paths with space are more likely in Windows. Give it another try with the whole 34052 # argument. 34053 path="$complete" 34054 arguments="EOL" 34055 new_path=`$CYGPATH -u "$path"` 34056 new_path=`$WHICH "$new_path" 2> /dev/null` 34057 # bat and cmd files are not always considered executable in cygwin causing which 34058 # to not find them 34059 if test "x$new_path" = x \ 34060 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34061 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34062 new_path=`$CYGPATH -u "$path"` 34063 fi 34064 if test "x$new_path" = x; then 34065 # It's still not found. Now this is an unrecoverable error. 34066 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34067 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34068 has_space=`$ECHO "$complete" | $GREP " "` 34069 if test "x$has_space" != x; then 34070 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34071 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34072 fi 34073 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34074 fi 34075 fi 34076 34077 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34078 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34079 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34080 # "foo.exe" is OK but "foo" is an error. 34081 # 34082 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34083 # It is also a way to make sure we got the proper file name for the real test later on. 34084 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34085 if test "x$test_shortpath" = x; then 34086 # Short path failed, file does not exist as specified. 34087 # Try adding .exe or .cmd 34088 if test -f "${new_path}.exe"; then 34089 input_to_shortpath="${new_path}.exe" 34090 elif test -f "${new_path}.cmd"; then 34091 input_to_shortpath="${new_path}.cmd" 34092 else 34093 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 34094 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 34095 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34096 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34097 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34098 fi 34099 else 34100 input_to_shortpath="$new_path" 34101 fi 34102 34103 # Call helper function which possibly converts this using DOS-style short mode. 34104 # If so, the updated path is stored in $new_path. 34105 new_path="$input_to_shortpath" 34106 34107 input_path="$input_to_shortpath" 34108 # Check if we need to convert this using DOS-style short mode. If the path 34109 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34110 # take no chances and rewrite it. 34111 # Note: m4 eats our [], so we need to use [ and ] instead. 34112 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34113 if test "x$has_forbidden_chars" != x; then 34114 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34115 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34116 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34117 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34118 # Going to short mode and back again did indeed matter. Since short mode is 34119 # case insensitive, let's make it lowercase to improve readability. 34120 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34121 # Now convert it back to Unix-style (cygpath) 34122 input_path=`$CYGPATH -u "$shortmode_path"` 34123 new_path="$input_path" 34124 fi 34125 fi 34126 34127 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34128 if test "x$test_cygdrive_prefix" = x; then 34129 # As a simple fix, exclude /usr/bin since it's not a real path. 34130 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34131 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34132 # a path prefixed by /cygdrive for fixpath to work. 34133 new_path="$CYGWIN_ROOT_PATH$input_path" 34134 fi 34135 fi 34136 34137 # remove trailing .exe if any 34138 new_path="${new_path/%.exe/}" 34139 34140 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34141 34142 # First separate the path from the arguments. This will split at the first 34143 # space. 34144 complete="$CC" 34145 path="${complete%% *}" 34146 tmp="$complete EOL" 34147 arguments="${tmp#* }" 34148 34149 # Input might be given as Windows format, start by converting to 34150 # unix format. 34151 new_path="$path" 34152 34153 windows_path="$new_path" 34154 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34155 unix_path=`$CYGPATH -u "$windows_path"` 34156 new_path="$unix_path" 34157 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34158 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34159 new_path="$unix_path" 34160 fi 34161 34162 34163 # Now try to locate executable using which 34164 new_path=`$WHICH "$new_path" 2> /dev/null` 34165 34166 if test "x$new_path" = x; then 34167 # Oops. Which didn't find the executable. 34168 # The splitting of arguments from the executable at a space might have been incorrect, 34169 # since paths with space are more likely in Windows. Give it another try with the whole 34170 # argument. 34171 path="$complete" 34172 arguments="EOL" 34173 new_path="$path" 34174 34175 windows_path="$new_path" 34176 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34177 unix_path=`$CYGPATH -u "$windows_path"` 34178 new_path="$unix_path" 34179 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34180 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34181 new_path="$unix_path" 34182 fi 34183 34184 34185 new_path=`$WHICH "$new_path" 2> /dev/null` 34186 # bat and cmd files are not always considered executable in MSYS causing which 34187 # to not find them 34188 if test "x$new_path" = x \ 34189 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34190 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34191 new_path="$path" 34192 34193 windows_path="$new_path" 34194 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34195 unix_path=`$CYGPATH -u "$windows_path"` 34196 new_path="$unix_path" 34197 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34198 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34199 new_path="$unix_path" 34200 fi 34201 34202 fi 34203 34204 if test "x$new_path" = x; then 34205 # It's still not found. Now this is an unrecoverable error. 34206 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34207 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34208 has_space=`$ECHO "$complete" | $GREP " "` 34209 if test "x$has_space" != x; then 34210 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34211 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34212 fi 34213 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34214 fi 34215 fi 34216 34217 # Now new_path has a complete unix path to the binary 34218 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34219 # Keep paths in /bin as-is, but remove trailing .exe if any 34220 new_path="${new_path/%.exe/}" 34221 # Do not save /bin paths to all_fixpath_prefixes! 34222 else 34223 # Not in mixed or Windows style, start by that. 34224 new_path=`cmd //c echo $new_path` 34225 34226 input_path="$new_path" 34227 # Check if we need to convert this using DOS-style short mode. If the path 34228 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34229 # take no chances and rewrite it. 34230 # Note: m4 eats our [], so we need to use [ and ] instead. 34231 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34232 if test "x$has_forbidden_chars" != x; then 34233 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34234 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34235 fi 34236 34237 # Output is in $new_path 34238 34239 windows_path="$new_path" 34240 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34241 unix_path=`$CYGPATH -u "$windows_path"` 34242 new_path="$unix_path" 34243 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34244 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34245 new_path="$unix_path" 34246 fi 34247 34248 # remove trailing .exe if any 34249 new_path="${new_path/%.exe/}" 34250 34251 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34252 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34253 fi 34254 34255 else 34256 # We're on a unix platform. Hooray! :) 34257 # First separate the path from the arguments. This will split at the first 34258 # space. 34259 complete="$CC" 34260 path="${complete%% *}" 34261 tmp="$complete EOL" 34262 arguments="${tmp#* }" 34263 34264 # Cannot rely on the command "which" here since it doesn't always work. 34265 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34266 if test -z "$is_absolute_path"; then 34267 # Path to executable is not absolute. Find it. 34268 IFS_save="$IFS" 34269 IFS=: 34270 for p in $PATH; do 34271 if test -f "$p/$path" && test -x "$p/$path"; then 34272 new_path="$p/$path" 34273 break 34274 fi 34275 done 34276 IFS="$IFS_save" 34277 else 34278 # This is an absolute path, we can use it without further modifications. 34279 new_path="$path" 34280 fi 34281 34282 if test "x$new_path" = x; then 34283 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 34284 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 34285 has_space=`$ECHO "$complete" | $GREP " "` 34286 if test "x$has_space" != x; then 34287 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34288 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34289 fi 34290 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 34291 fi 34292 fi 34293 34294 # Now join together the path and the arguments once again 34295 if test "x$arguments" != xEOL; then 34296 new_complete="$new_path ${arguments% *}" 34297 else 34298 new_complete="$new_path" 34299 fi 34300 34301 if test "x$complete" != "x$new_complete"; then 34302 CC="$new_complete" 34303 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 34304 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 34305 fi 34306 fi 34307 34308 TEST_COMPILER="$CC" 34309 34310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 34311 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 34312 SYMLINK_ORIGINAL="$TEST_COMPILER" 34313 34314 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34315 # Follow a chain of symbolic links. Use readlink 34316 # where it exists, else fall back to horribly 34317 # complicated shell code. 34318 if test "x$READLINK_TESTED" != yes; then 34319 # On MacOSX there is a readlink tool with a different 34320 # purpose than the GNU readlink tool. Check the found readlink. 34321 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34322 if test "x$ISGNU" = x; then 34323 # A readlink that we do not know how to use. 34324 # Are there other non-GNU readlinks out there? 34325 READLINK_TESTED=yes 34326 READLINK= 34327 fi 34328 fi 34329 34330 if test "x$READLINK" != x; then 34331 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 34332 else 34333 # Save the current directory for restoring afterwards 34334 STARTDIR=$PWD 34335 COUNTER=0 34336 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 34337 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 34338 cd $sym_link_dir 34339 # Use -P flag to resolve symlinks in directories. 34340 cd `$THEPWDCMD -P` 34341 sym_link_dir=`$THEPWDCMD -P` 34342 # Resolve file symlinks 34343 while test $COUNTER -lt 20; do 34344 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34345 if test "x$ISLINK" == x; then 34346 # This is not a symbolic link! We are done! 34347 break 34348 fi 34349 # Again resolve directory symlinks since the target of the just found 34350 # link could be in a different directory 34351 cd `$DIRNAME $ISLINK` 34352 sym_link_dir=`$THEPWDCMD -P` 34353 sym_link_file=`$BASENAME $ISLINK` 34354 let COUNTER=COUNTER+1 34355 done 34356 cd $STARTDIR 34357 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 34358 fi 34359 fi 34360 34361 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 34362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 34363 $as_echo "no symlink" >&6; } 34364 else 34365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 34366 $as_echo "$SYMLINK_ORIGINAL" >&6; } 34367 34368 # We can't handle ccache by gcc wrappers, since we need to know if we're 34369 # using ccache. Instead ccache usage must be controlled by a configure option. 34370 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 34371 if test "x$COMPILER_BASENAME" = "xccache"; then 34372 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 34373 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 34374 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 34375 fi 34376 fi 34377 34378 34379 COMPILER=$CC 34380 COMPILER_NAME=$COMPILER_NAME 34381 34382 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34383 # cc -V output typically looks like 34384 # cc: Sun C 5.12 Linux_i386 2011/11/16 34385 # or 34386 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 34387 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34388 # Check that this is likely to be the Solaris Studio cc. 34389 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 34390 if test $? -ne 0; then 34391 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34392 { $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 34393 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34394 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34395 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34396 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34397 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34398 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34399 fi 34400 # Remove usage instructions (if present), and 34401 # collapse compiler output into a single line 34402 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34403 $SED -e 's/ *[Uu]sage:.*//'` 34404 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34405 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34406 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34407 # xlc -qversion output typically looks like 34408 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34409 # Version: 11.01.0000.0015 34410 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34411 # Check that this is likely to be the IBM XL C compiler. 34412 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 34413 if test $? -ne 0; then 34414 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34415 { $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 34416 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34417 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34418 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34419 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34420 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34421 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34422 fi 34423 # Collapse compiler output into a single line 34424 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34425 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34426 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34427 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34428 # There is no specific version flag, but all output starts with a version string. 34429 # First line typically looks something like: 34430 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34431 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34432 # Check that this is likely to be Microsoft CL.EXE. 34433 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34434 if test $? -ne 0; then 34435 { $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 34436 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34437 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34438 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34439 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34440 fi 34441 # Collapse compiler output into a single line 34442 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34443 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34444 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34445 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34446 # gcc --version output typically looks like 34447 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34448 # Copyright (C) 2013 Free Software Foundation, Inc. 34449 # This is free software; see the source for copying conditions. There is NO 34450 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34451 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34452 # Check that this is likely to be GCC. 34453 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34454 if test $? -ne 0; then 34455 { $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 34456 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34457 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34458 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34459 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34460 fi 34461 # Remove Copyright and legalese from version string, and 34462 # collapse into a single line 34463 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34464 $SED -e 's/ *Copyright .*//'` 34465 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34466 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34467 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34468 # clang --version output typically looks like 34469 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34470 # clang version 3.3 (tags/RELEASE_33/final) 34471 # or 34472 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34473 # Target: x86_64-pc-linux-gnu 34474 # Thread model: posix 34475 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34476 # Check that this is likely to be clang 34477 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34478 if test $? -ne 0; then 34479 { $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 34480 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34481 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34482 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34483 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34484 fi 34485 # Collapse compiler output into a single line 34486 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34487 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34488 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34489 else 34490 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34491 fi 34492 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34493 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34494 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34495 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 34496 34497 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34498 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34499 34500 34501 # Now that we have resolved CC ourself, let autoconf have its go at it 34502 ac_ext=c 34503 ac_cpp='$CPP $CPPFLAGS' 34504 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34505 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34506 ac_compiler_gnu=$ac_cv_c_compiler_gnu 34507 if test -n "$ac_tool_prefix"; then 34508 for ac_prog in $CC 34509 do 34510 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34511 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 34512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34513 $as_echo_n "checking for $ac_word... " >&6; } 34514 if ${ac_cv_prog_CC+:} false; then : 34515 $as_echo_n "(cached) " >&6 34516 else 34517 if test -n "$CC"; then 34518 ac_cv_prog_CC="$CC" # Let the user override the test. 34519 else 34520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34521 for as_dir in $PATH 34522 do 34523 IFS=$as_save_IFS 34524 test -z "$as_dir" && as_dir=. 34525 for ac_exec_ext in '' $ac_executable_extensions; do 34526 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34527 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 34528 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34529 break 2 34530 fi 34531 done 34532 done 34533 IFS=$as_save_IFS 34534 34535 fi 34536 fi 34537 CC=$ac_cv_prog_CC 34538 if test -n "$CC"; then 34539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 34540 $as_echo "$CC" >&6; } 34541 else 34542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34543 $as_echo "no" >&6; } 34544 fi 34545 34546 34547 test -n "$CC" && break 34548 done 34549 fi 34550 if test -z "$CC"; then 34551 ac_ct_CC=$CC 34552 for ac_prog in $CC 34553 do 34554 # Extract the first word of "$ac_prog", so it can be a program name with args. 34555 set dummy $ac_prog; ac_word=$2 34556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34557 $as_echo_n "checking for $ac_word... " >&6; } 34558 if ${ac_cv_prog_ac_ct_CC+:} false; then : 34559 $as_echo_n "(cached) " >&6 34560 else 34561 if test -n "$ac_ct_CC"; then 34562 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 34563 else 34564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34565 for as_dir in $PATH 34566 do 34567 IFS=$as_save_IFS 34568 test -z "$as_dir" && as_dir=. 34569 for ac_exec_ext in '' $ac_executable_extensions; do 34570 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34571 ac_cv_prog_ac_ct_CC="$ac_prog" 34572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34573 break 2 34574 fi 34575 done 34576 done 34577 IFS=$as_save_IFS 34578 34579 fi 34580 fi 34581 ac_ct_CC=$ac_cv_prog_ac_ct_CC 34582 if test -n "$ac_ct_CC"; then 34583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 34584 $as_echo "$ac_ct_CC" >&6; } 34585 else 34586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34587 $as_echo "no" >&6; } 34588 fi 34589 34590 34591 test -n "$ac_ct_CC" && break 34592 done 34593 34594 if test "x$ac_ct_CC" = x; then 34595 CC="" 34596 else 34597 case $cross_compiling:$ac_tool_warned in 34598 yes:) 34599 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34600 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34601 ac_tool_warned=yes ;; 34602 esac 34603 CC=$ac_ct_CC 34604 fi 34605 fi 34606 34607 34608 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34609 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34610 as_fn_error $? "no acceptable C compiler found in \$PATH 34611 See \`config.log' for more details" "$LINENO" 5; } 34612 34613 # Provide some information about the compiler. 34614 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 34615 set X $ac_compile 34616 ac_compiler=$2 34617 for ac_option in --version -v -V -qversion; do 34618 { { ac_try="$ac_compiler $ac_option >&5" 34619 case "(($ac_try" in 34620 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34621 *) ac_try_echo=$ac_try;; 34622 esac 34623 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34624 $as_echo "$ac_try_echo"; } >&5 34625 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 34626 ac_status=$? 34627 if test -s conftest.err; then 34628 sed '10a\ 34629 ... rest of stderr output deleted ... 34630 10q' conftest.err >conftest.er1 34631 cat conftest.er1 >&5 34632 fi 34633 rm -f conftest.er1 conftest.err 34634 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34635 test $ac_status = 0; } 34636 done 34637 34638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34639 /* end confdefs.h. */ 34640 34641 int 34642 main () 34643 { 34644 34645 ; 34646 return 0; 34647 } 34648 _ACEOF 34649 ac_clean_files_save=$ac_clean_files 34650 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 34651 # Try to create an executable without -o first, disregard a.out. 34652 # It will help us diagnose broken compilers, and finding out an intuition 34653 # of exeext. 34654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 34655 $as_echo_n "checking whether the C compiler works... " >&6; } 34656 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 34657 34658 # The possible output files: 34659 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 34660 34661 ac_rmfiles= 34662 for ac_file in $ac_files 34663 do 34664 case $ac_file in 34665 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34666 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 34667 esac 34668 done 34669 rm -f $ac_rmfiles 34670 34671 if { { ac_try="$ac_link_default" 34672 case "(($ac_try" in 34673 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34674 *) ac_try_echo=$ac_try;; 34675 esac 34676 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34677 $as_echo "$ac_try_echo"; } >&5 34678 (eval "$ac_link_default") 2>&5 34679 ac_status=$? 34680 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34681 test $ac_status = 0; }; then : 34682 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 34683 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 34684 # in a Makefile. We should not override ac_cv_exeext if it was cached, 34685 # so that the user can short-circuit this test for compilers unknown to 34686 # Autoconf. 34687 for ac_file in $ac_files '' 34688 do 34689 test -f "$ac_file" || continue 34690 case $ac_file in 34691 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 34692 ;; 34693 [ab].out ) 34694 # We found the default executable, but exeext='' is most 34695 # certainly right. 34696 break;; 34697 *.* ) 34698 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 34699 then :; else 34700 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34701 fi 34702 # We set ac_cv_exeext here because the later test for it is not 34703 # safe: cross compilers may not add the suffix if given an `-o' 34704 # argument, so we may need to know it at that point already. 34705 # Even if this section looks crufty: it has the advantage of 34706 # actually working. 34707 break;; 34708 * ) 34709 break;; 34710 esac 34711 done 34712 test "$ac_cv_exeext" = no && ac_cv_exeext= 34713 34714 else 34715 ac_file='' 34716 fi 34717 if test -z "$ac_file"; then : 34718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34719 $as_echo "no" >&6; } 34720 $as_echo "$as_me: failed program was:" >&5 34721 sed 's/^/| /' conftest.$ac_ext >&5 34722 34723 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34724 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34725 as_fn_error 77 "C compiler cannot create executables 34726 See \`config.log' for more details" "$LINENO" 5; } 34727 else 34728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 34729 $as_echo "yes" >&6; } 34730 fi 34731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 34732 $as_echo_n "checking for C compiler default output file name... " >&6; } 34733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 34734 $as_echo "$ac_file" >&6; } 34735 ac_exeext=$ac_cv_exeext 34736 34737 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 34738 ac_clean_files=$ac_clean_files_save 34739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 34740 $as_echo_n "checking for suffix of executables... " >&6; } 34741 if { { ac_try="$ac_link" 34742 case "(($ac_try" in 34743 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34744 *) ac_try_echo=$ac_try;; 34745 esac 34746 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34747 $as_echo "$ac_try_echo"; } >&5 34748 (eval "$ac_link") 2>&5 34749 ac_status=$? 34750 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34751 test $ac_status = 0; }; then : 34752 # If both `conftest.exe' and `conftest' are `present' (well, observable) 34753 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 34754 # work properly (i.e., refer to `conftest.exe'), while it won't with 34755 # `rm'. 34756 for ac_file in conftest.exe conftest conftest.*; do 34757 test -f "$ac_file" || continue 34758 case $ac_file in 34759 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34760 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34761 break;; 34762 * ) break;; 34763 esac 34764 done 34765 else 34766 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34767 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34768 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 34769 See \`config.log' for more details" "$LINENO" 5; } 34770 fi 34771 rm -f conftest conftest$ac_cv_exeext 34772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 34773 $as_echo "$ac_cv_exeext" >&6; } 34774 34775 rm -f conftest.$ac_ext 34776 EXEEXT=$ac_cv_exeext 34777 ac_exeext=$EXEEXT 34778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34779 /* end confdefs.h. */ 34780 #include <stdio.h> 34781 int 34782 main () 34783 { 34784 FILE *f = fopen ("conftest.out", "w"); 34785 return ferror (f) || fclose (f) != 0; 34786 34787 ; 34788 return 0; 34789 } 34790 _ACEOF 34791 ac_clean_files="$ac_clean_files conftest.out" 34792 # Check that the compiler produces executables we can run. If not, either 34793 # the compiler is broken, or we cross compile. 34794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 34795 $as_echo_n "checking whether we are cross compiling... " >&6; } 34796 if test "$cross_compiling" != yes; then 34797 { { ac_try="$ac_link" 34798 case "(($ac_try" in 34799 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34800 *) ac_try_echo=$ac_try;; 34801 esac 34802 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34803 $as_echo "$ac_try_echo"; } >&5 34804 (eval "$ac_link") 2>&5 34805 ac_status=$? 34806 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34807 test $ac_status = 0; } 34808 if { ac_try='./conftest$ac_cv_exeext' 34809 { { case "(($ac_try" in 34810 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34811 *) ac_try_echo=$ac_try;; 34812 esac 34813 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34814 $as_echo "$ac_try_echo"; } >&5 34815 (eval "$ac_try") 2>&5 34816 ac_status=$? 34817 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34818 test $ac_status = 0; }; }; then 34819 cross_compiling=no 34820 else 34821 if test "$cross_compiling" = maybe; then 34822 cross_compiling=yes 34823 else 34824 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34825 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34826 as_fn_error $? "cannot run C compiled programs. 34827 If you meant to cross compile, use \`--host'. 34828 See \`config.log' for more details" "$LINENO" 5; } 34829 fi 34830 fi 34831 fi 34832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34833 $as_echo "$cross_compiling" >&6; } 34834 34835 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34836 ac_clean_files=$ac_clean_files_save 34837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34838 $as_echo_n "checking for suffix of object files... " >&6; } 34839 if ${ac_cv_objext+:} false; then : 34840 $as_echo_n "(cached) " >&6 34841 else 34842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34843 /* end confdefs.h. */ 34844 34845 int 34846 main () 34847 { 34848 34849 ; 34850 return 0; 34851 } 34852 _ACEOF 34853 rm -f conftest.o conftest.obj 34854 if { { ac_try="$ac_compile" 34855 case "(($ac_try" in 34856 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34857 *) ac_try_echo=$ac_try;; 34858 esac 34859 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34860 $as_echo "$ac_try_echo"; } >&5 34861 (eval "$ac_compile") 2>&5 34862 ac_status=$? 34863 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34864 test $ac_status = 0; }; then : 34865 for ac_file in conftest.o conftest.obj conftest.*; do 34866 test -f "$ac_file" || continue; 34867 case $ac_file in 34868 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34869 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34870 break;; 34871 esac 34872 done 34873 else 34874 $as_echo "$as_me: failed program was:" >&5 34875 sed 's/^/| /' conftest.$ac_ext >&5 34876 34877 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34878 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34879 as_fn_error $? "cannot compute suffix of object files: cannot compile 34880 See \`config.log' for more details" "$LINENO" 5; } 34881 fi 34882 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34883 fi 34884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34885 $as_echo "$ac_cv_objext" >&6; } 34886 OBJEXT=$ac_cv_objext 34887 ac_objext=$OBJEXT 34888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34889 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34890 if ${ac_cv_c_compiler_gnu+:} false; then : 34891 $as_echo_n "(cached) " >&6 34892 else 34893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34894 /* end confdefs.h. */ 34895 34896 int 34897 main () 34898 { 34899 #ifndef __GNUC__ 34900 choke me 34901 #endif 34902 34903 ; 34904 return 0; 34905 } 34906 _ACEOF 34907 if ac_fn_c_try_compile "$LINENO"; then : 34908 ac_compiler_gnu=yes 34909 else 34910 ac_compiler_gnu=no 34911 fi 34912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34913 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34914 34915 fi 34916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34917 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34918 if test $ac_compiler_gnu = yes; then 34919 GCC=yes 34920 else 34921 GCC= 34922 fi 34923 ac_test_CFLAGS=${CFLAGS+set} 34924 ac_save_CFLAGS=$CFLAGS 34925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34926 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34927 if ${ac_cv_prog_cc_g+:} false; then : 34928 $as_echo_n "(cached) " >&6 34929 else 34930 ac_save_c_werror_flag=$ac_c_werror_flag 34931 ac_c_werror_flag=yes 34932 ac_cv_prog_cc_g=no 34933 CFLAGS="-g" 34934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34935 /* end confdefs.h. */ 34936 34937 int 34938 main () 34939 { 34940 34941 ; 34942 return 0; 34943 } 34944 _ACEOF 34945 if ac_fn_c_try_compile "$LINENO"; then : 34946 ac_cv_prog_cc_g=yes 34947 else 34948 CFLAGS="" 34949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34950 /* end confdefs.h. */ 34951 34952 int 34953 main () 34954 { 34955 34956 ; 34957 return 0; 34958 } 34959 _ACEOF 34960 if ac_fn_c_try_compile "$LINENO"; then : 34961 34962 else 34963 ac_c_werror_flag=$ac_save_c_werror_flag 34964 CFLAGS="-g" 34965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34966 /* end confdefs.h. */ 34967 34968 int 34969 main () 34970 { 34971 34972 ; 34973 return 0; 34974 } 34975 _ACEOF 34976 if ac_fn_c_try_compile "$LINENO"; then : 34977 ac_cv_prog_cc_g=yes 34978 fi 34979 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34980 fi 34981 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34982 fi 34983 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34984 ac_c_werror_flag=$ac_save_c_werror_flag 34985 fi 34986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 34987 $as_echo "$ac_cv_prog_cc_g" >&6; } 34988 if test "$ac_test_CFLAGS" = set; then 34989 CFLAGS=$ac_save_CFLAGS 34990 elif test $ac_cv_prog_cc_g = yes; then 34991 if test "$GCC" = yes; then 34992 CFLAGS="-g -O2" 34993 else 34994 CFLAGS="-g" 34995 fi 34996 else 34997 if test "$GCC" = yes; then 34998 CFLAGS="-O2" 34999 else 35000 CFLAGS= 35001 fi 35002 fi 35003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 35004 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 35005 if ${ac_cv_prog_cc_c89+:} false; then : 35006 $as_echo_n "(cached) " >&6 35007 else 35008 ac_cv_prog_cc_c89=no 35009 ac_save_CC=$CC 35010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35011 /* end confdefs.h. */ 35012 #include <stdarg.h> 35013 #include <stdio.h> 35014 struct stat; 35015 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 35016 struct buf { int x; }; 35017 FILE * (*rcsopen) (struct buf *, struct stat *, int); 35018 static char *e (p, i) 35019 char **p; 35020 int i; 35021 { 35022 return p[i]; 35023 } 35024 static char *f (char * (*g) (char **, int), char **p, ...) 35025 { 35026 char *s; 35027 va_list v; 35028 va_start (v,p); 35029 s = g (p, va_arg (v,int)); 35030 va_end (v); 35031 return s; 35032 } 35033 35034 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 35035 function prototypes and stuff, but not '\xHH' hex character constants. 35036 These don't provoke an error unfortunately, instead are silently treated 35037 as 'x'. The following induces an error, until -std is added to get 35038 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 35039 array size at least. It's necessary to write '\x00'==0 to get something 35040 that's true only with -std. */ 35041 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 35042 35043 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 35044 inside strings and character constants. */ 35045 #define FOO(x) 'x' 35046 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 35047 35048 int test (int i, double x); 35049 struct s1 {int (*f) (int a);}; 35050 struct s2 {int (*f) (double a);}; 35051 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 35052 int argc; 35053 char **argv; 35054 int 35055 main () 35056 { 35057 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 35058 ; 35059 return 0; 35060 } 35061 _ACEOF 35062 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 35063 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 35064 do 35065 CC="$ac_save_CC $ac_arg" 35066 if ac_fn_c_try_compile "$LINENO"; then : 35067 ac_cv_prog_cc_c89=$ac_arg 35068 fi 35069 rm -f core conftest.err conftest.$ac_objext 35070 test "x$ac_cv_prog_cc_c89" != "xno" && break 35071 done 35072 rm -f conftest.$ac_ext 35073 CC=$ac_save_CC 35074 35075 fi 35076 # AC_CACHE_VAL 35077 case "x$ac_cv_prog_cc_c89" in 35078 x) 35079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 35080 $as_echo "none needed" >&6; } ;; 35081 xno) 35082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 35083 $as_echo "unsupported" >&6; } ;; 35084 *) 35085 CC="$CC $ac_cv_prog_cc_c89" 35086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 35087 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 35088 esac 35089 if test "x$ac_cv_prog_cc_c89" != xno; then : 35090 35091 fi 35092 35093 ac_ext=cpp 35094 ac_cpp='$CXXCPP $CPPFLAGS' 35095 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35096 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35097 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35098 35099 35100 35101 COMPILER_NAME=C++ 35102 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 35103 35104 if test "x$CXX" != x; then 35105 # User has supplied compiler name already, always let that override. 35106 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 35107 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 35108 if test "x`basename $CXX`" = "x$CXX"; then 35109 # A command without a complete path is provided, search $PATH. 35110 35111 for ac_prog in $CXX 35112 do 35113 # Extract the first word of "$ac_prog", so it can be a program name with args. 35114 set dummy $ac_prog; ac_word=$2 35115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35116 $as_echo_n "checking for $ac_word... " >&6; } 35117 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 35118 $as_echo_n "(cached) " >&6 35119 else 35120 case $POTENTIAL_CXX in 35121 [\\/]* | ?:[\\/]*) 35122 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 35123 ;; 35124 *) 35125 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35126 for as_dir in $PATH 35127 do 35128 IFS=$as_save_IFS 35129 test -z "$as_dir" && as_dir=. 35130 for ac_exec_ext in '' $ac_executable_extensions; do 35131 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35132 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35133 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35134 break 2 35135 fi 35136 done 35137 done 35138 IFS=$as_save_IFS 35139 35140 ;; 35141 esac 35142 fi 35143 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 35144 if test -n "$POTENTIAL_CXX"; then 35145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 35146 $as_echo "$POTENTIAL_CXX" >&6; } 35147 else 35148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35149 $as_echo "no" >&6; } 35150 fi 35151 35152 35153 test -n "$POTENTIAL_CXX" && break 35154 done 35155 35156 if test "x$POTENTIAL_CXX" != x; then 35157 CXX=$POTENTIAL_CXX 35158 else 35159 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 35160 fi 35161 else 35162 # Otherwise it might already be a complete path 35163 if test ! -x "$CXX"; then 35164 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 35165 fi 35166 fi 35167 else 35168 # No user supplied value. Locate compiler ourselves. 35169 35170 # If we are cross compiling, assume cross compilation tools follows the 35171 # cross compilation standard where they are prefixed with the autoconf 35172 # standard name for the target. For example the binary 35173 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 35174 # If we are not cross compiling, then the default compiler name will be 35175 # used. 35176 35177 CXX= 35178 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 35179 # before checking the rest of the PATH. 35180 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 35181 # step, this should not be necessary. 35182 if test -n "$TOOLCHAIN_PATH"; then 35183 PATH_save="$PATH" 35184 PATH="$TOOLCHAIN_PATH" 35185 if test -n "$ac_tool_prefix"; then 35186 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 35187 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 35188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35189 $as_echo_n "checking for $ac_word... " >&6; } 35190 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 35191 $as_echo_n "(cached) " >&6 35192 else 35193 case $TOOLCHAIN_PATH_CXX in 35194 [\\/]* | ?:[\\/]*) 35195 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 35196 ;; 35197 *) 35198 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35199 for as_dir in $PATH 35200 do 35201 IFS=$as_save_IFS 35202 test -z "$as_dir" && as_dir=. 35203 for ac_exec_ext in '' $ac_executable_extensions; do 35204 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35205 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 35206 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35207 break 2 35208 fi 35209 done 35210 done 35211 IFS=$as_save_IFS 35212 35213 ;; 35214 esac 35215 fi 35216 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 35217 if test -n "$TOOLCHAIN_PATH_CXX"; then 35218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 35219 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 35220 else 35221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35222 $as_echo "no" >&6; } 35223 fi 35224 35225 35226 fi 35227 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CXX"; then 35228 ac_pt_TOOLCHAIN_PATH_CXX=$TOOLCHAIN_PATH_CXX 35229 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 35230 set dummy $SEARCH_LIST; ac_word=$2 35231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35232 $as_echo_n "checking for $ac_word... " >&6; } 35233 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX+:} false; then : 35234 $as_echo_n "(cached) " >&6 35235 else 35236 case $ac_pt_TOOLCHAIN_PATH_CXX in 35237 [\\/]* | ?:[\\/]*) 35238 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$ac_pt_TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 35239 ;; 35240 *) 35241 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35242 for as_dir in $PATH 35243 do 35244 IFS=$as_save_IFS 35245 test -z "$as_dir" && as_dir=. 35246 for ac_exec_ext in '' $ac_executable_extensions; do 35247 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35248 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 35249 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35250 break 2 35251 fi 35252 done 35253 done 35254 IFS=$as_save_IFS 35255 35256 ;; 35257 esac 35258 fi 35259 ac_pt_TOOLCHAIN_PATH_CXX=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX 35260 if test -n "$ac_pt_TOOLCHAIN_PATH_CXX"; then 35261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CXX" >&5 35262 $as_echo "$ac_pt_TOOLCHAIN_PATH_CXX" >&6; } 35263 else 35264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35265 $as_echo "no" >&6; } 35266 fi 35267 35268 if test "x$ac_pt_TOOLCHAIN_PATH_CXX" = x; then 35269 TOOLCHAIN_PATH_CXX="" 35270 else 35271 case $cross_compiling:$ac_tool_warned in 35272 yes:) 35273 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35274 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35275 ac_tool_warned=yes ;; 35276 esac 35277 TOOLCHAIN_PATH_CXX=$ac_pt_TOOLCHAIN_PATH_CXX 35278 fi 35279 else 35280 TOOLCHAIN_PATH_CXX="$ac_cv_path_TOOLCHAIN_PATH_CXX" 35281 fi 35282 35283 CXX=$TOOLCHAIN_PATH_CXX 35284 PATH="$PATH_save" 35285 fi 35286 35287 # AC_PATH_TOOL can't be run multiple times with the same variable, 35288 # so create a new name for this run. 35289 if test "x$CXX" = x; then 35290 if test -n "$ac_tool_prefix"; then 35291 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 35292 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 35293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35294 $as_echo_n "checking for $ac_word... " >&6; } 35295 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 35296 $as_echo_n "(cached) " >&6 35297 else 35298 case $POTENTIAL_CXX in 35299 [\\/]* | ?:[\\/]*) 35300 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 35301 ;; 35302 *) 35303 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35304 for as_dir in $PATH 35305 do 35306 IFS=$as_save_IFS 35307 test -z "$as_dir" && as_dir=. 35308 for ac_exec_ext in '' $ac_executable_extensions; do 35309 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35310 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35311 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35312 break 2 35313 fi 35314 done 35315 done 35316 IFS=$as_save_IFS 35317 35318 ;; 35319 esac 35320 fi 35321 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 35322 if test -n "$POTENTIAL_CXX"; then 35323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 35324 $as_echo "$POTENTIAL_CXX" >&6; } 35325 else 35326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35327 $as_echo "no" >&6; } 35328 fi 35329 35330 35331 fi 35332 if test -z "$ac_cv_path_POTENTIAL_CXX"; then 35333 ac_pt_POTENTIAL_CXX=$POTENTIAL_CXX 35334 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 35335 set dummy $SEARCH_LIST; ac_word=$2 35336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35337 $as_echo_n "checking for $ac_word... " >&6; } 35338 if ${ac_cv_path_ac_pt_POTENTIAL_CXX+:} false; then : 35339 $as_echo_n "(cached) " >&6 35340 else 35341 case $ac_pt_POTENTIAL_CXX in 35342 [\\/]* | ?:[\\/]*) 35343 ac_cv_path_ac_pt_POTENTIAL_CXX="$ac_pt_POTENTIAL_CXX" # Let the user override the test with a path. 35344 ;; 35345 *) 35346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35347 for as_dir in $PATH 35348 do 35349 IFS=$as_save_IFS 35350 test -z "$as_dir" && as_dir=. 35351 for ac_exec_ext in '' $ac_executable_extensions; do 35352 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35353 ac_cv_path_ac_pt_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 35354 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35355 break 2 35356 fi 35357 done 35358 done 35359 IFS=$as_save_IFS 35360 35361 ;; 35362 esac 35363 fi 35364 ac_pt_POTENTIAL_CXX=$ac_cv_path_ac_pt_POTENTIAL_CXX 35365 if test -n "$ac_pt_POTENTIAL_CXX"; then 35366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CXX" >&5 35367 $as_echo "$ac_pt_POTENTIAL_CXX" >&6; } 35368 else 35369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35370 $as_echo "no" >&6; } 35371 fi 35372 35373 if test "x$ac_pt_POTENTIAL_CXX" = x; then 35374 POTENTIAL_CXX="" 35375 else 35376 case $cross_compiling:$ac_tool_warned in 35377 yes:) 35378 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35379 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35380 ac_tool_warned=yes ;; 35381 esac 35382 POTENTIAL_CXX=$ac_pt_POTENTIAL_CXX 35383 fi 35384 else 35385 POTENTIAL_CXX="$ac_cv_path_POTENTIAL_CXX" 35386 fi 35387 35388 CXX=$POTENTIAL_CXX 35389 fi 35390 35391 if test "x$CXX" = x; then 35392 35393 # Print a helpful message on how to acquire the necessary build dependency. 35394 # devkit is the help tag: freetype, cups, alsa etc 35395 MISSING_DEPENDENCY=devkit 35396 35397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35398 cygwin_help $MISSING_DEPENDENCY 35399 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35400 msys_help $MISSING_DEPENDENCY 35401 else 35402 PKGHANDLER_COMMAND= 35403 35404 case $PKGHANDLER in 35405 apt-get) 35406 apt_help $MISSING_DEPENDENCY ;; 35407 yum) 35408 yum_help $MISSING_DEPENDENCY ;; 35409 brew) 35410 brew_help $MISSING_DEPENDENCY ;; 35411 port) 35412 port_help $MISSING_DEPENDENCY ;; 35413 pkgutil) 35414 pkgutil_help $MISSING_DEPENDENCY ;; 35415 pkgadd) 35416 pkgadd_help $MISSING_DEPENDENCY ;; 35417 esac 35418 35419 if test "x$PKGHANDLER_COMMAND" != x; then 35420 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 35421 fi 35422 fi 35423 35424 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 35425 fi 35426 fi 35427 35428 # Now we have a compiler binary in CXX. Make sure it's okay. 35429 35430 # Only process if variable expands to non-empty 35431 35432 if test "x$CXX" != x; then 35433 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35434 35435 # First separate the path from the arguments. This will split at the first 35436 # space. 35437 complete="$CXX" 35438 path="${complete%% *}" 35439 tmp="$complete EOL" 35440 arguments="${tmp#* }" 35441 35442 # Input might be given as Windows format, start by converting to 35443 # unix format. 35444 new_path=`$CYGPATH -u "$path"` 35445 35446 # Now try to locate executable using which 35447 new_path=`$WHICH "$new_path" 2> /dev/null` 35448 # bat and cmd files are not always considered executable in cygwin causing which 35449 # to not find them 35450 if test "x$new_path" = x \ 35451 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35452 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35453 new_path=`$CYGPATH -u "$path"` 35454 fi 35455 if test "x$new_path" = x; then 35456 # Oops. Which didn't find the executable. 35457 # The splitting of arguments from the executable at a space might have been incorrect, 35458 # since paths with space are more likely in Windows. Give it another try with the whole 35459 # argument. 35460 path="$complete" 35461 arguments="EOL" 35462 new_path=`$CYGPATH -u "$path"` 35463 new_path=`$WHICH "$new_path" 2> /dev/null` 35464 # bat and cmd files are not always considered executable in cygwin causing which 35465 # to not find them 35466 if test "x$new_path" = x \ 35467 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35468 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35469 new_path=`$CYGPATH -u "$path"` 35470 fi 35471 if test "x$new_path" = x; then 35472 # It's still not found. Now this is an unrecoverable error. 35473 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35474 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35475 has_space=`$ECHO "$complete" | $GREP " "` 35476 if test "x$has_space" != x; then 35477 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35478 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35479 fi 35480 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35481 fi 35482 fi 35483 35484 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35485 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35486 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35487 # "foo.exe" is OK but "foo" is an error. 35488 # 35489 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35490 # It is also a way to make sure we got the proper file name for the real test later on. 35491 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35492 if test "x$test_shortpath" = x; then 35493 # Short path failed, file does not exist as specified. 35494 # Try adding .exe or .cmd 35495 if test -f "${new_path}.exe"; then 35496 input_to_shortpath="${new_path}.exe" 35497 elif test -f "${new_path}.cmd"; then 35498 input_to_shortpath="${new_path}.cmd" 35499 else 35500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 35501 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 35502 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35503 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35504 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35505 fi 35506 else 35507 input_to_shortpath="$new_path" 35508 fi 35509 35510 # Call helper function which possibly converts this using DOS-style short mode. 35511 # If so, the updated path is stored in $new_path. 35512 new_path="$input_to_shortpath" 35513 35514 input_path="$input_to_shortpath" 35515 # Check if we need to convert this using DOS-style short mode. If the path 35516 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35517 # take no chances and rewrite it. 35518 # Note: m4 eats our [], so we need to use [ and ] instead. 35519 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35520 if test "x$has_forbidden_chars" != x; then 35521 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35522 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35523 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35524 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35525 # Going to short mode and back again did indeed matter. Since short mode is 35526 # case insensitive, let's make it lowercase to improve readability. 35527 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35528 # Now convert it back to Unix-style (cygpath) 35529 input_path=`$CYGPATH -u "$shortmode_path"` 35530 new_path="$input_path" 35531 fi 35532 fi 35533 35534 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35535 if test "x$test_cygdrive_prefix" = x; then 35536 # As a simple fix, exclude /usr/bin since it's not a real path. 35537 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35538 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35539 # a path prefixed by /cygdrive for fixpath to work. 35540 new_path="$CYGWIN_ROOT_PATH$input_path" 35541 fi 35542 fi 35543 35544 # remove trailing .exe if any 35545 new_path="${new_path/%.exe/}" 35546 35547 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35548 35549 # First separate the path from the arguments. This will split at the first 35550 # space. 35551 complete="$CXX" 35552 path="${complete%% *}" 35553 tmp="$complete EOL" 35554 arguments="${tmp#* }" 35555 35556 # Input might be given as Windows format, start by converting to 35557 # unix format. 35558 new_path="$path" 35559 35560 windows_path="$new_path" 35561 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35562 unix_path=`$CYGPATH -u "$windows_path"` 35563 new_path="$unix_path" 35564 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35565 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35566 new_path="$unix_path" 35567 fi 35568 35569 35570 # Now try to locate executable using which 35571 new_path=`$WHICH "$new_path" 2> /dev/null` 35572 35573 if test "x$new_path" = x; then 35574 # Oops. Which didn't find the executable. 35575 # The splitting of arguments from the executable at a space might have been incorrect, 35576 # since paths with space are more likely in Windows. Give it another try with the whole 35577 # argument. 35578 path="$complete" 35579 arguments="EOL" 35580 new_path="$path" 35581 35582 windows_path="$new_path" 35583 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35584 unix_path=`$CYGPATH -u "$windows_path"` 35585 new_path="$unix_path" 35586 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35587 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35588 new_path="$unix_path" 35589 fi 35590 35591 35592 new_path=`$WHICH "$new_path" 2> /dev/null` 35593 # bat and cmd files are not always considered executable in MSYS causing which 35594 # to not find them 35595 if test "x$new_path" = x \ 35596 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35597 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35598 new_path="$path" 35599 35600 windows_path="$new_path" 35601 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35602 unix_path=`$CYGPATH -u "$windows_path"` 35603 new_path="$unix_path" 35604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35605 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35606 new_path="$unix_path" 35607 fi 35608 35609 fi 35610 35611 if test "x$new_path" = x; then 35612 # It's still not found. Now this is an unrecoverable error. 35613 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35614 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35615 has_space=`$ECHO "$complete" | $GREP " "` 35616 if test "x$has_space" != x; then 35617 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35618 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35619 fi 35620 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35621 fi 35622 fi 35623 35624 # Now new_path has a complete unix path to the binary 35625 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35626 # Keep paths in /bin as-is, but remove trailing .exe if any 35627 new_path="${new_path/%.exe/}" 35628 # Do not save /bin paths to all_fixpath_prefixes! 35629 else 35630 # Not in mixed or Windows style, start by that. 35631 new_path=`cmd //c echo $new_path` 35632 35633 input_path="$new_path" 35634 # Check if we need to convert this using DOS-style short mode. If the path 35635 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35636 # take no chances and rewrite it. 35637 # Note: m4 eats our [], so we need to use [ and ] instead. 35638 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35639 if test "x$has_forbidden_chars" != x; then 35640 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35641 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35642 fi 35643 35644 # Output is in $new_path 35645 35646 windows_path="$new_path" 35647 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35648 unix_path=`$CYGPATH -u "$windows_path"` 35649 new_path="$unix_path" 35650 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35651 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35652 new_path="$unix_path" 35653 fi 35654 35655 # remove trailing .exe if any 35656 new_path="${new_path/%.exe/}" 35657 35658 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35659 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35660 fi 35661 35662 else 35663 # We're on a unix platform. Hooray! :) 35664 # First separate the path from the arguments. This will split at the first 35665 # space. 35666 complete="$CXX" 35667 path="${complete%% *}" 35668 tmp="$complete EOL" 35669 arguments="${tmp#* }" 35670 35671 # Cannot rely on the command "which" here since it doesn't always work. 35672 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35673 if test -z "$is_absolute_path"; then 35674 # Path to executable is not absolute. Find it. 35675 IFS_save="$IFS" 35676 IFS=: 35677 for p in $PATH; do 35678 if test -f "$p/$path" && test -x "$p/$path"; then 35679 new_path="$p/$path" 35680 break 35681 fi 35682 done 35683 IFS="$IFS_save" 35684 else 35685 # This is an absolute path, we can use it without further modifications. 35686 new_path="$path" 35687 fi 35688 35689 if test "x$new_path" = x; then 35690 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35691 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35692 has_space=`$ECHO "$complete" | $GREP " "` 35693 if test "x$has_space" != x; then 35694 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35695 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35696 fi 35697 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35698 fi 35699 fi 35700 35701 # Now join together the path and the arguments once again 35702 if test "x$arguments" != xEOL; then 35703 new_complete="$new_path ${arguments% *}" 35704 else 35705 new_complete="$new_path" 35706 fi 35707 35708 if test "x$complete" != "x$new_complete"; then 35709 CXX="$new_complete" 35710 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 35711 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 35712 fi 35713 fi 35714 35715 TEST_COMPILER="$CXX" 35716 35717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 35718 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 35719 SYMLINK_ORIGINAL="$TEST_COMPILER" 35720 35721 if test "x$OPENJDK_BUILD_OS" != xwindows; then 35722 # Follow a chain of symbolic links. Use readlink 35723 # where it exists, else fall back to horribly 35724 # complicated shell code. 35725 if test "x$READLINK_TESTED" != yes; then 35726 # On MacOSX there is a readlink tool with a different 35727 # purpose than the GNU readlink tool. Check the found readlink. 35728 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 35729 if test "x$ISGNU" = x; then 35730 # A readlink that we do not know how to use. 35731 # Are there other non-GNU readlinks out there? 35732 READLINK_TESTED=yes 35733 READLINK= 35734 fi 35735 fi 35736 35737 if test "x$READLINK" != x; then 35738 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 35739 else 35740 # Save the current directory for restoring afterwards 35741 STARTDIR=$PWD 35742 COUNTER=0 35743 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 35744 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 35745 cd $sym_link_dir 35746 # Use -P flag to resolve symlinks in directories. 35747 cd `$THEPWDCMD -P` 35748 sym_link_dir=`$THEPWDCMD -P` 35749 # Resolve file symlinks 35750 while test $COUNTER -lt 20; do 35751 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 35752 if test "x$ISLINK" == x; then 35753 # This is not a symbolic link! We are done! 35754 break 35755 fi 35756 # Again resolve directory symlinks since the target of the just found 35757 # link could be in a different directory 35758 cd `$DIRNAME $ISLINK` 35759 sym_link_dir=`$THEPWDCMD -P` 35760 sym_link_file=`$BASENAME $ISLINK` 35761 let COUNTER=COUNTER+1 35762 done 35763 cd $STARTDIR 35764 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 35765 fi 35766 fi 35767 35768 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 35769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 35770 $as_echo "no symlink" >&6; } 35771 else 35772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 35773 $as_echo "$SYMLINK_ORIGINAL" >&6; } 35774 35775 # We can't handle ccache by gcc wrappers, since we need to know if we're 35776 # using ccache. Instead ccache usage must be controlled by a configure option. 35777 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 35778 if test "x$COMPILER_BASENAME" = "xccache"; then 35779 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 35780 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 35781 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 35782 fi 35783 fi 35784 35785 35786 COMPILER=$CXX 35787 COMPILER_NAME=$COMPILER_NAME 35788 35789 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 35790 # cc -V output typically looks like 35791 # cc: Sun C 5.12 Linux_i386 2011/11/16 35792 # or 35793 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 35794 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 35795 # Check that this is likely to be the Solaris Studio cc. 35796 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 35797 if test $? -ne 0; then 35798 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35799 { $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 35800 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35801 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35802 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35803 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35804 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35805 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35806 fi 35807 # Remove usage instructions (if present), and 35808 # collapse compiler output into a single line 35809 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35810 $SED -e 's/ *[Uu]sage:.*//'` 35811 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35812 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 35813 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 35814 # xlc -qversion output typically looks like 35815 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 35816 # Version: 11.01.0000.0015 35817 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 35818 # Check that this is likely to be the IBM XL C compiler. 35819 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 35820 if test $? -ne 0; then 35821 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35822 { $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 35823 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35824 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35825 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35826 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35827 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35828 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35829 fi 35830 # Collapse compiler output into a single line 35831 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35832 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35833 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 35834 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 35835 # There is no specific version flag, but all output starts with a version string. 35836 # First line typically looks something like: 35837 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 35838 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 35839 # Check that this is likely to be Microsoft CL.EXE. 35840 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 35841 if test $? -ne 0; then 35842 { $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 35843 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35844 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35845 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35846 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35847 fi 35848 # Collapse compiler output into a single line 35849 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35850 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35851 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 35852 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 35853 # gcc --version output typically looks like 35854 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 35855 # Copyright (C) 2013 Free Software Foundation, Inc. 35856 # This is free software; see the source for copying conditions. There is NO 35857 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 35858 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35859 # Check that this is likely to be GCC. 35860 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 35861 if test $? -ne 0; then 35862 { $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 35863 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35864 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 35865 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 35866 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35867 fi 35868 # Remove Copyright and legalese from version string, and 35869 # collapse into a single line 35870 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35871 $SED -e 's/ *Copyright .*//'` 35872 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35873 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 35874 elif test "x$TOOLCHAIN_TYPE" = xclang; then 35875 # clang --version output typically looks like 35876 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 35877 # clang version 3.3 (tags/RELEASE_33/final) 35878 # or 35879 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 35880 # Target: x86_64-pc-linux-gnu 35881 # Thread model: posix 35882 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35883 # Check that this is likely to be clang 35884 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 35885 if test $? -ne 0; then 35886 { $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 35887 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35888 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35889 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35890 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35891 fi 35892 # Collapse compiler output into a single line 35893 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35894 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35895 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 35896 else 35897 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 35898 fi 35899 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 35900 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 35901 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 35902 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 35903 35904 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 35905 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 35906 35907 35908 # Now that we have resolved CXX ourself, let autoconf have its go at it 35909 ac_ext=cpp 35910 ac_cpp='$CXXCPP $CPPFLAGS' 35911 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35912 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35913 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35914 if test -z "$CXX"; then 35915 if test -n "$CCC"; then 35916 CXX=$CCC 35917 else 35918 if test -n "$ac_tool_prefix"; then 35919 for ac_prog in $CXX 35920 do 35921 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 35922 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 35923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35924 $as_echo_n "checking for $ac_word... " >&6; } 35925 if ${ac_cv_prog_CXX+:} false; then : 35926 $as_echo_n "(cached) " >&6 35927 else 35928 if test -n "$CXX"; then 35929 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35930 else 35931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35932 for as_dir in $PATH 35933 do 35934 IFS=$as_save_IFS 35935 test -z "$as_dir" && as_dir=. 35936 for ac_exec_ext in '' $ac_executable_extensions; do 35937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35938 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35940 break 2 35941 fi 35942 done 35943 done 35944 IFS=$as_save_IFS 35945 35946 fi 35947 fi 35948 CXX=$ac_cv_prog_CXX 35949 if test -n "$CXX"; then 35950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 35951 $as_echo "$CXX" >&6; } 35952 else 35953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35954 $as_echo "no" >&6; } 35955 fi 35956 35957 35958 test -n "$CXX" && break 35959 done 35960 fi 35961 if test -z "$CXX"; then 35962 ac_ct_CXX=$CXX 35963 for ac_prog in $CXX 35964 do 35965 # Extract the first word of "$ac_prog", so it can be a program name with args. 35966 set dummy $ac_prog; ac_word=$2 35967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35968 $as_echo_n "checking for $ac_word... " >&6; } 35969 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 35970 $as_echo_n "(cached) " >&6 35971 else 35972 if test -n "$ac_ct_CXX"; then 35973 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 35974 else 35975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35976 for as_dir in $PATH 35977 do 35978 IFS=$as_save_IFS 35979 test -z "$as_dir" && as_dir=. 35980 for ac_exec_ext in '' $ac_executable_extensions; do 35981 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35982 ac_cv_prog_ac_ct_CXX="$ac_prog" 35983 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35984 break 2 35985 fi 35986 done 35987 done 35988 IFS=$as_save_IFS 35989 35990 fi 35991 fi 35992 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 35993 if test -n "$ac_ct_CXX"; then 35994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 35995 $as_echo "$ac_ct_CXX" >&6; } 35996 else 35997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35998 $as_echo "no" >&6; } 35999 fi 36000 36001 36002 test -n "$ac_ct_CXX" && break 36003 done 36004 36005 if test "x$ac_ct_CXX" = x; then 36006 CXX="g++" 36007 else 36008 case $cross_compiling:$ac_tool_warned in 36009 yes:) 36010 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36011 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36012 ac_tool_warned=yes ;; 36013 esac 36014 CXX=$ac_ct_CXX 36015 fi 36016 fi 36017 36018 fi 36019 fi 36020 # Provide some information about the compiler. 36021 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 36022 set X $ac_compile 36023 ac_compiler=$2 36024 for ac_option in --version -v -V -qversion; do 36025 { { ac_try="$ac_compiler $ac_option >&5" 36026 case "(($ac_try" in 36027 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 36028 *) ac_try_echo=$ac_try;; 36029 esac 36030 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 36031 $as_echo "$ac_try_echo"; } >&5 36032 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 36033 ac_status=$? 36034 if test -s conftest.err; then 36035 sed '10a\ 36036 ... rest of stderr output deleted ... 36037 10q' conftest.err >conftest.er1 36038 cat conftest.er1 >&5 36039 fi 36040 rm -f conftest.er1 conftest.err 36041 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 36042 test $ac_status = 0; } 36043 done 36044 36045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 36046 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 36047 if ${ac_cv_cxx_compiler_gnu+:} false; then : 36048 $as_echo_n "(cached) " >&6 36049 else 36050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36051 /* end confdefs.h. */ 36052 36053 int 36054 main () 36055 { 36056 #ifndef __GNUC__ 36057 choke me 36058 #endif 36059 36060 ; 36061 return 0; 36062 } 36063 _ACEOF 36064 if ac_fn_cxx_try_compile "$LINENO"; then : 36065 ac_compiler_gnu=yes 36066 else 36067 ac_compiler_gnu=no 36068 fi 36069 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36070 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 36071 36072 fi 36073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 36074 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 36075 if test $ac_compiler_gnu = yes; then 36076 GXX=yes 36077 else 36078 GXX= 36079 fi 36080 ac_test_CXXFLAGS=${CXXFLAGS+set} 36081 ac_save_CXXFLAGS=$CXXFLAGS 36082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 36083 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 36084 if ${ac_cv_prog_cxx_g+:} false; then : 36085 $as_echo_n "(cached) " >&6 36086 else 36087 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 36088 ac_cxx_werror_flag=yes 36089 ac_cv_prog_cxx_g=no 36090 CXXFLAGS="-g" 36091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36092 /* end confdefs.h. */ 36093 36094 int 36095 main () 36096 { 36097 36098 ; 36099 return 0; 36100 } 36101 _ACEOF 36102 if ac_fn_cxx_try_compile "$LINENO"; then : 36103 ac_cv_prog_cxx_g=yes 36104 else 36105 CXXFLAGS="" 36106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36107 /* end confdefs.h. */ 36108 36109 int 36110 main () 36111 { 36112 36113 ; 36114 return 0; 36115 } 36116 _ACEOF 36117 if ac_fn_cxx_try_compile "$LINENO"; then : 36118 36119 else 36120 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 36121 CXXFLAGS="-g" 36122 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36123 /* end confdefs.h. */ 36124 36125 int 36126 main () 36127 { 36128 36129 ; 36130 return 0; 36131 } 36132 _ACEOF 36133 if ac_fn_cxx_try_compile "$LINENO"; then : 36134 ac_cv_prog_cxx_g=yes 36135 fi 36136 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36137 fi 36138 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36139 fi 36140 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 36141 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 36142 fi 36143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 36144 $as_echo "$ac_cv_prog_cxx_g" >&6; } 36145 if test "$ac_test_CXXFLAGS" = set; then 36146 CXXFLAGS=$ac_save_CXXFLAGS 36147 elif test $ac_cv_prog_cxx_g = yes; then 36148 if test "$GXX" = yes; then 36149 CXXFLAGS="-g -O2" 36150 else 36151 CXXFLAGS="-g" 36152 fi 36153 else 36154 if test "$GXX" = yes; then 36155 CXXFLAGS="-O2" 36156 else 36157 CXXFLAGS= 36158 fi 36159 fi 36160 ac_ext=cpp 36161 ac_cpp='$CXXCPP $CPPFLAGS' 36162 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36163 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36164 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36165 36166 36167 # This is the compiler version number on the form X.Y[.Z] 36168 36169 36170 36171 36172 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 36173 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 36174 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 36175 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 36176 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 36177 fi 36178 36179 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 36180 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 36181 { $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 36182 $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;} 36183 fi 36184 36185 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 36186 { $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 36187 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 36188 fi 36189 36190 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 36191 36192 36193 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 36194 36195 36196 36197 36198 36199 36200 36201 36202 36203 36204 36205 36206 36207 36208 36209 36210 36211 36212 36213 36214 36215 36216 36217 36218 36219 36220 36221 36222 36223 36224 36225 36226 36227 36228 36229 36230 36231 36232 36233 36234 36235 36236 36237 36238 36239 36240 36241 36242 36243 # Execute function body 36244 36245 # Need to assign to a variable since m4 is blocked from modifying parts in []. 36246 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 36247 36248 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 36249 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 36250 fi 36251 36252 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 36253 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 36254 fi 36255 36256 # Version comparison method inspired by http://stackoverflow.com/a/24067243 36257 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 36258 36259 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 36260 : 36261 36262 else 36263 : 36264 36265 { $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 36266 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 36267 36268 36269 fi 36270 36271 36272 36273 36274 36275 36276 36277 36278 36279 36280 36281 36282 36283 36284 fi 36285 36286 # 36287 # Setup the preprocessor (CPP and CXXCPP) 36288 # 36289 ac_ext=c 36290 ac_cpp='$CPP $CPPFLAGS' 36291 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36292 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36293 ac_compiler_gnu=$ac_cv_c_compiler_gnu 36294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 36295 $as_echo_n "checking how to run the C preprocessor... " >&6; } 36296 # On Suns, sometimes $CPP names a directory. 36297 if test -n "$CPP" && test -d "$CPP"; then 36298 CPP= 36299 fi 36300 if test -z "$CPP"; then 36301 if ${ac_cv_prog_CPP+:} false; then : 36302 $as_echo_n "(cached) " >&6 36303 else 36304 # Double quotes because CPP needs to be expanded 36305 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 36306 do 36307 ac_preproc_ok=false 36308 for ac_c_preproc_warn_flag in '' yes 36309 do 36310 # Use a header file that comes with gcc, so configuring glibc 36311 # with a fresh cross-compiler works. 36312 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36313 # <limits.h> exists even on freestanding compilers. 36314 # On the NeXT, cc -E runs the code through the compiler's parser, 36315 # not just through cpp. "Syntax error" is here to catch this case. 36316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36317 /* end confdefs.h. */ 36318 #ifdef __STDC__ 36319 # include <limits.h> 36320 #else 36321 # include <assert.h> 36322 #endif 36323 Syntax error 36324 _ACEOF 36325 if ac_fn_c_try_cpp "$LINENO"; then : 36326 36327 else 36328 # Broken: fails on valid input. 36329 continue 36330 fi 36331 rm -f conftest.err conftest.i conftest.$ac_ext 36332 36333 # OK, works on sane cases. Now check whether nonexistent headers 36334 # can be detected and how. 36335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36336 /* end confdefs.h. */ 36337 #include <ac_nonexistent.h> 36338 _ACEOF 36339 if ac_fn_c_try_cpp "$LINENO"; then : 36340 # Broken: success on invalid input. 36341 continue 36342 else 36343 # Passes both tests. 36344 ac_preproc_ok=: 36345 break 36346 fi 36347 rm -f conftest.err conftest.i conftest.$ac_ext 36348 36349 done 36350 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36351 rm -f conftest.i conftest.err conftest.$ac_ext 36352 if $ac_preproc_ok; then : 36353 break 36354 fi 36355 36356 done 36357 ac_cv_prog_CPP=$CPP 36358 36359 fi 36360 CPP=$ac_cv_prog_CPP 36361 else 36362 ac_cv_prog_CPP=$CPP 36363 fi 36364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 36365 $as_echo "$CPP" >&6; } 36366 ac_preproc_ok=false 36367 for ac_c_preproc_warn_flag in '' yes 36368 do 36369 # Use a header file that comes with gcc, so configuring glibc 36370 # with a fresh cross-compiler works. 36371 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36372 # <limits.h> exists even on freestanding compilers. 36373 # On the NeXT, cc -E runs the code through the compiler's parser, 36374 # not just through cpp. "Syntax error" is here to catch this case. 36375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36376 /* end confdefs.h. */ 36377 #ifdef __STDC__ 36378 # include <limits.h> 36379 #else 36380 # include <assert.h> 36381 #endif 36382 Syntax error 36383 _ACEOF 36384 if ac_fn_c_try_cpp "$LINENO"; then : 36385 36386 else 36387 # Broken: fails on valid input. 36388 continue 36389 fi 36390 rm -f conftest.err conftest.i conftest.$ac_ext 36391 36392 # OK, works on sane cases. Now check whether nonexistent headers 36393 # can be detected and how. 36394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36395 /* end confdefs.h. */ 36396 #include <ac_nonexistent.h> 36397 _ACEOF 36398 if ac_fn_c_try_cpp "$LINENO"; then : 36399 # Broken: success on invalid input. 36400 continue 36401 else 36402 # Passes both tests. 36403 ac_preproc_ok=: 36404 break 36405 fi 36406 rm -f conftest.err conftest.i conftest.$ac_ext 36407 36408 done 36409 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36410 rm -f conftest.i conftest.err conftest.$ac_ext 36411 if $ac_preproc_ok; then : 36412 36413 else 36414 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36415 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36416 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 36417 See \`config.log' for more details" "$LINENO" 5; } 36418 fi 36419 36420 ac_ext=cpp 36421 ac_cpp='$CXXCPP $CPPFLAGS' 36422 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36423 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36424 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36425 36426 36427 # Only process if variable expands to non-empty 36428 36429 if test "x$CPP" != x; then 36430 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36431 36432 # First separate the path from the arguments. This will split at the first 36433 # space. 36434 complete="$CPP" 36435 path="${complete%% *}" 36436 tmp="$complete EOL" 36437 arguments="${tmp#* }" 36438 36439 # Input might be given as Windows format, start by converting to 36440 # unix format. 36441 new_path=`$CYGPATH -u "$path"` 36442 36443 # Now try to locate executable using which 36444 new_path=`$WHICH "$new_path" 2> /dev/null` 36445 # bat and cmd files are not always considered executable in cygwin causing which 36446 # to not find them 36447 if test "x$new_path" = x \ 36448 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36449 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36450 new_path=`$CYGPATH -u "$path"` 36451 fi 36452 if test "x$new_path" = x; then 36453 # Oops. Which didn't find the executable. 36454 # The splitting of arguments from the executable at a space might have been incorrect, 36455 # since paths with space are more likely in Windows. Give it another try with the whole 36456 # argument. 36457 path="$complete" 36458 arguments="EOL" 36459 new_path=`$CYGPATH -u "$path"` 36460 new_path=`$WHICH "$new_path" 2> /dev/null` 36461 # bat and cmd files are not always considered executable in cygwin causing which 36462 # to not find them 36463 if test "x$new_path" = x \ 36464 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36465 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36466 new_path=`$CYGPATH -u "$path"` 36467 fi 36468 if test "x$new_path" = x; then 36469 # It's still not found. Now this is an unrecoverable error. 36470 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36471 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36472 has_space=`$ECHO "$complete" | $GREP " "` 36473 if test "x$has_space" != x; then 36474 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36475 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36476 fi 36477 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36478 fi 36479 fi 36480 36481 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36482 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36483 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36484 # "foo.exe" is OK but "foo" is an error. 36485 # 36486 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36487 # It is also a way to make sure we got the proper file name for the real test later on. 36488 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36489 if test "x$test_shortpath" = x; then 36490 # Short path failed, file does not exist as specified. 36491 # Try adding .exe or .cmd 36492 if test -f "${new_path}.exe"; then 36493 input_to_shortpath="${new_path}.exe" 36494 elif test -f "${new_path}.cmd"; then 36495 input_to_shortpath="${new_path}.cmd" 36496 else 36497 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 36498 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 36499 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36500 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36501 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36502 fi 36503 else 36504 input_to_shortpath="$new_path" 36505 fi 36506 36507 # Call helper function which possibly converts this using DOS-style short mode. 36508 # If so, the updated path is stored in $new_path. 36509 new_path="$input_to_shortpath" 36510 36511 input_path="$input_to_shortpath" 36512 # Check if we need to convert this using DOS-style short mode. If the path 36513 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36514 # take no chances and rewrite it. 36515 # Note: m4 eats our [], so we need to use [ and ] instead. 36516 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36517 if test "x$has_forbidden_chars" != x; then 36518 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36519 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36520 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36521 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36522 # Going to short mode and back again did indeed matter. Since short mode is 36523 # case insensitive, let's make it lowercase to improve readability. 36524 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36525 # Now convert it back to Unix-style (cygpath) 36526 input_path=`$CYGPATH -u "$shortmode_path"` 36527 new_path="$input_path" 36528 fi 36529 fi 36530 36531 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36532 if test "x$test_cygdrive_prefix" = x; then 36533 # As a simple fix, exclude /usr/bin since it's not a real path. 36534 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36535 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36536 # a path prefixed by /cygdrive for fixpath to work. 36537 new_path="$CYGWIN_ROOT_PATH$input_path" 36538 fi 36539 fi 36540 36541 # remove trailing .exe if any 36542 new_path="${new_path/%.exe/}" 36543 36544 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36545 36546 # First separate the path from the arguments. This will split at the first 36547 # space. 36548 complete="$CPP" 36549 path="${complete%% *}" 36550 tmp="$complete EOL" 36551 arguments="${tmp#* }" 36552 36553 # Input might be given as Windows format, start by converting to 36554 # unix format. 36555 new_path="$path" 36556 36557 windows_path="$new_path" 36558 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36559 unix_path=`$CYGPATH -u "$windows_path"` 36560 new_path="$unix_path" 36561 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36562 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36563 new_path="$unix_path" 36564 fi 36565 36566 36567 # Now try to locate executable using which 36568 new_path=`$WHICH "$new_path" 2> /dev/null` 36569 36570 if test "x$new_path" = x; then 36571 # Oops. Which didn't find the executable. 36572 # The splitting of arguments from the executable at a space might have been incorrect, 36573 # since paths with space are more likely in Windows. Give it another try with the whole 36574 # argument. 36575 path="$complete" 36576 arguments="EOL" 36577 new_path="$path" 36578 36579 windows_path="$new_path" 36580 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36581 unix_path=`$CYGPATH -u "$windows_path"` 36582 new_path="$unix_path" 36583 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36584 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36585 new_path="$unix_path" 36586 fi 36587 36588 36589 new_path=`$WHICH "$new_path" 2> /dev/null` 36590 # bat and cmd files are not always considered executable in MSYS causing which 36591 # to not find them 36592 if test "x$new_path" = x \ 36593 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36594 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36595 new_path="$path" 36596 36597 windows_path="$new_path" 36598 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36599 unix_path=`$CYGPATH -u "$windows_path"` 36600 new_path="$unix_path" 36601 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36602 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36603 new_path="$unix_path" 36604 fi 36605 36606 fi 36607 36608 if test "x$new_path" = x; then 36609 # It's still not found. Now this is an unrecoverable error. 36610 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36611 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36612 has_space=`$ECHO "$complete" | $GREP " "` 36613 if test "x$has_space" != x; then 36614 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36615 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36616 fi 36617 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36618 fi 36619 fi 36620 36621 # Now new_path has a complete unix path to the binary 36622 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36623 # Keep paths in /bin as-is, but remove trailing .exe if any 36624 new_path="${new_path/%.exe/}" 36625 # Do not save /bin paths to all_fixpath_prefixes! 36626 else 36627 # Not in mixed or Windows style, start by that. 36628 new_path=`cmd //c echo $new_path` 36629 36630 input_path="$new_path" 36631 # Check if we need to convert this using DOS-style short mode. If the path 36632 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36633 # take no chances and rewrite it. 36634 # Note: m4 eats our [], so we need to use [ and ] instead. 36635 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36636 if test "x$has_forbidden_chars" != x; then 36637 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36638 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36639 fi 36640 36641 # Output is in $new_path 36642 36643 windows_path="$new_path" 36644 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36645 unix_path=`$CYGPATH -u "$windows_path"` 36646 new_path="$unix_path" 36647 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36648 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36649 new_path="$unix_path" 36650 fi 36651 36652 # remove trailing .exe if any 36653 new_path="${new_path/%.exe/}" 36654 36655 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36656 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36657 fi 36658 36659 else 36660 # We're on a unix platform. Hooray! :) 36661 # First separate the path from the arguments. This will split at the first 36662 # space. 36663 complete="$CPP" 36664 path="${complete%% *}" 36665 tmp="$complete EOL" 36666 arguments="${tmp#* }" 36667 36668 # Cannot rely on the command "which" here since it doesn't always work. 36669 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36670 if test -z "$is_absolute_path"; then 36671 # Path to executable is not absolute. Find it. 36672 IFS_save="$IFS" 36673 IFS=: 36674 for p in $PATH; do 36675 if test -f "$p/$path" && test -x "$p/$path"; then 36676 new_path="$p/$path" 36677 break 36678 fi 36679 done 36680 IFS="$IFS_save" 36681 else 36682 # This is an absolute path, we can use it without further modifications. 36683 new_path="$path" 36684 fi 36685 36686 if test "x$new_path" = x; then 36687 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36688 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36689 has_space=`$ECHO "$complete" | $GREP " "` 36690 if test "x$has_space" != x; then 36691 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36692 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36693 fi 36694 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36695 fi 36696 fi 36697 36698 # Now join together the path and the arguments once again 36699 if test "x$arguments" != xEOL; then 36700 new_complete="$new_path ${arguments% *}" 36701 else 36702 new_complete="$new_path" 36703 fi 36704 36705 if test "x$complete" != "x$new_complete"; then 36706 CPP="$new_complete" 36707 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 36708 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 36709 fi 36710 fi 36711 36712 ac_ext=cpp 36713 ac_cpp='$CXXCPP $CPPFLAGS' 36714 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36715 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36716 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 36718 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 36719 if test -z "$CXXCPP"; then 36720 if ${ac_cv_prog_CXXCPP+:} false; then : 36721 $as_echo_n "(cached) " >&6 36722 else 36723 # Double quotes because CXXCPP needs to be expanded 36724 for CXXCPP in "$CXX -E" "/lib/cpp" 36725 do 36726 ac_preproc_ok=false 36727 for ac_cxx_preproc_warn_flag in '' yes 36728 do 36729 # Use a header file that comes with gcc, so configuring glibc 36730 # with a fresh cross-compiler works. 36731 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36732 # <limits.h> exists even on freestanding compilers. 36733 # On the NeXT, cc -E runs the code through the compiler's parser, 36734 # not just through cpp. "Syntax error" is here to catch this case. 36735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36736 /* end confdefs.h. */ 36737 #ifdef __STDC__ 36738 # include <limits.h> 36739 #else 36740 # include <assert.h> 36741 #endif 36742 Syntax error 36743 _ACEOF 36744 if ac_fn_cxx_try_cpp "$LINENO"; then : 36745 36746 else 36747 # Broken: fails on valid input. 36748 continue 36749 fi 36750 rm -f conftest.err conftest.i conftest.$ac_ext 36751 36752 # OK, works on sane cases. Now check whether nonexistent headers 36753 # can be detected and how. 36754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36755 /* end confdefs.h. */ 36756 #include <ac_nonexistent.h> 36757 _ACEOF 36758 if ac_fn_cxx_try_cpp "$LINENO"; then : 36759 # Broken: success on invalid input. 36760 continue 36761 else 36762 # Passes both tests. 36763 ac_preproc_ok=: 36764 break 36765 fi 36766 rm -f conftest.err conftest.i conftest.$ac_ext 36767 36768 done 36769 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36770 rm -f conftest.i conftest.err conftest.$ac_ext 36771 if $ac_preproc_ok; then : 36772 break 36773 fi 36774 36775 done 36776 ac_cv_prog_CXXCPP=$CXXCPP 36777 36778 fi 36779 CXXCPP=$ac_cv_prog_CXXCPP 36780 else 36781 ac_cv_prog_CXXCPP=$CXXCPP 36782 fi 36783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 36784 $as_echo "$CXXCPP" >&6; } 36785 ac_preproc_ok=false 36786 for ac_cxx_preproc_warn_flag in '' yes 36787 do 36788 # Use a header file that comes with gcc, so configuring glibc 36789 # with a fresh cross-compiler works. 36790 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36791 # <limits.h> exists even on freestanding compilers. 36792 # On the NeXT, cc -E runs the code through the compiler's parser, 36793 # not just through cpp. "Syntax error" is here to catch this case. 36794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36795 /* end confdefs.h. */ 36796 #ifdef __STDC__ 36797 # include <limits.h> 36798 #else 36799 # include <assert.h> 36800 #endif 36801 Syntax error 36802 _ACEOF 36803 if ac_fn_cxx_try_cpp "$LINENO"; then : 36804 36805 else 36806 # Broken: fails on valid input. 36807 continue 36808 fi 36809 rm -f conftest.err conftest.i conftest.$ac_ext 36810 36811 # OK, works on sane cases. Now check whether nonexistent headers 36812 # can be detected and how. 36813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36814 /* end confdefs.h. */ 36815 #include <ac_nonexistent.h> 36816 _ACEOF 36817 if ac_fn_cxx_try_cpp "$LINENO"; then : 36818 # Broken: success on invalid input. 36819 continue 36820 else 36821 # Passes both tests. 36822 ac_preproc_ok=: 36823 break 36824 fi 36825 rm -f conftest.err conftest.i conftest.$ac_ext 36826 36827 done 36828 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36829 rm -f conftest.i conftest.err conftest.$ac_ext 36830 if $ac_preproc_ok; then : 36831 36832 else 36833 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36834 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36835 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 36836 See \`config.log' for more details" "$LINENO" 5; } 36837 fi 36838 36839 ac_ext=cpp 36840 ac_cpp='$CXXCPP $CPPFLAGS' 36841 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36842 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36843 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36844 36845 36846 # Only process if variable expands to non-empty 36847 36848 if test "x$CXXCPP" != x; then 36849 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36850 36851 # First separate the path from the arguments. This will split at the first 36852 # space. 36853 complete="$CXXCPP" 36854 path="${complete%% *}" 36855 tmp="$complete EOL" 36856 arguments="${tmp#* }" 36857 36858 # Input might be given as Windows format, start by converting to 36859 # unix format. 36860 new_path=`$CYGPATH -u "$path"` 36861 36862 # Now try to locate executable using which 36863 new_path=`$WHICH "$new_path" 2> /dev/null` 36864 # bat and cmd files are not always considered executable in cygwin causing which 36865 # to not find them 36866 if test "x$new_path" = x \ 36867 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36868 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36869 new_path=`$CYGPATH -u "$path"` 36870 fi 36871 if test "x$new_path" = x; then 36872 # Oops. Which didn't find the executable. 36873 # The splitting of arguments from the executable at a space might have been incorrect, 36874 # since paths with space are more likely in Windows. Give it another try with the whole 36875 # argument. 36876 path="$complete" 36877 arguments="EOL" 36878 new_path=`$CYGPATH -u "$path"` 36879 new_path=`$WHICH "$new_path" 2> /dev/null` 36880 # bat and cmd files are not always considered executable in cygwin causing which 36881 # to not find them 36882 if test "x$new_path" = x \ 36883 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36884 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36885 new_path=`$CYGPATH -u "$path"` 36886 fi 36887 if test "x$new_path" = x; then 36888 # It's still not found. Now this is an unrecoverable error. 36889 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36890 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36891 has_space=`$ECHO "$complete" | $GREP " "` 36892 if test "x$has_space" != x; then 36893 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36894 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36895 fi 36896 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36897 fi 36898 fi 36899 36900 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36901 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36902 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36903 # "foo.exe" is OK but "foo" is an error. 36904 # 36905 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36906 # It is also a way to make sure we got the proper file name for the real test later on. 36907 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36908 if test "x$test_shortpath" = x; then 36909 # Short path failed, file does not exist as specified. 36910 # Try adding .exe or .cmd 36911 if test -f "${new_path}.exe"; then 36912 input_to_shortpath="${new_path}.exe" 36913 elif test -f "${new_path}.cmd"; then 36914 input_to_shortpath="${new_path}.cmd" 36915 else 36916 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 36917 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 36918 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36919 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36920 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36921 fi 36922 else 36923 input_to_shortpath="$new_path" 36924 fi 36925 36926 # Call helper function which possibly converts this using DOS-style short mode. 36927 # If so, the updated path is stored in $new_path. 36928 new_path="$input_to_shortpath" 36929 36930 input_path="$input_to_shortpath" 36931 # Check if we need to convert this using DOS-style short mode. If the path 36932 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36933 # take no chances and rewrite it. 36934 # Note: m4 eats our [], so we need to use [ and ] instead. 36935 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36936 if test "x$has_forbidden_chars" != x; then 36937 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36938 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36939 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36940 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36941 # Going to short mode and back again did indeed matter. Since short mode is 36942 # case insensitive, let's make it lowercase to improve readability. 36943 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36944 # Now convert it back to Unix-style (cygpath) 36945 input_path=`$CYGPATH -u "$shortmode_path"` 36946 new_path="$input_path" 36947 fi 36948 fi 36949 36950 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36951 if test "x$test_cygdrive_prefix" = x; then 36952 # As a simple fix, exclude /usr/bin since it's not a real path. 36953 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36954 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36955 # a path prefixed by /cygdrive for fixpath to work. 36956 new_path="$CYGWIN_ROOT_PATH$input_path" 36957 fi 36958 fi 36959 36960 # remove trailing .exe if any 36961 new_path="${new_path/%.exe/}" 36962 36963 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36964 36965 # First separate the path from the arguments. This will split at the first 36966 # space. 36967 complete="$CXXCPP" 36968 path="${complete%% *}" 36969 tmp="$complete EOL" 36970 arguments="${tmp#* }" 36971 36972 # Input might be given as Windows format, start by converting to 36973 # unix format. 36974 new_path="$path" 36975 36976 windows_path="$new_path" 36977 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36978 unix_path=`$CYGPATH -u "$windows_path"` 36979 new_path="$unix_path" 36980 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36981 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36982 new_path="$unix_path" 36983 fi 36984 36985 36986 # Now try to locate executable using which 36987 new_path=`$WHICH "$new_path" 2> /dev/null` 36988 36989 if test "x$new_path" = x; then 36990 # Oops. Which didn't find the executable. 36991 # The splitting of arguments from the executable at a space might have been incorrect, 36992 # since paths with space are more likely in Windows. Give it another try with the whole 36993 # argument. 36994 path="$complete" 36995 arguments="EOL" 36996 new_path="$path" 36997 36998 windows_path="$new_path" 36999 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37000 unix_path=`$CYGPATH -u "$windows_path"` 37001 new_path="$unix_path" 37002 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37003 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37004 new_path="$unix_path" 37005 fi 37006 37007 37008 new_path=`$WHICH "$new_path" 2> /dev/null` 37009 # bat and cmd files are not always considered executable in MSYS causing which 37010 # to not find them 37011 if test "x$new_path" = x \ 37012 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37013 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37014 new_path="$path" 37015 37016 windows_path="$new_path" 37017 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37018 unix_path=`$CYGPATH -u "$windows_path"` 37019 new_path="$unix_path" 37020 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37021 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37022 new_path="$unix_path" 37023 fi 37024 37025 fi 37026 37027 if test "x$new_path" = x; then 37028 # It's still not found. Now this is an unrecoverable error. 37029 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 37030 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 37031 has_space=`$ECHO "$complete" | $GREP " "` 37032 if test "x$has_space" != x; then 37033 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37034 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37035 fi 37036 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 37037 fi 37038 fi 37039 37040 # Now new_path has a complete unix path to the binary 37041 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37042 # Keep paths in /bin as-is, but remove trailing .exe if any 37043 new_path="${new_path/%.exe/}" 37044 # Do not save /bin paths to all_fixpath_prefixes! 37045 else 37046 # Not in mixed or Windows style, start by that. 37047 new_path=`cmd //c echo $new_path` 37048 37049 input_path="$new_path" 37050 # Check if we need to convert this using DOS-style short mode. If the path 37051 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37052 # take no chances and rewrite it. 37053 # Note: m4 eats our [], so we need to use [ and ] instead. 37054 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37055 if test "x$has_forbidden_chars" != x; then 37056 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37057 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37058 fi 37059 37060 # Output is in $new_path 37061 37062 windows_path="$new_path" 37063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37064 unix_path=`$CYGPATH -u "$windows_path"` 37065 new_path="$unix_path" 37066 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37067 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37068 new_path="$unix_path" 37069 fi 37070 37071 # remove trailing .exe if any 37072 new_path="${new_path/%.exe/}" 37073 37074 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37075 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37076 fi 37077 37078 else 37079 # We're on a unix platform. Hooray! :) 37080 # First separate the path from the arguments. This will split at the first 37081 # space. 37082 complete="$CXXCPP" 37083 path="${complete%% *}" 37084 tmp="$complete EOL" 37085 arguments="${tmp#* }" 37086 37087 # Cannot rely on the command "which" here since it doesn't always work. 37088 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37089 if test -z "$is_absolute_path"; then 37090 # Path to executable is not absolute. Find it. 37091 IFS_save="$IFS" 37092 IFS=: 37093 for p in $PATH; do 37094 if test -f "$p/$path" && test -x "$p/$path"; then 37095 new_path="$p/$path" 37096 break 37097 fi 37098 done 37099 IFS="$IFS_save" 37100 else 37101 # This is an absolute path, we can use it without further modifications. 37102 new_path="$path" 37103 fi 37104 37105 if test "x$new_path" = x; then 37106 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 37107 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 37108 has_space=`$ECHO "$complete" | $GREP " "` 37109 if test "x$has_space" != x; then 37110 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37111 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37112 fi 37113 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 37114 fi 37115 fi 37116 37117 # Now join together the path and the arguments once again 37118 if test "x$arguments" != xEOL; then 37119 new_complete="$new_path ${arguments% *}" 37120 else 37121 new_complete="$new_path" 37122 fi 37123 37124 if test "x$complete" != "x$new_complete"; then 37125 CXXCPP="$new_complete" 37126 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 37127 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 37128 fi 37129 fi 37130 37131 37132 # 37133 # Setup the linker (LD) 37134 # 37135 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37136 # In the Microsoft toolchain we have a separate LD command "link". 37137 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 37138 # a cygwin program for something completely different. 37139 # Extract the first word of "link", so it can be a program name with args. 37140 set dummy link; ac_word=$2 37141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37142 $as_echo_n "checking for $ac_word... " >&6; } 37143 if ${ac_cv_prog_LD+:} false; then : 37144 $as_echo_n "(cached) " >&6 37145 else 37146 if test -n "$LD"; then 37147 ac_cv_prog_LD="$LD" # Let the user override the test. 37148 else 37149 ac_prog_rejected=no 37150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37151 for as_dir in $PATH 37152 do 37153 IFS=$as_save_IFS 37154 test -z "$as_dir" && as_dir=. 37155 for ac_exec_ext in '' $ac_executable_extensions; do 37156 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37157 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 37158 ac_prog_rejected=yes 37159 continue 37160 fi 37161 ac_cv_prog_LD="link" 37162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37163 break 2 37164 fi 37165 done 37166 done 37167 IFS=$as_save_IFS 37168 37169 if test $ac_prog_rejected = yes; then 37170 # We found a bogon in the path, so make sure we never use it. 37171 set dummy $ac_cv_prog_LD 37172 shift 37173 if test $# != 0; then 37174 # We chose a different compiler from the bogus one. 37175 # However, it has the same basename, so the bogon will be chosen 37176 # first if we set LD to just the basename; use the full file name. 37177 shift 37178 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 37179 fi 37180 fi 37181 fi 37182 fi 37183 LD=$ac_cv_prog_LD 37184 if test -n "$LD"; then 37185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 37186 $as_echo "$LD" >&6; } 37187 else 37188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37189 $as_echo "no" >&6; } 37190 fi 37191 37192 37193 37194 # Only process if variable expands to non-empty 37195 37196 if test "x$LD" != x; then 37197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37198 37199 # First separate the path from the arguments. This will split at the first 37200 # space. 37201 complete="$LD" 37202 path="${complete%% *}" 37203 tmp="$complete EOL" 37204 arguments="${tmp#* }" 37205 37206 # Input might be given as Windows format, start by converting to 37207 # unix format. 37208 new_path=`$CYGPATH -u "$path"` 37209 37210 # Now try to locate executable using which 37211 new_path=`$WHICH "$new_path" 2> /dev/null` 37212 # bat and cmd files are not always considered executable in cygwin causing which 37213 # to not find them 37214 if test "x$new_path" = x \ 37215 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37216 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37217 new_path=`$CYGPATH -u "$path"` 37218 fi 37219 if test "x$new_path" = x; then 37220 # Oops. Which didn't find the executable. 37221 # The splitting of arguments from the executable at a space might have been incorrect, 37222 # since paths with space are more likely in Windows. Give it another try with the whole 37223 # argument. 37224 path="$complete" 37225 arguments="EOL" 37226 new_path=`$CYGPATH -u "$path"` 37227 new_path=`$WHICH "$new_path" 2> /dev/null` 37228 # bat and cmd files are not always considered executable in cygwin causing which 37229 # to not find them 37230 if test "x$new_path" = x \ 37231 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37232 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37233 new_path=`$CYGPATH -u "$path"` 37234 fi 37235 if test "x$new_path" = x; then 37236 # It's still not found. Now this is an unrecoverable error. 37237 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37238 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37239 has_space=`$ECHO "$complete" | $GREP " "` 37240 if test "x$has_space" != x; then 37241 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37242 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37243 fi 37244 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37245 fi 37246 fi 37247 37248 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37249 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37250 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37251 # "foo.exe" is OK but "foo" is an error. 37252 # 37253 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37254 # It is also a way to make sure we got the proper file name for the real test later on. 37255 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37256 if test "x$test_shortpath" = x; then 37257 # Short path failed, file does not exist as specified. 37258 # Try adding .exe or .cmd 37259 if test -f "${new_path}.exe"; then 37260 input_to_shortpath="${new_path}.exe" 37261 elif test -f "${new_path}.cmd"; then 37262 input_to_shortpath="${new_path}.cmd" 37263 else 37264 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 37265 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 37266 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37267 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37268 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37269 fi 37270 else 37271 input_to_shortpath="$new_path" 37272 fi 37273 37274 # Call helper function which possibly converts this using DOS-style short mode. 37275 # If so, the updated path is stored in $new_path. 37276 new_path="$input_to_shortpath" 37277 37278 input_path="$input_to_shortpath" 37279 # Check if we need to convert this using DOS-style short mode. If the path 37280 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37281 # take no chances and rewrite it. 37282 # Note: m4 eats our [], so we need to use [ and ] instead. 37283 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37284 if test "x$has_forbidden_chars" != x; then 37285 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37286 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37287 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37288 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37289 # Going to short mode and back again did indeed matter. Since short mode is 37290 # case insensitive, let's make it lowercase to improve readability. 37291 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37292 # Now convert it back to Unix-style (cygpath) 37293 input_path=`$CYGPATH -u "$shortmode_path"` 37294 new_path="$input_path" 37295 fi 37296 fi 37297 37298 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37299 if test "x$test_cygdrive_prefix" = x; then 37300 # As a simple fix, exclude /usr/bin since it's not a real path. 37301 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37302 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37303 # a path prefixed by /cygdrive for fixpath to work. 37304 new_path="$CYGWIN_ROOT_PATH$input_path" 37305 fi 37306 fi 37307 37308 # remove trailing .exe if any 37309 new_path="${new_path/%.exe/}" 37310 37311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37312 37313 # First separate the path from the arguments. This will split at the first 37314 # space. 37315 complete="$LD" 37316 path="${complete%% *}" 37317 tmp="$complete EOL" 37318 arguments="${tmp#* }" 37319 37320 # Input might be given as Windows format, start by converting to 37321 # unix format. 37322 new_path="$path" 37323 37324 windows_path="$new_path" 37325 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37326 unix_path=`$CYGPATH -u "$windows_path"` 37327 new_path="$unix_path" 37328 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37329 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37330 new_path="$unix_path" 37331 fi 37332 37333 37334 # Now try to locate executable using which 37335 new_path=`$WHICH "$new_path" 2> /dev/null` 37336 37337 if test "x$new_path" = x; then 37338 # Oops. Which didn't find the executable. 37339 # The splitting of arguments from the executable at a space might have been incorrect, 37340 # since paths with space are more likely in Windows. Give it another try with the whole 37341 # argument. 37342 path="$complete" 37343 arguments="EOL" 37344 new_path="$path" 37345 37346 windows_path="$new_path" 37347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37348 unix_path=`$CYGPATH -u "$windows_path"` 37349 new_path="$unix_path" 37350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37351 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37352 new_path="$unix_path" 37353 fi 37354 37355 37356 new_path=`$WHICH "$new_path" 2> /dev/null` 37357 # bat and cmd files are not always considered executable in MSYS causing which 37358 # to not find them 37359 if test "x$new_path" = x \ 37360 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37361 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37362 new_path="$path" 37363 37364 windows_path="$new_path" 37365 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37366 unix_path=`$CYGPATH -u "$windows_path"` 37367 new_path="$unix_path" 37368 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37369 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37370 new_path="$unix_path" 37371 fi 37372 37373 fi 37374 37375 if test "x$new_path" = x; then 37376 # It's still not found. Now this is an unrecoverable error. 37377 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37378 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37379 has_space=`$ECHO "$complete" | $GREP " "` 37380 if test "x$has_space" != x; then 37381 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37382 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37383 fi 37384 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37385 fi 37386 fi 37387 37388 # Now new_path has a complete unix path to the binary 37389 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37390 # Keep paths in /bin as-is, but remove trailing .exe if any 37391 new_path="${new_path/%.exe/}" 37392 # Do not save /bin paths to all_fixpath_prefixes! 37393 else 37394 # Not in mixed or Windows style, start by that. 37395 new_path=`cmd //c echo $new_path` 37396 37397 input_path="$new_path" 37398 # Check if we need to convert this using DOS-style short mode. If the path 37399 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37400 # take no chances and rewrite it. 37401 # Note: m4 eats our [], so we need to use [ and ] instead. 37402 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37403 if test "x$has_forbidden_chars" != x; then 37404 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37405 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37406 fi 37407 37408 # Output is in $new_path 37409 37410 windows_path="$new_path" 37411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37412 unix_path=`$CYGPATH -u "$windows_path"` 37413 new_path="$unix_path" 37414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37416 new_path="$unix_path" 37417 fi 37418 37419 # remove trailing .exe if any 37420 new_path="${new_path/%.exe/}" 37421 37422 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37423 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37424 fi 37425 37426 else 37427 # We're on a unix platform. Hooray! :) 37428 # First separate the path from the arguments. This will split at the first 37429 # space. 37430 complete="$LD" 37431 path="${complete%% *}" 37432 tmp="$complete EOL" 37433 arguments="${tmp#* }" 37434 37435 # Cannot rely on the command "which" here since it doesn't always work. 37436 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37437 if test -z "$is_absolute_path"; then 37438 # Path to executable is not absolute. Find it. 37439 IFS_save="$IFS" 37440 IFS=: 37441 for p in $PATH; do 37442 if test -f "$p/$path" && test -x "$p/$path"; then 37443 new_path="$p/$path" 37444 break 37445 fi 37446 done 37447 IFS="$IFS_save" 37448 else 37449 # This is an absolute path, we can use it without further modifications. 37450 new_path="$path" 37451 fi 37452 37453 if test "x$new_path" = x; then 37454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37455 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37456 has_space=`$ECHO "$complete" | $GREP " "` 37457 if test "x$has_space" != x; then 37458 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37459 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37460 fi 37461 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37462 fi 37463 fi 37464 37465 # Now join together the path and the arguments once again 37466 if test "x$arguments" != xEOL; then 37467 new_complete="$new_path ${arguments% *}" 37468 else 37469 new_complete="$new_path" 37470 fi 37471 37472 if test "x$complete" != "x$new_complete"; then 37473 LD="$new_complete" 37474 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 37475 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 37476 fi 37477 fi 37478 37479 # Verify that we indeed succeeded with this trick. 37480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 37481 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 37482 "$LD" --version > /dev/null 37483 if test $? -eq 0 ; then 37484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37485 $as_echo "no" >&6; } 37486 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 37487 else 37488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 37489 $as_echo "yes" >&6; } 37490 fi 37491 LDCXX="$LD" 37492 else 37493 # All other toolchains use the compiler to link. 37494 LD="$CC" 37495 LDCXX="$CXX" 37496 fi 37497 37498 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 37499 37500 37501 # 37502 # Setup the assembler (AS) 37503 # 37504 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 37505 37506 37507 # Publish this variable in the help. 37508 37509 37510 if [ -z "${AS+x}" ]; then 37511 # The variable is not set by user, try to locate tool using the code snippet 37512 for ac_prog in as 37513 do 37514 # Extract the first word of "$ac_prog", so it can be a program name with args. 37515 set dummy $ac_prog; ac_word=$2 37516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37517 $as_echo_n "checking for $ac_word... " >&6; } 37518 if ${ac_cv_path_AS+:} false; then : 37519 $as_echo_n "(cached) " >&6 37520 else 37521 case $AS in 37522 [\\/]* | ?:[\\/]*) 37523 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37524 ;; 37525 *) 37526 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37527 for as_dir in $PATH 37528 do 37529 IFS=$as_save_IFS 37530 test -z "$as_dir" && as_dir=. 37531 for ac_exec_ext in '' $ac_executable_extensions; do 37532 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37533 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37534 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37535 break 2 37536 fi 37537 done 37538 done 37539 IFS=$as_save_IFS 37540 37541 ;; 37542 esac 37543 fi 37544 AS=$ac_cv_path_AS 37545 if test -n "$AS"; then 37546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37547 $as_echo "$AS" >&6; } 37548 else 37549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37550 $as_echo "no" >&6; } 37551 fi 37552 37553 37554 test -n "$AS" && break 37555 done 37556 37557 else 37558 # The variable is set, but is it from the command line or the environment? 37559 37560 # Try to remove the string !AS! from our list. 37561 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 37562 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37563 # If it failed, the variable was not from the command line. Ignore it, 37564 # but warn the user (except for BASH, which is always set by the calling BASH). 37565 if test "xAS" != xBASH; then 37566 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 37567 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 37568 fi 37569 # Try to locate tool using the code snippet 37570 for ac_prog in as 37571 do 37572 # Extract the first word of "$ac_prog", so it can be a program name with args. 37573 set dummy $ac_prog; ac_word=$2 37574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37575 $as_echo_n "checking for $ac_word... " >&6; } 37576 if ${ac_cv_path_AS+:} false; then : 37577 $as_echo_n "(cached) " >&6 37578 else 37579 case $AS in 37580 [\\/]* | ?:[\\/]*) 37581 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37582 ;; 37583 *) 37584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37585 for as_dir in $PATH 37586 do 37587 IFS=$as_save_IFS 37588 test -z "$as_dir" && as_dir=. 37589 for ac_exec_ext in '' $ac_executable_extensions; do 37590 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37591 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37593 break 2 37594 fi 37595 done 37596 done 37597 IFS=$as_save_IFS 37598 37599 ;; 37600 esac 37601 fi 37602 AS=$ac_cv_path_AS 37603 if test -n "$AS"; then 37604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37605 $as_echo "$AS" >&6; } 37606 else 37607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37608 $as_echo "no" >&6; } 37609 fi 37610 37611 37612 test -n "$AS" && break 37613 done 37614 37615 else 37616 # If it succeeded, then it was overridden by the user. We will use it 37617 # for the tool. 37618 37619 # First remove it from the list of overridden variables, so we can test 37620 # for unknown variables in the end. 37621 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37622 37623 # Check if we try to supply an empty value 37624 if test "x$AS" = x; then 37625 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 37626 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 37627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37628 $as_echo_n "checking for AS... " >&6; } 37629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37630 $as_echo "disabled" >&6; } 37631 else 37632 # Check if the provided tool contains a complete path. 37633 tool_specified="$AS" 37634 tool_basename="${tool_specified##*/}" 37635 if test "x$tool_basename" = "x$tool_specified"; then 37636 # A command without a complete path is provided, search $PATH. 37637 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 37638 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 37639 # Extract the first word of "$tool_basename", so it can be a program name with args. 37640 set dummy $tool_basename; ac_word=$2 37641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37642 $as_echo_n "checking for $ac_word... " >&6; } 37643 if ${ac_cv_path_AS+:} false; then : 37644 $as_echo_n "(cached) " >&6 37645 else 37646 case $AS in 37647 [\\/]* | ?:[\\/]*) 37648 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37649 ;; 37650 *) 37651 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37652 for as_dir in $PATH 37653 do 37654 IFS=$as_save_IFS 37655 test -z "$as_dir" && as_dir=. 37656 for ac_exec_ext in '' $ac_executable_extensions; do 37657 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37658 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37659 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37660 break 2 37661 fi 37662 done 37663 done 37664 IFS=$as_save_IFS 37665 37666 ;; 37667 esac 37668 fi 37669 AS=$ac_cv_path_AS 37670 if test -n "$AS"; then 37671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37672 $as_echo "$AS" >&6; } 37673 else 37674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37675 $as_echo "no" >&6; } 37676 fi 37677 37678 37679 if test "x$AS" = x; then 37680 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37681 fi 37682 else 37683 # Otherwise we believe it is a complete path. Use it as it is. 37684 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 37685 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 37686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37687 $as_echo_n "checking for AS... " >&6; } 37688 if test ! -x "$tool_specified"; then 37689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37690 $as_echo "not found" >&6; } 37691 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 37692 fi 37693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37694 $as_echo "$tool_specified" >&6; } 37695 fi 37696 fi 37697 fi 37698 37699 fi 37700 37701 37702 37703 # Only process if variable expands to non-empty 37704 37705 if test "x$AS" != x; then 37706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37707 37708 # First separate the path from the arguments. This will split at the first 37709 # space. 37710 complete="$AS" 37711 path="${complete%% *}" 37712 tmp="$complete EOL" 37713 arguments="${tmp#* }" 37714 37715 # Input might be given as Windows format, start by converting to 37716 # unix format. 37717 new_path=`$CYGPATH -u "$path"` 37718 37719 # Now try to locate executable using which 37720 new_path=`$WHICH "$new_path" 2> /dev/null` 37721 # bat and cmd files are not always considered executable in cygwin causing which 37722 # to not find them 37723 if test "x$new_path" = x \ 37724 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37725 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37726 new_path=`$CYGPATH -u "$path"` 37727 fi 37728 if test "x$new_path" = x; then 37729 # Oops. Which didn't find the executable. 37730 # The splitting of arguments from the executable at a space might have been incorrect, 37731 # since paths with space are more likely in Windows. Give it another try with the whole 37732 # argument. 37733 path="$complete" 37734 arguments="EOL" 37735 new_path=`$CYGPATH -u "$path"` 37736 new_path=`$WHICH "$new_path" 2> /dev/null` 37737 # bat and cmd files are not always considered executable in cygwin causing which 37738 # to not find them 37739 if test "x$new_path" = x \ 37740 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37741 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37742 new_path=`$CYGPATH -u "$path"` 37743 fi 37744 if test "x$new_path" = x; then 37745 # It's still not found. Now this is an unrecoverable error. 37746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37747 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37748 has_space=`$ECHO "$complete" | $GREP " "` 37749 if test "x$has_space" != x; then 37750 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37751 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37752 fi 37753 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37754 fi 37755 fi 37756 37757 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37758 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37759 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37760 # "foo.exe" is OK but "foo" is an error. 37761 # 37762 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37763 # It is also a way to make sure we got the proper file name for the real test later on. 37764 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37765 if test "x$test_shortpath" = x; then 37766 # Short path failed, file does not exist as specified. 37767 # Try adding .exe or .cmd 37768 if test -f "${new_path}.exe"; then 37769 input_to_shortpath="${new_path}.exe" 37770 elif test -f "${new_path}.cmd"; then 37771 input_to_shortpath="${new_path}.cmd" 37772 else 37773 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 37774 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 37775 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37776 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37777 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37778 fi 37779 else 37780 input_to_shortpath="$new_path" 37781 fi 37782 37783 # Call helper function which possibly converts this using DOS-style short mode. 37784 # If so, the updated path is stored in $new_path. 37785 new_path="$input_to_shortpath" 37786 37787 input_path="$input_to_shortpath" 37788 # Check if we need to convert this using DOS-style short mode. If the path 37789 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37790 # take no chances and rewrite it. 37791 # Note: m4 eats our [], so we need to use [ and ] instead. 37792 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37793 if test "x$has_forbidden_chars" != x; then 37794 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37795 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37796 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37797 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37798 # Going to short mode and back again did indeed matter. Since short mode is 37799 # case insensitive, let's make it lowercase to improve readability. 37800 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37801 # Now convert it back to Unix-style (cygpath) 37802 input_path=`$CYGPATH -u "$shortmode_path"` 37803 new_path="$input_path" 37804 fi 37805 fi 37806 37807 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37808 if test "x$test_cygdrive_prefix" = x; then 37809 # As a simple fix, exclude /usr/bin since it's not a real path. 37810 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37811 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37812 # a path prefixed by /cygdrive for fixpath to work. 37813 new_path="$CYGWIN_ROOT_PATH$input_path" 37814 fi 37815 fi 37816 37817 # remove trailing .exe if any 37818 new_path="${new_path/%.exe/}" 37819 37820 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37821 37822 # First separate the path from the arguments. This will split at the first 37823 # space. 37824 complete="$AS" 37825 path="${complete%% *}" 37826 tmp="$complete EOL" 37827 arguments="${tmp#* }" 37828 37829 # Input might be given as Windows format, start by converting to 37830 # unix format. 37831 new_path="$path" 37832 37833 windows_path="$new_path" 37834 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37835 unix_path=`$CYGPATH -u "$windows_path"` 37836 new_path="$unix_path" 37837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37838 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37839 new_path="$unix_path" 37840 fi 37841 37842 37843 # Now try to locate executable using which 37844 new_path=`$WHICH "$new_path" 2> /dev/null` 37845 37846 if test "x$new_path" = x; then 37847 # Oops. Which didn't find the executable. 37848 # The splitting of arguments from the executable at a space might have been incorrect, 37849 # since paths with space are more likely in Windows. Give it another try with the whole 37850 # argument. 37851 path="$complete" 37852 arguments="EOL" 37853 new_path="$path" 37854 37855 windows_path="$new_path" 37856 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37857 unix_path=`$CYGPATH -u "$windows_path"` 37858 new_path="$unix_path" 37859 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37860 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37861 new_path="$unix_path" 37862 fi 37863 37864 37865 new_path=`$WHICH "$new_path" 2> /dev/null` 37866 # bat and cmd files are not always considered executable in MSYS causing which 37867 # to not find them 37868 if test "x$new_path" = x \ 37869 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37870 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37871 new_path="$path" 37872 37873 windows_path="$new_path" 37874 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37875 unix_path=`$CYGPATH -u "$windows_path"` 37876 new_path="$unix_path" 37877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37878 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37879 new_path="$unix_path" 37880 fi 37881 37882 fi 37883 37884 if test "x$new_path" = x; then 37885 # It's still not found. Now this is an unrecoverable error. 37886 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37887 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37888 has_space=`$ECHO "$complete" | $GREP " "` 37889 if test "x$has_space" != x; then 37890 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37891 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37892 fi 37893 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37894 fi 37895 fi 37896 37897 # Now new_path has a complete unix path to the binary 37898 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37899 # Keep paths in /bin as-is, but remove trailing .exe if any 37900 new_path="${new_path/%.exe/}" 37901 # Do not save /bin paths to all_fixpath_prefixes! 37902 else 37903 # Not in mixed or Windows style, start by that. 37904 new_path=`cmd //c echo $new_path` 37905 37906 input_path="$new_path" 37907 # Check if we need to convert this using DOS-style short mode. If the path 37908 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37909 # take no chances and rewrite it. 37910 # Note: m4 eats our [], so we need to use [ and ] instead. 37911 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37912 if test "x$has_forbidden_chars" != x; then 37913 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37914 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37915 fi 37916 37917 # Output is in $new_path 37918 37919 windows_path="$new_path" 37920 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37921 unix_path=`$CYGPATH -u "$windows_path"` 37922 new_path="$unix_path" 37923 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37924 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37925 new_path="$unix_path" 37926 fi 37927 37928 # remove trailing .exe if any 37929 new_path="${new_path/%.exe/}" 37930 37931 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37932 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37933 fi 37934 37935 else 37936 # We're on a unix platform. Hooray! :) 37937 # First separate the path from the arguments. This will split at the first 37938 # space. 37939 complete="$AS" 37940 path="${complete%% *}" 37941 tmp="$complete EOL" 37942 arguments="${tmp#* }" 37943 37944 # Cannot rely on the command "which" here since it doesn't always work. 37945 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37946 if test -z "$is_absolute_path"; then 37947 # Path to executable is not absolute. Find it. 37948 IFS_save="$IFS" 37949 IFS=: 37950 for p in $PATH; do 37951 if test -f "$p/$path" && test -x "$p/$path"; then 37952 new_path="$p/$path" 37953 break 37954 fi 37955 done 37956 IFS="$IFS_save" 37957 else 37958 # This is an absolute path, we can use it without further modifications. 37959 new_path="$path" 37960 fi 37961 37962 if test "x$new_path" = x; then 37963 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37964 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37965 has_space=`$ECHO "$complete" | $GREP " "` 37966 if test "x$has_space" != x; then 37967 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37968 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37969 fi 37970 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37971 fi 37972 fi 37973 37974 # Now join together the path and the arguments once again 37975 if test "x$arguments" != xEOL; then 37976 new_complete="$new_path ${arguments% *}" 37977 else 37978 new_complete="$new_path" 37979 fi 37980 37981 if test "x$complete" != "x$new_complete"; then 37982 AS="$new_complete" 37983 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 37984 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 37985 fi 37986 fi 37987 37988 if test "x$AS" = x; then 37989 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 37990 fi 37991 else 37992 # FIXME: is this correct for microsoft? 37993 AS="$CC -c" 37994 fi 37995 37996 37997 # 37998 # Setup the archiver (AR) 37999 # 38000 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38001 # The corresponding ar tool is lib.exe (used to create static libraries) 38002 # Extract the first word of "lib", so it can be a program name with args. 38003 set dummy lib; ac_word=$2 38004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38005 $as_echo_n "checking for $ac_word... " >&6; } 38006 if ${ac_cv_prog_AR+:} false; then : 38007 $as_echo_n "(cached) " >&6 38008 else 38009 if test -n "$AR"; then 38010 ac_cv_prog_AR="$AR" # Let the user override the test. 38011 else 38012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38013 for as_dir in $PATH 38014 do 38015 IFS=$as_save_IFS 38016 test -z "$as_dir" && as_dir=. 38017 for ac_exec_ext in '' $ac_executable_extensions; do 38018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38019 ac_cv_prog_AR="lib" 38020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38021 break 2 38022 fi 38023 done 38024 done 38025 IFS=$as_save_IFS 38026 38027 fi 38028 fi 38029 AR=$ac_cv_prog_AR 38030 if test -n "$AR"; then 38031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38032 $as_echo "$AR" >&6; } 38033 else 38034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38035 $as_echo "no" >&6; } 38036 fi 38037 38038 38039 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 38040 38041 38042 # Publish this variable in the help. 38043 38044 38045 if [ -z "${AR+x}" ]; then 38046 # The variable is not set by user, try to locate tool using the code snippet 38047 if test -n "$ac_tool_prefix"; then 38048 for ac_prog in ar gcc-ar 38049 do 38050 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38051 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38053 $as_echo_n "checking for $ac_word... " >&6; } 38054 if ${ac_cv_prog_AR+:} false; then : 38055 $as_echo_n "(cached) " >&6 38056 else 38057 if test -n "$AR"; then 38058 ac_cv_prog_AR="$AR" # Let the user override the test. 38059 else 38060 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38061 for as_dir in $PATH 38062 do 38063 IFS=$as_save_IFS 38064 test -z "$as_dir" && as_dir=. 38065 for ac_exec_ext in '' $ac_executable_extensions; do 38066 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38067 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38068 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38069 break 2 38070 fi 38071 done 38072 done 38073 IFS=$as_save_IFS 38074 38075 fi 38076 fi 38077 AR=$ac_cv_prog_AR 38078 if test -n "$AR"; then 38079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38080 $as_echo "$AR" >&6; } 38081 else 38082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38083 $as_echo "no" >&6; } 38084 fi 38085 38086 38087 test -n "$AR" && break 38088 done 38089 fi 38090 if test -z "$AR"; then 38091 ac_ct_AR=$AR 38092 for ac_prog in ar gcc-ar 38093 do 38094 # Extract the first word of "$ac_prog", so it can be a program name with args. 38095 set dummy $ac_prog; ac_word=$2 38096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38097 $as_echo_n "checking for $ac_word... " >&6; } 38098 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38099 $as_echo_n "(cached) " >&6 38100 else 38101 if test -n "$ac_ct_AR"; then 38102 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38103 else 38104 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38105 for as_dir in $PATH 38106 do 38107 IFS=$as_save_IFS 38108 test -z "$as_dir" && as_dir=. 38109 for ac_exec_ext in '' $ac_executable_extensions; do 38110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38111 ac_cv_prog_ac_ct_AR="$ac_prog" 38112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38113 break 2 38114 fi 38115 done 38116 done 38117 IFS=$as_save_IFS 38118 38119 fi 38120 fi 38121 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38122 if test -n "$ac_ct_AR"; then 38123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38124 $as_echo "$ac_ct_AR" >&6; } 38125 else 38126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38127 $as_echo "no" >&6; } 38128 fi 38129 38130 38131 test -n "$ac_ct_AR" && break 38132 done 38133 38134 if test "x$ac_ct_AR" = x; then 38135 AR="" 38136 else 38137 case $cross_compiling:$ac_tool_warned in 38138 yes:) 38139 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38140 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38141 ac_tool_warned=yes ;; 38142 esac 38143 AR=$ac_ct_AR 38144 fi 38145 fi 38146 38147 else 38148 # The variable is set, but is it from the command line or the environment? 38149 38150 # Try to remove the string !AR! from our list. 38151 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38152 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38153 # If it failed, the variable was not from the command line. Ignore it, 38154 # but warn the user (except for BASH, which is always set by the calling BASH). 38155 if test "xAR" != xBASH; then 38156 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38157 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38158 fi 38159 # Try to locate tool using the code snippet 38160 if test -n "$ac_tool_prefix"; then 38161 for ac_prog in ar gcc-ar 38162 do 38163 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38164 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38166 $as_echo_n "checking for $ac_word... " >&6; } 38167 if ${ac_cv_prog_AR+:} false; then : 38168 $as_echo_n "(cached) " >&6 38169 else 38170 if test -n "$AR"; then 38171 ac_cv_prog_AR="$AR" # Let the user override the test. 38172 else 38173 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38174 for as_dir in $PATH 38175 do 38176 IFS=$as_save_IFS 38177 test -z "$as_dir" && as_dir=. 38178 for ac_exec_ext in '' $ac_executable_extensions; do 38179 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38180 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38181 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38182 break 2 38183 fi 38184 done 38185 done 38186 IFS=$as_save_IFS 38187 38188 fi 38189 fi 38190 AR=$ac_cv_prog_AR 38191 if test -n "$AR"; then 38192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38193 $as_echo "$AR" >&6; } 38194 else 38195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38196 $as_echo "no" >&6; } 38197 fi 38198 38199 38200 test -n "$AR" && break 38201 done 38202 fi 38203 if test -z "$AR"; then 38204 ac_ct_AR=$AR 38205 for ac_prog in ar gcc-ar 38206 do 38207 # Extract the first word of "$ac_prog", so it can be a program name with args. 38208 set dummy $ac_prog; ac_word=$2 38209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38210 $as_echo_n "checking for $ac_word... " >&6; } 38211 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38212 $as_echo_n "(cached) " >&6 38213 else 38214 if test -n "$ac_ct_AR"; then 38215 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38216 else 38217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38218 for as_dir in $PATH 38219 do 38220 IFS=$as_save_IFS 38221 test -z "$as_dir" && as_dir=. 38222 for ac_exec_ext in '' $ac_executable_extensions; do 38223 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38224 ac_cv_prog_ac_ct_AR="$ac_prog" 38225 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38226 break 2 38227 fi 38228 done 38229 done 38230 IFS=$as_save_IFS 38231 38232 fi 38233 fi 38234 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38235 if test -n "$ac_ct_AR"; then 38236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38237 $as_echo "$ac_ct_AR" >&6; } 38238 else 38239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38240 $as_echo "no" >&6; } 38241 fi 38242 38243 38244 test -n "$ac_ct_AR" && break 38245 done 38246 38247 if test "x$ac_ct_AR" = x; then 38248 AR="" 38249 else 38250 case $cross_compiling:$ac_tool_warned in 38251 yes:) 38252 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38253 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38254 ac_tool_warned=yes ;; 38255 esac 38256 AR=$ac_ct_AR 38257 fi 38258 fi 38259 38260 else 38261 # If it succeeded, then it was overridden by the user. We will use it 38262 # for the tool. 38263 38264 # First remove it from the list of overridden variables, so we can test 38265 # for unknown variables in the end. 38266 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38267 38268 # Check if we try to supply an empty value 38269 if test "x$AR" = x; then 38270 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38271 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38273 $as_echo_n "checking for AR... " >&6; } 38274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38275 $as_echo "disabled" >&6; } 38276 else 38277 # Check if the provided tool contains a complete path. 38278 tool_specified="$AR" 38279 tool_basename="${tool_specified##*/}" 38280 if test "x$tool_basename" = "x$tool_specified"; then 38281 # A command without a complete path is provided, search $PATH. 38282 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38283 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38284 # Extract the first word of "$tool_basename", so it can be a program name with args. 38285 set dummy $tool_basename; ac_word=$2 38286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38287 $as_echo_n "checking for $ac_word... " >&6; } 38288 if ${ac_cv_path_AR+:} false; then : 38289 $as_echo_n "(cached) " >&6 38290 else 38291 case $AR in 38292 [\\/]* | ?:[\\/]*) 38293 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38294 ;; 38295 *) 38296 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38297 for as_dir in $PATH 38298 do 38299 IFS=$as_save_IFS 38300 test -z "$as_dir" && as_dir=. 38301 for ac_exec_ext in '' $ac_executable_extensions; do 38302 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38303 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38304 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38305 break 2 38306 fi 38307 done 38308 done 38309 IFS=$as_save_IFS 38310 38311 ;; 38312 esac 38313 fi 38314 AR=$ac_cv_path_AR 38315 if test -n "$AR"; then 38316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38317 $as_echo "$AR" >&6; } 38318 else 38319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38320 $as_echo "no" >&6; } 38321 fi 38322 38323 38324 if test "x$AR" = x; then 38325 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38326 fi 38327 else 38328 # Otherwise we believe it is a complete path. Use it as it is. 38329 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38330 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38332 $as_echo_n "checking for AR... " >&6; } 38333 if test ! -x "$tool_specified"; then 38334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38335 $as_echo "not found" >&6; } 38336 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38337 fi 38338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38339 $as_echo "$tool_specified" >&6; } 38340 fi 38341 fi 38342 fi 38343 38344 fi 38345 38346 38347 else 38348 38349 38350 # Publish this variable in the help. 38351 38352 38353 if [ -z "${AR+x}" ]; then 38354 # The variable is not set by user, try to locate tool using the code snippet 38355 if test -n "$ac_tool_prefix"; then 38356 for ac_prog in ar 38357 do 38358 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38359 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38361 $as_echo_n "checking for $ac_word... " >&6; } 38362 if ${ac_cv_prog_AR+:} false; then : 38363 $as_echo_n "(cached) " >&6 38364 else 38365 if test -n "$AR"; then 38366 ac_cv_prog_AR="$AR" # Let the user override the test. 38367 else 38368 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38369 for as_dir in $PATH 38370 do 38371 IFS=$as_save_IFS 38372 test -z "$as_dir" && as_dir=. 38373 for ac_exec_ext in '' $ac_executable_extensions; do 38374 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38375 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38376 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38377 break 2 38378 fi 38379 done 38380 done 38381 IFS=$as_save_IFS 38382 38383 fi 38384 fi 38385 AR=$ac_cv_prog_AR 38386 if test -n "$AR"; then 38387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38388 $as_echo "$AR" >&6; } 38389 else 38390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38391 $as_echo "no" >&6; } 38392 fi 38393 38394 38395 test -n "$AR" && break 38396 done 38397 fi 38398 if test -z "$AR"; then 38399 ac_ct_AR=$AR 38400 for ac_prog in ar 38401 do 38402 # Extract the first word of "$ac_prog", so it can be a program name with args. 38403 set dummy $ac_prog; ac_word=$2 38404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38405 $as_echo_n "checking for $ac_word... " >&6; } 38406 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38407 $as_echo_n "(cached) " >&6 38408 else 38409 if test -n "$ac_ct_AR"; then 38410 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38411 else 38412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38413 for as_dir in $PATH 38414 do 38415 IFS=$as_save_IFS 38416 test -z "$as_dir" && as_dir=. 38417 for ac_exec_ext in '' $ac_executable_extensions; do 38418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38419 ac_cv_prog_ac_ct_AR="$ac_prog" 38420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38421 break 2 38422 fi 38423 done 38424 done 38425 IFS=$as_save_IFS 38426 38427 fi 38428 fi 38429 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38430 if test -n "$ac_ct_AR"; then 38431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38432 $as_echo "$ac_ct_AR" >&6; } 38433 else 38434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38435 $as_echo "no" >&6; } 38436 fi 38437 38438 38439 test -n "$ac_ct_AR" && break 38440 done 38441 38442 if test "x$ac_ct_AR" = x; then 38443 AR="" 38444 else 38445 case $cross_compiling:$ac_tool_warned in 38446 yes:) 38447 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38448 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38449 ac_tool_warned=yes ;; 38450 esac 38451 AR=$ac_ct_AR 38452 fi 38453 fi 38454 38455 else 38456 # The variable is set, but is it from the command line or the environment? 38457 38458 # Try to remove the string !AR! from our list. 38459 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38460 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38461 # If it failed, the variable was not from the command line. Ignore it, 38462 # but warn the user (except for BASH, which is always set by the calling BASH). 38463 if test "xAR" != xBASH; then 38464 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38465 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38466 fi 38467 # Try to locate tool using the code snippet 38468 if test -n "$ac_tool_prefix"; then 38469 for ac_prog in ar 38470 do 38471 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38472 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38474 $as_echo_n "checking for $ac_word... " >&6; } 38475 if ${ac_cv_prog_AR+:} false; then : 38476 $as_echo_n "(cached) " >&6 38477 else 38478 if test -n "$AR"; then 38479 ac_cv_prog_AR="$AR" # Let the user override the test. 38480 else 38481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38482 for as_dir in $PATH 38483 do 38484 IFS=$as_save_IFS 38485 test -z "$as_dir" && as_dir=. 38486 for ac_exec_ext in '' $ac_executable_extensions; do 38487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38488 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38490 break 2 38491 fi 38492 done 38493 done 38494 IFS=$as_save_IFS 38495 38496 fi 38497 fi 38498 AR=$ac_cv_prog_AR 38499 if test -n "$AR"; then 38500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38501 $as_echo "$AR" >&6; } 38502 else 38503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38504 $as_echo "no" >&6; } 38505 fi 38506 38507 38508 test -n "$AR" && break 38509 done 38510 fi 38511 if test -z "$AR"; then 38512 ac_ct_AR=$AR 38513 for ac_prog in ar 38514 do 38515 # Extract the first word of "$ac_prog", so it can be a program name with args. 38516 set dummy $ac_prog; ac_word=$2 38517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38518 $as_echo_n "checking for $ac_word... " >&6; } 38519 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38520 $as_echo_n "(cached) " >&6 38521 else 38522 if test -n "$ac_ct_AR"; then 38523 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38524 else 38525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38526 for as_dir in $PATH 38527 do 38528 IFS=$as_save_IFS 38529 test -z "$as_dir" && as_dir=. 38530 for ac_exec_ext in '' $ac_executable_extensions; do 38531 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38532 ac_cv_prog_ac_ct_AR="$ac_prog" 38533 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38534 break 2 38535 fi 38536 done 38537 done 38538 IFS=$as_save_IFS 38539 38540 fi 38541 fi 38542 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38543 if test -n "$ac_ct_AR"; then 38544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38545 $as_echo "$ac_ct_AR" >&6; } 38546 else 38547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38548 $as_echo "no" >&6; } 38549 fi 38550 38551 38552 test -n "$ac_ct_AR" && break 38553 done 38554 38555 if test "x$ac_ct_AR" = x; then 38556 AR="" 38557 else 38558 case $cross_compiling:$ac_tool_warned in 38559 yes:) 38560 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38561 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38562 ac_tool_warned=yes ;; 38563 esac 38564 AR=$ac_ct_AR 38565 fi 38566 fi 38567 38568 else 38569 # If it succeeded, then it was overridden by the user. We will use it 38570 # for the tool. 38571 38572 # First remove it from the list of overridden variables, so we can test 38573 # for unknown variables in the end. 38574 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38575 38576 # Check if we try to supply an empty value 38577 if test "x$AR" = x; then 38578 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38579 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38581 $as_echo_n "checking for AR... " >&6; } 38582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38583 $as_echo "disabled" >&6; } 38584 else 38585 # Check if the provided tool contains a complete path. 38586 tool_specified="$AR" 38587 tool_basename="${tool_specified##*/}" 38588 if test "x$tool_basename" = "x$tool_specified"; then 38589 # A command without a complete path is provided, search $PATH. 38590 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38591 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38592 # Extract the first word of "$tool_basename", so it can be a program name with args. 38593 set dummy $tool_basename; ac_word=$2 38594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38595 $as_echo_n "checking for $ac_word... " >&6; } 38596 if ${ac_cv_path_AR+:} false; then : 38597 $as_echo_n "(cached) " >&6 38598 else 38599 case $AR in 38600 [\\/]* | ?:[\\/]*) 38601 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38602 ;; 38603 *) 38604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38605 for as_dir in $PATH 38606 do 38607 IFS=$as_save_IFS 38608 test -z "$as_dir" && as_dir=. 38609 for ac_exec_ext in '' $ac_executable_extensions; do 38610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38611 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38613 break 2 38614 fi 38615 done 38616 done 38617 IFS=$as_save_IFS 38618 38619 ;; 38620 esac 38621 fi 38622 AR=$ac_cv_path_AR 38623 if test -n "$AR"; then 38624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38625 $as_echo "$AR" >&6; } 38626 else 38627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38628 $as_echo "no" >&6; } 38629 fi 38630 38631 38632 if test "x$AR" = x; then 38633 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38634 fi 38635 else 38636 # Otherwise we believe it is a complete path. Use it as it is. 38637 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38638 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38640 $as_echo_n "checking for AR... " >&6; } 38641 if test ! -x "$tool_specified"; then 38642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38643 $as_echo "not found" >&6; } 38644 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38645 fi 38646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38647 $as_echo "$tool_specified" >&6; } 38648 fi 38649 fi 38650 fi 38651 38652 fi 38653 38654 38655 fi 38656 38657 # Only process if variable expands to non-empty 38658 38659 if test "x$AR" != x; then 38660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38661 38662 # First separate the path from the arguments. This will split at the first 38663 # space. 38664 complete="$AR" 38665 path="${complete%% *}" 38666 tmp="$complete EOL" 38667 arguments="${tmp#* }" 38668 38669 # Input might be given as Windows format, start by converting to 38670 # unix format. 38671 new_path=`$CYGPATH -u "$path"` 38672 38673 # Now try to locate executable using which 38674 new_path=`$WHICH "$new_path" 2> /dev/null` 38675 # bat and cmd files are not always considered executable in cygwin causing which 38676 # to not find them 38677 if test "x$new_path" = x \ 38678 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38679 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38680 new_path=`$CYGPATH -u "$path"` 38681 fi 38682 if test "x$new_path" = x; then 38683 # Oops. Which didn't find the executable. 38684 # The splitting of arguments from the executable at a space might have been incorrect, 38685 # since paths with space are more likely in Windows. Give it another try with the whole 38686 # argument. 38687 path="$complete" 38688 arguments="EOL" 38689 new_path=`$CYGPATH -u "$path"` 38690 new_path=`$WHICH "$new_path" 2> /dev/null` 38691 # bat and cmd files are not always considered executable in cygwin causing which 38692 # to not find them 38693 if test "x$new_path" = x \ 38694 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38695 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38696 new_path=`$CYGPATH -u "$path"` 38697 fi 38698 if test "x$new_path" = x; then 38699 # It's still not found. Now this is an unrecoverable error. 38700 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38701 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38702 has_space=`$ECHO "$complete" | $GREP " "` 38703 if test "x$has_space" != x; then 38704 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38705 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38706 fi 38707 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38708 fi 38709 fi 38710 38711 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38712 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38713 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38714 # "foo.exe" is OK but "foo" is an error. 38715 # 38716 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38717 # It is also a way to make sure we got the proper file name for the real test later on. 38718 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38719 if test "x$test_shortpath" = x; then 38720 # Short path failed, file does not exist as specified. 38721 # Try adding .exe or .cmd 38722 if test -f "${new_path}.exe"; then 38723 input_to_shortpath="${new_path}.exe" 38724 elif test -f "${new_path}.cmd"; then 38725 input_to_shortpath="${new_path}.cmd" 38726 else 38727 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 38728 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 38729 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38730 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38731 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38732 fi 38733 else 38734 input_to_shortpath="$new_path" 38735 fi 38736 38737 # Call helper function which possibly converts this using DOS-style short mode. 38738 # If so, the updated path is stored in $new_path. 38739 new_path="$input_to_shortpath" 38740 38741 input_path="$input_to_shortpath" 38742 # Check if we need to convert this using DOS-style short mode. If the path 38743 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38744 # take no chances and rewrite it. 38745 # Note: m4 eats our [], so we need to use [ and ] instead. 38746 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38747 if test "x$has_forbidden_chars" != x; then 38748 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38749 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38750 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38751 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38752 # Going to short mode and back again did indeed matter. Since short mode is 38753 # case insensitive, let's make it lowercase to improve readability. 38754 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38755 # Now convert it back to Unix-style (cygpath) 38756 input_path=`$CYGPATH -u "$shortmode_path"` 38757 new_path="$input_path" 38758 fi 38759 fi 38760 38761 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38762 if test "x$test_cygdrive_prefix" = x; then 38763 # As a simple fix, exclude /usr/bin since it's not a real path. 38764 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38765 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38766 # a path prefixed by /cygdrive for fixpath to work. 38767 new_path="$CYGWIN_ROOT_PATH$input_path" 38768 fi 38769 fi 38770 38771 # remove trailing .exe if any 38772 new_path="${new_path/%.exe/}" 38773 38774 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38775 38776 # First separate the path from the arguments. This will split at the first 38777 # space. 38778 complete="$AR" 38779 path="${complete%% *}" 38780 tmp="$complete EOL" 38781 arguments="${tmp#* }" 38782 38783 # Input might be given as Windows format, start by converting to 38784 # unix format. 38785 new_path="$path" 38786 38787 windows_path="$new_path" 38788 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38789 unix_path=`$CYGPATH -u "$windows_path"` 38790 new_path="$unix_path" 38791 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38792 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38793 new_path="$unix_path" 38794 fi 38795 38796 38797 # Now try to locate executable using which 38798 new_path=`$WHICH "$new_path" 2> /dev/null` 38799 38800 if test "x$new_path" = x; then 38801 # Oops. Which didn't find the executable. 38802 # The splitting of arguments from the executable at a space might have been incorrect, 38803 # since paths with space are more likely in Windows. Give it another try with the whole 38804 # argument. 38805 path="$complete" 38806 arguments="EOL" 38807 new_path="$path" 38808 38809 windows_path="$new_path" 38810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38811 unix_path=`$CYGPATH -u "$windows_path"` 38812 new_path="$unix_path" 38813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38814 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38815 new_path="$unix_path" 38816 fi 38817 38818 38819 new_path=`$WHICH "$new_path" 2> /dev/null` 38820 # bat and cmd files are not always considered executable in MSYS causing which 38821 # to not find them 38822 if test "x$new_path" = x \ 38823 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38824 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38825 new_path="$path" 38826 38827 windows_path="$new_path" 38828 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38829 unix_path=`$CYGPATH -u "$windows_path"` 38830 new_path="$unix_path" 38831 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38832 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38833 new_path="$unix_path" 38834 fi 38835 38836 fi 38837 38838 if test "x$new_path" = x; then 38839 # It's still not found. Now this is an unrecoverable error. 38840 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38841 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38842 has_space=`$ECHO "$complete" | $GREP " "` 38843 if test "x$has_space" != x; then 38844 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38845 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38846 fi 38847 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38848 fi 38849 fi 38850 38851 # Now new_path has a complete unix path to the binary 38852 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38853 # Keep paths in /bin as-is, but remove trailing .exe if any 38854 new_path="${new_path/%.exe/}" 38855 # Do not save /bin paths to all_fixpath_prefixes! 38856 else 38857 # Not in mixed or Windows style, start by that. 38858 new_path=`cmd //c echo $new_path` 38859 38860 input_path="$new_path" 38861 # Check if we need to convert this using DOS-style short mode. If the path 38862 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38863 # take no chances and rewrite it. 38864 # Note: m4 eats our [], so we need to use [ and ] instead. 38865 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38866 if test "x$has_forbidden_chars" != x; then 38867 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38868 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38869 fi 38870 38871 # Output is in $new_path 38872 38873 windows_path="$new_path" 38874 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38875 unix_path=`$CYGPATH -u "$windows_path"` 38876 new_path="$unix_path" 38877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38878 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38879 new_path="$unix_path" 38880 fi 38881 38882 # remove trailing .exe if any 38883 new_path="${new_path/%.exe/}" 38884 38885 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38886 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38887 fi 38888 38889 else 38890 # We're on a unix platform. Hooray! :) 38891 # First separate the path from the arguments. This will split at the first 38892 # space. 38893 complete="$AR" 38894 path="${complete%% *}" 38895 tmp="$complete EOL" 38896 arguments="${tmp#* }" 38897 38898 # Cannot rely on the command "which" here since it doesn't always work. 38899 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38900 if test -z "$is_absolute_path"; then 38901 # Path to executable is not absolute. Find it. 38902 IFS_save="$IFS" 38903 IFS=: 38904 for p in $PATH; do 38905 if test -f "$p/$path" && test -x "$p/$path"; then 38906 new_path="$p/$path" 38907 break 38908 fi 38909 done 38910 IFS="$IFS_save" 38911 else 38912 # This is an absolute path, we can use it without further modifications. 38913 new_path="$path" 38914 fi 38915 38916 if test "x$new_path" = x; then 38917 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38918 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38919 has_space=`$ECHO "$complete" | $GREP " "` 38920 if test "x$has_space" != x; then 38921 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38922 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38923 fi 38924 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38925 fi 38926 fi 38927 38928 # Now join together the path and the arguments once again 38929 if test "x$arguments" != xEOL; then 38930 new_complete="$new_path ${arguments% *}" 38931 else 38932 new_complete="$new_path" 38933 fi 38934 38935 if test "x$complete" != "x$new_complete"; then 38936 AR="$new_complete" 38937 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38938 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38939 fi 38940 fi 38941 38942 38943 38944 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 38945 38946 38947 # Publish this variable in the help. 38948 38949 38950 if [ -z "${LIPO+x}" ]; then 38951 # The variable is not set by user, try to locate tool using the code snippet 38952 for ac_prog in lipo 38953 do 38954 # Extract the first word of "$ac_prog", so it can be a program name with args. 38955 set dummy $ac_prog; ac_word=$2 38956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38957 $as_echo_n "checking for $ac_word... " >&6; } 38958 if ${ac_cv_path_LIPO+:} false; then : 38959 $as_echo_n "(cached) " >&6 38960 else 38961 case $LIPO in 38962 [\\/]* | ?:[\\/]*) 38963 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38964 ;; 38965 *) 38966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38967 for as_dir in $PATH 38968 do 38969 IFS=$as_save_IFS 38970 test -z "$as_dir" && as_dir=. 38971 for ac_exec_ext in '' $ac_executable_extensions; do 38972 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38973 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38975 break 2 38976 fi 38977 done 38978 done 38979 IFS=$as_save_IFS 38980 38981 ;; 38982 esac 38983 fi 38984 LIPO=$ac_cv_path_LIPO 38985 if test -n "$LIPO"; then 38986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38987 $as_echo "$LIPO" >&6; } 38988 else 38989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38990 $as_echo "no" >&6; } 38991 fi 38992 38993 38994 test -n "$LIPO" && break 38995 done 38996 38997 else 38998 # The variable is set, but is it from the command line or the environment? 38999 39000 # Try to remove the string !LIPO! from our list. 39001 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 39002 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39003 # If it failed, the variable was not from the command line. Ignore it, 39004 # but warn the user (except for BASH, which is always set by the calling BASH). 39005 if test "xLIPO" != xBASH; then 39006 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 39007 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 39008 fi 39009 # Try to locate tool using the code snippet 39010 for ac_prog in lipo 39011 do 39012 # Extract the first word of "$ac_prog", so it can be a program name with args. 39013 set dummy $ac_prog; ac_word=$2 39014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39015 $as_echo_n "checking for $ac_word... " >&6; } 39016 if ${ac_cv_path_LIPO+:} false; then : 39017 $as_echo_n "(cached) " >&6 39018 else 39019 case $LIPO in 39020 [\\/]* | ?:[\\/]*) 39021 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39022 ;; 39023 *) 39024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39025 for as_dir in $PATH 39026 do 39027 IFS=$as_save_IFS 39028 test -z "$as_dir" && as_dir=. 39029 for ac_exec_ext in '' $ac_executable_extensions; do 39030 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39031 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39033 break 2 39034 fi 39035 done 39036 done 39037 IFS=$as_save_IFS 39038 39039 ;; 39040 esac 39041 fi 39042 LIPO=$ac_cv_path_LIPO 39043 if test -n "$LIPO"; then 39044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39045 $as_echo "$LIPO" >&6; } 39046 else 39047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39048 $as_echo "no" >&6; } 39049 fi 39050 39051 39052 test -n "$LIPO" && break 39053 done 39054 39055 else 39056 # If it succeeded, then it was overridden by the user. We will use it 39057 # for the tool. 39058 39059 # First remove it from the list of overridden variables, so we can test 39060 # for unknown variables in the end. 39061 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39062 39063 # Check if we try to supply an empty value 39064 if test "x$LIPO" = x; then 39065 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 39066 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 39067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 39068 $as_echo_n "checking for LIPO... " >&6; } 39069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39070 $as_echo "disabled" >&6; } 39071 else 39072 # Check if the provided tool contains a complete path. 39073 tool_specified="$LIPO" 39074 tool_basename="${tool_specified##*/}" 39075 if test "x$tool_basename" = "x$tool_specified"; then 39076 # A command without a complete path is provided, search $PATH. 39077 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 39078 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 39079 # Extract the first word of "$tool_basename", so it can be a program name with args. 39080 set dummy $tool_basename; ac_word=$2 39081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39082 $as_echo_n "checking for $ac_word... " >&6; } 39083 if ${ac_cv_path_LIPO+:} false; then : 39084 $as_echo_n "(cached) " >&6 39085 else 39086 case $LIPO in 39087 [\\/]* | ?:[\\/]*) 39088 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 39089 ;; 39090 *) 39091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39092 for as_dir in $PATH 39093 do 39094 IFS=$as_save_IFS 39095 test -z "$as_dir" && as_dir=. 39096 for ac_exec_ext in '' $ac_executable_extensions; do 39097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39098 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 39099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39100 break 2 39101 fi 39102 done 39103 done 39104 IFS=$as_save_IFS 39105 39106 ;; 39107 esac 39108 fi 39109 LIPO=$ac_cv_path_LIPO 39110 if test -n "$LIPO"; then 39111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 39112 $as_echo "$LIPO" >&6; } 39113 else 39114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39115 $as_echo "no" >&6; } 39116 fi 39117 39118 39119 if test "x$LIPO" = x; then 39120 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39121 fi 39122 else 39123 # Otherwise we believe it is a complete path. Use it as it is. 39124 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 39125 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 39126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 39127 $as_echo_n "checking for LIPO... " >&6; } 39128 if test ! -x "$tool_specified"; then 39129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39130 $as_echo "not found" >&6; } 39131 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 39132 fi 39133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39134 $as_echo "$tool_specified" >&6; } 39135 fi 39136 fi 39137 fi 39138 39139 fi 39140 39141 39142 39143 # Only process if variable expands to non-empty 39144 39145 if test "x$LIPO" != x; then 39146 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39147 39148 # First separate the path from the arguments. This will split at the first 39149 # space. 39150 complete="$LIPO" 39151 path="${complete%% *}" 39152 tmp="$complete EOL" 39153 arguments="${tmp#* }" 39154 39155 # Input might be given as Windows format, start by converting to 39156 # unix format. 39157 new_path=`$CYGPATH -u "$path"` 39158 39159 # Now try to locate executable using which 39160 new_path=`$WHICH "$new_path" 2> /dev/null` 39161 # bat and cmd files are not always considered executable in cygwin causing which 39162 # to not find them 39163 if test "x$new_path" = x \ 39164 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39165 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39166 new_path=`$CYGPATH -u "$path"` 39167 fi 39168 if test "x$new_path" = x; then 39169 # Oops. Which didn't find the executable. 39170 # The splitting of arguments from the executable at a space might have been incorrect, 39171 # since paths with space are more likely in Windows. Give it another try with the whole 39172 # argument. 39173 path="$complete" 39174 arguments="EOL" 39175 new_path=`$CYGPATH -u "$path"` 39176 new_path=`$WHICH "$new_path" 2> /dev/null` 39177 # bat and cmd files are not always considered executable in cygwin causing which 39178 # to not find them 39179 if test "x$new_path" = x \ 39180 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39181 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39182 new_path=`$CYGPATH -u "$path"` 39183 fi 39184 if test "x$new_path" = x; then 39185 # It's still not found. Now this is an unrecoverable error. 39186 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39187 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39188 has_space=`$ECHO "$complete" | $GREP " "` 39189 if test "x$has_space" != x; then 39190 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39191 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39192 fi 39193 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39194 fi 39195 fi 39196 39197 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39198 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39199 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39200 # "foo.exe" is OK but "foo" is an error. 39201 # 39202 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39203 # It is also a way to make sure we got the proper file name for the real test later on. 39204 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39205 if test "x$test_shortpath" = x; then 39206 # Short path failed, file does not exist as specified. 39207 # Try adding .exe or .cmd 39208 if test -f "${new_path}.exe"; then 39209 input_to_shortpath="${new_path}.exe" 39210 elif test -f "${new_path}.cmd"; then 39211 input_to_shortpath="${new_path}.cmd" 39212 else 39213 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 39214 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 39215 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39216 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39217 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39218 fi 39219 else 39220 input_to_shortpath="$new_path" 39221 fi 39222 39223 # Call helper function which possibly converts this using DOS-style short mode. 39224 # If so, the updated path is stored in $new_path. 39225 new_path="$input_to_shortpath" 39226 39227 input_path="$input_to_shortpath" 39228 # Check if we need to convert this using DOS-style short mode. If the path 39229 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39230 # take no chances and rewrite it. 39231 # Note: m4 eats our [], so we need to use [ and ] instead. 39232 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39233 if test "x$has_forbidden_chars" != x; then 39234 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39235 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39236 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39237 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39238 # Going to short mode and back again did indeed matter. Since short mode is 39239 # case insensitive, let's make it lowercase to improve readability. 39240 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39241 # Now convert it back to Unix-style (cygpath) 39242 input_path=`$CYGPATH -u "$shortmode_path"` 39243 new_path="$input_path" 39244 fi 39245 fi 39246 39247 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39248 if test "x$test_cygdrive_prefix" = x; then 39249 # As a simple fix, exclude /usr/bin since it's not a real path. 39250 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39251 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39252 # a path prefixed by /cygdrive for fixpath to work. 39253 new_path="$CYGWIN_ROOT_PATH$input_path" 39254 fi 39255 fi 39256 39257 # remove trailing .exe if any 39258 new_path="${new_path/%.exe/}" 39259 39260 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39261 39262 # First separate the path from the arguments. This will split at the first 39263 # space. 39264 complete="$LIPO" 39265 path="${complete%% *}" 39266 tmp="$complete EOL" 39267 arguments="${tmp#* }" 39268 39269 # Input might be given as Windows format, start by converting to 39270 # unix format. 39271 new_path="$path" 39272 39273 windows_path="$new_path" 39274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39275 unix_path=`$CYGPATH -u "$windows_path"` 39276 new_path="$unix_path" 39277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39278 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39279 new_path="$unix_path" 39280 fi 39281 39282 39283 # Now try to locate executable using which 39284 new_path=`$WHICH "$new_path" 2> /dev/null` 39285 39286 if test "x$new_path" = x; then 39287 # Oops. Which didn't find the executable. 39288 # The splitting of arguments from the executable at a space might have been incorrect, 39289 # since paths with space are more likely in Windows. Give it another try with the whole 39290 # argument. 39291 path="$complete" 39292 arguments="EOL" 39293 new_path="$path" 39294 39295 windows_path="$new_path" 39296 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39297 unix_path=`$CYGPATH -u "$windows_path"` 39298 new_path="$unix_path" 39299 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39300 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39301 new_path="$unix_path" 39302 fi 39303 39304 39305 new_path=`$WHICH "$new_path" 2> /dev/null` 39306 # bat and cmd files are not always considered executable in MSYS causing which 39307 # to not find them 39308 if test "x$new_path" = x \ 39309 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39310 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39311 new_path="$path" 39312 39313 windows_path="$new_path" 39314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39315 unix_path=`$CYGPATH -u "$windows_path"` 39316 new_path="$unix_path" 39317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39319 new_path="$unix_path" 39320 fi 39321 39322 fi 39323 39324 if test "x$new_path" = x; then 39325 # It's still not found. Now this is an unrecoverable error. 39326 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39327 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39328 has_space=`$ECHO "$complete" | $GREP " "` 39329 if test "x$has_space" != x; then 39330 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39331 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39332 fi 39333 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39334 fi 39335 fi 39336 39337 # Now new_path has a complete unix path to the binary 39338 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39339 # Keep paths in /bin as-is, but remove trailing .exe if any 39340 new_path="${new_path/%.exe/}" 39341 # Do not save /bin paths to all_fixpath_prefixes! 39342 else 39343 # Not in mixed or Windows style, start by that. 39344 new_path=`cmd //c echo $new_path` 39345 39346 input_path="$new_path" 39347 # Check if we need to convert this using DOS-style short mode. If the path 39348 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39349 # take no chances and rewrite it. 39350 # Note: m4 eats our [], so we need to use [ and ] instead. 39351 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39352 if test "x$has_forbidden_chars" != x; then 39353 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39354 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39355 fi 39356 39357 # Output is in $new_path 39358 39359 windows_path="$new_path" 39360 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39361 unix_path=`$CYGPATH -u "$windows_path"` 39362 new_path="$unix_path" 39363 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39364 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39365 new_path="$unix_path" 39366 fi 39367 39368 # remove trailing .exe if any 39369 new_path="${new_path/%.exe/}" 39370 39371 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39372 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39373 fi 39374 39375 else 39376 # We're on a unix platform. Hooray! :) 39377 # First separate the path from the arguments. This will split at the first 39378 # space. 39379 complete="$LIPO" 39380 path="${complete%% *}" 39381 tmp="$complete EOL" 39382 arguments="${tmp#* }" 39383 39384 # Cannot rely on the command "which" here since it doesn't always work. 39385 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39386 if test -z "$is_absolute_path"; then 39387 # Path to executable is not absolute. Find it. 39388 IFS_save="$IFS" 39389 IFS=: 39390 for p in $PATH; do 39391 if test -f "$p/$path" && test -x "$p/$path"; then 39392 new_path="$p/$path" 39393 break 39394 fi 39395 done 39396 IFS="$IFS_save" 39397 else 39398 # This is an absolute path, we can use it without further modifications. 39399 new_path="$path" 39400 fi 39401 39402 if test "x$new_path" = x; then 39403 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 39404 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 39405 has_space=`$ECHO "$complete" | $GREP " "` 39406 if test "x$has_space" != x; then 39407 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39408 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39409 fi 39410 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 39411 fi 39412 fi 39413 39414 # Now join together the path and the arguments once again 39415 if test "x$arguments" != xEOL; then 39416 new_complete="$new_path ${arguments% *}" 39417 else 39418 new_complete="$new_path" 39419 fi 39420 39421 if test "x$complete" != "x$new_complete"; then 39422 LIPO="$new_complete" 39423 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 39424 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 39425 fi 39426 fi 39427 39428 fi 39429 39430 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 39431 # Extract the first word of "mt", so it can be a program name with args. 39432 set dummy mt; ac_word=$2 39433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39434 $as_echo_n "checking for $ac_word... " >&6; } 39435 if ${ac_cv_prog_MT+:} false; then : 39436 $as_echo_n "(cached) " >&6 39437 else 39438 if test -n "$MT"; then 39439 ac_cv_prog_MT="$MT" # Let the user override the test. 39440 else 39441 ac_prog_rejected=no 39442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39443 for as_dir in $PATH 39444 do 39445 IFS=$as_save_IFS 39446 test -z "$as_dir" && as_dir=. 39447 for ac_exec_ext in '' $ac_executable_extensions; do 39448 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39449 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 39450 ac_prog_rejected=yes 39451 continue 39452 fi 39453 ac_cv_prog_MT="mt" 39454 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39455 break 2 39456 fi 39457 done 39458 done 39459 IFS=$as_save_IFS 39460 39461 if test $ac_prog_rejected = yes; then 39462 # We found a bogon in the path, so make sure we never use it. 39463 set dummy $ac_cv_prog_MT 39464 shift 39465 if test $# != 0; then 39466 # We chose a different compiler from the bogus one. 39467 # However, it has the same basename, so the bogon will be chosen 39468 # first if we set MT to just the basename; use the full file name. 39469 shift 39470 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 39471 fi 39472 fi 39473 fi 39474 fi 39475 MT=$ac_cv_prog_MT 39476 if test -n "$MT"; then 39477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 39478 $as_echo "$MT" >&6; } 39479 else 39480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39481 $as_echo "no" >&6; } 39482 fi 39483 39484 39485 39486 # Only process if variable expands to non-empty 39487 39488 if test "x$MT" != x; then 39489 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39490 39491 # First separate the path from the arguments. This will split at the first 39492 # space. 39493 complete="$MT" 39494 path="${complete%% *}" 39495 tmp="$complete EOL" 39496 arguments="${tmp#* }" 39497 39498 # Input might be given as Windows format, start by converting to 39499 # unix format. 39500 new_path=`$CYGPATH -u "$path"` 39501 39502 # Now try to locate executable using which 39503 new_path=`$WHICH "$new_path" 2> /dev/null` 39504 # bat and cmd files are not always considered executable in cygwin causing which 39505 # to not find them 39506 if test "x$new_path" = x \ 39507 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39508 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39509 new_path=`$CYGPATH -u "$path"` 39510 fi 39511 if test "x$new_path" = x; then 39512 # Oops. Which didn't find the executable. 39513 # The splitting of arguments from the executable at a space might have been incorrect, 39514 # since paths with space are more likely in Windows. Give it another try with the whole 39515 # argument. 39516 path="$complete" 39517 arguments="EOL" 39518 new_path=`$CYGPATH -u "$path"` 39519 new_path=`$WHICH "$new_path" 2> /dev/null` 39520 # bat and cmd files are not always considered executable in cygwin causing which 39521 # to not find them 39522 if test "x$new_path" = x \ 39523 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39524 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39525 new_path=`$CYGPATH -u "$path"` 39526 fi 39527 if test "x$new_path" = x; then 39528 # It's still not found. Now this is an unrecoverable error. 39529 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39530 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39531 has_space=`$ECHO "$complete" | $GREP " "` 39532 if test "x$has_space" != x; then 39533 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39534 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39535 fi 39536 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39537 fi 39538 fi 39539 39540 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39541 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39542 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39543 # "foo.exe" is OK but "foo" is an error. 39544 # 39545 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39546 # It is also a way to make sure we got the proper file name for the real test later on. 39547 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39548 if test "x$test_shortpath" = x; then 39549 # Short path failed, file does not exist as specified. 39550 # Try adding .exe or .cmd 39551 if test -f "${new_path}.exe"; then 39552 input_to_shortpath="${new_path}.exe" 39553 elif test -f "${new_path}.cmd"; then 39554 input_to_shortpath="${new_path}.cmd" 39555 else 39556 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 39557 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 39558 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39559 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39560 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39561 fi 39562 else 39563 input_to_shortpath="$new_path" 39564 fi 39565 39566 # Call helper function which possibly converts this using DOS-style short mode. 39567 # If so, the updated path is stored in $new_path. 39568 new_path="$input_to_shortpath" 39569 39570 input_path="$input_to_shortpath" 39571 # Check if we need to convert this using DOS-style short mode. If the path 39572 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39573 # take no chances and rewrite it. 39574 # Note: m4 eats our [], so we need to use [ and ] instead. 39575 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39576 if test "x$has_forbidden_chars" != x; then 39577 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39578 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39579 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39580 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39581 # Going to short mode and back again did indeed matter. Since short mode is 39582 # case insensitive, let's make it lowercase to improve readability. 39583 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39584 # Now convert it back to Unix-style (cygpath) 39585 input_path=`$CYGPATH -u "$shortmode_path"` 39586 new_path="$input_path" 39587 fi 39588 fi 39589 39590 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39591 if test "x$test_cygdrive_prefix" = x; then 39592 # As a simple fix, exclude /usr/bin since it's not a real path. 39593 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39594 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39595 # a path prefixed by /cygdrive for fixpath to work. 39596 new_path="$CYGWIN_ROOT_PATH$input_path" 39597 fi 39598 fi 39599 39600 # remove trailing .exe if any 39601 new_path="${new_path/%.exe/}" 39602 39603 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39604 39605 # First separate the path from the arguments. This will split at the first 39606 # space. 39607 complete="$MT" 39608 path="${complete%% *}" 39609 tmp="$complete EOL" 39610 arguments="${tmp#* }" 39611 39612 # Input might be given as Windows format, start by converting to 39613 # unix format. 39614 new_path="$path" 39615 39616 windows_path="$new_path" 39617 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39618 unix_path=`$CYGPATH -u "$windows_path"` 39619 new_path="$unix_path" 39620 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39621 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39622 new_path="$unix_path" 39623 fi 39624 39625 39626 # Now try to locate executable using which 39627 new_path=`$WHICH "$new_path" 2> /dev/null` 39628 39629 if test "x$new_path" = x; then 39630 # Oops. Which didn't find the executable. 39631 # The splitting of arguments from the executable at a space might have been incorrect, 39632 # since paths with space are more likely in Windows. Give it another try with the whole 39633 # argument. 39634 path="$complete" 39635 arguments="EOL" 39636 new_path="$path" 39637 39638 windows_path="$new_path" 39639 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39640 unix_path=`$CYGPATH -u "$windows_path"` 39641 new_path="$unix_path" 39642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39643 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39644 new_path="$unix_path" 39645 fi 39646 39647 39648 new_path=`$WHICH "$new_path" 2> /dev/null` 39649 # bat and cmd files are not always considered executable in MSYS causing which 39650 # to not find them 39651 if test "x$new_path" = x \ 39652 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39653 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39654 new_path="$path" 39655 39656 windows_path="$new_path" 39657 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39658 unix_path=`$CYGPATH -u "$windows_path"` 39659 new_path="$unix_path" 39660 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39661 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39662 new_path="$unix_path" 39663 fi 39664 39665 fi 39666 39667 if test "x$new_path" = x; then 39668 # It's still not found. Now this is an unrecoverable error. 39669 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39670 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39671 has_space=`$ECHO "$complete" | $GREP " "` 39672 if test "x$has_space" != x; then 39673 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39674 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39675 fi 39676 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39677 fi 39678 fi 39679 39680 # Now new_path has a complete unix path to the binary 39681 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39682 # Keep paths in /bin as-is, but remove trailing .exe if any 39683 new_path="${new_path/%.exe/}" 39684 # Do not save /bin paths to all_fixpath_prefixes! 39685 else 39686 # Not in mixed or Windows style, start by that. 39687 new_path=`cmd //c echo $new_path` 39688 39689 input_path="$new_path" 39690 # Check if we need to convert this using DOS-style short mode. If the path 39691 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39692 # take no chances and rewrite it. 39693 # Note: m4 eats our [], so we need to use [ and ] instead. 39694 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39695 if test "x$has_forbidden_chars" != x; then 39696 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39697 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39698 fi 39699 39700 # Output is in $new_path 39701 39702 windows_path="$new_path" 39703 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39704 unix_path=`$CYGPATH -u "$windows_path"` 39705 new_path="$unix_path" 39706 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39707 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39708 new_path="$unix_path" 39709 fi 39710 39711 # remove trailing .exe if any 39712 new_path="${new_path/%.exe/}" 39713 39714 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39715 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39716 fi 39717 39718 else 39719 # We're on a unix platform. Hooray! :) 39720 # First separate the path from the arguments. This will split at the first 39721 # space. 39722 complete="$MT" 39723 path="${complete%% *}" 39724 tmp="$complete EOL" 39725 arguments="${tmp#* }" 39726 39727 # Cannot rely on the command "which" here since it doesn't always work. 39728 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39729 if test -z "$is_absolute_path"; then 39730 # Path to executable is not absolute. Find it. 39731 IFS_save="$IFS" 39732 IFS=: 39733 for p in $PATH; do 39734 if test -f "$p/$path" && test -x "$p/$path"; then 39735 new_path="$p/$path" 39736 break 39737 fi 39738 done 39739 IFS="$IFS_save" 39740 else 39741 # This is an absolute path, we can use it without further modifications. 39742 new_path="$path" 39743 fi 39744 39745 if test "x$new_path" = x; then 39746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39747 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39748 has_space=`$ECHO "$complete" | $GREP " "` 39749 if test "x$has_space" != x; then 39750 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39751 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39752 fi 39753 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39754 fi 39755 fi 39756 39757 # Now join together the path and the arguments once again 39758 if test "x$arguments" != xEOL; then 39759 new_complete="$new_path ${arguments% *}" 39760 else 39761 new_complete="$new_path" 39762 fi 39763 39764 if test "x$complete" != "x$new_complete"; then 39765 MT="$new_complete" 39766 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 39767 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 39768 fi 39769 fi 39770 39771 # Setup the resource compiler (RC) 39772 # Extract the first word of "rc", so it can be a program name with args. 39773 set dummy rc; ac_word=$2 39774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39775 $as_echo_n "checking for $ac_word... " >&6; } 39776 if ${ac_cv_prog_RC+:} false; then : 39777 $as_echo_n "(cached) " >&6 39778 else 39779 if test -n "$RC"; then 39780 ac_cv_prog_RC="$RC" # Let the user override the test. 39781 else 39782 ac_prog_rejected=no 39783 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39784 for as_dir in $PATH 39785 do 39786 IFS=$as_save_IFS 39787 test -z "$as_dir" && as_dir=. 39788 for ac_exec_ext in '' $ac_executable_extensions; do 39789 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39790 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 39791 ac_prog_rejected=yes 39792 continue 39793 fi 39794 ac_cv_prog_RC="rc" 39795 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39796 break 2 39797 fi 39798 done 39799 done 39800 IFS=$as_save_IFS 39801 39802 if test $ac_prog_rejected = yes; then 39803 # We found a bogon in the path, so make sure we never use it. 39804 set dummy $ac_cv_prog_RC 39805 shift 39806 if test $# != 0; then 39807 # We chose a different compiler from the bogus one. 39808 # However, it has the same basename, so the bogon will be chosen 39809 # first if we set RC to just the basename; use the full file name. 39810 shift 39811 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 39812 fi 39813 fi 39814 fi 39815 fi 39816 RC=$ac_cv_prog_RC 39817 if test -n "$RC"; then 39818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 39819 $as_echo "$RC" >&6; } 39820 else 39821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39822 $as_echo "no" >&6; } 39823 fi 39824 39825 39826 39827 # Only process if variable expands to non-empty 39828 39829 if test "x$RC" != x; then 39830 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39831 39832 # First separate the path from the arguments. This will split at the first 39833 # space. 39834 complete="$RC" 39835 path="${complete%% *}" 39836 tmp="$complete EOL" 39837 arguments="${tmp#* }" 39838 39839 # Input might be given as Windows format, start by converting to 39840 # unix format. 39841 new_path=`$CYGPATH -u "$path"` 39842 39843 # Now try to locate executable using which 39844 new_path=`$WHICH "$new_path" 2> /dev/null` 39845 # bat and cmd files are not always considered executable in cygwin causing which 39846 # to not find them 39847 if test "x$new_path" = x \ 39848 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39849 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39850 new_path=`$CYGPATH -u "$path"` 39851 fi 39852 if test "x$new_path" = x; then 39853 # Oops. Which didn't find the executable. 39854 # The splitting of arguments from the executable at a space might have been incorrect, 39855 # since paths with space are more likely in Windows. Give it another try with the whole 39856 # argument. 39857 path="$complete" 39858 arguments="EOL" 39859 new_path=`$CYGPATH -u "$path"` 39860 new_path=`$WHICH "$new_path" 2> /dev/null` 39861 # bat and cmd files are not always considered executable in cygwin causing which 39862 # to not find them 39863 if test "x$new_path" = x \ 39864 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39865 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39866 new_path=`$CYGPATH -u "$path"` 39867 fi 39868 if test "x$new_path" = x; then 39869 # It's still not found. Now this is an unrecoverable error. 39870 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39871 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39872 has_space=`$ECHO "$complete" | $GREP " "` 39873 if test "x$has_space" != x; then 39874 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39875 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39876 fi 39877 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39878 fi 39879 fi 39880 39881 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39882 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39883 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39884 # "foo.exe" is OK but "foo" is an error. 39885 # 39886 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39887 # It is also a way to make sure we got the proper file name for the real test later on. 39888 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39889 if test "x$test_shortpath" = x; then 39890 # Short path failed, file does not exist as specified. 39891 # Try adding .exe or .cmd 39892 if test -f "${new_path}.exe"; then 39893 input_to_shortpath="${new_path}.exe" 39894 elif test -f "${new_path}.cmd"; then 39895 input_to_shortpath="${new_path}.cmd" 39896 else 39897 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 39898 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 39899 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39900 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39901 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39902 fi 39903 else 39904 input_to_shortpath="$new_path" 39905 fi 39906 39907 # Call helper function which possibly converts this using DOS-style short mode. 39908 # If so, the updated path is stored in $new_path. 39909 new_path="$input_to_shortpath" 39910 39911 input_path="$input_to_shortpath" 39912 # Check if we need to convert this using DOS-style short mode. If the path 39913 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39914 # take no chances and rewrite it. 39915 # Note: m4 eats our [], so we need to use [ and ] instead. 39916 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39917 if test "x$has_forbidden_chars" != x; then 39918 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39919 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39920 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39921 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39922 # Going to short mode and back again did indeed matter. Since short mode is 39923 # case insensitive, let's make it lowercase to improve readability. 39924 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39925 # Now convert it back to Unix-style (cygpath) 39926 input_path=`$CYGPATH -u "$shortmode_path"` 39927 new_path="$input_path" 39928 fi 39929 fi 39930 39931 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39932 if test "x$test_cygdrive_prefix" = x; then 39933 # As a simple fix, exclude /usr/bin since it's not a real path. 39934 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39935 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39936 # a path prefixed by /cygdrive for fixpath to work. 39937 new_path="$CYGWIN_ROOT_PATH$input_path" 39938 fi 39939 fi 39940 39941 # remove trailing .exe if any 39942 new_path="${new_path/%.exe/}" 39943 39944 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39945 39946 # First separate the path from the arguments. This will split at the first 39947 # space. 39948 complete="$RC" 39949 path="${complete%% *}" 39950 tmp="$complete EOL" 39951 arguments="${tmp#* }" 39952 39953 # Input might be given as Windows format, start by converting to 39954 # unix format. 39955 new_path="$path" 39956 39957 windows_path="$new_path" 39958 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39959 unix_path=`$CYGPATH -u "$windows_path"` 39960 new_path="$unix_path" 39961 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39962 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39963 new_path="$unix_path" 39964 fi 39965 39966 39967 # Now try to locate executable using which 39968 new_path=`$WHICH "$new_path" 2> /dev/null` 39969 39970 if test "x$new_path" = x; then 39971 # Oops. Which didn't find the executable. 39972 # The splitting of arguments from the executable at a space might have been incorrect, 39973 # since paths with space are more likely in Windows. Give it another try with the whole 39974 # argument. 39975 path="$complete" 39976 arguments="EOL" 39977 new_path="$path" 39978 39979 windows_path="$new_path" 39980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39981 unix_path=`$CYGPATH -u "$windows_path"` 39982 new_path="$unix_path" 39983 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39984 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39985 new_path="$unix_path" 39986 fi 39987 39988 39989 new_path=`$WHICH "$new_path" 2> /dev/null` 39990 # bat and cmd files are not always considered executable in MSYS causing which 39991 # to not find them 39992 if test "x$new_path" = x \ 39993 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39994 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39995 new_path="$path" 39996 39997 windows_path="$new_path" 39998 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39999 unix_path=`$CYGPATH -u "$windows_path"` 40000 new_path="$unix_path" 40001 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40002 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40003 new_path="$unix_path" 40004 fi 40005 40006 fi 40007 40008 if test "x$new_path" = x; then 40009 # It's still not found. Now this is an unrecoverable error. 40010 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 40011 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 40012 has_space=`$ECHO "$complete" | $GREP " "` 40013 if test "x$has_space" != x; then 40014 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40015 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40016 fi 40017 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 40018 fi 40019 fi 40020 40021 # Now new_path has a complete unix path to the binary 40022 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40023 # Keep paths in /bin as-is, but remove trailing .exe if any 40024 new_path="${new_path/%.exe/}" 40025 # Do not save /bin paths to all_fixpath_prefixes! 40026 else 40027 # Not in mixed or Windows style, start by that. 40028 new_path=`cmd //c echo $new_path` 40029 40030 input_path="$new_path" 40031 # Check if we need to convert this using DOS-style short mode. If the path 40032 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40033 # take no chances and rewrite it. 40034 # Note: m4 eats our [], so we need to use [ and ] instead. 40035 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40036 if test "x$has_forbidden_chars" != x; then 40037 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40038 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40039 fi 40040 40041 # Output is in $new_path 40042 40043 windows_path="$new_path" 40044 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40045 unix_path=`$CYGPATH -u "$windows_path"` 40046 new_path="$unix_path" 40047 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40048 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40049 new_path="$unix_path" 40050 fi 40051 40052 # remove trailing .exe if any 40053 new_path="${new_path/%.exe/}" 40054 40055 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40056 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40057 fi 40058 40059 else 40060 # We're on a unix platform. Hooray! :) 40061 # First separate the path from the arguments. This will split at the first 40062 # space. 40063 complete="$RC" 40064 path="${complete%% *}" 40065 tmp="$complete EOL" 40066 arguments="${tmp#* }" 40067 40068 # Cannot rely on the command "which" here since it doesn't always work. 40069 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40070 if test -z "$is_absolute_path"; then 40071 # Path to executable is not absolute. Find it. 40072 IFS_save="$IFS" 40073 IFS=: 40074 for p in $PATH; do 40075 if test -f "$p/$path" && test -x "$p/$path"; then 40076 new_path="$p/$path" 40077 break 40078 fi 40079 done 40080 IFS="$IFS_save" 40081 else 40082 # This is an absolute path, we can use it without further modifications. 40083 new_path="$path" 40084 fi 40085 40086 if test "x$new_path" = x; then 40087 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 40088 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 40089 has_space=`$ECHO "$complete" | $GREP " "` 40090 if test "x$has_space" != x; then 40091 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40092 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40093 fi 40094 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 40095 fi 40096 fi 40097 40098 # Now join together the path and the arguments once again 40099 if test "x$arguments" != xEOL; then 40100 new_complete="$new_path ${arguments% *}" 40101 else 40102 new_complete="$new_path" 40103 fi 40104 40105 if test "x$complete" != "x$new_complete"; then 40106 RC="$new_complete" 40107 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 40108 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 40109 fi 40110 fi 40111 40112 # Extract the first word of "dumpbin", so it can be a program name with args. 40113 set dummy dumpbin; ac_word=$2 40114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40115 $as_echo_n "checking for $ac_word... " >&6; } 40116 if ${ac_cv_prog_DUMPBIN+:} false; then : 40117 $as_echo_n "(cached) " >&6 40118 else 40119 if test -n "$DUMPBIN"; then 40120 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 40121 else 40122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40123 for as_dir in $PATH 40124 do 40125 IFS=$as_save_IFS 40126 test -z "$as_dir" && as_dir=. 40127 for ac_exec_ext in '' $ac_executable_extensions; do 40128 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40129 ac_cv_prog_DUMPBIN="dumpbin" 40130 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40131 break 2 40132 fi 40133 done 40134 done 40135 IFS=$as_save_IFS 40136 40137 fi 40138 fi 40139 DUMPBIN=$ac_cv_prog_DUMPBIN 40140 if test -n "$DUMPBIN"; then 40141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 40142 $as_echo "$DUMPBIN" >&6; } 40143 else 40144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40145 $as_echo "no" >&6; } 40146 fi 40147 40148 40149 40150 # Only process if variable expands to non-empty 40151 40152 if test "x$DUMPBIN" != x; then 40153 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40154 40155 # First separate the path from the arguments. This will split at the first 40156 # space. 40157 complete="$DUMPBIN" 40158 path="${complete%% *}" 40159 tmp="$complete EOL" 40160 arguments="${tmp#* }" 40161 40162 # Input might be given as Windows format, start by converting to 40163 # unix format. 40164 new_path=`$CYGPATH -u "$path"` 40165 40166 # Now try to locate executable using which 40167 new_path=`$WHICH "$new_path" 2> /dev/null` 40168 # bat and cmd files are not always considered executable in cygwin causing which 40169 # to not find them 40170 if test "x$new_path" = x \ 40171 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40172 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40173 new_path=`$CYGPATH -u "$path"` 40174 fi 40175 if test "x$new_path" = x; then 40176 # Oops. Which didn't find the executable. 40177 # The splitting of arguments from the executable at a space might have been incorrect, 40178 # since paths with space are more likely in Windows. Give it another try with the whole 40179 # argument. 40180 path="$complete" 40181 arguments="EOL" 40182 new_path=`$CYGPATH -u "$path"` 40183 new_path=`$WHICH "$new_path" 2> /dev/null` 40184 # bat and cmd files are not always considered executable in cygwin causing which 40185 # to not find them 40186 if test "x$new_path" = x \ 40187 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40188 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40189 new_path=`$CYGPATH -u "$path"` 40190 fi 40191 if test "x$new_path" = x; then 40192 # It's still not found. Now this is an unrecoverable error. 40193 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 40194 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 40195 has_space=`$ECHO "$complete" | $GREP " "` 40196 if test "x$has_space" != x; then 40197 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40198 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40199 fi 40200 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40201 fi 40202 fi 40203 40204 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40205 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40206 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40207 # "foo.exe" is OK but "foo" is an error. 40208 # 40209 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40210 # It is also a way to make sure we got the proper file name for the real test later on. 40211 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40212 if test "x$test_shortpath" = x; then 40213 # Short path failed, file does not exist as specified. 40214 # Try adding .exe or .cmd 40215 if test -f "${new_path}.exe"; then 40216 input_to_shortpath="${new_path}.exe" 40217 elif test -f "${new_path}.cmd"; then 40218 input_to_shortpath="${new_path}.cmd" 40219 else 40220 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 40221 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 40222 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40223 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40224 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40225 fi 40226 else 40227 input_to_shortpath="$new_path" 40228 fi 40229 40230 # Call helper function which possibly converts this using DOS-style short mode. 40231 # If so, the updated path is stored in $new_path. 40232 new_path="$input_to_shortpath" 40233 40234 input_path="$input_to_shortpath" 40235 # Check if we need to convert this using DOS-style short mode. If the path 40236 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40237 # take no chances and rewrite it. 40238 # Note: m4 eats our [], so we need to use [ and ] instead. 40239 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40240 if test "x$has_forbidden_chars" != x; then 40241 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40242 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40243 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40244 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40245 # Going to short mode and back again did indeed matter. Since short mode is 40246 # case insensitive, let's make it lowercase to improve readability. 40247 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40248 # Now convert it back to Unix-style (cygpath) 40249 input_path=`$CYGPATH -u "$shortmode_path"` 40250 new_path="$input_path" 40251 fi 40252 fi 40253 40254 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40255 if test "x$test_cygdrive_prefix" = x; then 40256 # As a simple fix, exclude /usr/bin since it's not a real path. 40257 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40258 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40259 # a path prefixed by /cygdrive for fixpath to work. 40260 new_path="$CYGWIN_ROOT_PATH$input_path" 40261 fi 40262 fi 40263 40264 # remove trailing .exe if any 40265 new_path="${new_path/%.exe/}" 40266 40267 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40268 40269 # First separate the path from the arguments. This will split at the first 40270 # space. 40271 complete="$DUMPBIN" 40272 path="${complete%% *}" 40273 tmp="$complete EOL" 40274 arguments="${tmp#* }" 40275 40276 # Input might be given as Windows format, start by converting to 40277 # unix format. 40278 new_path="$path" 40279 40280 windows_path="$new_path" 40281 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40282 unix_path=`$CYGPATH -u "$windows_path"` 40283 new_path="$unix_path" 40284 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40285 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40286 new_path="$unix_path" 40287 fi 40288 40289 40290 # Now try to locate executable using which 40291 new_path=`$WHICH "$new_path" 2> /dev/null` 40292 40293 if test "x$new_path" = x; then 40294 # Oops. Which didn't find the executable. 40295 # The splitting of arguments from the executable at a space might have been incorrect, 40296 # since paths with space are more likely in Windows. Give it another try with the whole 40297 # argument. 40298 path="$complete" 40299 arguments="EOL" 40300 new_path="$path" 40301 40302 windows_path="$new_path" 40303 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40304 unix_path=`$CYGPATH -u "$windows_path"` 40305 new_path="$unix_path" 40306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40307 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40308 new_path="$unix_path" 40309 fi 40310 40311 40312 new_path=`$WHICH "$new_path" 2> /dev/null` 40313 # bat and cmd files are not always considered executable in MSYS causing which 40314 # to not find them 40315 if test "x$new_path" = x \ 40316 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40317 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40318 new_path="$path" 40319 40320 windows_path="$new_path" 40321 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40322 unix_path=`$CYGPATH -u "$windows_path"` 40323 new_path="$unix_path" 40324 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40325 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40326 new_path="$unix_path" 40327 fi 40328 40329 fi 40330 40331 if test "x$new_path" = x; then 40332 # It's still not found. Now this is an unrecoverable error. 40333 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 40334 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 40335 has_space=`$ECHO "$complete" | $GREP " "` 40336 if test "x$has_space" != x; then 40337 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40338 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40339 fi 40340 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40341 fi 40342 fi 40343 40344 # Now new_path has a complete unix path to the binary 40345 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40346 # Keep paths in /bin as-is, but remove trailing .exe if any 40347 new_path="${new_path/%.exe/}" 40348 # Do not save /bin paths to all_fixpath_prefixes! 40349 else 40350 # Not in mixed or Windows style, start by that. 40351 new_path=`cmd //c echo $new_path` 40352 40353 input_path="$new_path" 40354 # Check if we need to convert this using DOS-style short mode. If the path 40355 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40356 # take no chances and rewrite it. 40357 # Note: m4 eats our [], so we need to use [ and ] instead. 40358 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40359 if test "x$has_forbidden_chars" != x; then 40360 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40361 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40362 fi 40363 40364 # Output is in $new_path 40365 40366 windows_path="$new_path" 40367 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40368 unix_path=`$CYGPATH -u "$windows_path"` 40369 new_path="$unix_path" 40370 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40371 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40372 new_path="$unix_path" 40373 fi 40374 40375 # remove trailing .exe if any 40376 new_path="${new_path/%.exe/}" 40377 40378 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40379 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40380 fi 40381 40382 else 40383 # We're on a unix platform. Hooray! :) 40384 # First separate the path from the arguments. This will split at the first 40385 # space. 40386 complete="$DUMPBIN" 40387 path="${complete%% *}" 40388 tmp="$complete EOL" 40389 arguments="${tmp#* }" 40390 40391 # Cannot rely on the command "which" here since it doesn't always work. 40392 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40393 if test -z "$is_absolute_path"; then 40394 # Path to executable is not absolute. Find it. 40395 IFS_save="$IFS" 40396 IFS=: 40397 for p in $PATH; do 40398 if test -f "$p/$path" && test -x "$p/$path"; then 40399 new_path="$p/$path" 40400 break 40401 fi 40402 done 40403 IFS="$IFS_save" 40404 else 40405 # This is an absolute path, we can use it without further modifications. 40406 new_path="$path" 40407 fi 40408 40409 if test "x$new_path" = x; then 40410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 40411 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 40412 has_space=`$ECHO "$complete" | $GREP " "` 40413 if test "x$has_space" != x; then 40414 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40415 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40416 fi 40417 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 40418 fi 40419 fi 40420 40421 # Now join together the path and the arguments once again 40422 if test "x$arguments" != xEOL; then 40423 new_complete="$new_path ${arguments% *}" 40424 else 40425 new_complete="$new_path" 40426 fi 40427 40428 if test "x$complete" != "x$new_complete"; then 40429 DUMPBIN="$new_complete" 40430 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 40431 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 40432 fi 40433 fi 40434 40435 # We need to check for 'msbuild.exe' because at the place where we expect to 40436 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 40437 # won't find the 'msbuild.exe' executable in that case (and the 40438 # 'ac_executable_extensions' is unusable due to performance reasons). 40439 # Notice that we intentionally don't fix up the path to MSBUILD because we 40440 # will call it in a DOS shell during freetype detection on Windows (see 40441 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 40442 # Extract the first word of "msbuild.exe", so it can be a program name with args. 40443 set dummy msbuild.exe; ac_word=$2 40444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40445 $as_echo_n "checking for $ac_word... " >&6; } 40446 if ${ac_cv_prog_MSBUILD+:} false; then : 40447 $as_echo_n "(cached) " >&6 40448 else 40449 if test -n "$MSBUILD"; then 40450 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 40451 else 40452 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40453 for as_dir in $PATH 40454 do 40455 IFS=$as_save_IFS 40456 test -z "$as_dir" && as_dir=. 40457 for ac_exec_ext in '' $ac_executable_extensions; do 40458 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40459 ac_cv_prog_MSBUILD="msbuild.exe" 40460 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40461 break 2 40462 fi 40463 done 40464 done 40465 IFS=$as_save_IFS 40466 40467 fi 40468 fi 40469 MSBUILD=$ac_cv_prog_MSBUILD 40470 if test -n "$MSBUILD"; then 40471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 40472 $as_echo "$MSBUILD" >&6; } 40473 else 40474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40475 $as_echo "no" >&6; } 40476 fi 40477 40478 40479 fi 40480 40481 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 40482 40483 40484 # Publish this variable in the help. 40485 40486 40487 if [ -z "${STRIP+x}" ]; then 40488 # The variable is not set by user, try to locate tool using the code snippet 40489 for ac_prog in strip 40490 do 40491 # Extract the first word of "$ac_prog", so it can be a program name with args. 40492 set dummy $ac_prog; ac_word=$2 40493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40494 $as_echo_n "checking for $ac_word... " >&6; } 40495 if ${ac_cv_path_STRIP+:} false; then : 40496 $as_echo_n "(cached) " >&6 40497 else 40498 case $STRIP in 40499 [\\/]* | ?:[\\/]*) 40500 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40501 ;; 40502 *) 40503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40504 for as_dir in $PATH 40505 do 40506 IFS=$as_save_IFS 40507 test -z "$as_dir" && as_dir=. 40508 for ac_exec_ext in '' $ac_executable_extensions; do 40509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40510 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40512 break 2 40513 fi 40514 done 40515 done 40516 IFS=$as_save_IFS 40517 40518 ;; 40519 esac 40520 fi 40521 STRIP=$ac_cv_path_STRIP 40522 if test -n "$STRIP"; then 40523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40524 $as_echo "$STRIP" >&6; } 40525 else 40526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40527 $as_echo "no" >&6; } 40528 fi 40529 40530 40531 test -n "$STRIP" && break 40532 done 40533 40534 else 40535 # The variable is set, but is it from the command line or the environment? 40536 40537 # Try to remove the string !STRIP! from our list. 40538 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 40539 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40540 # If it failed, the variable was not from the command line. Ignore it, 40541 # but warn the user (except for BASH, which is always set by the calling BASH). 40542 if test "xSTRIP" != xBASH; then 40543 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 40544 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 40545 fi 40546 # Try to locate tool using the code snippet 40547 for ac_prog in strip 40548 do 40549 # Extract the first word of "$ac_prog", so it can be a program name with args. 40550 set dummy $ac_prog; ac_word=$2 40551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40552 $as_echo_n "checking for $ac_word... " >&6; } 40553 if ${ac_cv_path_STRIP+:} false; then : 40554 $as_echo_n "(cached) " >&6 40555 else 40556 case $STRIP in 40557 [\\/]* | ?:[\\/]*) 40558 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40559 ;; 40560 *) 40561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40562 for as_dir in $PATH 40563 do 40564 IFS=$as_save_IFS 40565 test -z "$as_dir" && as_dir=. 40566 for ac_exec_ext in '' $ac_executable_extensions; do 40567 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40568 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40570 break 2 40571 fi 40572 done 40573 done 40574 IFS=$as_save_IFS 40575 40576 ;; 40577 esac 40578 fi 40579 STRIP=$ac_cv_path_STRIP 40580 if test -n "$STRIP"; then 40581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40582 $as_echo "$STRIP" >&6; } 40583 else 40584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40585 $as_echo "no" >&6; } 40586 fi 40587 40588 40589 test -n "$STRIP" && break 40590 done 40591 40592 else 40593 # If it succeeded, then it was overridden by the user. We will use it 40594 # for the tool. 40595 40596 # First remove it from the list of overridden variables, so we can test 40597 # for unknown variables in the end. 40598 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40599 40600 # Check if we try to supply an empty value 40601 if test "x$STRIP" = x; then 40602 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 40603 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 40604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40605 $as_echo_n "checking for STRIP... " >&6; } 40606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40607 $as_echo "disabled" >&6; } 40608 else 40609 # Check if the provided tool contains a complete path. 40610 tool_specified="$STRIP" 40611 tool_basename="${tool_specified##*/}" 40612 if test "x$tool_basename" = "x$tool_specified"; then 40613 # A command without a complete path is provided, search $PATH. 40614 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 40615 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 40616 # Extract the first word of "$tool_basename", so it can be a program name with args. 40617 set dummy $tool_basename; ac_word=$2 40618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40619 $as_echo_n "checking for $ac_word... " >&6; } 40620 if ${ac_cv_path_STRIP+:} false; then : 40621 $as_echo_n "(cached) " >&6 40622 else 40623 case $STRIP in 40624 [\\/]* | ?:[\\/]*) 40625 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40626 ;; 40627 *) 40628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40629 for as_dir in $PATH 40630 do 40631 IFS=$as_save_IFS 40632 test -z "$as_dir" && as_dir=. 40633 for ac_exec_ext in '' $ac_executable_extensions; do 40634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40635 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40637 break 2 40638 fi 40639 done 40640 done 40641 IFS=$as_save_IFS 40642 40643 ;; 40644 esac 40645 fi 40646 STRIP=$ac_cv_path_STRIP 40647 if test -n "$STRIP"; then 40648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40649 $as_echo "$STRIP" >&6; } 40650 else 40651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40652 $as_echo "no" >&6; } 40653 fi 40654 40655 40656 if test "x$STRIP" = x; then 40657 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40658 fi 40659 else 40660 # Otherwise we believe it is a complete path. Use it as it is. 40661 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 40662 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 40663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40664 $as_echo_n "checking for STRIP... " >&6; } 40665 if test ! -x "$tool_specified"; then 40666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40667 $as_echo "not found" >&6; } 40668 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 40669 fi 40670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40671 $as_echo "$tool_specified" >&6; } 40672 fi 40673 fi 40674 fi 40675 40676 fi 40677 40678 40679 40680 # Only process if variable expands to non-empty 40681 40682 if test "x$STRIP" != x; then 40683 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40684 40685 # First separate the path from the arguments. This will split at the first 40686 # space. 40687 complete="$STRIP" 40688 path="${complete%% *}" 40689 tmp="$complete EOL" 40690 arguments="${tmp#* }" 40691 40692 # Input might be given as Windows format, start by converting to 40693 # unix format. 40694 new_path=`$CYGPATH -u "$path"` 40695 40696 # Now try to locate executable using which 40697 new_path=`$WHICH "$new_path" 2> /dev/null` 40698 # bat and cmd files are not always considered executable in cygwin causing which 40699 # to not find them 40700 if test "x$new_path" = x \ 40701 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40702 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40703 new_path=`$CYGPATH -u "$path"` 40704 fi 40705 if test "x$new_path" = x; then 40706 # Oops. Which didn't find the executable. 40707 # The splitting of arguments from the executable at a space might have been incorrect, 40708 # since paths with space are more likely in Windows. Give it another try with the whole 40709 # argument. 40710 path="$complete" 40711 arguments="EOL" 40712 new_path=`$CYGPATH -u "$path"` 40713 new_path=`$WHICH "$new_path" 2> /dev/null` 40714 # bat and cmd files are not always considered executable in cygwin causing which 40715 # to not find them 40716 if test "x$new_path" = x \ 40717 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40718 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40719 new_path=`$CYGPATH -u "$path"` 40720 fi 40721 if test "x$new_path" = x; then 40722 # It's still not found. Now this is an unrecoverable error. 40723 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40724 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40725 has_space=`$ECHO "$complete" | $GREP " "` 40726 if test "x$has_space" != x; then 40727 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40728 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40729 fi 40730 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40731 fi 40732 fi 40733 40734 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40735 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40736 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40737 # "foo.exe" is OK but "foo" is an error. 40738 # 40739 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40740 # It is also a way to make sure we got the proper file name for the real test later on. 40741 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40742 if test "x$test_shortpath" = x; then 40743 # Short path failed, file does not exist as specified. 40744 # Try adding .exe or .cmd 40745 if test -f "${new_path}.exe"; then 40746 input_to_shortpath="${new_path}.exe" 40747 elif test -f "${new_path}.cmd"; then 40748 input_to_shortpath="${new_path}.cmd" 40749 else 40750 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 40751 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 40752 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40753 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40754 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40755 fi 40756 else 40757 input_to_shortpath="$new_path" 40758 fi 40759 40760 # Call helper function which possibly converts this using DOS-style short mode. 40761 # If so, the updated path is stored in $new_path. 40762 new_path="$input_to_shortpath" 40763 40764 input_path="$input_to_shortpath" 40765 # Check if we need to convert this using DOS-style short mode. If the path 40766 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40767 # take no chances and rewrite it. 40768 # Note: m4 eats our [], so we need to use [ and ] instead. 40769 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40770 if test "x$has_forbidden_chars" != x; then 40771 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40772 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40773 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40774 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40775 # Going to short mode and back again did indeed matter. Since short mode is 40776 # case insensitive, let's make it lowercase to improve readability. 40777 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40778 # Now convert it back to Unix-style (cygpath) 40779 input_path=`$CYGPATH -u "$shortmode_path"` 40780 new_path="$input_path" 40781 fi 40782 fi 40783 40784 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40785 if test "x$test_cygdrive_prefix" = x; then 40786 # As a simple fix, exclude /usr/bin since it's not a real path. 40787 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40788 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40789 # a path prefixed by /cygdrive for fixpath to work. 40790 new_path="$CYGWIN_ROOT_PATH$input_path" 40791 fi 40792 fi 40793 40794 # remove trailing .exe if any 40795 new_path="${new_path/%.exe/}" 40796 40797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40798 40799 # First separate the path from the arguments. This will split at the first 40800 # space. 40801 complete="$STRIP" 40802 path="${complete%% *}" 40803 tmp="$complete EOL" 40804 arguments="${tmp#* }" 40805 40806 # Input might be given as Windows format, start by converting to 40807 # unix format. 40808 new_path="$path" 40809 40810 windows_path="$new_path" 40811 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40812 unix_path=`$CYGPATH -u "$windows_path"` 40813 new_path="$unix_path" 40814 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40815 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40816 new_path="$unix_path" 40817 fi 40818 40819 40820 # Now try to locate executable using which 40821 new_path=`$WHICH "$new_path" 2> /dev/null` 40822 40823 if test "x$new_path" = x; then 40824 # Oops. Which didn't find the executable. 40825 # The splitting of arguments from the executable at a space might have been incorrect, 40826 # since paths with space are more likely in Windows. Give it another try with the whole 40827 # argument. 40828 path="$complete" 40829 arguments="EOL" 40830 new_path="$path" 40831 40832 windows_path="$new_path" 40833 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40834 unix_path=`$CYGPATH -u "$windows_path"` 40835 new_path="$unix_path" 40836 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40837 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40838 new_path="$unix_path" 40839 fi 40840 40841 40842 new_path=`$WHICH "$new_path" 2> /dev/null` 40843 # bat and cmd files are not always considered executable in MSYS causing which 40844 # to not find them 40845 if test "x$new_path" = x \ 40846 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40847 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40848 new_path="$path" 40849 40850 windows_path="$new_path" 40851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40852 unix_path=`$CYGPATH -u "$windows_path"` 40853 new_path="$unix_path" 40854 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40855 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40856 new_path="$unix_path" 40857 fi 40858 40859 fi 40860 40861 if test "x$new_path" = x; then 40862 # It's still not found. Now this is an unrecoverable error. 40863 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40864 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40865 has_space=`$ECHO "$complete" | $GREP " "` 40866 if test "x$has_space" != x; then 40867 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40868 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40869 fi 40870 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40871 fi 40872 fi 40873 40874 # Now new_path has a complete unix path to the binary 40875 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40876 # Keep paths in /bin as-is, but remove trailing .exe if any 40877 new_path="${new_path/%.exe/}" 40878 # Do not save /bin paths to all_fixpath_prefixes! 40879 else 40880 # Not in mixed or Windows style, start by that. 40881 new_path=`cmd //c echo $new_path` 40882 40883 input_path="$new_path" 40884 # Check if we need to convert this using DOS-style short mode. If the path 40885 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40886 # take no chances and rewrite it. 40887 # Note: m4 eats our [], so we need to use [ and ] instead. 40888 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40889 if test "x$has_forbidden_chars" != x; then 40890 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40891 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40892 fi 40893 40894 # Output is in $new_path 40895 40896 windows_path="$new_path" 40897 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40898 unix_path=`$CYGPATH -u "$windows_path"` 40899 new_path="$unix_path" 40900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40901 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40902 new_path="$unix_path" 40903 fi 40904 40905 # remove trailing .exe if any 40906 new_path="${new_path/%.exe/}" 40907 40908 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40909 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40910 fi 40911 40912 else 40913 # We're on a unix platform. Hooray! :) 40914 # First separate the path from the arguments. This will split at the first 40915 # space. 40916 complete="$STRIP" 40917 path="${complete%% *}" 40918 tmp="$complete EOL" 40919 arguments="${tmp#* }" 40920 40921 # Cannot rely on the command "which" here since it doesn't always work. 40922 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40923 if test -z "$is_absolute_path"; then 40924 # Path to executable is not absolute. Find it. 40925 IFS_save="$IFS" 40926 IFS=: 40927 for p in $PATH; do 40928 if test -f "$p/$path" && test -x "$p/$path"; then 40929 new_path="$p/$path" 40930 break 40931 fi 40932 done 40933 IFS="$IFS_save" 40934 else 40935 # This is an absolute path, we can use it without further modifications. 40936 new_path="$path" 40937 fi 40938 40939 if test "x$new_path" = x; then 40940 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40941 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40942 has_space=`$ECHO "$complete" | $GREP " "` 40943 if test "x$has_space" != x; then 40944 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40945 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40946 fi 40947 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40948 fi 40949 fi 40950 40951 # Now join together the path and the arguments once again 40952 if test "x$arguments" != xEOL; then 40953 new_complete="$new_path ${arguments% *}" 40954 else 40955 new_complete="$new_path" 40956 fi 40957 40958 if test "x$complete" != "x$new_complete"; then 40959 STRIP="$new_complete" 40960 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 40961 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 40962 fi 40963 fi 40964 40965 40966 40967 # Publish this variable in the help. 40968 40969 40970 if [ -z "${NM+x}" ]; then 40971 # The variable is not set by user, try to locate tool using the code snippet 40972 for ac_prog in nm 40973 do 40974 # Extract the first word of "$ac_prog", so it can be a program name with args. 40975 set dummy $ac_prog; ac_word=$2 40976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40977 $as_echo_n "checking for $ac_word... " >&6; } 40978 if ${ac_cv_path_NM+:} false; then : 40979 $as_echo_n "(cached) " >&6 40980 else 40981 case $NM in 40982 [\\/]* | ?:[\\/]*) 40983 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40984 ;; 40985 *) 40986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40987 for as_dir in $PATH 40988 do 40989 IFS=$as_save_IFS 40990 test -z "$as_dir" && as_dir=. 40991 for ac_exec_ext in '' $ac_executable_extensions; do 40992 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40993 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40994 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40995 break 2 40996 fi 40997 done 40998 done 40999 IFS=$as_save_IFS 41000 41001 ;; 41002 esac 41003 fi 41004 NM=$ac_cv_path_NM 41005 if test -n "$NM"; then 41006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41007 $as_echo "$NM" >&6; } 41008 else 41009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41010 $as_echo "no" >&6; } 41011 fi 41012 41013 41014 test -n "$NM" && break 41015 done 41016 41017 else 41018 # The variable is set, but is it from the command line or the environment? 41019 41020 # Try to remove the string !NM! from our list. 41021 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 41022 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41023 # If it failed, the variable was not from the command line. Ignore it, 41024 # but warn the user (except for BASH, which is always set by the calling BASH). 41025 if test "xNM" != xBASH; then 41026 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 41027 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 41028 fi 41029 # Try to locate tool using the code snippet 41030 for ac_prog in nm 41031 do 41032 # Extract the first word of "$ac_prog", so it can be a program name with args. 41033 set dummy $ac_prog; ac_word=$2 41034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41035 $as_echo_n "checking for $ac_word... " >&6; } 41036 if ${ac_cv_path_NM+:} false; then : 41037 $as_echo_n "(cached) " >&6 41038 else 41039 case $NM in 41040 [\\/]* | ?:[\\/]*) 41041 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41042 ;; 41043 *) 41044 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41045 for as_dir in $PATH 41046 do 41047 IFS=$as_save_IFS 41048 test -z "$as_dir" && as_dir=. 41049 for ac_exec_ext in '' $ac_executable_extensions; do 41050 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41051 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41052 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41053 break 2 41054 fi 41055 done 41056 done 41057 IFS=$as_save_IFS 41058 41059 ;; 41060 esac 41061 fi 41062 NM=$ac_cv_path_NM 41063 if test -n "$NM"; then 41064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41065 $as_echo "$NM" >&6; } 41066 else 41067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41068 $as_echo "no" >&6; } 41069 fi 41070 41071 41072 test -n "$NM" && break 41073 done 41074 41075 else 41076 # If it succeeded, then it was overridden by the user. We will use it 41077 # for the tool. 41078 41079 # First remove it from the list of overridden variables, so we can test 41080 # for unknown variables in the end. 41081 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41082 41083 # Check if we try to supply an empty value 41084 if test "x$NM" = x; then 41085 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41086 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41088 $as_echo_n "checking for NM... " >&6; } 41089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41090 $as_echo "disabled" >&6; } 41091 else 41092 # Check if the provided tool contains a complete path. 41093 tool_specified="$NM" 41094 tool_basename="${tool_specified##*/}" 41095 if test "x$tool_basename" = "x$tool_specified"; then 41096 # A command without a complete path is provided, search $PATH. 41097 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41098 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41099 # Extract the first word of "$tool_basename", so it can be a program name with args. 41100 set dummy $tool_basename; ac_word=$2 41101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41102 $as_echo_n "checking for $ac_word... " >&6; } 41103 if ${ac_cv_path_NM+:} false; then : 41104 $as_echo_n "(cached) " >&6 41105 else 41106 case $NM in 41107 [\\/]* | ?:[\\/]*) 41108 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41109 ;; 41110 *) 41111 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41112 for as_dir in $PATH 41113 do 41114 IFS=$as_save_IFS 41115 test -z "$as_dir" && as_dir=. 41116 for ac_exec_ext in '' $ac_executable_extensions; do 41117 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41118 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41119 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41120 break 2 41121 fi 41122 done 41123 done 41124 IFS=$as_save_IFS 41125 41126 ;; 41127 esac 41128 fi 41129 NM=$ac_cv_path_NM 41130 if test -n "$NM"; then 41131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41132 $as_echo "$NM" >&6; } 41133 else 41134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41135 $as_echo "no" >&6; } 41136 fi 41137 41138 41139 if test "x$NM" = x; then 41140 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41141 fi 41142 else 41143 # Otherwise we believe it is a complete path. Use it as it is. 41144 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41145 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41147 $as_echo_n "checking for NM... " >&6; } 41148 if test ! -x "$tool_specified"; then 41149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41150 $as_echo "not found" >&6; } 41151 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41152 fi 41153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41154 $as_echo "$tool_specified" >&6; } 41155 fi 41156 fi 41157 fi 41158 41159 fi 41160 41161 41162 41163 # Only process if variable expands to non-empty 41164 41165 if test "x$NM" != x; then 41166 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41167 41168 # First separate the path from the arguments. This will split at the first 41169 # space. 41170 complete="$NM" 41171 path="${complete%% *}" 41172 tmp="$complete EOL" 41173 arguments="${tmp#* }" 41174 41175 # Input might be given as Windows format, start by converting to 41176 # unix format. 41177 new_path=`$CYGPATH -u "$path"` 41178 41179 # Now try to locate executable using which 41180 new_path=`$WHICH "$new_path" 2> /dev/null` 41181 # bat and cmd files are not always considered executable in cygwin causing which 41182 # to not find them 41183 if test "x$new_path" = x \ 41184 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41185 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41186 new_path=`$CYGPATH -u "$path"` 41187 fi 41188 if test "x$new_path" = x; then 41189 # Oops. Which didn't find the executable. 41190 # The splitting of arguments from the executable at a space might have been incorrect, 41191 # since paths with space are more likely in Windows. Give it another try with the whole 41192 # argument. 41193 path="$complete" 41194 arguments="EOL" 41195 new_path=`$CYGPATH -u "$path"` 41196 new_path=`$WHICH "$new_path" 2> /dev/null` 41197 # bat and cmd files are not always considered executable in cygwin causing which 41198 # to not find them 41199 if test "x$new_path" = x \ 41200 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41201 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41202 new_path=`$CYGPATH -u "$path"` 41203 fi 41204 if test "x$new_path" = x; then 41205 # It's still not found. Now this is an unrecoverable error. 41206 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41207 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41208 has_space=`$ECHO "$complete" | $GREP " "` 41209 if test "x$has_space" != x; then 41210 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41211 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41212 fi 41213 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41214 fi 41215 fi 41216 41217 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41218 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41219 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41220 # "foo.exe" is OK but "foo" is an error. 41221 # 41222 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41223 # It is also a way to make sure we got the proper file name for the real test later on. 41224 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41225 if test "x$test_shortpath" = x; then 41226 # Short path failed, file does not exist as specified. 41227 # Try adding .exe or .cmd 41228 if test -f "${new_path}.exe"; then 41229 input_to_shortpath="${new_path}.exe" 41230 elif test -f "${new_path}.cmd"; then 41231 input_to_shortpath="${new_path}.cmd" 41232 else 41233 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 41234 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 41235 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41236 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41237 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41238 fi 41239 else 41240 input_to_shortpath="$new_path" 41241 fi 41242 41243 # Call helper function which possibly converts this using DOS-style short mode. 41244 # If so, the updated path is stored in $new_path. 41245 new_path="$input_to_shortpath" 41246 41247 input_path="$input_to_shortpath" 41248 # Check if we need to convert this using DOS-style short mode. If the path 41249 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41250 # take no chances and rewrite it. 41251 # Note: m4 eats our [], so we need to use [ and ] instead. 41252 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41253 if test "x$has_forbidden_chars" != x; then 41254 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41255 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41256 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41257 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41258 # Going to short mode and back again did indeed matter. Since short mode is 41259 # case insensitive, let's make it lowercase to improve readability. 41260 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41261 # Now convert it back to Unix-style (cygpath) 41262 input_path=`$CYGPATH -u "$shortmode_path"` 41263 new_path="$input_path" 41264 fi 41265 fi 41266 41267 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41268 if test "x$test_cygdrive_prefix" = x; then 41269 # As a simple fix, exclude /usr/bin since it's not a real path. 41270 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41271 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41272 # a path prefixed by /cygdrive for fixpath to work. 41273 new_path="$CYGWIN_ROOT_PATH$input_path" 41274 fi 41275 fi 41276 41277 # remove trailing .exe if any 41278 new_path="${new_path/%.exe/}" 41279 41280 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41281 41282 # First separate the path from the arguments. This will split at the first 41283 # space. 41284 complete="$NM" 41285 path="${complete%% *}" 41286 tmp="$complete EOL" 41287 arguments="${tmp#* }" 41288 41289 # Input might be given as Windows format, start by converting to 41290 # unix format. 41291 new_path="$path" 41292 41293 windows_path="$new_path" 41294 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41295 unix_path=`$CYGPATH -u "$windows_path"` 41296 new_path="$unix_path" 41297 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41298 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41299 new_path="$unix_path" 41300 fi 41301 41302 41303 # Now try to locate executable using which 41304 new_path=`$WHICH "$new_path" 2> /dev/null` 41305 41306 if test "x$new_path" = x; then 41307 # Oops. Which didn't find the executable. 41308 # The splitting of arguments from the executable at a space might have been incorrect, 41309 # since paths with space are more likely in Windows. Give it another try with the whole 41310 # argument. 41311 path="$complete" 41312 arguments="EOL" 41313 new_path="$path" 41314 41315 windows_path="$new_path" 41316 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41317 unix_path=`$CYGPATH -u "$windows_path"` 41318 new_path="$unix_path" 41319 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41320 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41321 new_path="$unix_path" 41322 fi 41323 41324 41325 new_path=`$WHICH "$new_path" 2> /dev/null` 41326 # bat and cmd files are not always considered executable in MSYS causing which 41327 # to not find them 41328 if test "x$new_path" = x \ 41329 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41330 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41331 new_path="$path" 41332 41333 windows_path="$new_path" 41334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41335 unix_path=`$CYGPATH -u "$windows_path"` 41336 new_path="$unix_path" 41337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41338 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41339 new_path="$unix_path" 41340 fi 41341 41342 fi 41343 41344 if test "x$new_path" = x; then 41345 # It's still not found. Now this is an unrecoverable error. 41346 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41347 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41348 has_space=`$ECHO "$complete" | $GREP " "` 41349 if test "x$has_space" != x; then 41350 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41351 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41352 fi 41353 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41354 fi 41355 fi 41356 41357 # Now new_path has a complete unix path to the binary 41358 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41359 # Keep paths in /bin as-is, but remove trailing .exe if any 41360 new_path="${new_path/%.exe/}" 41361 # Do not save /bin paths to all_fixpath_prefixes! 41362 else 41363 # Not in mixed or Windows style, start by that. 41364 new_path=`cmd //c echo $new_path` 41365 41366 input_path="$new_path" 41367 # Check if we need to convert this using DOS-style short mode. If the path 41368 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41369 # take no chances and rewrite it. 41370 # Note: m4 eats our [], so we need to use [ and ] instead. 41371 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41372 if test "x$has_forbidden_chars" != x; then 41373 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41374 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41375 fi 41376 41377 # Output is in $new_path 41378 41379 windows_path="$new_path" 41380 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41381 unix_path=`$CYGPATH -u "$windows_path"` 41382 new_path="$unix_path" 41383 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41384 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41385 new_path="$unix_path" 41386 fi 41387 41388 # remove trailing .exe if any 41389 new_path="${new_path/%.exe/}" 41390 41391 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41392 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41393 fi 41394 41395 else 41396 # We're on a unix platform. Hooray! :) 41397 # First separate the path from the arguments. This will split at the first 41398 # space. 41399 complete="$NM" 41400 path="${complete%% *}" 41401 tmp="$complete EOL" 41402 arguments="${tmp#* }" 41403 41404 # Cannot rely on the command "which" here since it doesn't always work. 41405 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41406 if test -z "$is_absolute_path"; then 41407 # Path to executable is not absolute. Find it. 41408 IFS_save="$IFS" 41409 IFS=: 41410 for p in $PATH; do 41411 if test -f "$p/$path" && test -x "$p/$path"; then 41412 new_path="$p/$path" 41413 break 41414 fi 41415 done 41416 IFS="$IFS_save" 41417 else 41418 # This is an absolute path, we can use it without further modifications. 41419 new_path="$path" 41420 fi 41421 41422 if test "x$new_path" = x; then 41423 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41424 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41425 has_space=`$ECHO "$complete" | $GREP " "` 41426 if test "x$has_space" != x; then 41427 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41428 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41429 fi 41430 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41431 fi 41432 fi 41433 41434 # Now join together the path and the arguments once again 41435 if test "x$arguments" != xEOL; then 41436 new_complete="$new_path ${arguments% *}" 41437 else 41438 new_complete="$new_path" 41439 fi 41440 41441 if test "x$complete" != "x$new_complete"; then 41442 NM="$new_complete" 41443 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 41444 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 41445 fi 41446 fi 41447 41448 41449 41450 # Publish this variable in the help. 41451 41452 41453 if [ -z "${GNM+x}" ]; then 41454 # The variable is not set by user, try to locate tool using the code snippet 41455 for ac_prog in gnm 41456 do 41457 # Extract the first word of "$ac_prog", so it can be a program name with args. 41458 set dummy $ac_prog; ac_word=$2 41459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41460 $as_echo_n "checking for $ac_word... " >&6; } 41461 if ${ac_cv_path_GNM+:} false; then : 41462 $as_echo_n "(cached) " >&6 41463 else 41464 case $GNM in 41465 [\\/]* | ?:[\\/]*) 41466 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41467 ;; 41468 *) 41469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41470 for as_dir in $PATH 41471 do 41472 IFS=$as_save_IFS 41473 test -z "$as_dir" && as_dir=. 41474 for ac_exec_ext in '' $ac_executable_extensions; do 41475 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41476 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41477 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41478 break 2 41479 fi 41480 done 41481 done 41482 IFS=$as_save_IFS 41483 41484 ;; 41485 esac 41486 fi 41487 GNM=$ac_cv_path_GNM 41488 if test -n "$GNM"; then 41489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41490 $as_echo "$GNM" >&6; } 41491 else 41492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41493 $as_echo "no" >&6; } 41494 fi 41495 41496 41497 test -n "$GNM" && break 41498 done 41499 41500 else 41501 # The variable is set, but is it from the command line or the environment? 41502 41503 # Try to remove the string !GNM! from our list. 41504 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 41505 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41506 # If it failed, the variable was not from the command line. Ignore it, 41507 # but warn the user (except for BASH, which is always set by the calling BASH). 41508 if test "xGNM" != xBASH; then 41509 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 41510 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 41511 fi 41512 # Try to locate tool using the code snippet 41513 for ac_prog in gnm 41514 do 41515 # Extract the first word of "$ac_prog", so it can be a program name with args. 41516 set dummy $ac_prog; ac_word=$2 41517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41518 $as_echo_n "checking for $ac_word... " >&6; } 41519 if ${ac_cv_path_GNM+:} false; then : 41520 $as_echo_n "(cached) " >&6 41521 else 41522 case $GNM in 41523 [\\/]* | ?:[\\/]*) 41524 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41525 ;; 41526 *) 41527 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41528 for as_dir in $PATH 41529 do 41530 IFS=$as_save_IFS 41531 test -z "$as_dir" && as_dir=. 41532 for ac_exec_ext in '' $ac_executable_extensions; do 41533 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41534 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41535 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41536 break 2 41537 fi 41538 done 41539 done 41540 IFS=$as_save_IFS 41541 41542 ;; 41543 esac 41544 fi 41545 GNM=$ac_cv_path_GNM 41546 if test -n "$GNM"; then 41547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41548 $as_echo "$GNM" >&6; } 41549 else 41550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41551 $as_echo "no" >&6; } 41552 fi 41553 41554 41555 test -n "$GNM" && break 41556 done 41557 41558 else 41559 # If it succeeded, then it was overridden by the user. We will use it 41560 # for the tool. 41561 41562 # First remove it from the list of overridden variables, so we can test 41563 # for unknown variables in the end. 41564 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41565 41566 # Check if we try to supply an empty value 41567 if test "x$GNM" = x; then 41568 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 41569 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 41570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 41571 $as_echo_n "checking for GNM... " >&6; } 41572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41573 $as_echo "disabled" >&6; } 41574 else 41575 # Check if the provided tool contains a complete path. 41576 tool_specified="$GNM" 41577 tool_basename="${tool_specified##*/}" 41578 if test "x$tool_basename" = "x$tool_specified"; then 41579 # A command without a complete path is provided, search $PATH. 41580 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 41581 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 41582 # Extract the first word of "$tool_basename", so it can be a program name with args. 41583 set dummy $tool_basename; ac_word=$2 41584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41585 $as_echo_n "checking for $ac_word... " >&6; } 41586 if ${ac_cv_path_GNM+:} false; then : 41587 $as_echo_n "(cached) " >&6 41588 else 41589 case $GNM in 41590 [\\/]* | ?:[\\/]*) 41591 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41592 ;; 41593 *) 41594 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41595 for as_dir in $PATH 41596 do 41597 IFS=$as_save_IFS 41598 test -z "$as_dir" && as_dir=. 41599 for ac_exec_ext in '' $ac_executable_extensions; do 41600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41601 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41603 break 2 41604 fi 41605 done 41606 done 41607 IFS=$as_save_IFS 41608 41609 ;; 41610 esac 41611 fi 41612 GNM=$ac_cv_path_GNM 41613 if test -n "$GNM"; then 41614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41615 $as_echo "$GNM" >&6; } 41616 else 41617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41618 $as_echo "no" >&6; } 41619 fi 41620 41621 41622 if test "x$GNM" = x; then 41623 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41624 fi 41625 else 41626 # Otherwise we believe it is a complete path. Use it as it is. 41627 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 41628 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 41629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 41630 $as_echo_n "checking for GNM... " >&6; } 41631 if test ! -x "$tool_specified"; then 41632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41633 $as_echo "not found" >&6; } 41634 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 41635 fi 41636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41637 $as_echo "$tool_specified" >&6; } 41638 fi 41639 fi 41640 fi 41641 41642 fi 41643 41644 41645 41646 # Only process if variable expands to non-empty 41647 41648 if test "x$GNM" != x; then 41649 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41650 41651 # First separate the path from the arguments. This will split at the first 41652 # space. 41653 complete="$GNM" 41654 path="${complete%% *}" 41655 tmp="$complete EOL" 41656 arguments="${tmp#* }" 41657 41658 # Input might be given as Windows format, start by converting to 41659 # unix format. 41660 new_path=`$CYGPATH -u "$path"` 41661 41662 # Now try to locate executable using which 41663 new_path=`$WHICH "$new_path" 2> /dev/null` 41664 # bat and cmd files are not always considered executable in cygwin causing which 41665 # to not find them 41666 if test "x$new_path" = x \ 41667 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41668 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41669 new_path=`$CYGPATH -u "$path"` 41670 fi 41671 if test "x$new_path" = x; then 41672 # Oops. Which didn't find the executable. 41673 # The splitting of arguments from the executable at a space might have been incorrect, 41674 # since paths with space are more likely in Windows. Give it another try with the whole 41675 # argument. 41676 path="$complete" 41677 arguments="EOL" 41678 new_path=`$CYGPATH -u "$path"` 41679 new_path=`$WHICH "$new_path" 2> /dev/null` 41680 # bat and cmd files are not always considered executable in cygwin causing which 41681 # to not find them 41682 if test "x$new_path" = x \ 41683 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41684 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41685 new_path=`$CYGPATH -u "$path"` 41686 fi 41687 if test "x$new_path" = x; then 41688 # It's still not found. Now this is an unrecoverable error. 41689 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41690 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41691 has_space=`$ECHO "$complete" | $GREP " "` 41692 if test "x$has_space" != x; then 41693 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41694 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41695 fi 41696 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41697 fi 41698 fi 41699 41700 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41701 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41702 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41703 # "foo.exe" is OK but "foo" is an error. 41704 # 41705 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41706 # It is also a way to make sure we got the proper file name for the real test later on. 41707 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41708 if test "x$test_shortpath" = x; then 41709 # Short path failed, file does not exist as specified. 41710 # Try adding .exe or .cmd 41711 if test -f "${new_path}.exe"; then 41712 input_to_shortpath="${new_path}.exe" 41713 elif test -f "${new_path}.cmd"; then 41714 input_to_shortpath="${new_path}.cmd" 41715 else 41716 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 41717 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 41718 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41719 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41720 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41721 fi 41722 else 41723 input_to_shortpath="$new_path" 41724 fi 41725 41726 # Call helper function which possibly converts this using DOS-style short mode. 41727 # If so, the updated path is stored in $new_path. 41728 new_path="$input_to_shortpath" 41729 41730 input_path="$input_to_shortpath" 41731 # Check if we need to convert this using DOS-style short mode. If the path 41732 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41733 # take no chances and rewrite it. 41734 # Note: m4 eats our [], so we need to use [ and ] instead. 41735 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41736 if test "x$has_forbidden_chars" != x; then 41737 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41738 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41739 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41740 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41741 # Going to short mode and back again did indeed matter. Since short mode is 41742 # case insensitive, let's make it lowercase to improve readability. 41743 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41744 # Now convert it back to Unix-style (cygpath) 41745 input_path=`$CYGPATH -u "$shortmode_path"` 41746 new_path="$input_path" 41747 fi 41748 fi 41749 41750 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41751 if test "x$test_cygdrive_prefix" = x; then 41752 # As a simple fix, exclude /usr/bin since it's not a real path. 41753 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41754 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41755 # a path prefixed by /cygdrive for fixpath to work. 41756 new_path="$CYGWIN_ROOT_PATH$input_path" 41757 fi 41758 fi 41759 41760 # remove trailing .exe if any 41761 new_path="${new_path/%.exe/}" 41762 41763 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41764 41765 # First separate the path from the arguments. This will split at the first 41766 # space. 41767 complete="$GNM" 41768 path="${complete%% *}" 41769 tmp="$complete EOL" 41770 arguments="${tmp#* }" 41771 41772 # Input might be given as Windows format, start by converting to 41773 # unix format. 41774 new_path="$path" 41775 41776 windows_path="$new_path" 41777 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41778 unix_path=`$CYGPATH -u "$windows_path"` 41779 new_path="$unix_path" 41780 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41781 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41782 new_path="$unix_path" 41783 fi 41784 41785 41786 # Now try to locate executable using which 41787 new_path=`$WHICH "$new_path" 2> /dev/null` 41788 41789 if test "x$new_path" = x; then 41790 # Oops. Which didn't find the executable. 41791 # The splitting of arguments from the executable at a space might have been incorrect, 41792 # since paths with space are more likely in Windows. Give it another try with the whole 41793 # argument. 41794 path="$complete" 41795 arguments="EOL" 41796 new_path="$path" 41797 41798 windows_path="$new_path" 41799 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41800 unix_path=`$CYGPATH -u "$windows_path"` 41801 new_path="$unix_path" 41802 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41803 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41804 new_path="$unix_path" 41805 fi 41806 41807 41808 new_path=`$WHICH "$new_path" 2> /dev/null` 41809 # bat and cmd files are not always considered executable in MSYS causing which 41810 # to not find them 41811 if test "x$new_path" = x \ 41812 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41813 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41814 new_path="$path" 41815 41816 windows_path="$new_path" 41817 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41818 unix_path=`$CYGPATH -u "$windows_path"` 41819 new_path="$unix_path" 41820 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41821 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41822 new_path="$unix_path" 41823 fi 41824 41825 fi 41826 41827 if test "x$new_path" = x; then 41828 # It's still not found. Now this is an unrecoverable error. 41829 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41830 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41831 has_space=`$ECHO "$complete" | $GREP " "` 41832 if test "x$has_space" != x; then 41833 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41834 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41835 fi 41836 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41837 fi 41838 fi 41839 41840 # Now new_path has a complete unix path to the binary 41841 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41842 # Keep paths in /bin as-is, but remove trailing .exe if any 41843 new_path="${new_path/%.exe/}" 41844 # Do not save /bin paths to all_fixpath_prefixes! 41845 else 41846 # Not in mixed or Windows style, start by that. 41847 new_path=`cmd //c echo $new_path` 41848 41849 input_path="$new_path" 41850 # Check if we need to convert this using DOS-style short mode. If the path 41851 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41852 # take no chances and rewrite it. 41853 # Note: m4 eats our [], so we need to use [ and ] instead. 41854 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41855 if test "x$has_forbidden_chars" != x; then 41856 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41857 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41858 fi 41859 41860 # Output is in $new_path 41861 41862 windows_path="$new_path" 41863 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41864 unix_path=`$CYGPATH -u "$windows_path"` 41865 new_path="$unix_path" 41866 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41867 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41868 new_path="$unix_path" 41869 fi 41870 41871 # remove trailing .exe if any 41872 new_path="${new_path/%.exe/}" 41873 41874 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41875 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41876 fi 41877 41878 else 41879 # We're on a unix platform. Hooray! :) 41880 # First separate the path from the arguments. This will split at the first 41881 # space. 41882 complete="$GNM" 41883 path="${complete%% *}" 41884 tmp="$complete EOL" 41885 arguments="${tmp#* }" 41886 41887 # Cannot rely on the command "which" here since it doesn't always work. 41888 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41889 if test -z "$is_absolute_path"; then 41890 # Path to executable is not absolute. Find it. 41891 IFS_save="$IFS" 41892 IFS=: 41893 for p in $PATH; do 41894 if test -f "$p/$path" && test -x "$p/$path"; then 41895 new_path="$p/$path" 41896 break 41897 fi 41898 done 41899 IFS="$IFS_save" 41900 else 41901 # This is an absolute path, we can use it without further modifications. 41902 new_path="$path" 41903 fi 41904 41905 if test "x$new_path" = x; then 41906 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41907 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41908 has_space=`$ECHO "$complete" | $GREP " "` 41909 if test "x$has_space" != x; then 41910 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41911 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41912 fi 41913 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41914 fi 41915 fi 41916 41917 # Now join together the path and the arguments once again 41918 if test "x$arguments" != xEOL; then 41919 new_complete="$new_path ${arguments% *}" 41920 else 41921 new_complete="$new_path" 41922 fi 41923 41924 if test "x$complete" != "x$new_complete"; then 41925 GNM="$new_complete" 41926 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 41927 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 41928 fi 41929 fi 41930 41931 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 41932 # FIXME: we should unify this with the solaris case above. 41933 41934 41935 # Publish this variable in the help. 41936 41937 41938 if [ -z "${STRIP+x}" ]; then 41939 # The variable is not set by user, try to locate tool using the code snippet 41940 if test -n "$ac_tool_prefix"; then 41941 for ac_prog in strip 41942 do 41943 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41944 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41946 $as_echo_n "checking for $ac_word... " >&6; } 41947 if ${ac_cv_prog_STRIP+:} false; then : 41948 $as_echo_n "(cached) " >&6 41949 else 41950 if test -n "$STRIP"; then 41951 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41952 else 41953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41954 for as_dir in $PATH 41955 do 41956 IFS=$as_save_IFS 41957 test -z "$as_dir" && as_dir=. 41958 for ac_exec_ext in '' $ac_executable_extensions; do 41959 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41960 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41961 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41962 break 2 41963 fi 41964 done 41965 done 41966 IFS=$as_save_IFS 41967 41968 fi 41969 fi 41970 STRIP=$ac_cv_prog_STRIP 41971 if test -n "$STRIP"; then 41972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41973 $as_echo "$STRIP" >&6; } 41974 else 41975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41976 $as_echo "no" >&6; } 41977 fi 41978 41979 41980 test -n "$STRIP" && break 41981 done 41982 fi 41983 if test -z "$STRIP"; then 41984 ac_ct_STRIP=$STRIP 41985 for ac_prog in strip 41986 do 41987 # Extract the first word of "$ac_prog", so it can be a program name with args. 41988 set dummy $ac_prog; ac_word=$2 41989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41990 $as_echo_n "checking for $ac_word... " >&6; } 41991 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41992 $as_echo_n "(cached) " >&6 41993 else 41994 if test -n "$ac_ct_STRIP"; then 41995 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41996 else 41997 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41998 for as_dir in $PATH 41999 do 42000 IFS=$as_save_IFS 42001 test -z "$as_dir" && as_dir=. 42002 for ac_exec_ext in '' $ac_executable_extensions; do 42003 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42004 ac_cv_prog_ac_ct_STRIP="$ac_prog" 42005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42006 break 2 42007 fi 42008 done 42009 done 42010 IFS=$as_save_IFS 42011 42012 fi 42013 fi 42014 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 42015 if test -n "$ac_ct_STRIP"; then 42016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 42017 $as_echo "$ac_ct_STRIP" >&6; } 42018 else 42019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42020 $as_echo "no" >&6; } 42021 fi 42022 42023 42024 test -n "$ac_ct_STRIP" && break 42025 done 42026 42027 if test "x$ac_ct_STRIP" = x; then 42028 STRIP="" 42029 else 42030 case $cross_compiling:$ac_tool_warned in 42031 yes:) 42032 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42033 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42034 ac_tool_warned=yes ;; 42035 esac 42036 STRIP=$ac_ct_STRIP 42037 fi 42038 fi 42039 42040 else 42041 # The variable is set, but is it from the command line or the environment? 42042 42043 # Try to remove the string !STRIP! from our list. 42044 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 42045 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42046 # If it failed, the variable was not from the command line. Ignore it, 42047 # but warn the user (except for BASH, which is always set by the calling BASH). 42048 if test "xSTRIP" != xBASH; then 42049 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 42050 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 42051 fi 42052 # Try to locate tool using the code snippet 42053 if test -n "$ac_tool_prefix"; then 42054 for ac_prog in strip 42055 do 42056 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42057 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42059 $as_echo_n "checking for $ac_word... " >&6; } 42060 if ${ac_cv_prog_STRIP+:} false; then : 42061 $as_echo_n "(cached) " >&6 42062 else 42063 if test -n "$STRIP"; then 42064 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 42065 else 42066 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42067 for as_dir in $PATH 42068 do 42069 IFS=$as_save_IFS 42070 test -z "$as_dir" && as_dir=. 42071 for ac_exec_ext in '' $ac_executable_extensions; do 42072 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42073 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 42074 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42075 break 2 42076 fi 42077 done 42078 done 42079 IFS=$as_save_IFS 42080 42081 fi 42082 fi 42083 STRIP=$ac_cv_prog_STRIP 42084 if test -n "$STRIP"; then 42085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 42086 $as_echo "$STRIP" >&6; } 42087 else 42088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42089 $as_echo "no" >&6; } 42090 fi 42091 42092 42093 test -n "$STRIP" && break 42094 done 42095 fi 42096 if test -z "$STRIP"; then 42097 ac_ct_STRIP=$STRIP 42098 for ac_prog in strip 42099 do 42100 # Extract the first word of "$ac_prog", so it can be a program name with args. 42101 set dummy $ac_prog; ac_word=$2 42102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42103 $as_echo_n "checking for $ac_word... " >&6; } 42104 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 42105 $as_echo_n "(cached) " >&6 42106 else 42107 if test -n "$ac_ct_STRIP"; then 42108 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 42109 else 42110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42111 for as_dir in $PATH 42112 do 42113 IFS=$as_save_IFS 42114 test -z "$as_dir" && as_dir=. 42115 for ac_exec_ext in '' $ac_executable_extensions; do 42116 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42117 ac_cv_prog_ac_ct_STRIP="$ac_prog" 42118 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42119 break 2 42120 fi 42121 done 42122 done 42123 IFS=$as_save_IFS 42124 42125 fi 42126 fi 42127 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 42128 if test -n "$ac_ct_STRIP"; then 42129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 42130 $as_echo "$ac_ct_STRIP" >&6; } 42131 else 42132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42133 $as_echo "no" >&6; } 42134 fi 42135 42136 42137 test -n "$ac_ct_STRIP" && break 42138 done 42139 42140 if test "x$ac_ct_STRIP" = x; then 42141 STRIP="" 42142 else 42143 case $cross_compiling:$ac_tool_warned in 42144 yes:) 42145 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42146 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42147 ac_tool_warned=yes ;; 42148 esac 42149 STRIP=$ac_ct_STRIP 42150 fi 42151 fi 42152 42153 else 42154 # If it succeeded, then it was overridden by the user. We will use it 42155 # for the tool. 42156 42157 # First remove it from the list of overridden variables, so we can test 42158 # for unknown variables in the end. 42159 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42160 42161 # Check if we try to supply an empty value 42162 if test "x$STRIP" = x; then 42163 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 42164 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 42165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 42166 $as_echo_n "checking for STRIP... " >&6; } 42167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42168 $as_echo "disabled" >&6; } 42169 else 42170 # Check if the provided tool contains a complete path. 42171 tool_specified="$STRIP" 42172 tool_basename="${tool_specified##*/}" 42173 if test "x$tool_basename" = "x$tool_specified"; then 42174 # A command without a complete path is provided, search $PATH. 42175 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 42176 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 42177 # Extract the first word of "$tool_basename", so it can be a program name with args. 42178 set dummy $tool_basename; ac_word=$2 42179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42180 $as_echo_n "checking for $ac_word... " >&6; } 42181 if ${ac_cv_path_STRIP+:} false; then : 42182 $as_echo_n "(cached) " >&6 42183 else 42184 case $STRIP in 42185 [\\/]* | ?:[\\/]*) 42186 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 42187 ;; 42188 *) 42189 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42190 for as_dir in $PATH 42191 do 42192 IFS=$as_save_IFS 42193 test -z "$as_dir" && as_dir=. 42194 for ac_exec_ext in '' $ac_executable_extensions; do 42195 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42196 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 42197 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42198 break 2 42199 fi 42200 done 42201 done 42202 IFS=$as_save_IFS 42203 42204 ;; 42205 esac 42206 fi 42207 STRIP=$ac_cv_path_STRIP 42208 if test -n "$STRIP"; then 42209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 42210 $as_echo "$STRIP" >&6; } 42211 else 42212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42213 $as_echo "no" >&6; } 42214 fi 42215 42216 42217 if test "x$STRIP" = x; then 42218 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42219 fi 42220 else 42221 # Otherwise we believe it is a complete path. Use it as it is. 42222 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 42223 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 42224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 42225 $as_echo_n "checking for STRIP... " >&6; } 42226 if test ! -x "$tool_specified"; then 42227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42228 $as_echo "not found" >&6; } 42229 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 42230 fi 42231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42232 $as_echo "$tool_specified" >&6; } 42233 fi 42234 fi 42235 fi 42236 42237 fi 42238 42239 42240 42241 # Only process if variable expands to non-empty 42242 42243 if test "x$STRIP" != x; then 42244 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42245 42246 # First separate the path from the arguments. This will split at the first 42247 # space. 42248 complete="$STRIP" 42249 path="${complete%% *}" 42250 tmp="$complete EOL" 42251 arguments="${tmp#* }" 42252 42253 # Input might be given as Windows format, start by converting to 42254 # unix format. 42255 new_path=`$CYGPATH -u "$path"` 42256 42257 # Now try to locate executable using which 42258 new_path=`$WHICH "$new_path" 2> /dev/null` 42259 # bat and cmd files are not always considered executable in cygwin causing which 42260 # to not find them 42261 if test "x$new_path" = x \ 42262 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42263 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42264 new_path=`$CYGPATH -u "$path"` 42265 fi 42266 if test "x$new_path" = x; then 42267 # Oops. Which didn't find the executable. 42268 # The splitting of arguments from the executable at a space might have been incorrect, 42269 # since paths with space are more likely in Windows. Give it another try with the whole 42270 # argument. 42271 path="$complete" 42272 arguments="EOL" 42273 new_path=`$CYGPATH -u "$path"` 42274 new_path=`$WHICH "$new_path" 2> /dev/null` 42275 # bat and cmd files are not always considered executable in cygwin causing which 42276 # to not find them 42277 if test "x$new_path" = x \ 42278 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42279 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42280 new_path=`$CYGPATH -u "$path"` 42281 fi 42282 if test "x$new_path" = x; then 42283 # It's still not found. Now this is an unrecoverable error. 42284 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42285 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42286 has_space=`$ECHO "$complete" | $GREP " "` 42287 if test "x$has_space" != x; then 42288 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42289 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42290 fi 42291 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42292 fi 42293 fi 42294 42295 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42296 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42297 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42298 # "foo.exe" is OK but "foo" is an error. 42299 # 42300 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42301 # It is also a way to make sure we got the proper file name for the real test later on. 42302 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42303 if test "x$test_shortpath" = x; then 42304 # Short path failed, file does not exist as specified. 42305 # Try adding .exe or .cmd 42306 if test -f "${new_path}.exe"; then 42307 input_to_shortpath="${new_path}.exe" 42308 elif test -f "${new_path}.cmd"; then 42309 input_to_shortpath="${new_path}.cmd" 42310 else 42311 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 42312 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 42313 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42314 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42315 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42316 fi 42317 else 42318 input_to_shortpath="$new_path" 42319 fi 42320 42321 # Call helper function which possibly converts this using DOS-style short mode. 42322 # If so, the updated path is stored in $new_path. 42323 new_path="$input_to_shortpath" 42324 42325 input_path="$input_to_shortpath" 42326 # Check if we need to convert this using DOS-style short mode. If the path 42327 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42328 # take no chances and rewrite it. 42329 # Note: m4 eats our [], so we need to use [ and ] instead. 42330 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42331 if test "x$has_forbidden_chars" != x; then 42332 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42333 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42334 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42335 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42336 # Going to short mode and back again did indeed matter. Since short mode is 42337 # case insensitive, let's make it lowercase to improve readability. 42338 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42339 # Now convert it back to Unix-style (cygpath) 42340 input_path=`$CYGPATH -u "$shortmode_path"` 42341 new_path="$input_path" 42342 fi 42343 fi 42344 42345 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42346 if test "x$test_cygdrive_prefix" = x; then 42347 # As a simple fix, exclude /usr/bin since it's not a real path. 42348 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42349 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42350 # a path prefixed by /cygdrive for fixpath to work. 42351 new_path="$CYGWIN_ROOT_PATH$input_path" 42352 fi 42353 fi 42354 42355 # remove trailing .exe if any 42356 new_path="${new_path/%.exe/}" 42357 42358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42359 42360 # First separate the path from the arguments. This will split at the first 42361 # space. 42362 complete="$STRIP" 42363 path="${complete%% *}" 42364 tmp="$complete EOL" 42365 arguments="${tmp#* }" 42366 42367 # Input might be given as Windows format, start by converting to 42368 # unix format. 42369 new_path="$path" 42370 42371 windows_path="$new_path" 42372 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42373 unix_path=`$CYGPATH -u "$windows_path"` 42374 new_path="$unix_path" 42375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42376 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42377 new_path="$unix_path" 42378 fi 42379 42380 42381 # Now try to locate executable using which 42382 new_path=`$WHICH "$new_path" 2> /dev/null` 42383 42384 if test "x$new_path" = x; then 42385 # Oops. Which didn't find the executable. 42386 # The splitting of arguments from the executable at a space might have been incorrect, 42387 # since paths with space are more likely in Windows. Give it another try with the whole 42388 # argument. 42389 path="$complete" 42390 arguments="EOL" 42391 new_path="$path" 42392 42393 windows_path="$new_path" 42394 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42395 unix_path=`$CYGPATH -u "$windows_path"` 42396 new_path="$unix_path" 42397 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42398 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42399 new_path="$unix_path" 42400 fi 42401 42402 42403 new_path=`$WHICH "$new_path" 2> /dev/null` 42404 # bat and cmd files are not always considered executable in MSYS causing which 42405 # to not find them 42406 if test "x$new_path" = x \ 42407 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42408 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42409 new_path="$path" 42410 42411 windows_path="$new_path" 42412 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42413 unix_path=`$CYGPATH -u "$windows_path"` 42414 new_path="$unix_path" 42415 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42416 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42417 new_path="$unix_path" 42418 fi 42419 42420 fi 42421 42422 if test "x$new_path" = x; then 42423 # It's still not found. Now this is an unrecoverable error. 42424 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42425 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42426 has_space=`$ECHO "$complete" | $GREP " "` 42427 if test "x$has_space" != x; then 42428 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42429 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42430 fi 42431 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42432 fi 42433 fi 42434 42435 # Now new_path has a complete unix path to the binary 42436 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42437 # Keep paths in /bin as-is, but remove trailing .exe if any 42438 new_path="${new_path/%.exe/}" 42439 # Do not save /bin paths to all_fixpath_prefixes! 42440 else 42441 # Not in mixed or Windows style, start by that. 42442 new_path=`cmd //c echo $new_path` 42443 42444 input_path="$new_path" 42445 # Check if we need to convert this using DOS-style short mode. If the path 42446 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42447 # take no chances and rewrite it. 42448 # Note: m4 eats our [], so we need to use [ and ] instead. 42449 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42450 if test "x$has_forbidden_chars" != x; then 42451 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42452 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42453 fi 42454 42455 # Output is in $new_path 42456 42457 windows_path="$new_path" 42458 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42459 unix_path=`$CYGPATH -u "$windows_path"` 42460 new_path="$unix_path" 42461 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42462 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42463 new_path="$unix_path" 42464 fi 42465 42466 # remove trailing .exe if any 42467 new_path="${new_path/%.exe/}" 42468 42469 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42470 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42471 fi 42472 42473 else 42474 # We're on a unix platform. Hooray! :) 42475 # First separate the path from the arguments. This will split at the first 42476 # space. 42477 complete="$STRIP" 42478 path="${complete%% *}" 42479 tmp="$complete EOL" 42480 arguments="${tmp#* }" 42481 42482 # Cannot rely on the command "which" here since it doesn't always work. 42483 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42484 if test -z "$is_absolute_path"; then 42485 # Path to executable is not absolute. Find it. 42486 IFS_save="$IFS" 42487 IFS=: 42488 for p in $PATH; do 42489 if test -f "$p/$path" && test -x "$p/$path"; then 42490 new_path="$p/$path" 42491 break 42492 fi 42493 done 42494 IFS="$IFS_save" 42495 else 42496 # This is an absolute path, we can use it without further modifications. 42497 new_path="$path" 42498 fi 42499 42500 if test "x$new_path" = x; then 42501 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42502 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42503 has_space=`$ECHO "$complete" | $GREP " "` 42504 if test "x$has_space" != x; then 42505 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42506 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42507 fi 42508 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42509 fi 42510 fi 42511 42512 # Now join together the path and the arguments once again 42513 if test "x$arguments" != xEOL; then 42514 new_complete="$new_path ${arguments% *}" 42515 else 42516 new_complete="$new_path" 42517 fi 42518 42519 if test "x$complete" != "x$new_complete"; then 42520 STRIP="$new_complete" 42521 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 42522 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 42523 fi 42524 fi 42525 42526 if test "x$TOOLCHAIN_TYPE" = xgcc; then 42527 42528 42529 # Publish this variable in the help. 42530 42531 42532 if [ -z "${NM+x}" ]; then 42533 # The variable is not set by user, try to locate tool using the code snippet 42534 if test -n "$ac_tool_prefix"; then 42535 for ac_prog in nm gcc-nm 42536 do 42537 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42538 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42540 $as_echo_n "checking for $ac_word... " >&6; } 42541 if ${ac_cv_prog_NM+:} false; then : 42542 $as_echo_n "(cached) " >&6 42543 else 42544 if test -n "$NM"; then 42545 ac_cv_prog_NM="$NM" # Let the user override the test. 42546 else 42547 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42548 for as_dir in $PATH 42549 do 42550 IFS=$as_save_IFS 42551 test -z "$as_dir" && as_dir=. 42552 for ac_exec_ext in '' $ac_executable_extensions; do 42553 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42554 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42555 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42556 break 2 42557 fi 42558 done 42559 done 42560 IFS=$as_save_IFS 42561 42562 fi 42563 fi 42564 NM=$ac_cv_prog_NM 42565 if test -n "$NM"; then 42566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42567 $as_echo "$NM" >&6; } 42568 else 42569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42570 $as_echo "no" >&6; } 42571 fi 42572 42573 42574 test -n "$NM" && break 42575 done 42576 fi 42577 if test -z "$NM"; then 42578 ac_ct_NM=$NM 42579 for ac_prog in nm gcc-nm 42580 do 42581 # Extract the first word of "$ac_prog", so it can be a program name with args. 42582 set dummy $ac_prog; ac_word=$2 42583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42584 $as_echo_n "checking for $ac_word... " >&6; } 42585 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42586 $as_echo_n "(cached) " >&6 42587 else 42588 if test -n "$ac_ct_NM"; then 42589 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42590 else 42591 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42592 for as_dir in $PATH 42593 do 42594 IFS=$as_save_IFS 42595 test -z "$as_dir" && as_dir=. 42596 for ac_exec_ext in '' $ac_executable_extensions; do 42597 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42598 ac_cv_prog_ac_ct_NM="$ac_prog" 42599 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42600 break 2 42601 fi 42602 done 42603 done 42604 IFS=$as_save_IFS 42605 42606 fi 42607 fi 42608 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42609 if test -n "$ac_ct_NM"; then 42610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42611 $as_echo "$ac_ct_NM" >&6; } 42612 else 42613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42614 $as_echo "no" >&6; } 42615 fi 42616 42617 42618 test -n "$ac_ct_NM" && break 42619 done 42620 42621 if test "x$ac_ct_NM" = x; then 42622 NM="" 42623 else 42624 case $cross_compiling:$ac_tool_warned in 42625 yes:) 42626 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42627 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42628 ac_tool_warned=yes ;; 42629 esac 42630 NM=$ac_ct_NM 42631 fi 42632 fi 42633 42634 else 42635 # The variable is set, but is it from the command line or the environment? 42636 42637 # Try to remove the string !NM! from our list. 42638 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42639 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42640 # If it failed, the variable was not from the command line. Ignore it, 42641 # but warn the user (except for BASH, which is always set by the calling BASH). 42642 if test "xNM" != xBASH; then 42643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42644 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42645 fi 42646 # Try to locate tool using the code snippet 42647 if test -n "$ac_tool_prefix"; then 42648 for ac_prog in nm gcc-nm 42649 do 42650 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42651 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42653 $as_echo_n "checking for $ac_word... " >&6; } 42654 if ${ac_cv_prog_NM+:} false; then : 42655 $as_echo_n "(cached) " >&6 42656 else 42657 if test -n "$NM"; then 42658 ac_cv_prog_NM="$NM" # Let the user override the test. 42659 else 42660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42661 for as_dir in $PATH 42662 do 42663 IFS=$as_save_IFS 42664 test -z "$as_dir" && as_dir=. 42665 for ac_exec_ext in '' $ac_executable_extensions; do 42666 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42667 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42668 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42669 break 2 42670 fi 42671 done 42672 done 42673 IFS=$as_save_IFS 42674 42675 fi 42676 fi 42677 NM=$ac_cv_prog_NM 42678 if test -n "$NM"; then 42679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42680 $as_echo "$NM" >&6; } 42681 else 42682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42683 $as_echo "no" >&6; } 42684 fi 42685 42686 42687 test -n "$NM" && break 42688 done 42689 fi 42690 if test -z "$NM"; then 42691 ac_ct_NM=$NM 42692 for ac_prog in nm gcc-nm 42693 do 42694 # Extract the first word of "$ac_prog", so it can be a program name with args. 42695 set dummy $ac_prog; ac_word=$2 42696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42697 $as_echo_n "checking for $ac_word... " >&6; } 42698 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42699 $as_echo_n "(cached) " >&6 42700 else 42701 if test -n "$ac_ct_NM"; then 42702 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42703 else 42704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42705 for as_dir in $PATH 42706 do 42707 IFS=$as_save_IFS 42708 test -z "$as_dir" && as_dir=. 42709 for ac_exec_ext in '' $ac_executable_extensions; do 42710 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42711 ac_cv_prog_ac_ct_NM="$ac_prog" 42712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42713 break 2 42714 fi 42715 done 42716 done 42717 IFS=$as_save_IFS 42718 42719 fi 42720 fi 42721 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42722 if test -n "$ac_ct_NM"; then 42723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42724 $as_echo "$ac_ct_NM" >&6; } 42725 else 42726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42727 $as_echo "no" >&6; } 42728 fi 42729 42730 42731 test -n "$ac_ct_NM" && break 42732 done 42733 42734 if test "x$ac_ct_NM" = x; then 42735 NM="" 42736 else 42737 case $cross_compiling:$ac_tool_warned in 42738 yes:) 42739 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42740 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42741 ac_tool_warned=yes ;; 42742 esac 42743 NM=$ac_ct_NM 42744 fi 42745 fi 42746 42747 else 42748 # If it succeeded, then it was overridden by the user. We will use it 42749 # for the tool. 42750 42751 # First remove it from the list of overridden variables, so we can test 42752 # for unknown variables in the end. 42753 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42754 42755 # Check if we try to supply an empty value 42756 if test "x$NM" = x; then 42757 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42758 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42760 $as_echo_n "checking for NM... " >&6; } 42761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42762 $as_echo "disabled" >&6; } 42763 else 42764 # Check if the provided tool contains a complete path. 42765 tool_specified="$NM" 42766 tool_basename="${tool_specified##*/}" 42767 if test "x$tool_basename" = "x$tool_specified"; then 42768 # A command without a complete path is provided, search $PATH. 42769 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42770 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42771 # Extract the first word of "$tool_basename", so it can be a program name with args. 42772 set dummy $tool_basename; ac_word=$2 42773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42774 $as_echo_n "checking for $ac_word... " >&6; } 42775 if ${ac_cv_path_NM+:} false; then : 42776 $as_echo_n "(cached) " >&6 42777 else 42778 case $NM in 42779 [\\/]* | ?:[\\/]*) 42780 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42781 ;; 42782 *) 42783 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42784 for as_dir in $PATH 42785 do 42786 IFS=$as_save_IFS 42787 test -z "$as_dir" && as_dir=. 42788 for ac_exec_ext in '' $ac_executable_extensions; do 42789 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42790 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42791 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42792 break 2 42793 fi 42794 done 42795 done 42796 IFS=$as_save_IFS 42797 42798 ;; 42799 esac 42800 fi 42801 NM=$ac_cv_path_NM 42802 if test -n "$NM"; then 42803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42804 $as_echo "$NM" >&6; } 42805 else 42806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42807 $as_echo "no" >&6; } 42808 fi 42809 42810 42811 if test "x$NM" = x; then 42812 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42813 fi 42814 else 42815 # Otherwise we believe it is a complete path. Use it as it is. 42816 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42817 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42819 $as_echo_n "checking for NM... " >&6; } 42820 if test ! -x "$tool_specified"; then 42821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42822 $as_echo "not found" >&6; } 42823 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42824 fi 42825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42826 $as_echo "$tool_specified" >&6; } 42827 fi 42828 fi 42829 fi 42830 42831 fi 42832 42833 42834 else 42835 42836 42837 # Publish this variable in the help. 42838 42839 42840 if [ -z "${NM+x}" ]; then 42841 # The variable is not set by user, try to locate tool using the code snippet 42842 if test -n "$ac_tool_prefix"; then 42843 for ac_prog in nm 42844 do 42845 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42846 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42848 $as_echo_n "checking for $ac_word... " >&6; } 42849 if ${ac_cv_prog_NM+:} false; then : 42850 $as_echo_n "(cached) " >&6 42851 else 42852 if test -n "$NM"; then 42853 ac_cv_prog_NM="$NM" # Let the user override the test. 42854 else 42855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42856 for as_dir in $PATH 42857 do 42858 IFS=$as_save_IFS 42859 test -z "$as_dir" && as_dir=. 42860 for ac_exec_ext in '' $ac_executable_extensions; do 42861 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42862 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42863 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42864 break 2 42865 fi 42866 done 42867 done 42868 IFS=$as_save_IFS 42869 42870 fi 42871 fi 42872 NM=$ac_cv_prog_NM 42873 if test -n "$NM"; then 42874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42875 $as_echo "$NM" >&6; } 42876 else 42877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42878 $as_echo "no" >&6; } 42879 fi 42880 42881 42882 test -n "$NM" && break 42883 done 42884 fi 42885 if test -z "$NM"; then 42886 ac_ct_NM=$NM 42887 for ac_prog in nm 42888 do 42889 # Extract the first word of "$ac_prog", so it can be a program name with args. 42890 set dummy $ac_prog; ac_word=$2 42891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42892 $as_echo_n "checking for $ac_word... " >&6; } 42893 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42894 $as_echo_n "(cached) " >&6 42895 else 42896 if test -n "$ac_ct_NM"; then 42897 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42898 else 42899 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42900 for as_dir in $PATH 42901 do 42902 IFS=$as_save_IFS 42903 test -z "$as_dir" && as_dir=. 42904 for ac_exec_ext in '' $ac_executable_extensions; do 42905 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42906 ac_cv_prog_ac_ct_NM="$ac_prog" 42907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42908 break 2 42909 fi 42910 done 42911 done 42912 IFS=$as_save_IFS 42913 42914 fi 42915 fi 42916 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42917 if test -n "$ac_ct_NM"; then 42918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42919 $as_echo "$ac_ct_NM" >&6; } 42920 else 42921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42922 $as_echo "no" >&6; } 42923 fi 42924 42925 42926 test -n "$ac_ct_NM" && break 42927 done 42928 42929 if test "x$ac_ct_NM" = x; then 42930 NM="" 42931 else 42932 case $cross_compiling:$ac_tool_warned in 42933 yes:) 42934 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42935 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42936 ac_tool_warned=yes ;; 42937 esac 42938 NM=$ac_ct_NM 42939 fi 42940 fi 42941 42942 else 42943 # The variable is set, but is it from the command line or the environment? 42944 42945 # Try to remove the string !NM! from our list. 42946 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42947 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42948 # If it failed, the variable was not from the command line. Ignore it, 42949 # but warn the user (except for BASH, which is always set by the calling BASH). 42950 if test "xNM" != xBASH; then 42951 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42952 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42953 fi 42954 # Try to locate tool using the code snippet 42955 if test -n "$ac_tool_prefix"; then 42956 for ac_prog in nm 42957 do 42958 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42959 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42961 $as_echo_n "checking for $ac_word... " >&6; } 42962 if ${ac_cv_prog_NM+:} false; then : 42963 $as_echo_n "(cached) " >&6 42964 else 42965 if test -n "$NM"; then 42966 ac_cv_prog_NM="$NM" # Let the user override the test. 42967 else 42968 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42969 for as_dir in $PATH 42970 do 42971 IFS=$as_save_IFS 42972 test -z "$as_dir" && as_dir=. 42973 for ac_exec_ext in '' $ac_executable_extensions; do 42974 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42975 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42976 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42977 break 2 42978 fi 42979 done 42980 done 42981 IFS=$as_save_IFS 42982 42983 fi 42984 fi 42985 NM=$ac_cv_prog_NM 42986 if test -n "$NM"; then 42987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42988 $as_echo "$NM" >&6; } 42989 else 42990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42991 $as_echo "no" >&6; } 42992 fi 42993 42994 42995 test -n "$NM" && break 42996 done 42997 fi 42998 if test -z "$NM"; then 42999 ac_ct_NM=$NM 43000 for ac_prog in nm 43001 do 43002 # Extract the first word of "$ac_prog", so it can be a program name with args. 43003 set dummy $ac_prog; ac_word=$2 43004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43005 $as_echo_n "checking for $ac_word... " >&6; } 43006 if ${ac_cv_prog_ac_ct_NM+:} false; then : 43007 $as_echo_n "(cached) " >&6 43008 else 43009 if test -n "$ac_ct_NM"; then 43010 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 43011 else 43012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43013 for as_dir in $PATH 43014 do 43015 IFS=$as_save_IFS 43016 test -z "$as_dir" && as_dir=. 43017 for ac_exec_ext in '' $ac_executable_extensions; do 43018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43019 ac_cv_prog_ac_ct_NM="$ac_prog" 43020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43021 break 2 43022 fi 43023 done 43024 done 43025 IFS=$as_save_IFS 43026 43027 fi 43028 fi 43029 ac_ct_NM=$ac_cv_prog_ac_ct_NM 43030 if test -n "$ac_ct_NM"; then 43031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 43032 $as_echo "$ac_ct_NM" >&6; } 43033 else 43034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43035 $as_echo "no" >&6; } 43036 fi 43037 43038 43039 test -n "$ac_ct_NM" && break 43040 done 43041 43042 if test "x$ac_ct_NM" = x; then 43043 NM="" 43044 else 43045 case $cross_compiling:$ac_tool_warned in 43046 yes:) 43047 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43048 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43049 ac_tool_warned=yes ;; 43050 esac 43051 NM=$ac_ct_NM 43052 fi 43053 fi 43054 43055 else 43056 # If it succeeded, then it was overridden by the user. We will use it 43057 # for the tool. 43058 43059 # First remove it from the list of overridden variables, so we can test 43060 # for unknown variables in the end. 43061 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43062 43063 # Check if we try to supply an empty value 43064 if test "x$NM" = x; then 43065 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 43066 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 43067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 43068 $as_echo_n "checking for NM... " >&6; } 43069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43070 $as_echo "disabled" >&6; } 43071 else 43072 # Check if the provided tool contains a complete path. 43073 tool_specified="$NM" 43074 tool_basename="${tool_specified##*/}" 43075 if test "x$tool_basename" = "x$tool_specified"; then 43076 # A command without a complete path is provided, search $PATH. 43077 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 43078 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 43079 # Extract the first word of "$tool_basename", so it can be a program name with args. 43080 set dummy $tool_basename; ac_word=$2 43081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43082 $as_echo_n "checking for $ac_word... " >&6; } 43083 if ${ac_cv_path_NM+:} false; then : 43084 $as_echo_n "(cached) " >&6 43085 else 43086 case $NM in 43087 [\\/]* | ?:[\\/]*) 43088 ac_cv_path_NM="$NM" # Let the user override the test with a path. 43089 ;; 43090 *) 43091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43092 for as_dir in $PATH 43093 do 43094 IFS=$as_save_IFS 43095 test -z "$as_dir" && as_dir=. 43096 for ac_exec_ext in '' $ac_executable_extensions; do 43097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43098 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 43099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43100 break 2 43101 fi 43102 done 43103 done 43104 IFS=$as_save_IFS 43105 43106 ;; 43107 esac 43108 fi 43109 NM=$ac_cv_path_NM 43110 if test -n "$NM"; then 43111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 43112 $as_echo "$NM" >&6; } 43113 else 43114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43115 $as_echo "no" >&6; } 43116 fi 43117 43118 43119 if test "x$NM" = x; then 43120 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43121 fi 43122 else 43123 # Otherwise we believe it is a complete path. Use it as it is. 43124 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 43125 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 43126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 43127 $as_echo_n "checking for NM... " >&6; } 43128 if test ! -x "$tool_specified"; then 43129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43130 $as_echo "not found" >&6; } 43131 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 43132 fi 43133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43134 $as_echo "$tool_specified" >&6; } 43135 fi 43136 fi 43137 fi 43138 43139 fi 43140 43141 43142 fi 43143 43144 # Only process if variable expands to non-empty 43145 43146 if test "x$NM" != x; then 43147 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43148 43149 # First separate the path from the arguments. This will split at the first 43150 # space. 43151 complete="$NM" 43152 path="${complete%% *}" 43153 tmp="$complete EOL" 43154 arguments="${tmp#* }" 43155 43156 # Input might be given as Windows format, start by converting to 43157 # unix format. 43158 new_path=`$CYGPATH -u "$path"` 43159 43160 # Now try to locate executable using which 43161 new_path=`$WHICH "$new_path" 2> /dev/null` 43162 # bat and cmd files are not always considered executable in cygwin causing which 43163 # to not find them 43164 if test "x$new_path" = x \ 43165 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43166 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43167 new_path=`$CYGPATH -u "$path"` 43168 fi 43169 if test "x$new_path" = x; then 43170 # Oops. Which didn't find the executable. 43171 # The splitting of arguments from the executable at a space might have been incorrect, 43172 # since paths with space are more likely in Windows. Give it another try with the whole 43173 # argument. 43174 path="$complete" 43175 arguments="EOL" 43176 new_path=`$CYGPATH -u "$path"` 43177 new_path=`$WHICH "$new_path" 2> /dev/null` 43178 # bat and cmd files are not always considered executable in cygwin causing which 43179 # to not find them 43180 if test "x$new_path" = x \ 43181 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43182 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43183 new_path=`$CYGPATH -u "$path"` 43184 fi 43185 if test "x$new_path" = x; then 43186 # It's still not found. Now this is an unrecoverable error. 43187 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 43188 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 43189 has_space=`$ECHO "$complete" | $GREP " "` 43190 if test "x$has_space" != x; then 43191 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43192 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43193 fi 43194 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43195 fi 43196 fi 43197 43198 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43199 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43200 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43201 # "foo.exe" is OK but "foo" is an error. 43202 # 43203 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43204 # It is also a way to make sure we got the proper file name for the real test later on. 43205 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43206 if test "x$test_shortpath" = x; then 43207 # Short path failed, file does not exist as specified. 43208 # Try adding .exe or .cmd 43209 if test -f "${new_path}.exe"; then 43210 input_to_shortpath="${new_path}.exe" 43211 elif test -f "${new_path}.cmd"; then 43212 input_to_shortpath="${new_path}.cmd" 43213 else 43214 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 43215 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 43216 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43217 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43218 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43219 fi 43220 else 43221 input_to_shortpath="$new_path" 43222 fi 43223 43224 # Call helper function which possibly converts this using DOS-style short mode. 43225 # If so, the updated path is stored in $new_path. 43226 new_path="$input_to_shortpath" 43227 43228 input_path="$input_to_shortpath" 43229 # Check if we need to convert this using DOS-style short mode. If the path 43230 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43231 # take no chances and rewrite it. 43232 # Note: m4 eats our [], so we need to use [ and ] instead. 43233 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43234 if test "x$has_forbidden_chars" != x; then 43235 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43236 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43237 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43238 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43239 # Going to short mode and back again did indeed matter. Since short mode is 43240 # case insensitive, let's make it lowercase to improve readability. 43241 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43242 # Now convert it back to Unix-style (cygpath) 43243 input_path=`$CYGPATH -u "$shortmode_path"` 43244 new_path="$input_path" 43245 fi 43246 fi 43247 43248 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43249 if test "x$test_cygdrive_prefix" = x; then 43250 # As a simple fix, exclude /usr/bin since it's not a real path. 43251 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43252 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43253 # a path prefixed by /cygdrive for fixpath to work. 43254 new_path="$CYGWIN_ROOT_PATH$input_path" 43255 fi 43256 fi 43257 43258 # remove trailing .exe if any 43259 new_path="${new_path/%.exe/}" 43260 43261 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43262 43263 # First separate the path from the arguments. This will split at the first 43264 # space. 43265 complete="$NM" 43266 path="${complete%% *}" 43267 tmp="$complete EOL" 43268 arguments="${tmp#* }" 43269 43270 # Input might be given as Windows format, start by converting to 43271 # unix format. 43272 new_path="$path" 43273 43274 windows_path="$new_path" 43275 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43276 unix_path=`$CYGPATH -u "$windows_path"` 43277 new_path="$unix_path" 43278 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43279 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43280 new_path="$unix_path" 43281 fi 43282 43283 43284 # Now try to locate executable using which 43285 new_path=`$WHICH "$new_path" 2> /dev/null` 43286 43287 if test "x$new_path" = x; then 43288 # Oops. Which didn't find the executable. 43289 # The splitting of arguments from the executable at a space might have been incorrect, 43290 # since paths with space are more likely in Windows. Give it another try with the whole 43291 # argument. 43292 path="$complete" 43293 arguments="EOL" 43294 new_path="$path" 43295 43296 windows_path="$new_path" 43297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43298 unix_path=`$CYGPATH -u "$windows_path"` 43299 new_path="$unix_path" 43300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43301 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43302 new_path="$unix_path" 43303 fi 43304 43305 43306 new_path=`$WHICH "$new_path" 2> /dev/null` 43307 # bat and cmd files are not always considered executable in MSYS causing which 43308 # to not find them 43309 if test "x$new_path" = x \ 43310 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43311 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43312 new_path="$path" 43313 43314 windows_path="$new_path" 43315 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43316 unix_path=`$CYGPATH -u "$windows_path"` 43317 new_path="$unix_path" 43318 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43319 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43320 new_path="$unix_path" 43321 fi 43322 43323 fi 43324 43325 if test "x$new_path" = x; then 43326 # It's still not found. Now this is an unrecoverable error. 43327 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 43328 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 43329 has_space=`$ECHO "$complete" | $GREP " "` 43330 if test "x$has_space" != x; then 43331 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43332 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43333 fi 43334 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43335 fi 43336 fi 43337 43338 # Now new_path has a complete unix path to the binary 43339 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43340 # Keep paths in /bin as-is, but remove trailing .exe if any 43341 new_path="${new_path/%.exe/}" 43342 # Do not save /bin paths to all_fixpath_prefixes! 43343 else 43344 # Not in mixed or Windows style, start by that. 43345 new_path=`cmd //c echo $new_path` 43346 43347 input_path="$new_path" 43348 # Check if we need to convert this using DOS-style short mode. If the path 43349 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43350 # take no chances and rewrite it. 43351 # Note: m4 eats our [], so we need to use [ and ] instead. 43352 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43353 if test "x$has_forbidden_chars" != x; then 43354 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43355 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43356 fi 43357 43358 # Output is in $new_path 43359 43360 windows_path="$new_path" 43361 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43362 unix_path=`$CYGPATH -u "$windows_path"` 43363 new_path="$unix_path" 43364 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43365 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43366 new_path="$unix_path" 43367 fi 43368 43369 # remove trailing .exe if any 43370 new_path="${new_path/%.exe/}" 43371 43372 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43373 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43374 fi 43375 43376 else 43377 # We're on a unix platform. Hooray! :) 43378 # First separate the path from the arguments. This will split at the first 43379 # space. 43380 complete="$NM" 43381 path="${complete%% *}" 43382 tmp="$complete EOL" 43383 arguments="${tmp#* }" 43384 43385 # Cannot rely on the command "which" here since it doesn't always work. 43386 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43387 if test -z "$is_absolute_path"; then 43388 # Path to executable is not absolute. Find it. 43389 IFS_save="$IFS" 43390 IFS=: 43391 for p in $PATH; do 43392 if test -f "$p/$path" && test -x "$p/$path"; then 43393 new_path="$p/$path" 43394 break 43395 fi 43396 done 43397 IFS="$IFS_save" 43398 else 43399 # This is an absolute path, we can use it without further modifications. 43400 new_path="$path" 43401 fi 43402 43403 if test "x$new_path" = x; then 43404 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 43405 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 43406 has_space=`$ECHO "$complete" | $GREP " "` 43407 if test "x$has_space" != x; then 43408 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43409 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43410 fi 43411 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 43412 fi 43413 fi 43414 43415 # Now join together the path and the arguments once again 43416 if test "x$arguments" != xEOL; then 43417 new_complete="$new_path ${arguments% *}" 43418 else 43419 new_complete="$new_path" 43420 fi 43421 43422 if test "x$complete" != "x$new_complete"; then 43423 NM="$new_complete" 43424 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 43425 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 43426 fi 43427 fi 43428 43429 GNM="$NM" 43430 43431 fi 43432 43433 # objcopy is used for moving debug symbols to separate files when 43434 # full debug symbols are enabled. 43435 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 43436 43437 43438 # Publish this variable in the help. 43439 43440 43441 if [ -z "${OBJCOPY+x}" ]; then 43442 # The variable is not set by user, try to locate tool using the code snippet 43443 if test -n "$ac_tool_prefix"; then 43444 for ac_prog in gobjcopy objcopy 43445 do 43446 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43447 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43449 $as_echo_n "checking for $ac_word... " >&6; } 43450 if ${ac_cv_prog_OBJCOPY+:} false; then : 43451 $as_echo_n "(cached) " >&6 43452 else 43453 if test -n "$OBJCOPY"; then 43454 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 43455 else 43456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43457 for as_dir in $PATH 43458 do 43459 IFS=$as_save_IFS 43460 test -z "$as_dir" && as_dir=. 43461 for ac_exec_ext in '' $ac_executable_extensions; do 43462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43463 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 43464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43465 break 2 43466 fi 43467 done 43468 done 43469 IFS=$as_save_IFS 43470 43471 fi 43472 fi 43473 OBJCOPY=$ac_cv_prog_OBJCOPY 43474 if test -n "$OBJCOPY"; then 43475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43476 $as_echo "$OBJCOPY" >&6; } 43477 else 43478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43479 $as_echo "no" >&6; } 43480 fi 43481 43482 43483 test -n "$OBJCOPY" && break 43484 done 43485 fi 43486 if test -z "$OBJCOPY"; then 43487 ac_ct_OBJCOPY=$OBJCOPY 43488 for ac_prog in gobjcopy objcopy 43489 do 43490 # Extract the first word of "$ac_prog", so it can be a program name with args. 43491 set dummy $ac_prog; ac_word=$2 43492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43493 $as_echo_n "checking for $ac_word... " >&6; } 43494 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 43495 $as_echo_n "(cached) " >&6 43496 else 43497 if test -n "$ac_ct_OBJCOPY"; then 43498 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 43499 else 43500 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43501 for as_dir in $PATH 43502 do 43503 IFS=$as_save_IFS 43504 test -z "$as_dir" && as_dir=. 43505 for ac_exec_ext in '' $ac_executable_extensions; do 43506 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43507 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 43508 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43509 break 2 43510 fi 43511 done 43512 done 43513 IFS=$as_save_IFS 43514 43515 fi 43516 fi 43517 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 43518 if test -n "$ac_ct_OBJCOPY"; then 43519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 43520 $as_echo "$ac_ct_OBJCOPY" >&6; } 43521 else 43522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43523 $as_echo "no" >&6; } 43524 fi 43525 43526 43527 test -n "$ac_ct_OBJCOPY" && break 43528 done 43529 43530 if test "x$ac_ct_OBJCOPY" = x; then 43531 OBJCOPY="" 43532 else 43533 case $cross_compiling:$ac_tool_warned in 43534 yes:) 43535 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43536 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43537 ac_tool_warned=yes ;; 43538 esac 43539 OBJCOPY=$ac_ct_OBJCOPY 43540 fi 43541 fi 43542 43543 else 43544 # The variable is set, but is it from the command line or the environment? 43545 43546 # Try to remove the string !OBJCOPY! from our list. 43547 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 43548 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43549 # If it failed, the variable was not from the command line. Ignore it, 43550 # but warn the user (except for BASH, which is always set by the calling BASH). 43551 if test "xOBJCOPY" != xBASH; then 43552 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 43553 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 43554 fi 43555 # Try to locate tool using the code snippet 43556 if test -n "$ac_tool_prefix"; then 43557 for ac_prog in gobjcopy objcopy 43558 do 43559 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43560 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43562 $as_echo_n "checking for $ac_word... " >&6; } 43563 if ${ac_cv_prog_OBJCOPY+:} false; then : 43564 $as_echo_n "(cached) " >&6 43565 else 43566 if test -n "$OBJCOPY"; then 43567 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 43568 else 43569 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43570 for as_dir in $PATH 43571 do 43572 IFS=$as_save_IFS 43573 test -z "$as_dir" && as_dir=. 43574 for ac_exec_ext in '' $ac_executable_extensions; do 43575 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43576 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 43577 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43578 break 2 43579 fi 43580 done 43581 done 43582 IFS=$as_save_IFS 43583 43584 fi 43585 fi 43586 OBJCOPY=$ac_cv_prog_OBJCOPY 43587 if test -n "$OBJCOPY"; then 43588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43589 $as_echo "$OBJCOPY" >&6; } 43590 else 43591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43592 $as_echo "no" >&6; } 43593 fi 43594 43595 43596 test -n "$OBJCOPY" && break 43597 done 43598 fi 43599 if test -z "$OBJCOPY"; then 43600 ac_ct_OBJCOPY=$OBJCOPY 43601 for ac_prog in gobjcopy objcopy 43602 do 43603 # Extract the first word of "$ac_prog", so it can be a program name with args. 43604 set dummy $ac_prog; ac_word=$2 43605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43606 $as_echo_n "checking for $ac_word... " >&6; } 43607 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 43608 $as_echo_n "(cached) " >&6 43609 else 43610 if test -n "$ac_ct_OBJCOPY"; then 43611 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 43612 else 43613 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43614 for as_dir in $PATH 43615 do 43616 IFS=$as_save_IFS 43617 test -z "$as_dir" && as_dir=. 43618 for ac_exec_ext in '' $ac_executable_extensions; do 43619 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43620 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 43621 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43622 break 2 43623 fi 43624 done 43625 done 43626 IFS=$as_save_IFS 43627 43628 fi 43629 fi 43630 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 43631 if test -n "$ac_ct_OBJCOPY"; then 43632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 43633 $as_echo "$ac_ct_OBJCOPY" >&6; } 43634 else 43635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43636 $as_echo "no" >&6; } 43637 fi 43638 43639 43640 test -n "$ac_ct_OBJCOPY" && break 43641 done 43642 43643 if test "x$ac_ct_OBJCOPY" = x; then 43644 OBJCOPY="" 43645 else 43646 case $cross_compiling:$ac_tool_warned in 43647 yes:) 43648 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43649 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43650 ac_tool_warned=yes ;; 43651 esac 43652 OBJCOPY=$ac_ct_OBJCOPY 43653 fi 43654 fi 43655 43656 else 43657 # If it succeeded, then it was overridden by the user. We will use it 43658 # for the tool. 43659 43660 # First remove it from the list of overridden variables, so we can test 43661 # for unknown variables in the end. 43662 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43663 43664 # Check if we try to supply an empty value 43665 if test "x$OBJCOPY" = x; then 43666 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 43667 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 43668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 43669 $as_echo_n "checking for OBJCOPY... " >&6; } 43670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43671 $as_echo "disabled" >&6; } 43672 else 43673 # Check if the provided tool contains a complete path. 43674 tool_specified="$OBJCOPY" 43675 tool_basename="${tool_specified##*/}" 43676 if test "x$tool_basename" = "x$tool_specified"; then 43677 # A command without a complete path is provided, search $PATH. 43678 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 43679 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 43680 # Extract the first word of "$tool_basename", so it can be a program name with args. 43681 set dummy $tool_basename; ac_word=$2 43682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43683 $as_echo_n "checking for $ac_word... " >&6; } 43684 if ${ac_cv_path_OBJCOPY+:} false; then : 43685 $as_echo_n "(cached) " >&6 43686 else 43687 case $OBJCOPY in 43688 [\\/]* | ?:[\\/]*) 43689 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 43690 ;; 43691 *) 43692 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43693 for as_dir in $PATH 43694 do 43695 IFS=$as_save_IFS 43696 test -z "$as_dir" && as_dir=. 43697 for ac_exec_ext in '' $ac_executable_extensions; do 43698 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43699 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 43700 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43701 break 2 43702 fi 43703 done 43704 done 43705 IFS=$as_save_IFS 43706 43707 ;; 43708 esac 43709 fi 43710 OBJCOPY=$ac_cv_path_OBJCOPY 43711 if test -n "$OBJCOPY"; then 43712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43713 $as_echo "$OBJCOPY" >&6; } 43714 else 43715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43716 $as_echo "no" >&6; } 43717 fi 43718 43719 43720 if test "x$OBJCOPY" = x; then 43721 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43722 fi 43723 else 43724 # Otherwise we believe it is a complete path. Use it as it is. 43725 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 43726 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 43727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 43728 $as_echo_n "checking for OBJCOPY... " >&6; } 43729 if test ! -x "$tool_specified"; then 43730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43731 $as_echo "not found" >&6; } 43732 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 43733 fi 43734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43735 $as_echo "$tool_specified" >&6; } 43736 fi 43737 fi 43738 fi 43739 43740 fi 43741 43742 43743 # Only call fixup if objcopy was found. 43744 if test -n "$OBJCOPY"; then 43745 43746 # Only process if variable expands to non-empty 43747 43748 if test "x$OBJCOPY" != x; then 43749 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43750 43751 # First separate the path from the arguments. This will split at the first 43752 # space. 43753 complete="$OBJCOPY" 43754 path="${complete%% *}" 43755 tmp="$complete EOL" 43756 arguments="${tmp#* }" 43757 43758 # Input might be given as Windows format, start by converting to 43759 # unix format. 43760 new_path=`$CYGPATH -u "$path"` 43761 43762 # Now try to locate executable using which 43763 new_path=`$WHICH "$new_path" 2> /dev/null` 43764 # bat and cmd files are not always considered executable in cygwin causing which 43765 # to not find them 43766 if test "x$new_path" = x \ 43767 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43768 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43769 new_path=`$CYGPATH -u "$path"` 43770 fi 43771 if test "x$new_path" = x; then 43772 # Oops. Which didn't find the executable. 43773 # The splitting of arguments from the executable at a space might have been incorrect, 43774 # since paths with space are more likely in Windows. Give it another try with the whole 43775 # argument. 43776 path="$complete" 43777 arguments="EOL" 43778 new_path=`$CYGPATH -u "$path"` 43779 new_path=`$WHICH "$new_path" 2> /dev/null` 43780 # bat and cmd files are not always considered executable in cygwin causing which 43781 # to not find them 43782 if test "x$new_path" = x \ 43783 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43784 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43785 new_path=`$CYGPATH -u "$path"` 43786 fi 43787 if test "x$new_path" = x; then 43788 # It's still not found. Now this is an unrecoverable error. 43789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43790 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43791 has_space=`$ECHO "$complete" | $GREP " "` 43792 if test "x$has_space" != x; then 43793 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43794 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43795 fi 43796 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43797 fi 43798 fi 43799 43800 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43801 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43802 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43803 # "foo.exe" is OK but "foo" is an error. 43804 # 43805 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43806 # It is also a way to make sure we got the proper file name for the real test later on. 43807 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43808 if test "x$test_shortpath" = x; then 43809 # Short path failed, file does not exist as specified. 43810 # Try adding .exe or .cmd 43811 if test -f "${new_path}.exe"; then 43812 input_to_shortpath="${new_path}.exe" 43813 elif test -f "${new_path}.cmd"; then 43814 input_to_shortpath="${new_path}.cmd" 43815 else 43816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 43817 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 43818 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43819 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43820 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43821 fi 43822 else 43823 input_to_shortpath="$new_path" 43824 fi 43825 43826 # Call helper function which possibly converts this using DOS-style short mode. 43827 # If so, the updated path is stored in $new_path. 43828 new_path="$input_to_shortpath" 43829 43830 input_path="$input_to_shortpath" 43831 # Check if we need to convert this using DOS-style short mode. If the path 43832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43833 # take no chances and rewrite it. 43834 # Note: m4 eats our [], so we need to use [ and ] instead. 43835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43836 if test "x$has_forbidden_chars" != x; then 43837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43838 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43839 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43840 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43841 # Going to short mode and back again did indeed matter. Since short mode is 43842 # case insensitive, let's make it lowercase to improve readability. 43843 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43844 # Now convert it back to Unix-style (cygpath) 43845 input_path=`$CYGPATH -u "$shortmode_path"` 43846 new_path="$input_path" 43847 fi 43848 fi 43849 43850 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43851 if test "x$test_cygdrive_prefix" = x; then 43852 # As a simple fix, exclude /usr/bin since it's not a real path. 43853 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43854 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43855 # a path prefixed by /cygdrive for fixpath to work. 43856 new_path="$CYGWIN_ROOT_PATH$input_path" 43857 fi 43858 fi 43859 43860 # remove trailing .exe if any 43861 new_path="${new_path/%.exe/}" 43862 43863 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43864 43865 # First separate the path from the arguments. This will split at the first 43866 # space. 43867 complete="$OBJCOPY" 43868 path="${complete%% *}" 43869 tmp="$complete EOL" 43870 arguments="${tmp#* }" 43871 43872 # Input might be given as Windows format, start by converting to 43873 # unix format. 43874 new_path="$path" 43875 43876 windows_path="$new_path" 43877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43878 unix_path=`$CYGPATH -u "$windows_path"` 43879 new_path="$unix_path" 43880 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43881 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43882 new_path="$unix_path" 43883 fi 43884 43885 43886 # Now try to locate executable using which 43887 new_path=`$WHICH "$new_path" 2> /dev/null` 43888 43889 if test "x$new_path" = x; then 43890 # Oops. Which didn't find the executable. 43891 # The splitting of arguments from the executable at a space might have been incorrect, 43892 # since paths with space are more likely in Windows. Give it another try with the whole 43893 # argument. 43894 path="$complete" 43895 arguments="EOL" 43896 new_path="$path" 43897 43898 windows_path="$new_path" 43899 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43900 unix_path=`$CYGPATH -u "$windows_path"` 43901 new_path="$unix_path" 43902 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43903 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43904 new_path="$unix_path" 43905 fi 43906 43907 43908 new_path=`$WHICH "$new_path" 2> /dev/null` 43909 # bat and cmd files are not always considered executable in MSYS causing which 43910 # to not find them 43911 if test "x$new_path" = x \ 43912 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43913 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43914 new_path="$path" 43915 43916 windows_path="$new_path" 43917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43918 unix_path=`$CYGPATH -u "$windows_path"` 43919 new_path="$unix_path" 43920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43921 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43922 new_path="$unix_path" 43923 fi 43924 43925 fi 43926 43927 if test "x$new_path" = x; then 43928 # It's still not found. Now this is an unrecoverable error. 43929 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43930 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43931 has_space=`$ECHO "$complete" | $GREP " "` 43932 if test "x$has_space" != x; then 43933 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43934 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43935 fi 43936 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43937 fi 43938 fi 43939 43940 # Now new_path has a complete unix path to the binary 43941 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43942 # Keep paths in /bin as-is, but remove trailing .exe if any 43943 new_path="${new_path/%.exe/}" 43944 # Do not save /bin paths to all_fixpath_prefixes! 43945 else 43946 # Not in mixed or Windows style, start by that. 43947 new_path=`cmd //c echo $new_path` 43948 43949 input_path="$new_path" 43950 # Check if we need to convert this using DOS-style short mode. If the path 43951 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43952 # take no chances and rewrite it. 43953 # Note: m4 eats our [], so we need to use [ and ] instead. 43954 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43955 if test "x$has_forbidden_chars" != x; then 43956 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43957 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43958 fi 43959 43960 # Output is in $new_path 43961 43962 windows_path="$new_path" 43963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43964 unix_path=`$CYGPATH -u "$windows_path"` 43965 new_path="$unix_path" 43966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43967 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43968 new_path="$unix_path" 43969 fi 43970 43971 # remove trailing .exe if any 43972 new_path="${new_path/%.exe/}" 43973 43974 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43975 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43976 fi 43977 43978 else 43979 # We're on a unix platform. Hooray! :) 43980 # First separate the path from the arguments. This will split at the first 43981 # space. 43982 complete="$OBJCOPY" 43983 path="${complete%% *}" 43984 tmp="$complete EOL" 43985 arguments="${tmp#* }" 43986 43987 # Cannot rely on the command "which" here since it doesn't always work. 43988 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43989 if test -z "$is_absolute_path"; then 43990 # Path to executable is not absolute. Find it. 43991 IFS_save="$IFS" 43992 IFS=: 43993 for p in $PATH; do 43994 if test -f "$p/$path" && test -x "$p/$path"; then 43995 new_path="$p/$path" 43996 break 43997 fi 43998 done 43999 IFS="$IFS_save" 44000 else 44001 # This is an absolute path, we can use it without further modifications. 44002 new_path="$path" 44003 fi 44004 44005 if test "x$new_path" = x; then 44006 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 44007 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 44008 has_space=`$ECHO "$complete" | $GREP " "` 44009 if test "x$has_space" != x; then 44010 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44011 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44012 fi 44013 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 44014 fi 44015 fi 44016 44017 # Now join together the path and the arguments once again 44018 if test "x$arguments" != xEOL; then 44019 new_complete="$new_path ${arguments% *}" 44020 else 44021 new_complete="$new_path" 44022 fi 44023 44024 if test "x$complete" != "x$new_complete"; then 44025 OBJCOPY="$new_complete" 44026 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 44027 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 44028 fi 44029 fi 44030 44031 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 44032 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 44033 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 44034 # - version number is last blank separate word on first line 44035 # - version number formats that have been seen: 44036 # - <major>.<minor> 44037 # - <major>.<minor>.<micro> 44038 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 44039 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 44040 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 44041 -e 's/.* //' \ 44042 -e '/^[01]\./b bad' \ 44043 -e '/^2\./{' \ 44044 -e ' s/^2\.//' \ 44045 -e ' /^[0-9]$/b bad' \ 44046 -e ' /^[0-9]\./b bad' \ 44047 -e ' /^1[0-9]$/b bad' \ 44048 -e ' /^1[0-9]\./b bad' \ 44049 -e ' /^20\./b bad' \ 44050 -e ' /^21\.0$/b bad' \ 44051 -e ' /^21\.0\./b bad' \ 44052 -e '}' \ 44053 -e ':good' \ 44054 -e 's/.*/VALID_VERSION/p' \ 44055 -e 'q' \ 44056 -e ':bad' \ 44057 -e 's/.*/BAD_VERSION/p' \ 44058 -e 'q'` 44059 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 44060 OBJCOPY= 44061 { $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 44062 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 44063 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 44064 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 44065 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 44066 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 44067 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 44068 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 44069 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 44070 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 44071 fi 44072 fi 44073 fi 44074 fi 44075 44076 44077 44078 # Publish this variable in the help. 44079 44080 44081 if [ -z "${OBJDUMP+x}" ]; then 44082 # The variable is not set by user, try to locate tool using the code snippet 44083 if test -n "$ac_tool_prefix"; then 44084 for ac_prog in gobjdump objdump 44085 do 44086 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 44087 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 44088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44089 $as_echo_n "checking for $ac_word... " >&6; } 44090 if ${ac_cv_prog_OBJDUMP+:} false; then : 44091 $as_echo_n "(cached) " >&6 44092 else 44093 if test -n "$OBJDUMP"; then 44094 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 44095 else 44096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44097 for as_dir in $PATH 44098 do 44099 IFS=$as_save_IFS 44100 test -z "$as_dir" && as_dir=. 44101 for ac_exec_ext in '' $ac_executable_extensions; do 44102 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44103 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 44104 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44105 break 2 44106 fi 44107 done 44108 done 44109 IFS=$as_save_IFS 44110 44111 fi 44112 fi 44113 OBJDUMP=$ac_cv_prog_OBJDUMP 44114 if test -n "$OBJDUMP"; then 44115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 44116 $as_echo "$OBJDUMP" >&6; } 44117 else 44118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44119 $as_echo "no" >&6; } 44120 fi 44121 44122 44123 test -n "$OBJDUMP" && break 44124 done 44125 fi 44126 if test -z "$OBJDUMP"; then 44127 ac_ct_OBJDUMP=$OBJDUMP 44128 for ac_prog in gobjdump objdump 44129 do 44130 # Extract the first word of "$ac_prog", so it can be a program name with args. 44131 set dummy $ac_prog; ac_word=$2 44132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44133 $as_echo_n "checking for $ac_word... " >&6; } 44134 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 44135 $as_echo_n "(cached) " >&6 44136 else 44137 if test -n "$ac_ct_OBJDUMP"; then 44138 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 44139 else 44140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44141 for as_dir in $PATH 44142 do 44143 IFS=$as_save_IFS 44144 test -z "$as_dir" && as_dir=. 44145 for ac_exec_ext in '' $ac_executable_extensions; do 44146 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44147 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 44148 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44149 break 2 44150 fi 44151 done 44152 done 44153 IFS=$as_save_IFS 44154 44155 fi 44156 fi 44157 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 44158 if test -n "$ac_ct_OBJDUMP"; then 44159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 44160 $as_echo "$ac_ct_OBJDUMP" >&6; } 44161 else 44162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44163 $as_echo "no" >&6; } 44164 fi 44165 44166 44167 test -n "$ac_ct_OBJDUMP" && break 44168 done 44169 44170 if test "x$ac_ct_OBJDUMP" = x; then 44171 OBJDUMP="" 44172 else 44173 case $cross_compiling:$ac_tool_warned in 44174 yes:) 44175 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44176 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44177 ac_tool_warned=yes ;; 44178 esac 44179 OBJDUMP=$ac_ct_OBJDUMP 44180 fi 44181 fi 44182 44183 else 44184 # The variable is set, but is it from the command line or the environment? 44185 44186 # Try to remove the string !OBJDUMP! from our list. 44187 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 44188 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44189 # If it failed, the variable was not from the command line. Ignore it, 44190 # but warn the user (except for BASH, which is always set by the calling BASH). 44191 if test "xOBJDUMP" != xBASH; then 44192 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 44193 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 44194 fi 44195 # Try to locate tool using the code snippet 44196 if test -n "$ac_tool_prefix"; then 44197 for ac_prog in gobjdump objdump 44198 do 44199 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 44200 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 44201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44202 $as_echo_n "checking for $ac_word... " >&6; } 44203 if ${ac_cv_prog_OBJDUMP+:} false; then : 44204 $as_echo_n "(cached) " >&6 44205 else 44206 if test -n "$OBJDUMP"; then 44207 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 44208 else 44209 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44210 for as_dir in $PATH 44211 do 44212 IFS=$as_save_IFS 44213 test -z "$as_dir" && as_dir=. 44214 for ac_exec_ext in '' $ac_executable_extensions; do 44215 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44216 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 44217 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44218 break 2 44219 fi 44220 done 44221 done 44222 IFS=$as_save_IFS 44223 44224 fi 44225 fi 44226 OBJDUMP=$ac_cv_prog_OBJDUMP 44227 if test -n "$OBJDUMP"; then 44228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 44229 $as_echo "$OBJDUMP" >&6; } 44230 else 44231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44232 $as_echo "no" >&6; } 44233 fi 44234 44235 44236 test -n "$OBJDUMP" && break 44237 done 44238 fi 44239 if test -z "$OBJDUMP"; then 44240 ac_ct_OBJDUMP=$OBJDUMP 44241 for ac_prog in gobjdump objdump 44242 do 44243 # Extract the first word of "$ac_prog", so it can be a program name with args. 44244 set dummy $ac_prog; ac_word=$2 44245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44246 $as_echo_n "checking for $ac_word... " >&6; } 44247 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 44248 $as_echo_n "(cached) " >&6 44249 else 44250 if test -n "$ac_ct_OBJDUMP"; then 44251 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 44252 else 44253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44254 for as_dir in $PATH 44255 do 44256 IFS=$as_save_IFS 44257 test -z "$as_dir" && as_dir=. 44258 for ac_exec_ext in '' $ac_executable_extensions; do 44259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44260 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 44261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44262 break 2 44263 fi 44264 done 44265 done 44266 IFS=$as_save_IFS 44267 44268 fi 44269 fi 44270 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 44271 if test -n "$ac_ct_OBJDUMP"; then 44272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 44273 $as_echo "$ac_ct_OBJDUMP" >&6; } 44274 else 44275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44276 $as_echo "no" >&6; } 44277 fi 44278 44279 44280 test -n "$ac_ct_OBJDUMP" && break 44281 done 44282 44283 if test "x$ac_ct_OBJDUMP" = x; then 44284 OBJDUMP="" 44285 else 44286 case $cross_compiling:$ac_tool_warned in 44287 yes:) 44288 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 44289 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 44290 ac_tool_warned=yes ;; 44291 esac 44292 OBJDUMP=$ac_ct_OBJDUMP 44293 fi 44294 fi 44295 44296 else 44297 # If it succeeded, then it was overridden by the user. We will use it 44298 # for the tool. 44299 44300 # First remove it from the list of overridden variables, so we can test 44301 # for unknown variables in the end. 44302 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44303 44304 # Check if we try to supply an empty value 44305 if test "x$OBJDUMP" = x; then 44306 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 44307 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 44308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 44309 $as_echo_n "checking for OBJDUMP... " >&6; } 44310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44311 $as_echo "disabled" >&6; } 44312 else 44313 # Check if the provided tool contains a complete path. 44314 tool_specified="$OBJDUMP" 44315 tool_basename="${tool_specified##*/}" 44316 if test "x$tool_basename" = "x$tool_specified"; then 44317 # A command without a complete path is provided, search $PATH. 44318 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 44319 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 44320 # Extract the first word of "$tool_basename", so it can be a program name with args. 44321 set dummy $tool_basename; ac_word=$2 44322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44323 $as_echo_n "checking for $ac_word... " >&6; } 44324 if ${ac_cv_path_OBJDUMP+:} false; then : 44325 $as_echo_n "(cached) " >&6 44326 else 44327 case $OBJDUMP in 44328 [\\/]* | ?:[\\/]*) 44329 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 44330 ;; 44331 *) 44332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44333 for as_dir in $PATH 44334 do 44335 IFS=$as_save_IFS 44336 test -z "$as_dir" && as_dir=. 44337 for ac_exec_ext in '' $ac_executable_extensions; do 44338 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44339 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 44340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44341 break 2 44342 fi 44343 done 44344 done 44345 IFS=$as_save_IFS 44346 44347 ;; 44348 esac 44349 fi 44350 OBJDUMP=$ac_cv_path_OBJDUMP 44351 if test -n "$OBJDUMP"; then 44352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 44353 $as_echo "$OBJDUMP" >&6; } 44354 else 44355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44356 $as_echo "no" >&6; } 44357 fi 44358 44359 44360 if test "x$OBJDUMP" = x; then 44361 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44362 fi 44363 else 44364 # Otherwise we believe it is a complete path. Use it as it is. 44365 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 44366 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 44367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 44368 $as_echo_n "checking for OBJDUMP... " >&6; } 44369 if test ! -x "$tool_specified"; then 44370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44371 $as_echo "not found" >&6; } 44372 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 44373 fi 44374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44375 $as_echo "$tool_specified" >&6; } 44376 fi 44377 fi 44378 fi 44379 44380 fi 44381 44382 44383 if test "x$OBJDUMP" != x; then 44384 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 44385 # bails if argument is missing. 44386 44387 # Only process if variable expands to non-empty 44388 44389 if test "x$OBJDUMP" != x; then 44390 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44391 44392 # First separate the path from the arguments. This will split at the first 44393 # space. 44394 complete="$OBJDUMP" 44395 path="${complete%% *}" 44396 tmp="$complete EOL" 44397 arguments="${tmp#* }" 44398 44399 # Input might be given as Windows format, start by converting to 44400 # unix format. 44401 new_path=`$CYGPATH -u "$path"` 44402 44403 # Now try to locate executable using which 44404 new_path=`$WHICH "$new_path" 2> /dev/null` 44405 # bat and cmd files are not always considered executable in cygwin causing which 44406 # to not find them 44407 if test "x$new_path" = x \ 44408 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44409 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44410 new_path=`$CYGPATH -u "$path"` 44411 fi 44412 if test "x$new_path" = x; then 44413 # Oops. Which didn't find the executable. 44414 # The splitting of arguments from the executable at a space might have been incorrect, 44415 # since paths with space are more likely in Windows. Give it another try with the whole 44416 # argument. 44417 path="$complete" 44418 arguments="EOL" 44419 new_path=`$CYGPATH -u "$path"` 44420 new_path=`$WHICH "$new_path" 2> /dev/null` 44421 # bat and cmd files are not always considered executable in cygwin causing which 44422 # to not find them 44423 if test "x$new_path" = x \ 44424 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44425 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44426 new_path=`$CYGPATH -u "$path"` 44427 fi 44428 if test "x$new_path" = x; then 44429 # It's still not found. Now this is an unrecoverable error. 44430 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44431 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44432 has_space=`$ECHO "$complete" | $GREP " "` 44433 if test "x$has_space" != x; then 44434 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44435 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44436 fi 44437 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44438 fi 44439 fi 44440 44441 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44442 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44443 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44444 # "foo.exe" is OK but "foo" is an error. 44445 # 44446 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44447 # It is also a way to make sure we got the proper file name for the real test later on. 44448 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44449 if test "x$test_shortpath" = x; then 44450 # Short path failed, file does not exist as specified. 44451 # Try adding .exe or .cmd 44452 if test -f "${new_path}.exe"; then 44453 input_to_shortpath="${new_path}.exe" 44454 elif test -f "${new_path}.cmd"; then 44455 input_to_shortpath="${new_path}.cmd" 44456 else 44457 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 44458 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 44459 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44460 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44461 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44462 fi 44463 else 44464 input_to_shortpath="$new_path" 44465 fi 44466 44467 # Call helper function which possibly converts this using DOS-style short mode. 44468 # If so, the updated path is stored in $new_path. 44469 new_path="$input_to_shortpath" 44470 44471 input_path="$input_to_shortpath" 44472 # Check if we need to convert this using DOS-style short mode. If the path 44473 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44474 # take no chances and rewrite it. 44475 # Note: m4 eats our [], so we need to use [ and ] instead. 44476 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44477 if test "x$has_forbidden_chars" != x; then 44478 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44479 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44480 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44481 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44482 # Going to short mode and back again did indeed matter. Since short mode is 44483 # case insensitive, let's make it lowercase to improve readability. 44484 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44485 # Now convert it back to Unix-style (cygpath) 44486 input_path=`$CYGPATH -u "$shortmode_path"` 44487 new_path="$input_path" 44488 fi 44489 fi 44490 44491 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44492 if test "x$test_cygdrive_prefix" = x; then 44493 # As a simple fix, exclude /usr/bin since it's not a real path. 44494 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44495 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44496 # a path prefixed by /cygdrive for fixpath to work. 44497 new_path="$CYGWIN_ROOT_PATH$input_path" 44498 fi 44499 fi 44500 44501 # remove trailing .exe if any 44502 new_path="${new_path/%.exe/}" 44503 44504 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44505 44506 # First separate the path from the arguments. This will split at the first 44507 # space. 44508 complete="$OBJDUMP" 44509 path="${complete%% *}" 44510 tmp="$complete EOL" 44511 arguments="${tmp#* }" 44512 44513 # Input might be given as Windows format, start by converting to 44514 # unix format. 44515 new_path="$path" 44516 44517 windows_path="$new_path" 44518 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44519 unix_path=`$CYGPATH -u "$windows_path"` 44520 new_path="$unix_path" 44521 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44522 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44523 new_path="$unix_path" 44524 fi 44525 44526 44527 # Now try to locate executable using which 44528 new_path=`$WHICH "$new_path" 2> /dev/null` 44529 44530 if test "x$new_path" = x; then 44531 # Oops. Which didn't find the executable. 44532 # The splitting of arguments from the executable at a space might have been incorrect, 44533 # since paths with space are more likely in Windows. Give it another try with the whole 44534 # argument. 44535 path="$complete" 44536 arguments="EOL" 44537 new_path="$path" 44538 44539 windows_path="$new_path" 44540 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44541 unix_path=`$CYGPATH -u "$windows_path"` 44542 new_path="$unix_path" 44543 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44544 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44545 new_path="$unix_path" 44546 fi 44547 44548 44549 new_path=`$WHICH "$new_path" 2> /dev/null` 44550 # bat and cmd files are not always considered executable in MSYS causing which 44551 # to not find them 44552 if test "x$new_path" = x \ 44553 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44554 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44555 new_path="$path" 44556 44557 windows_path="$new_path" 44558 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44559 unix_path=`$CYGPATH -u "$windows_path"` 44560 new_path="$unix_path" 44561 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44562 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44563 new_path="$unix_path" 44564 fi 44565 44566 fi 44567 44568 if test "x$new_path" = x; then 44569 # It's still not found. Now this is an unrecoverable error. 44570 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44571 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44572 has_space=`$ECHO "$complete" | $GREP " "` 44573 if test "x$has_space" != x; then 44574 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44575 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44576 fi 44577 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44578 fi 44579 fi 44580 44581 # Now new_path has a complete unix path to the binary 44582 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44583 # Keep paths in /bin as-is, but remove trailing .exe if any 44584 new_path="${new_path/%.exe/}" 44585 # Do not save /bin paths to all_fixpath_prefixes! 44586 else 44587 # Not in mixed or Windows style, start by that. 44588 new_path=`cmd //c echo $new_path` 44589 44590 input_path="$new_path" 44591 # Check if we need to convert this using DOS-style short mode. If the path 44592 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44593 # take no chances and rewrite it. 44594 # Note: m4 eats our [], so we need to use [ and ] instead. 44595 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44596 if test "x$has_forbidden_chars" != x; then 44597 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44598 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44599 fi 44600 44601 # Output is in $new_path 44602 44603 windows_path="$new_path" 44604 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44605 unix_path=`$CYGPATH -u "$windows_path"` 44606 new_path="$unix_path" 44607 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44608 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44609 new_path="$unix_path" 44610 fi 44611 44612 # remove trailing .exe if any 44613 new_path="${new_path/%.exe/}" 44614 44615 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44616 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44617 fi 44618 44619 else 44620 # We're on a unix platform. Hooray! :) 44621 # First separate the path from the arguments. This will split at the first 44622 # space. 44623 complete="$OBJDUMP" 44624 path="${complete%% *}" 44625 tmp="$complete EOL" 44626 arguments="${tmp#* }" 44627 44628 # Cannot rely on the command "which" here since it doesn't always work. 44629 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44630 if test -z "$is_absolute_path"; then 44631 # Path to executable is not absolute. Find it. 44632 IFS_save="$IFS" 44633 IFS=: 44634 for p in $PATH; do 44635 if test -f "$p/$path" && test -x "$p/$path"; then 44636 new_path="$p/$path" 44637 break 44638 fi 44639 done 44640 IFS="$IFS_save" 44641 else 44642 # This is an absolute path, we can use it without further modifications. 44643 new_path="$path" 44644 fi 44645 44646 if test "x$new_path" = x; then 44647 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44648 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44649 has_space=`$ECHO "$complete" | $GREP " "` 44650 if test "x$has_space" != x; then 44651 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44652 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44653 fi 44654 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44655 fi 44656 fi 44657 44658 # Now join together the path and the arguments once again 44659 if test "x$arguments" != xEOL; then 44660 new_complete="$new_path ${arguments% *}" 44661 else 44662 new_complete="$new_path" 44663 fi 44664 44665 if test "x$complete" != "x$new_complete"; then 44666 OBJDUMP="$new_complete" 44667 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 44668 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 44669 fi 44670 fi 44671 44672 fi 44673 44674 44675 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 44676 # to remain in place. Otherwise the compiler will not work in some siutations 44677 # in later configure checks. 44678 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 44679 PATH="$OLD_PATH" 44680 fi 44681 44682 # Restore the flags to the user specified values. 44683 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 44684 CFLAGS="$ORG_CFLAGS" 44685 CXXFLAGS="$ORG_CXXFLAGS" 44686 44687 44688 # Finally do some processing after the detection phase 44689 44690 if test "x$COMPILE_TYPE" = "xcross"; then 44691 # Now we need to find a C/C++ compiler that can build executables for the 44692 # build platform. We can't use the AC_PROG_CC macro, since it can only be 44693 # used once. Also, we need to do this without adding a tools dir to the 44694 # path, otherwise we might pick up cross-compilers which don't use standard 44695 # naming. 44696 44697 OLDPATH="$PATH" 44698 44699 44700 # Check whether --with-build-devkit was given. 44701 if test "${with_build_devkit+set}" = set; then : 44702 withval=$with_build_devkit; 44703 fi 44704 44705 if test "x$with_build_devkit" = "xyes"; then 44706 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 44707 elif test -n "$with_build_devkit"; then 44708 if test ! -d "$with_build_devkit"; then 44709 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 44710 else 44711 44712 # Only process if variable expands to non-empty 44713 44714 if test "x$with_build_devkit" != x; then 44715 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44716 44717 # Input might be given as Windows format, start by converting to 44718 # unix format. 44719 path="$with_build_devkit" 44720 new_path=`$CYGPATH -u "$path"` 44721 44722 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44723 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44724 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44725 # "foo.exe" is OK but "foo" is an error. 44726 # 44727 # This test is therefore slightly more accurate than "test -f" to check for file precense. 44728 # It is also a way to make sure we got the proper file name for the real test later on. 44729 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44730 if test "x$test_shortpath" = x; then 44731 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 44732 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 44733 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 44734 fi 44735 44736 # Call helper function which possibly converts this using DOS-style short mode. 44737 # If so, the updated path is stored in $new_path. 44738 44739 input_path="$new_path" 44740 # Check if we need to convert this using DOS-style short mode. If the path 44741 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44742 # take no chances and rewrite it. 44743 # Note: m4 eats our [], so we need to use [ and ] instead. 44744 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44745 if test "x$has_forbidden_chars" != x; then 44746 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44747 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44748 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44749 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44750 # Going to short mode and back again did indeed matter. Since short mode is 44751 # case insensitive, let's make it lowercase to improve readability. 44752 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44753 # Now convert it back to Unix-style (cygpath) 44754 input_path=`$CYGPATH -u "$shortmode_path"` 44755 new_path="$input_path" 44756 fi 44757 fi 44758 44759 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44760 if test "x$test_cygdrive_prefix" = x; then 44761 # As a simple fix, exclude /usr/bin since it's not a real path. 44762 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 44763 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44764 # a path prefixed by /cygdrive for fixpath to work. 44765 new_path="$CYGWIN_ROOT_PATH$input_path" 44766 fi 44767 fi 44768 44769 44770 if test "x$path" != "x$new_path"; then 44771 with_build_devkit="$new_path" 44772 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 44773 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 44774 fi 44775 44776 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44777 44778 path="$with_build_devkit" 44779 has_colon=`$ECHO $path | $GREP ^.:` 44780 new_path="$path" 44781 if test "x$has_colon" = x; then 44782 # Not in mixed or Windows style, start by that. 44783 new_path=`cmd //c echo $path` 44784 fi 44785 44786 44787 input_path="$new_path" 44788 # Check if we need to convert this using DOS-style short mode. If the path 44789 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44790 # take no chances and rewrite it. 44791 # Note: m4 eats our [], so we need to use [ and ] instead. 44792 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44793 if test "x$has_forbidden_chars" != x; then 44794 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44795 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44796 fi 44797 44798 44799 windows_path="$new_path" 44800 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44801 unix_path=`$CYGPATH -u "$windows_path"` 44802 new_path="$unix_path" 44803 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44804 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44805 new_path="$unix_path" 44806 fi 44807 44808 if test "x$path" != "x$new_path"; then 44809 with_build_devkit="$new_path" 44810 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 44811 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 44812 fi 44813 44814 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44815 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44816 44817 else 44818 # We're on a unix platform. Hooray! :) 44819 path="$with_build_devkit" 44820 has_space=`$ECHO "$path" | $GREP " "` 44821 if test "x$has_space" != x; then 44822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 44823 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 44824 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 44825 fi 44826 44827 # Use eval to expand a potential ~ 44828 eval path="$path" 44829 if test ! -f "$path" && test ! -d "$path"; then 44830 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 44831 fi 44832 44833 if test -d "$path"; then 44834 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 44835 else 44836 dir="`$DIRNAME "$path"`" 44837 base="`$BASENAME "$path"`" 44838 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 44839 fi 44840 fi 44841 fi 44842 44843 BUILD_DEVKIT_ROOT="$with_build_devkit" 44844 # Check for a meta data info file in the root of the devkit 44845 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 44846 # Process devkit.info so that existing devkit variables are not 44847 # modified by this 44848 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 44849 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 44850 -e "s/\$host/\$build/g" \ 44851 $BUILD_DEVKIT_ROOT/devkit.info \ 44852 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 44853 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 44854 # This potentially sets the following: 44855 # A descriptive name of the devkit 44856 44857 if test "x$BUILD_DEVKIT_NAME" = x; then 44858 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 44859 fi 44860 44861 # Corresponds to --with-extra-path 44862 44863 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 44864 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 44865 fi 44866 44867 # Corresponds to --with-toolchain-path 44868 44869 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44870 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 44871 fi 44872 44873 # Corresponds to --with-sysroot 44874 44875 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 44876 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 44877 fi 44878 44879 # Skip the Window specific parts 44880 fi 44881 44882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 44883 $as_echo_n "checking for build platform devkit... " >&6; } 44884 if test "x$BUILD_DEVKIT_NAME" != x; then 44885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 44886 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 44887 else 44888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 44889 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 44890 fi 44891 44892 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 44893 44894 if test "x$BUILD_SYSROOT" != "x"; then 44895 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 44896 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 44897 # Solaris Studio does not have a concept of sysroot. Instead we must 44898 # make sure the default include and lib dirs are appended to each 44899 # compile and link command line. Must also add -I-xbuiltin to enable 44900 # inlining of system functions and intrinsics. 44901 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 44902 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 44903 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 44904 fi 44905 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 44906 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 44907 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 44908 elif test "x$TOOLCHAIN_TYPE" = xclang; then 44909 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 44910 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 44911 fi 44912 # The global CFLAGS and LDFLAGS variables need these for configure to function 44913 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 44914 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 44915 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 44916 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 44917 fi 44918 44919 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 44920 # We also need -iframework<path>/System/Library/Frameworks 44921 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44922 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44923 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 44924 # set this here so it doesn't have to be peppered throughout the forest 44925 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44926 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44927 fi 44928 44929 44930 44931 44932 44933 # Fallback default of just /bin if DEVKIT_PATH is not defined 44934 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44935 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 44936 fi 44937 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 44938 fi 44939 fi 44940 44941 # FIXME: we should list the discovered compilers as an exclude pattern! 44942 # If we do that, we can do this detection before POST_DETECTION, and still 44943 # find the build compilers in the tools dir, if needed. 44944 44945 44946 44947 # Publish this variable in the help. 44948 44949 44950 if [ -z "${BUILD_CC+x}" ]; then 44951 # The variable is not set by user, try to locate tool using the code snippet 44952 for ac_prog in cl cc gcc 44953 do 44954 # Extract the first word of "$ac_prog", so it can be a program name with args. 44955 set dummy $ac_prog; ac_word=$2 44956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44957 $as_echo_n "checking for $ac_word... " >&6; } 44958 if ${ac_cv_path_BUILD_CC+:} false; then : 44959 $as_echo_n "(cached) " >&6 44960 else 44961 case $BUILD_CC in 44962 [\\/]* | ?:[\\/]*) 44963 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44964 ;; 44965 *) 44966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44967 for as_dir in $PATH 44968 do 44969 IFS=$as_save_IFS 44970 test -z "$as_dir" && as_dir=. 44971 for ac_exec_ext in '' $ac_executable_extensions; do 44972 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44973 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44975 break 2 44976 fi 44977 done 44978 done 44979 IFS=$as_save_IFS 44980 44981 ;; 44982 esac 44983 fi 44984 BUILD_CC=$ac_cv_path_BUILD_CC 44985 if test -n "$BUILD_CC"; then 44986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44987 $as_echo "$BUILD_CC" >&6; } 44988 else 44989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44990 $as_echo "no" >&6; } 44991 fi 44992 44993 44994 test -n "$BUILD_CC" && break 44995 done 44996 44997 else 44998 # The variable is set, but is it from the command line or the environment? 44999 45000 # Try to remove the string !BUILD_CC! from our list. 45001 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 45002 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45003 # If it failed, the variable was not from the command line. Ignore it, 45004 # but warn the user (except for BASH, which is always set by the calling BASH). 45005 if test "xBUILD_CC" != xBASH; then 45006 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 45007 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 45008 fi 45009 # Try to locate tool using the code snippet 45010 for ac_prog in cl cc gcc 45011 do 45012 # Extract the first word of "$ac_prog", so it can be a program name with args. 45013 set dummy $ac_prog; ac_word=$2 45014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45015 $as_echo_n "checking for $ac_word... " >&6; } 45016 if ${ac_cv_path_BUILD_CC+:} false; then : 45017 $as_echo_n "(cached) " >&6 45018 else 45019 case $BUILD_CC in 45020 [\\/]* | ?:[\\/]*) 45021 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 45022 ;; 45023 *) 45024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45025 for as_dir in $PATH 45026 do 45027 IFS=$as_save_IFS 45028 test -z "$as_dir" && as_dir=. 45029 for ac_exec_ext in '' $ac_executable_extensions; do 45030 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45031 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 45032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45033 break 2 45034 fi 45035 done 45036 done 45037 IFS=$as_save_IFS 45038 45039 ;; 45040 esac 45041 fi 45042 BUILD_CC=$ac_cv_path_BUILD_CC 45043 if test -n "$BUILD_CC"; then 45044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 45045 $as_echo "$BUILD_CC" >&6; } 45046 else 45047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45048 $as_echo "no" >&6; } 45049 fi 45050 45051 45052 test -n "$BUILD_CC" && break 45053 done 45054 45055 else 45056 # If it succeeded, then it was overridden by the user. We will use it 45057 # for the tool. 45058 45059 # First remove it from the list of overridden variables, so we can test 45060 # for unknown variables in the end. 45061 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45062 45063 # Check if we try to supply an empty value 45064 if test "x$BUILD_CC" = x; then 45065 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 45066 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 45067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 45068 $as_echo_n "checking for BUILD_CC... " >&6; } 45069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45070 $as_echo "disabled" >&6; } 45071 else 45072 # Check if the provided tool contains a complete path. 45073 tool_specified="$BUILD_CC" 45074 tool_basename="${tool_specified##*/}" 45075 if test "x$tool_basename" = "x$tool_specified"; then 45076 # A command without a complete path is provided, search $PATH. 45077 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 45078 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 45079 # Extract the first word of "$tool_basename", so it can be a program name with args. 45080 set dummy $tool_basename; ac_word=$2 45081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45082 $as_echo_n "checking for $ac_word... " >&6; } 45083 if ${ac_cv_path_BUILD_CC+:} false; then : 45084 $as_echo_n "(cached) " >&6 45085 else 45086 case $BUILD_CC in 45087 [\\/]* | ?:[\\/]*) 45088 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 45089 ;; 45090 *) 45091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45092 for as_dir in $PATH 45093 do 45094 IFS=$as_save_IFS 45095 test -z "$as_dir" && as_dir=. 45096 for ac_exec_ext in '' $ac_executable_extensions; do 45097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45098 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 45099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45100 break 2 45101 fi 45102 done 45103 done 45104 IFS=$as_save_IFS 45105 45106 ;; 45107 esac 45108 fi 45109 BUILD_CC=$ac_cv_path_BUILD_CC 45110 if test -n "$BUILD_CC"; then 45111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 45112 $as_echo "$BUILD_CC" >&6; } 45113 else 45114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45115 $as_echo "no" >&6; } 45116 fi 45117 45118 45119 if test "x$BUILD_CC" = x; then 45120 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45121 fi 45122 else 45123 # Otherwise we believe it is a complete path. Use it as it is. 45124 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 45125 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 45126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 45127 $as_echo_n "checking for BUILD_CC... " >&6; } 45128 if test ! -x "$tool_specified"; then 45129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45130 $as_echo "not found" >&6; } 45131 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 45132 fi 45133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45134 $as_echo "$tool_specified" >&6; } 45135 fi 45136 fi 45137 fi 45138 45139 fi 45140 45141 45142 45143 if test "x$BUILD_CC" = x; then 45144 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 45145 fi 45146 45147 45148 45149 # Only process if variable expands to non-empty 45150 45151 if test "x$BUILD_CC" != x; then 45152 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45153 45154 # First separate the path from the arguments. This will split at the first 45155 # space. 45156 complete="$BUILD_CC" 45157 path="${complete%% *}" 45158 tmp="$complete EOL" 45159 arguments="${tmp#* }" 45160 45161 # Input might be given as Windows format, start by converting to 45162 # unix format. 45163 new_path=`$CYGPATH -u "$path"` 45164 45165 # Now try to locate executable using which 45166 new_path=`$WHICH "$new_path" 2> /dev/null` 45167 # bat and cmd files are not always considered executable in cygwin causing which 45168 # to not find them 45169 if test "x$new_path" = x \ 45170 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45171 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45172 new_path=`$CYGPATH -u "$path"` 45173 fi 45174 if test "x$new_path" = x; then 45175 # Oops. Which didn't find the executable. 45176 # The splitting of arguments from the executable at a space might have been incorrect, 45177 # since paths with space are more likely in Windows. Give it another try with the whole 45178 # argument. 45179 path="$complete" 45180 arguments="EOL" 45181 new_path=`$CYGPATH -u "$path"` 45182 new_path=`$WHICH "$new_path" 2> /dev/null` 45183 # bat and cmd files are not always considered executable in cygwin causing which 45184 # to not find them 45185 if test "x$new_path" = x \ 45186 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45187 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45188 new_path=`$CYGPATH -u "$path"` 45189 fi 45190 if test "x$new_path" = x; then 45191 # It's still not found. Now this is an unrecoverable error. 45192 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 45193 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 45194 has_space=`$ECHO "$complete" | $GREP " "` 45195 if test "x$has_space" != x; then 45196 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45197 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45198 fi 45199 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45200 fi 45201 fi 45202 45203 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45204 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45205 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45206 # "foo.exe" is OK but "foo" is an error. 45207 # 45208 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45209 # It is also a way to make sure we got the proper file name for the real test later on. 45210 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45211 if test "x$test_shortpath" = x; then 45212 # Short path failed, file does not exist as specified. 45213 # Try adding .exe or .cmd 45214 if test -f "${new_path}.exe"; then 45215 input_to_shortpath="${new_path}.exe" 45216 elif test -f "${new_path}.cmd"; then 45217 input_to_shortpath="${new_path}.cmd" 45218 else 45219 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 45220 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 45221 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45222 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45223 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45224 fi 45225 else 45226 input_to_shortpath="$new_path" 45227 fi 45228 45229 # Call helper function which possibly converts this using DOS-style short mode. 45230 # If so, the updated path is stored in $new_path. 45231 new_path="$input_to_shortpath" 45232 45233 input_path="$input_to_shortpath" 45234 # Check if we need to convert this using DOS-style short mode. If the path 45235 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45236 # take no chances and rewrite it. 45237 # Note: m4 eats our [], so we need to use [ and ] instead. 45238 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45239 if test "x$has_forbidden_chars" != x; then 45240 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45241 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45242 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45243 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45244 # Going to short mode and back again did indeed matter. Since short mode is 45245 # case insensitive, let's make it lowercase to improve readability. 45246 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45247 # Now convert it back to Unix-style (cygpath) 45248 input_path=`$CYGPATH -u "$shortmode_path"` 45249 new_path="$input_path" 45250 fi 45251 fi 45252 45253 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45254 if test "x$test_cygdrive_prefix" = x; then 45255 # As a simple fix, exclude /usr/bin since it's not a real path. 45256 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45257 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45258 # a path prefixed by /cygdrive for fixpath to work. 45259 new_path="$CYGWIN_ROOT_PATH$input_path" 45260 fi 45261 fi 45262 45263 # remove trailing .exe if any 45264 new_path="${new_path/%.exe/}" 45265 45266 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45267 45268 # First separate the path from the arguments. This will split at the first 45269 # space. 45270 complete="$BUILD_CC" 45271 path="${complete%% *}" 45272 tmp="$complete EOL" 45273 arguments="${tmp#* }" 45274 45275 # Input might be given as Windows format, start by converting to 45276 # unix format. 45277 new_path="$path" 45278 45279 windows_path="$new_path" 45280 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45281 unix_path=`$CYGPATH -u "$windows_path"` 45282 new_path="$unix_path" 45283 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45284 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45285 new_path="$unix_path" 45286 fi 45287 45288 45289 # Now try to locate executable using which 45290 new_path=`$WHICH "$new_path" 2> /dev/null` 45291 45292 if test "x$new_path" = x; then 45293 # Oops. Which didn't find the executable. 45294 # The splitting of arguments from the executable at a space might have been incorrect, 45295 # since paths with space are more likely in Windows. Give it another try with the whole 45296 # argument. 45297 path="$complete" 45298 arguments="EOL" 45299 new_path="$path" 45300 45301 windows_path="$new_path" 45302 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45303 unix_path=`$CYGPATH -u "$windows_path"` 45304 new_path="$unix_path" 45305 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45306 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45307 new_path="$unix_path" 45308 fi 45309 45310 45311 new_path=`$WHICH "$new_path" 2> /dev/null` 45312 # bat and cmd files are not always considered executable in MSYS causing which 45313 # to not find them 45314 if test "x$new_path" = x \ 45315 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45316 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45317 new_path="$path" 45318 45319 windows_path="$new_path" 45320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45321 unix_path=`$CYGPATH -u "$windows_path"` 45322 new_path="$unix_path" 45323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45324 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45325 new_path="$unix_path" 45326 fi 45327 45328 fi 45329 45330 if test "x$new_path" = x; then 45331 # It's still not found. Now this is an unrecoverable error. 45332 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 45333 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 45334 has_space=`$ECHO "$complete" | $GREP " "` 45335 if test "x$has_space" != x; then 45336 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45337 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45338 fi 45339 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45340 fi 45341 fi 45342 45343 # Now new_path has a complete unix path to the binary 45344 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45345 # Keep paths in /bin as-is, but remove trailing .exe if any 45346 new_path="${new_path/%.exe/}" 45347 # Do not save /bin paths to all_fixpath_prefixes! 45348 else 45349 # Not in mixed or Windows style, start by that. 45350 new_path=`cmd //c echo $new_path` 45351 45352 input_path="$new_path" 45353 # Check if we need to convert this using DOS-style short mode. If the path 45354 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45355 # take no chances and rewrite it. 45356 # Note: m4 eats our [], so we need to use [ and ] instead. 45357 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45358 if test "x$has_forbidden_chars" != x; then 45359 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45360 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45361 fi 45362 45363 # Output is in $new_path 45364 45365 windows_path="$new_path" 45366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45367 unix_path=`$CYGPATH -u "$windows_path"` 45368 new_path="$unix_path" 45369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45370 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45371 new_path="$unix_path" 45372 fi 45373 45374 # remove trailing .exe if any 45375 new_path="${new_path/%.exe/}" 45376 45377 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45378 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45379 fi 45380 45381 else 45382 # We're on a unix platform. Hooray! :) 45383 # First separate the path from the arguments. This will split at the first 45384 # space. 45385 complete="$BUILD_CC" 45386 path="${complete%% *}" 45387 tmp="$complete EOL" 45388 arguments="${tmp#* }" 45389 45390 # Cannot rely on the command "which" here since it doesn't always work. 45391 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45392 if test -z "$is_absolute_path"; then 45393 # Path to executable is not absolute. Find it. 45394 IFS_save="$IFS" 45395 IFS=: 45396 for p in $PATH; do 45397 if test -f "$p/$path" && test -x "$p/$path"; then 45398 new_path="$p/$path" 45399 break 45400 fi 45401 done 45402 IFS="$IFS_save" 45403 else 45404 # This is an absolute path, we can use it without further modifications. 45405 new_path="$path" 45406 fi 45407 45408 if test "x$new_path" = x; then 45409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 45410 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 45411 has_space=`$ECHO "$complete" | $GREP " "` 45412 if test "x$has_space" != x; then 45413 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45414 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45415 fi 45416 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 45417 fi 45418 fi 45419 45420 # Now join together the path and the arguments once again 45421 if test "x$arguments" != xEOL; then 45422 new_complete="$new_path ${arguments% *}" 45423 else 45424 new_complete="$new_path" 45425 fi 45426 45427 if test "x$complete" != "x$new_complete"; then 45428 BUILD_CC="$new_complete" 45429 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 45430 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 45431 fi 45432 fi 45433 45434 45435 45436 45437 # Publish this variable in the help. 45438 45439 45440 if [ -z "${BUILD_CXX+x}" ]; then 45441 # The variable is not set by user, try to locate tool using the code snippet 45442 for ac_prog in cl CC g++ 45443 do 45444 # Extract the first word of "$ac_prog", so it can be a program name with args. 45445 set dummy $ac_prog; ac_word=$2 45446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45447 $as_echo_n "checking for $ac_word... " >&6; } 45448 if ${ac_cv_path_BUILD_CXX+:} false; then : 45449 $as_echo_n "(cached) " >&6 45450 else 45451 case $BUILD_CXX in 45452 [\\/]* | ?:[\\/]*) 45453 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45454 ;; 45455 *) 45456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45457 for as_dir in $PATH 45458 do 45459 IFS=$as_save_IFS 45460 test -z "$as_dir" && as_dir=. 45461 for ac_exec_ext in '' $ac_executable_extensions; do 45462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45463 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45465 break 2 45466 fi 45467 done 45468 done 45469 IFS=$as_save_IFS 45470 45471 ;; 45472 esac 45473 fi 45474 BUILD_CXX=$ac_cv_path_BUILD_CXX 45475 if test -n "$BUILD_CXX"; then 45476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45477 $as_echo "$BUILD_CXX" >&6; } 45478 else 45479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45480 $as_echo "no" >&6; } 45481 fi 45482 45483 45484 test -n "$BUILD_CXX" && break 45485 done 45486 45487 else 45488 # The variable is set, but is it from the command line or the environment? 45489 45490 # Try to remove the string !BUILD_CXX! from our list. 45491 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 45492 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45493 # If it failed, the variable was not from the command line. Ignore it, 45494 # but warn the user (except for BASH, which is always set by the calling BASH). 45495 if test "xBUILD_CXX" != xBASH; then 45496 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 45497 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 45498 fi 45499 # Try to locate tool using the code snippet 45500 for ac_prog in cl CC g++ 45501 do 45502 # Extract the first word of "$ac_prog", so it can be a program name with args. 45503 set dummy $ac_prog; ac_word=$2 45504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45505 $as_echo_n "checking for $ac_word... " >&6; } 45506 if ${ac_cv_path_BUILD_CXX+:} false; then : 45507 $as_echo_n "(cached) " >&6 45508 else 45509 case $BUILD_CXX in 45510 [\\/]* | ?:[\\/]*) 45511 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45512 ;; 45513 *) 45514 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45515 for as_dir in $PATH 45516 do 45517 IFS=$as_save_IFS 45518 test -z "$as_dir" && as_dir=. 45519 for ac_exec_ext in '' $ac_executable_extensions; do 45520 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45521 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45523 break 2 45524 fi 45525 done 45526 done 45527 IFS=$as_save_IFS 45528 45529 ;; 45530 esac 45531 fi 45532 BUILD_CXX=$ac_cv_path_BUILD_CXX 45533 if test -n "$BUILD_CXX"; then 45534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45535 $as_echo "$BUILD_CXX" >&6; } 45536 else 45537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45538 $as_echo "no" >&6; } 45539 fi 45540 45541 45542 test -n "$BUILD_CXX" && break 45543 done 45544 45545 else 45546 # If it succeeded, then it was overridden by the user. We will use it 45547 # for the tool. 45548 45549 # First remove it from the list of overridden variables, so we can test 45550 # for unknown variables in the end. 45551 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45552 45553 # Check if we try to supply an empty value 45554 if test "x$BUILD_CXX" = x; then 45555 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 45556 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 45557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 45558 $as_echo_n "checking for BUILD_CXX... " >&6; } 45559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45560 $as_echo "disabled" >&6; } 45561 else 45562 # Check if the provided tool contains a complete path. 45563 tool_specified="$BUILD_CXX" 45564 tool_basename="${tool_specified##*/}" 45565 if test "x$tool_basename" = "x$tool_specified"; then 45566 # A command without a complete path is provided, search $PATH. 45567 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 45568 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 45569 # Extract the first word of "$tool_basename", so it can be a program name with args. 45570 set dummy $tool_basename; ac_word=$2 45571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45572 $as_echo_n "checking for $ac_word... " >&6; } 45573 if ${ac_cv_path_BUILD_CXX+:} false; then : 45574 $as_echo_n "(cached) " >&6 45575 else 45576 case $BUILD_CXX in 45577 [\\/]* | ?:[\\/]*) 45578 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45579 ;; 45580 *) 45581 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45582 for as_dir in $PATH 45583 do 45584 IFS=$as_save_IFS 45585 test -z "$as_dir" && as_dir=. 45586 for ac_exec_ext in '' $ac_executable_extensions; do 45587 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45588 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45589 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45590 break 2 45591 fi 45592 done 45593 done 45594 IFS=$as_save_IFS 45595 45596 ;; 45597 esac 45598 fi 45599 BUILD_CXX=$ac_cv_path_BUILD_CXX 45600 if test -n "$BUILD_CXX"; then 45601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45602 $as_echo "$BUILD_CXX" >&6; } 45603 else 45604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45605 $as_echo "no" >&6; } 45606 fi 45607 45608 45609 if test "x$BUILD_CXX" = x; then 45610 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45611 fi 45612 else 45613 # Otherwise we believe it is a complete path. Use it as it is. 45614 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 45615 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 45616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 45617 $as_echo_n "checking for BUILD_CXX... " >&6; } 45618 if test ! -x "$tool_specified"; then 45619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45620 $as_echo "not found" >&6; } 45621 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 45622 fi 45623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45624 $as_echo "$tool_specified" >&6; } 45625 fi 45626 fi 45627 fi 45628 45629 fi 45630 45631 45632 45633 if test "x$BUILD_CXX" = x; then 45634 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 45635 fi 45636 45637 45638 45639 # Only process if variable expands to non-empty 45640 45641 if test "x$BUILD_CXX" != x; then 45642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45643 45644 # First separate the path from the arguments. This will split at the first 45645 # space. 45646 complete="$BUILD_CXX" 45647 path="${complete%% *}" 45648 tmp="$complete EOL" 45649 arguments="${tmp#* }" 45650 45651 # Input might be given as Windows format, start by converting to 45652 # unix format. 45653 new_path=`$CYGPATH -u "$path"` 45654 45655 # Now try to locate executable using which 45656 new_path=`$WHICH "$new_path" 2> /dev/null` 45657 # bat and cmd files are not always considered executable in cygwin causing which 45658 # to not find them 45659 if test "x$new_path" = x \ 45660 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45661 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45662 new_path=`$CYGPATH -u "$path"` 45663 fi 45664 if test "x$new_path" = x; then 45665 # Oops. Which didn't find the executable. 45666 # The splitting of arguments from the executable at a space might have been incorrect, 45667 # since paths with space are more likely in Windows. Give it another try with the whole 45668 # argument. 45669 path="$complete" 45670 arguments="EOL" 45671 new_path=`$CYGPATH -u "$path"` 45672 new_path=`$WHICH "$new_path" 2> /dev/null` 45673 # bat and cmd files are not always considered executable in cygwin causing which 45674 # to not find them 45675 if test "x$new_path" = x \ 45676 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45677 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45678 new_path=`$CYGPATH -u "$path"` 45679 fi 45680 if test "x$new_path" = x; then 45681 # It's still not found. Now this is an unrecoverable error. 45682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45683 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45684 has_space=`$ECHO "$complete" | $GREP " "` 45685 if test "x$has_space" != x; then 45686 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45687 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45688 fi 45689 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45690 fi 45691 fi 45692 45693 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45694 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45695 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45696 # "foo.exe" is OK but "foo" is an error. 45697 # 45698 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45699 # It is also a way to make sure we got the proper file name for the real test later on. 45700 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45701 if test "x$test_shortpath" = x; then 45702 # Short path failed, file does not exist as specified. 45703 # Try adding .exe or .cmd 45704 if test -f "${new_path}.exe"; then 45705 input_to_shortpath="${new_path}.exe" 45706 elif test -f "${new_path}.cmd"; then 45707 input_to_shortpath="${new_path}.cmd" 45708 else 45709 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 45710 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 45711 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45712 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45713 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45714 fi 45715 else 45716 input_to_shortpath="$new_path" 45717 fi 45718 45719 # Call helper function which possibly converts this using DOS-style short mode. 45720 # If so, the updated path is stored in $new_path. 45721 new_path="$input_to_shortpath" 45722 45723 input_path="$input_to_shortpath" 45724 # Check if we need to convert this using DOS-style short mode. If the path 45725 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45726 # take no chances and rewrite it. 45727 # Note: m4 eats our [], so we need to use [ and ] instead. 45728 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45729 if test "x$has_forbidden_chars" != x; then 45730 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45731 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45732 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45733 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45734 # Going to short mode and back again did indeed matter. Since short mode is 45735 # case insensitive, let's make it lowercase to improve readability. 45736 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45737 # Now convert it back to Unix-style (cygpath) 45738 input_path=`$CYGPATH -u "$shortmode_path"` 45739 new_path="$input_path" 45740 fi 45741 fi 45742 45743 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45744 if test "x$test_cygdrive_prefix" = x; then 45745 # As a simple fix, exclude /usr/bin since it's not a real path. 45746 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45747 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45748 # a path prefixed by /cygdrive for fixpath to work. 45749 new_path="$CYGWIN_ROOT_PATH$input_path" 45750 fi 45751 fi 45752 45753 # remove trailing .exe if any 45754 new_path="${new_path/%.exe/}" 45755 45756 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45757 45758 # First separate the path from the arguments. This will split at the first 45759 # space. 45760 complete="$BUILD_CXX" 45761 path="${complete%% *}" 45762 tmp="$complete EOL" 45763 arguments="${tmp#* }" 45764 45765 # Input might be given as Windows format, start by converting to 45766 # unix format. 45767 new_path="$path" 45768 45769 windows_path="$new_path" 45770 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45771 unix_path=`$CYGPATH -u "$windows_path"` 45772 new_path="$unix_path" 45773 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45774 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45775 new_path="$unix_path" 45776 fi 45777 45778 45779 # Now try to locate executable using which 45780 new_path=`$WHICH "$new_path" 2> /dev/null` 45781 45782 if test "x$new_path" = x; then 45783 # Oops. Which didn't find the executable. 45784 # The splitting of arguments from the executable at a space might have been incorrect, 45785 # since paths with space are more likely in Windows. Give it another try with the whole 45786 # argument. 45787 path="$complete" 45788 arguments="EOL" 45789 new_path="$path" 45790 45791 windows_path="$new_path" 45792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45793 unix_path=`$CYGPATH -u "$windows_path"` 45794 new_path="$unix_path" 45795 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45796 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45797 new_path="$unix_path" 45798 fi 45799 45800 45801 new_path=`$WHICH "$new_path" 2> /dev/null` 45802 # bat and cmd files are not always considered executable in MSYS causing which 45803 # to not find them 45804 if test "x$new_path" = x \ 45805 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45806 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45807 new_path="$path" 45808 45809 windows_path="$new_path" 45810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45811 unix_path=`$CYGPATH -u "$windows_path"` 45812 new_path="$unix_path" 45813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45814 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45815 new_path="$unix_path" 45816 fi 45817 45818 fi 45819 45820 if test "x$new_path" = x; then 45821 # It's still not found. Now this is an unrecoverable error. 45822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45823 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45824 has_space=`$ECHO "$complete" | $GREP " "` 45825 if test "x$has_space" != x; then 45826 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45827 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45828 fi 45829 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45830 fi 45831 fi 45832 45833 # Now new_path has a complete unix path to the binary 45834 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45835 # Keep paths in /bin as-is, but remove trailing .exe if any 45836 new_path="${new_path/%.exe/}" 45837 # Do not save /bin paths to all_fixpath_prefixes! 45838 else 45839 # Not in mixed or Windows style, start by that. 45840 new_path=`cmd //c echo $new_path` 45841 45842 input_path="$new_path" 45843 # Check if we need to convert this using DOS-style short mode. If the path 45844 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45845 # take no chances and rewrite it. 45846 # Note: m4 eats our [], so we need to use [ and ] instead. 45847 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45848 if test "x$has_forbidden_chars" != x; then 45849 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45850 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45851 fi 45852 45853 # Output is in $new_path 45854 45855 windows_path="$new_path" 45856 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45857 unix_path=`$CYGPATH -u "$windows_path"` 45858 new_path="$unix_path" 45859 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45860 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45861 new_path="$unix_path" 45862 fi 45863 45864 # remove trailing .exe if any 45865 new_path="${new_path/%.exe/}" 45866 45867 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45868 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45869 fi 45870 45871 else 45872 # We're on a unix platform. Hooray! :) 45873 # First separate the path from the arguments. This will split at the first 45874 # space. 45875 complete="$BUILD_CXX" 45876 path="${complete%% *}" 45877 tmp="$complete EOL" 45878 arguments="${tmp#* }" 45879 45880 # Cannot rely on the command "which" here since it doesn't always work. 45881 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45882 if test -z "$is_absolute_path"; then 45883 # Path to executable is not absolute. Find it. 45884 IFS_save="$IFS" 45885 IFS=: 45886 for p in $PATH; do 45887 if test -f "$p/$path" && test -x "$p/$path"; then 45888 new_path="$p/$path" 45889 break 45890 fi 45891 done 45892 IFS="$IFS_save" 45893 else 45894 # This is an absolute path, we can use it without further modifications. 45895 new_path="$path" 45896 fi 45897 45898 if test "x$new_path" = x; then 45899 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45900 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45901 has_space=`$ECHO "$complete" | $GREP " "` 45902 if test "x$has_space" != x; then 45903 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45904 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45905 fi 45906 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45907 fi 45908 fi 45909 45910 # Now join together the path and the arguments once again 45911 if test "x$arguments" != xEOL; then 45912 new_complete="$new_path ${arguments% *}" 45913 else 45914 new_complete="$new_path" 45915 fi 45916 45917 if test "x$complete" != "x$new_complete"; then 45918 BUILD_CXX="$new_complete" 45919 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 45920 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 45921 fi 45922 fi 45923 45924 45925 45926 # Publish this variable in the help. 45927 45928 45929 if [ -z "${BUILD_NM+x}" ]; then 45930 # The variable is not set by user, try to locate tool using the code snippet 45931 for ac_prog in nm gcc-nm 45932 do 45933 # Extract the first word of "$ac_prog", so it can be a program name with args. 45934 set dummy $ac_prog; ac_word=$2 45935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45936 $as_echo_n "checking for $ac_word... " >&6; } 45937 if ${ac_cv_path_BUILD_NM+:} false; then : 45938 $as_echo_n "(cached) " >&6 45939 else 45940 case $BUILD_NM in 45941 [\\/]* | ?:[\\/]*) 45942 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45943 ;; 45944 *) 45945 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45946 for as_dir in $PATH 45947 do 45948 IFS=$as_save_IFS 45949 test -z "$as_dir" && as_dir=. 45950 for ac_exec_ext in '' $ac_executable_extensions; do 45951 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45952 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45953 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45954 break 2 45955 fi 45956 done 45957 done 45958 IFS=$as_save_IFS 45959 45960 ;; 45961 esac 45962 fi 45963 BUILD_NM=$ac_cv_path_BUILD_NM 45964 if test -n "$BUILD_NM"; then 45965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45966 $as_echo "$BUILD_NM" >&6; } 45967 else 45968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45969 $as_echo "no" >&6; } 45970 fi 45971 45972 45973 test -n "$BUILD_NM" && break 45974 done 45975 45976 else 45977 # The variable is set, but is it from the command line or the environment? 45978 45979 # Try to remove the string !BUILD_NM! from our list. 45980 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 45981 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45982 # If it failed, the variable was not from the command line. Ignore it, 45983 # but warn the user (except for BASH, which is always set by the calling BASH). 45984 if test "xBUILD_NM" != xBASH; then 45985 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 45986 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 45987 fi 45988 # Try to locate tool using the code snippet 45989 for ac_prog in nm gcc-nm 45990 do 45991 # Extract the first word of "$ac_prog", so it can be a program name with args. 45992 set dummy $ac_prog; ac_word=$2 45993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45994 $as_echo_n "checking for $ac_word... " >&6; } 45995 if ${ac_cv_path_BUILD_NM+:} false; then : 45996 $as_echo_n "(cached) " >&6 45997 else 45998 case $BUILD_NM in 45999 [\\/]* | ?:[\\/]*) 46000 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 46001 ;; 46002 *) 46003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46004 for as_dir in $PATH 46005 do 46006 IFS=$as_save_IFS 46007 test -z "$as_dir" && as_dir=. 46008 for ac_exec_ext in '' $ac_executable_extensions; do 46009 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46010 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 46011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46012 break 2 46013 fi 46014 done 46015 done 46016 IFS=$as_save_IFS 46017 46018 ;; 46019 esac 46020 fi 46021 BUILD_NM=$ac_cv_path_BUILD_NM 46022 if test -n "$BUILD_NM"; then 46023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 46024 $as_echo "$BUILD_NM" >&6; } 46025 else 46026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46027 $as_echo "no" >&6; } 46028 fi 46029 46030 46031 test -n "$BUILD_NM" && break 46032 done 46033 46034 else 46035 # If it succeeded, then it was overridden by the user. We will use it 46036 # for the tool. 46037 46038 # First remove it from the list of overridden variables, so we can test 46039 # for unknown variables in the end. 46040 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46041 46042 # Check if we try to supply an empty value 46043 if test "x$BUILD_NM" = x; then 46044 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 46045 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 46046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 46047 $as_echo_n "checking for BUILD_NM... " >&6; } 46048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46049 $as_echo "disabled" >&6; } 46050 else 46051 # Check if the provided tool contains a complete path. 46052 tool_specified="$BUILD_NM" 46053 tool_basename="${tool_specified##*/}" 46054 if test "x$tool_basename" = "x$tool_specified"; then 46055 # A command without a complete path is provided, search $PATH. 46056 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 46057 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 46058 # Extract the first word of "$tool_basename", so it can be a program name with args. 46059 set dummy $tool_basename; ac_word=$2 46060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46061 $as_echo_n "checking for $ac_word... " >&6; } 46062 if ${ac_cv_path_BUILD_NM+:} false; then : 46063 $as_echo_n "(cached) " >&6 46064 else 46065 case $BUILD_NM in 46066 [\\/]* | ?:[\\/]*) 46067 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 46068 ;; 46069 *) 46070 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46071 for as_dir in $PATH 46072 do 46073 IFS=$as_save_IFS 46074 test -z "$as_dir" && as_dir=. 46075 for ac_exec_ext in '' $ac_executable_extensions; do 46076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46077 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 46078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46079 break 2 46080 fi 46081 done 46082 done 46083 IFS=$as_save_IFS 46084 46085 ;; 46086 esac 46087 fi 46088 BUILD_NM=$ac_cv_path_BUILD_NM 46089 if test -n "$BUILD_NM"; then 46090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 46091 $as_echo "$BUILD_NM" >&6; } 46092 else 46093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46094 $as_echo "no" >&6; } 46095 fi 46096 46097 46098 if test "x$BUILD_NM" = x; then 46099 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46100 fi 46101 else 46102 # Otherwise we believe it is a complete path. Use it as it is. 46103 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 46104 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 46105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 46106 $as_echo_n "checking for BUILD_NM... " >&6; } 46107 if test ! -x "$tool_specified"; then 46108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46109 $as_echo "not found" >&6; } 46110 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 46111 fi 46112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46113 $as_echo "$tool_specified" >&6; } 46114 fi 46115 fi 46116 fi 46117 46118 fi 46119 46120 46121 46122 # Only process if variable expands to non-empty 46123 46124 if test "x$BUILD_NM" != x; then 46125 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46126 46127 # First separate the path from the arguments. This will split at the first 46128 # space. 46129 complete="$BUILD_NM" 46130 path="${complete%% *}" 46131 tmp="$complete EOL" 46132 arguments="${tmp#* }" 46133 46134 # Input might be given as Windows format, start by converting to 46135 # unix format. 46136 new_path=`$CYGPATH -u "$path"` 46137 46138 # Now try to locate executable using which 46139 new_path=`$WHICH "$new_path" 2> /dev/null` 46140 # bat and cmd files are not always considered executable in cygwin causing which 46141 # to not find them 46142 if test "x$new_path" = x \ 46143 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46144 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46145 new_path=`$CYGPATH -u "$path"` 46146 fi 46147 if test "x$new_path" = x; then 46148 # Oops. Which didn't find the executable. 46149 # The splitting of arguments from the executable at a space might have been incorrect, 46150 # since paths with space are more likely in Windows. Give it another try with the whole 46151 # argument. 46152 path="$complete" 46153 arguments="EOL" 46154 new_path=`$CYGPATH -u "$path"` 46155 new_path=`$WHICH "$new_path" 2> /dev/null` 46156 # bat and cmd files are not always considered executable in cygwin causing which 46157 # to not find them 46158 if test "x$new_path" = x \ 46159 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46160 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46161 new_path=`$CYGPATH -u "$path"` 46162 fi 46163 if test "x$new_path" = x; then 46164 # It's still not found. Now this is an unrecoverable error. 46165 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 46166 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 46167 has_space=`$ECHO "$complete" | $GREP " "` 46168 if test "x$has_space" != x; then 46169 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46170 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46171 fi 46172 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46173 fi 46174 fi 46175 46176 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46177 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46178 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46179 # "foo.exe" is OK but "foo" is an error. 46180 # 46181 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46182 # It is also a way to make sure we got the proper file name for the real test later on. 46183 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46184 if test "x$test_shortpath" = x; then 46185 # Short path failed, file does not exist as specified. 46186 # Try adding .exe or .cmd 46187 if test -f "${new_path}.exe"; then 46188 input_to_shortpath="${new_path}.exe" 46189 elif test -f "${new_path}.cmd"; then 46190 input_to_shortpath="${new_path}.cmd" 46191 else 46192 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 46193 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 46194 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46195 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46196 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46197 fi 46198 else 46199 input_to_shortpath="$new_path" 46200 fi 46201 46202 # Call helper function which possibly converts this using DOS-style short mode. 46203 # If so, the updated path is stored in $new_path. 46204 new_path="$input_to_shortpath" 46205 46206 input_path="$input_to_shortpath" 46207 # Check if we need to convert this using DOS-style short mode. If the path 46208 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46209 # take no chances and rewrite it. 46210 # Note: m4 eats our [], so we need to use [ and ] instead. 46211 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46212 if test "x$has_forbidden_chars" != x; then 46213 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46214 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46215 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46216 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46217 # Going to short mode and back again did indeed matter. Since short mode is 46218 # case insensitive, let's make it lowercase to improve readability. 46219 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46220 # Now convert it back to Unix-style (cygpath) 46221 input_path=`$CYGPATH -u "$shortmode_path"` 46222 new_path="$input_path" 46223 fi 46224 fi 46225 46226 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46227 if test "x$test_cygdrive_prefix" = x; then 46228 # As a simple fix, exclude /usr/bin since it's not a real path. 46229 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46230 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46231 # a path prefixed by /cygdrive for fixpath to work. 46232 new_path="$CYGWIN_ROOT_PATH$input_path" 46233 fi 46234 fi 46235 46236 # remove trailing .exe if any 46237 new_path="${new_path/%.exe/}" 46238 46239 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46240 46241 # First separate the path from the arguments. This will split at the first 46242 # space. 46243 complete="$BUILD_NM" 46244 path="${complete%% *}" 46245 tmp="$complete EOL" 46246 arguments="${tmp#* }" 46247 46248 # Input might be given as Windows format, start by converting to 46249 # unix format. 46250 new_path="$path" 46251 46252 windows_path="$new_path" 46253 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46254 unix_path=`$CYGPATH -u "$windows_path"` 46255 new_path="$unix_path" 46256 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46257 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46258 new_path="$unix_path" 46259 fi 46260 46261 46262 # Now try to locate executable using which 46263 new_path=`$WHICH "$new_path" 2> /dev/null` 46264 46265 if test "x$new_path" = x; then 46266 # Oops. Which didn't find the executable. 46267 # The splitting of arguments from the executable at a space might have been incorrect, 46268 # since paths with space are more likely in Windows. Give it another try with the whole 46269 # argument. 46270 path="$complete" 46271 arguments="EOL" 46272 new_path="$path" 46273 46274 windows_path="$new_path" 46275 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46276 unix_path=`$CYGPATH -u "$windows_path"` 46277 new_path="$unix_path" 46278 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46279 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46280 new_path="$unix_path" 46281 fi 46282 46283 46284 new_path=`$WHICH "$new_path" 2> /dev/null` 46285 # bat and cmd files are not always considered executable in MSYS causing which 46286 # to not find them 46287 if test "x$new_path" = x \ 46288 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46289 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46290 new_path="$path" 46291 46292 windows_path="$new_path" 46293 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46294 unix_path=`$CYGPATH -u "$windows_path"` 46295 new_path="$unix_path" 46296 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46297 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46298 new_path="$unix_path" 46299 fi 46300 46301 fi 46302 46303 if test "x$new_path" = x; then 46304 # It's still not found. Now this is an unrecoverable error. 46305 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 46306 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 46307 has_space=`$ECHO "$complete" | $GREP " "` 46308 if test "x$has_space" != x; then 46309 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46310 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46311 fi 46312 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46313 fi 46314 fi 46315 46316 # Now new_path has a complete unix path to the binary 46317 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46318 # Keep paths in /bin as-is, but remove trailing .exe if any 46319 new_path="${new_path/%.exe/}" 46320 # Do not save /bin paths to all_fixpath_prefixes! 46321 else 46322 # Not in mixed or Windows style, start by that. 46323 new_path=`cmd //c echo $new_path` 46324 46325 input_path="$new_path" 46326 # Check if we need to convert this using DOS-style short mode. If the path 46327 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46328 # take no chances and rewrite it. 46329 # Note: m4 eats our [], so we need to use [ and ] instead. 46330 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46331 if test "x$has_forbidden_chars" != x; then 46332 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46333 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46334 fi 46335 46336 # Output is in $new_path 46337 46338 windows_path="$new_path" 46339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46340 unix_path=`$CYGPATH -u "$windows_path"` 46341 new_path="$unix_path" 46342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46344 new_path="$unix_path" 46345 fi 46346 46347 # remove trailing .exe if any 46348 new_path="${new_path/%.exe/}" 46349 46350 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46351 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46352 fi 46353 46354 else 46355 # We're on a unix platform. Hooray! :) 46356 # First separate the path from the arguments. This will split at the first 46357 # space. 46358 complete="$BUILD_NM" 46359 path="${complete%% *}" 46360 tmp="$complete EOL" 46361 arguments="${tmp#* }" 46362 46363 # Cannot rely on the command "which" here since it doesn't always work. 46364 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46365 if test -z "$is_absolute_path"; then 46366 # Path to executable is not absolute. Find it. 46367 IFS_save="$IFS" 46368 IFS=: 46369 for p in $PATH; do 46370 if test -f "$p/$path" && test -x "$p/$path"; then 46371 new_path="$p/$path" 46372 break 46373 fi 46374 done 46375 IFS="$IFS_save" 46376 else 46377 # This is an absolute path, we can use it without further modifications. 46378 new_path="$path" 46379 fi 46380 46381 if test "x$new_path" = x; then 46382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 46383 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 46384 has_space=`$ECHO "$complete" | $GREP " "` 46385 if test "x$has_space" != x; then 46386 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46387 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46388 fi 46389 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 46390 fi 46391 fi 46392 46393 # Now join together the path and the arguments once again 46394 if test "x$arguments" != xEOL; then 46395 new_complete="$new_path ${arguments% *}" 46396 else 46397 new_complete="$new_path" 46398 fi 46399 46400 if test "x$complete" != "x$new_complete"; then 46401 BUILD_NM="$new_complete" 46402 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 46403 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 46404 fi 46405 fi 46406 46407 46408 46409 # Publish this variable in the help. 46410 46411 46412 if [ -z "${BUILD_AR+x}" ]; then 46413 # The variable is not set by user, try to locate tool using the code snippet 46414 for ac_prog in ar gcc-ar 46415 do 46416 # Extract the first word of "$ac_prog", so it can be a program name with args. 46417 set dummy $ac_prog; ac_word=$2 46418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46419 $as_echo_n "checking for $ac_word... " >&6; } 46420 if ${ac_cv_path_BUILD_AR+:} false; then : 46421 $as_echo_n "(cached) " >&6 46422 else 46423 case $BUILD_AR in 46424 [\\/]* | ?:[\\/]*) 46425 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46426 ;; 46427 *) 46428 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46429 for as_dir in $PATH 46430 do 46431 IFS=$as_save_IFS 46432 test -z "$as_dir" && as_dir=. 46433 for ac_exec_ext in '' $ac_executable_extensions; do 46434 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46435 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46436 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46437 break 2 46438 fi 46439 done 46440 done 46441 IFS=$as_save_IFS 46442 46443 ;; 46444 esac 46445 fi 46446 BUILD_AR=$ac_cv_path_BUILD_AR 46447 if test -n "$BUILD_AR"; then 46448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46449 $as_echo "$BUILD_AR" >&6; } 46450 else 46451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46452 $as_echo "no" >&6; } 46453 fi 46454 46455 46456 test -n "$BUILD_AR" && break 46457 done 46458 46459 else 46460 # The variable is set, but is it from the command line or the environment? 46461 46462 # Try to remove the string !BUILD_AR! from our list. 46463 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 46464 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46465 # If it failed, the variable was not from the command line. Ignore it, 46466 # but warn the user (except for BASH, which is always set by the calling BASH). 46467 if test "xBUILD_AR" != xBASH; then 46468 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 46469 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 46470 fi 46471 # Try to locate tool using the code snippet 46472 for ac_prog in ar gcc-ar 46473 do 46474 # Extract the first word of "$ac_prog", so it can be a program name with args. 46475 set dummy $ac_prog; ac_word=$2 46476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46477 $as_echo_n "checking for $ac_word... " >&6; } 46478 if ${ac_cv_path_BUILD_AR+:} false; then : 46479 $as_echo_n "(cached) " >&6 46480 else 46481 case $BUILD_AR in 46482 [\\/]* | ?:[\\/]*) 46483 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46484 ;; 46485 *) 46486 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46487 for as_dir in $PATH 46488 do 46489 IFS=$as_save_IFS 46490 test -z "$as_dir" && as_dir=. 46491 for ac_exec_ext in '' $ac_executable_extensions; do 46492 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46493 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46494 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46495 break 2 46496 fi 46497 done 46498 done 46499 IFS=$as_save_IFS 46500 46501 ;; 46502 esac 46503 fi 46504 BUILD_AR=$ac_cv_path_BUILD_AR 46505 if test -n "$BUILD_AR"; then 46506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46507 $as_echo "$BUILD_AR" >&6; } 46508 else 46509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46510 $as_echo "no" >&6; } 46511 fi 46512 46513 46514 test -n "$BUILD_AR" && break 46515 done 46516 46517 else 46518 # If it succeeded, then it was overridden by the user. We will use it 46519 # for the tool. 46520 46521 # First remove it from the list of overridden variables, so we can test 46522 # for unknown variables in the end. 46523 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46524 46525 # Check if we try to supply an empty value 46526 if test "x$BUILD_AR" = x; then 46527 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 46528 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 46529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 46530 $as_echo_n "checking for BUILD_AR... " >&6; } 46531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46532 $as_echo "disabled" >&6; } 46533 else 46534 # Check if the provided tool contains a complete path. 46535 tool_specified="$BUILD_AR" 46536 tool_basename="${tool_specified##*/}" 46537 if test "x$tool_basename" = "x$tool_specified"; then 46538 # A command without a complete path is provided, search $PATH. 46539 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 46540 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 46541 # Extract the first word of "$tool_basename", so it can be a program name with args. 46542 set dummy $tool_basename; ac_word=$2 46543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46544 $as_echo_n "checking for $ac_word... " >&6; } 46545 if ${ac_cv_path_BUILD_AR+:} false; then : 46546 $as_echo_n "(cached) " >&6 46547 else 46548 case $BUILD_AR in 46549 [\\/]* | ?:[\\/]*) 46550 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46551 ;; 46552 *) 46553 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46554 for as_dir in $PATH 46555 do 46556 IFS=$as_save_IFS 46557 test -z "$as_dir" && as_dir=. 46558 for ac_exec_ext in '' $ac_executable_extensions; do 46559 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46560 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46561 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46562 break 2 46563 fi 46564 done 46565 done 46566 IFS=$as_save_IFS 46567 46568 ;; 46569 esac 46570 fi 46571 BUILD_AR=$ac_cv_path_BUILD_AR 46572 if test -n "$BUILD_AR"; then 46573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46574 $as_echo "$BUILD_AR" >&6; } 46575 else 46576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46577 $as_echo "no" >&6; } 46578 fi 46579 46580 46581 if test "x$BUILD_AR" = x; then 46582 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46583 fi 46584 else 46585 # Otherwise we believe it is a complete path. Use it as it is. 46586 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 46587 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 46588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 46589 $as_echo_n "checking for BUILD_AR... " >&6; } 46590 if test ! -x "$tool_specified"; then 46591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46592 $as_echo "not found" >&6; } 46593 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 46594 fi 46595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46596 $as_echo "$tool_specified" >&6; } 46597 fi 46598 fi 46599 fi 46600 46601 fi 46602 46603 46604 46605 # Only process if variable expands to non-empty 46606 46607 if test "x$BUILD_AR" != x; then 46608 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46609 46610 # First separate the path from the arguments. This will split at the first 46611 # space. 46612 complete="$BUILD_AR" 46613 path="${complete%% *}" 46614 tmp="$complete EOL" 46615 arguments="${tmp#* }" 46616 46617 # Input might be given as Windows format, start by converting to 46618 # unix format. 46619 new_path=`$CYGPATH -u "$path"` 46620 46621 # Now try to locate executable using which 46622 new_path=`$WHICH "$new_path" 2> /dev/null` 46623 # bat and cmd files are not always considered executable in cygwin causing which 46624 # to not find them 46625 if test "x$new_path" = x \ 46626 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46627 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46628 new_path=`$CYGPATH -u "$path"` 46629 fi 46630 if test "x$new_path" = x; then 46631 # Oops. Which didn't find the executable. 46632 # The splitting of arguments from the executable at a space might have been incorrect, 46633 # since paths with space are more likely in Windows. Give it another try with the whole 46634 # argument. 46635 path="$complete" 46636 arguments="EOL" 46637 new_path=`$CYGPATH -u "$path"` 46638 new_path=`$WHICH "$new_path" 2> /dev/null` 46639 # bat and cmd files are not always considered executable in cygwin causing which 46640 # to not find them 46641 if test "x$new_path" = x \ 46642 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46643 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46644 new_path=`$CYGPATH -u "$path"` 46645 fi 46646 if test "x$new_path" = x; then 46647 # It's still not found. Now this is an unrecoverable error. 46648 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46649 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46650 has_space=`$ECHO "$complete" | $GREP " "` 46651 if test "x$has_space" != x; then 46652 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46653 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46654 fi 46655 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46656 fi 46657 fi 46658 46659 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46660 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46661 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46662 # "foo.exe" is OK but "foo" is an error. 46663 # 46664 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46665 # It is also a way to make sure we got the proper file name for the real test later on. 46666 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46667 if test "x$test_shortpath" = x; then 46668 # Short path failed, file does not exist as specified. 46669 # Try adding .exe or .cmd 46670 if test -f "${new_path}.exe"; then 46671 input_to_shortpath="${new_path}.exe" 46672 elif test -f "${new_path}.cmd"; then 46673 input_to_shortpath="${new_path}.cmd" 46674 else 46675 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 46676 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 46677 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46678 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46679 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46680 fi 46681 else 46682 input_to_shortpath="$new_path" 46683 fi 46684 46685 # Call helper function which possibly converts this using DOS-style short mode. 46686 # If so, the updated path is stored in $new_path. 46687 new_path="$input_to_shortpath" 46688 46689 input_path="$input_to_shortpath" 46690 # Check if we need to convert this using DOS-style short mode. If the path 46691 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46692 # take no chances and rewrite it. 46693 # Note: m4 eats our [], so we need to use [ and ] instead. 46694 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46695 if test "x$has_forbidden_chars" != x; then 46696 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46697 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46698 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46699 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46700 # Going to short mode and back again did indeed matter. Since short mode is 46701 # case insensitive, let's make it lowercase to improve readability. 46702 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46703 # Now convert it back to Unix-style (cygpath) 46704 input_path=`$CYGPATH -u "$shortmode_path"` 46705 new_path="$input_path" 46706 fi 46707 fi 46708 46709 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46710 if test "x$test_cygdrive_prefix" = x; then 46711 # As a simple fix, exclude /usr/bin since it's not a real path. 46712 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46713 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46714 # a path prefixed by /cygdrive for fixpath to work. 46715 new_path="$CYGWIN_ROOT_PATH$input_path" 46716 fi 46717 fi 46718 46719 # remove trailing .exe if any 46720 new_path="${new_path/%.exe/}" 46721 46722 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46723 46724 # First separate the path from the arguments. This will split at the first 46725 # space. 46726 complete="$BUILD_AR" 46727 path="${complete%% *}" 46728 tmp="$complete EOL" 46729 arguments="${tmp#* }" 46730 46731 # Input might be given as Windows format, start by converting to 46732 # unix format. 46733 new_path="$path" 46734 46735 windows_path="$new_path" 46736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46737 unix_path=`$CYGPATH -u "$windows_path"` 46738 new_path="$unix_path" 46739 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46740 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46741 new_path="$unix_path" 46742 fi 46743 46744 46745 # Now try to locate executable using which 46746 new_path=`$WHICH "$new_path" 2> /dev/null` 46747 46748 if test "x$new_path" = x; then 46749 # Oops. Which didn't find the executable. 46750 # The splitting of arguments from the executable at a space might have been incorrect, 46751 # since paths with space are more likely in Windows. Give it another try with the whole 46752 # argument. 46753 path="$complete" 46754 arguments="EOL" 46755 new_path="$path" 46756 46757 windows_path="$new_path" 46758 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46759 unix_path=`$CYGPATH -u "$windows_path"` 46760 new_path="$unix_path" 46761 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46762 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46763 new_path="$unix_path" 46764 fi 46765 46766 46767 new_path=`$WHICH "$new_path" 2> /dev/null` 46768 # bat and cmd files are not always considered executable in MSYS causing which 46769 # to not find them 46770 if test "x$new_path" = x \ 46771 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46772 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46773 new_path="$path" 46774 46775 windows_path="$new_path" 46776 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46777 unix_path=`$CYGPATH -u "$windows_path"` 46778 new_path="$unix_path" 46779 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46780 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46781 new_path="$unix_path" 46782 fi 46783 46784 fi 46785 46786 if test "x$new_path" = x; then 46787 # It's still not found. Now this is an unrecoverable error. 46788 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46789 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46790 has_space=`$ECHO "$complete" | $GREP " "` 46791 if test "x$has_space" != x; then 46792 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46793 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46794 fi 46795 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46796 fi 46797 fi 46798 46799 # Now new_path has a complete unix path to the binary 46800 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46801 # Keep paths in /bin as-is, but remove trailing .exe if any 46802 new_path="${new_path/%.exe/}" 46803 # Do not save /bin paths to all_fixpath_prefixes! 46804 else 46805 # Not in mixed or Windows style, start by that. 46806 new_path=`cmd //c echo $new_path` 46807 46808 input_path="$new_path" 46809 # Check if we need to convert this using DOS-style short mode. If the path 46810 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46811 # take no chances and rewrite it. 46812 # Note: m4 eats our [], so we need to use [ and ] instead. 46813 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46814 if test "x$has_forbidden_chars" != x; then 46815 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46816 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46817 fi 46818 46819 # Output is in $new_path 46820 46821 windows_path="$new_path" 46822 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46823 unix_path=`$CYGPATH -u "$windows_path"` 46824 new_path="$unix_path" 46825 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46826 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46827 new_path="$unix_path" 46828 fi 46829 46830 # remove trailing .exe if any 46831 new_path="${new_path/%.exe/}" 46832 46833 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46834 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46835 fi 46836 46837 else 46838 # We're on a unix platform. Hooray! :) 46839 # First separate the path from the arguments. This will split at the first 46840 # space. 46841 complete="$BUILD_AR" 46842 path="${complete%% *}" 46843 tmp="$complete EOL" 46844 arguments="${tmp#* }" 46845 46846 # Cannot rely on the command "which" here since it doesn't always work. 46847 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46848 if test -z "$is_absolute_path"; then 46849 # Path to executable is not absolute. Find it. 46850 IFS_save="$IFS" 46851 IFS=: 46852 for p in $PATH; do 46853 if test -f "$p/$path" && test -x "$p/$path"; then 46854 new_path="$p/$path" 46855 break 46856 fi 46857 done 46858 IFS="$IFS_save" 46859 else 46860 # This is an absolute path, we can use it without further modifications. 46861 new_path="$path" 46862 fi 46863 46864 if test "x$new_path" = x; then 46865 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46866 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46867 has_space=`$ECHO "$complete" | $GREP " "` 46868 if test "x$has_space" != x; then 46869 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46870 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46871 fi 46872 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46873 fi 46874 fi 46875 46876 # Now join together the path and the arguments once again 46877 if test "x$arguments" != xEOL; then 46878 new_complete="$new_path ${arguments% *}" 46879 else 46880 new_complete="$new_path" 46881 fi 46882 46883 if test "x$complete" != "x$new_complete"; then 46884 BUILD_AR="$new_complete" 46885 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 46886 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 46887 fi 46888 fi 46889 46890 46891 46892 # Publish this variable in the help. 46893 46894 46895 if [ -z "${BUILD_OBJCOPY+x}" ]; then 46896 # The variable is not set by user, try to locate tool using the code snippet 46897 for ac_prog in objcopy 46898 do 46899 # Extract the first word of "$ac_prog", so it can be a program name with args. 46900 set dummy $ac_prog; ac_word=$2 46901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46902 $as_echo_n "checking for $ac_word... " >&6; } 46903 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46904 $as_echo_n "(cached) " >&6 46905 else 46906 case $BUILD_OBJCOPY in 46907 [\\/]* | ?:[\\/]*) 46908 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46909 ;; 46910 *) 46911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46912 for as_dir in $PATH 46913 do 46914 IFS=$as_save_IFS 46915 test -z "$as_dir" && as_dir=. 46916 for ac_exec_ext in '' $ac_executable_extensions; do 46917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46918 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46920 break 2 46921 fi 46922 done 46923 done 46924 IFS=$as_save_IFS 46925 46926 ;; 46927 esac 46928 fi 46929 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46930 if test -n "$BUILD_OBJCOPY"; then 46931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46932 $as_echo "$BUILD_OBJCOPY" >&6; } 46933 else 46934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46935 $as_echo "no" >&6; } 46936 fi 46937 46938 46939 test -n "$BUILD_OBJCOPY" && break 46940 done 46941 46942 else 46943 # The variable is set, but is it from the command line or the environment? 46944 46945 # Try to remove the string !BUILD_OBJCOPY! from our list. 46946 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 46947 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46948 # If it failed, the variable was not from the command line. Ignore it, 46949 # but warn the user (except for BASH, which is always set by the calling BASH). 46950 if test "xBUILD_OBJCOPY" != xBASH; then 46951 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 46952 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 46953 fi 46954 # Try to locate tool using the code snippet 46955 for ac_prog in objcopy 46956 do 46957 # Extract the first word of "$ac_prog", so it can be a program name with args. 46958 set dummy $ac_prog; ac_word=$2 46959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46960 $as_echo_n "checking for $ac_word... " >&6; } 46961 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46962 $as_echo_n "(cached) " >&6 46963 else 46964 case $BUILD_OBJCOPY in 46965 [\\/]* | ?:[\\/]*) 46966 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46967 ;; 46968 *) 46969 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46970 for as_dir in $PATH 46971 do 46972 IFS=$as_save_IFS 46973 test -z "$as_dir" && as_dir=. 46974 for ac_exec_ext in '' $ac_executable_extensions; do 46975 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46976 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46977 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46978 break 2 46979 fi 46980 done 46981 done 46982 IFS=$as_save_IFS 46983 46984 ;; 46985 esac 46986 fi 46987 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46988 if test -n "$BUILD_OBJCOPY"; then 46989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46990 $as_echo "$BUILD_OBJCOPY" >&6; } 46991 else 46992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46993 $as_echo "no" >&6; } 46994 fi 46995 46996 46997 test -n "$BUILD_OBJCOPY" && break 46998 done 46999 47000 else 47001 # If it succeeded, then it was overridden by the user. We will use it 47002 # for the tool. 47003 47004 # First remove it from the list of overridden variables, so we can test 47005 # for unknown variables in the end. 47006 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47007 47008 # Check if we try to supply an empty value 47009 if test "x$BUILD_OBJCOPY" = x; then 47010 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 47011 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 47012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 47013 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 47014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47015 $as_echo "disabled" >&6; } 47016 else 47017 # Check if the provided tool contains a complete path. 47018 tool_specified="$BUILD_OBJCOPY" 47019 tool_basename="${tool_specified##*/}" 47020 if test "x$tool_basename" = "x$tool_specified"; then 47021 # A command without a complete path is provided, search $PATH. 47022 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 47023 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 47024 # Extract the first word of "$tool_basename", so it can be a program name with args. 47025 set dummy $tool_basename; ac_word=$2 47026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47027 $as_echo_n "checking for $ac_word... " >&6; } 47028 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 47029 $as_echo_n "(cached) " >&6 47030 else 47031 case $BUILD_OBJCOPY in 47032 [\\/]* | ?:[\\/]*) 47033 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 47034 ;; 47035 *) 47036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47037 for as_dir in $PATH 47038 do 47039 IFS=$as_save_IFS 47040 test -z "$as_dir" && as_dir=. 47041 for ac_exec_ext in '' $ac_executable_extensions; do 47042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47043 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 47044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47045 break 2 47046 fi 47047 done 47048 done 47049 IFS=$as_save_IFS 47050 47051 ;; 47052 esac 47053 fi 47054 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 47055 if test -n "$BUILD_OBJCOPY"; then 47056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 47057 $as_echo "$BUILD_OBJCOPY" >&6; } 47058 else 47059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47060 $as_echo "no" >&6; } 47061 fi 47062 47063 47064 if test "x$BUILD_OBJCOPY" = x; then 47065 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47066 fi 47067 else 47068 # Otherwise we believe it is a complete path. Use it as it is. 47069 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 47070 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 47071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 47072 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 47073 if test ! -x "$tool_specified"; then 47074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47075 $as_echo "not found" >&6; } 47076 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 47077 fi 47078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47079 $as_echo "$tool_specified" >&6; } 47080 fi 47081 fi 47082 fi 47083 47084 fi 47085 47086 47087 47088 # Only process if variable expands to non-empty 47089 47090 if test "x$BUILD_OBJCOPY" != x; then 47091 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47092 47093 # First separate the path from the arguments. This will split at the first 47094 # space. 47095 complete="$BUILD_OBJCOPY" 47096 path="${complete%% *}" 47097 tmp="$complete EOL" 47098 arguments="${tmp#* }" 47099 47100 # Input might be given as Windows format, start by converting to 47101 # unix format. 47102 new_path=`$CYGPATH -u "$path"` 47103 47104 # Now try to locate executable using which 47105 new_path=`$WHICH "$new_path" 2> /dev/null` 47106 # bat and cmd files are not always considered executable in cygwin causing which 47107 # to not find them 47108 if test "x$new_path" = x \ 47109 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47110 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47111 new_path=`$CYGPATH -u "$path"` 47112 fi 47113 if test "x$new_path" = x; then 47114 # Oops. Which didn't find the executable. 47115 # The splitting of arguments from the executable at a space might have been incorrect, 47116 # since paths with space are more likely in Windows. Give it another try with the whole 47117 # argument. 47118 path="$complete" 47119 arguments="EOL" 47120 new_path=`$CYGPATH -u "$path"` 47121 new_path=`$WHICH "$new_path" 2> /dev/null` 47122 # bat and cmd files are not always considered executable in cygwin causing which 47123 # to not find them 47124 if test "x$new_path" = x \ 47125 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47126 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47127 new_path=`$CYGPATH -u "$path"` 47128 fi 47129 if test "x$new_path" = x; then 47130 # It's still not found. Now this is an unrecoverable error. 47131 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 47132 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 47133 has_space=`$ECHO "$complete" | $GREP " "` 47134 if test "x$has_space" != x; then 47135 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47136 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47137 fi 47138 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47139 fi 47140 fi 47141 47142 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47143 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47144 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47145 # "foo.exe" is OK but "foo" is an error. 47146 # 47147 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47148 # It is also a way to make sure we got the proper file name for the real test later on. 47149 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47150 if test "x$test_shortpath" = x; then 47151 # Short path failed, file does not exist as specified. 47152 # Try adding .exe or .cmd 47153 if test -f "${new_path}.exe"; then 47154 input_to_shortpath="${new_path}.exe" 47155 elif test -f "${new_path}.cmd"; then 47156 input_to_shortpath="${new_path}.cmd" 47157 else 47158 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 47159 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 47160 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47161 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47162 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47163 fi 47164 else 47165 input_to_shortpath="$new_path" 47166 fi 47167 47168 # Call helper function which possibly converts this using DOS-style short mode. 47169 # If so, the updated path is stored in $new_path. 47170 new_path="$input_to_shortpath" 47171 47172 input_path="$input_to_shortpath" 47173 # Check if we need to convert this using DOS-style short mode. If the path 47174 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47175 # take no chances and rewrite it. 47176 # Note: m4 eats our [], so we need to use [ and ] instead. 47177 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47178 if test "x$has_forbidden_chars" != x; then 47179 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47180 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47181 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47182 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47183 # Going to short mode and back again did indeed matter. Since short mode is 47184 # case insensitive, let's make it lowercase to improve readability. 47185 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47186 # Now convert it back to Unix-style (cygpath) 47187 input_path=`$CYGPATH -u "$shortmode_path"` 47188 new_path="$input_path" 47189 fi 47190 fi 47191 47192 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47193 if test "x$test_cygdrive_prefix" = x; then 47194 # As a simple fix, exclude /usr/bin since it's not a real path. 47195 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47196 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47197 # a path prefixed by /cygdrive for fixpath to work. 47198 new_path="$CYGWIN_ROOT_PATH$input_path" 47199 fi 47200 fi 47201 47202 # remove trailing .exe if any 47203 new_path="${new_path/%.exe/}" 47204 47205 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47206 47207 # First separate the path from the arguments. This will split at the first 47208 # space. 47209 complete="$BUILD_OBJCOPY" 47210 path="${complete%% *}" 47211 tmp="$complete EOL" 47212 arguments="${tmp#* }" 47213 47214 # Input might be given as Windows format, start by converting to 47215 # unix format. 47216 new_path="$path" 47217 47218 windows_path="$new_path" 47219 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47220 unix_path=`$CYGPATH -u "$windows_path"` 47221 new_path="$unix_path" 47222 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47223 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47224 new_path="$unix_path" 47225 fi 47226 47227 47228 # Now try to locate executable using which 47229 new_path=`$WHICH "$new_path" 2> /dev/null` 47230 47231 if test "x$new_path" = x; then 47232 # Oops. Which didn't find the executable. 47233 # The splitting of arguments from the executable at a space might have been incorrect, 47234 # since paths with space are more likely in Windows. Give it another try with the whole 47235 # argument. 47236 path="$complete" 47237 arguments="EOL" 47238 new_path="$path" 47239 47240 windows_path="$new_path" 47241 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47242 unix_path=`$CYGPATH -u "$windows_path"` 47243 new_path="$unix_path" 47244 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47245 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47246 new_path="$unix_path" 47247 fi 47248 47249 47250 new_path=`$WHICH "$new_path" 2> /dev/null` 47251 # bat and cmd files are not always considered executable in MSYS causing which 47252 # to not find them 47253 if test "x$new_path" = x \ 47254 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47255 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47256 new_path="$path" 47257 47258 windows_path="$new_path" 47259 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47260 unix_path=`$CYGPATH -u "$windows_path"` 47261 new_path="$unix_path" 47262 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47263 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47264 new_path="$unix_path" 47265 fi 47266 47267 fi 47268 47269 if test "x$new_path" = x; then 47270 # It's still not found. Now this is an unrecoverable error. 47271 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 47272 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 47273 has_space=`$ECHO "$complete" | $GREP " "` 47274 if test "x$has_space" != x; then 47275 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47276 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47277 fi 47278 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47279 fi 47280 fi 47281 47282 # Now new_path has a complete unix path to the binary 47283 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47284 # Keep paths in /bin as-is, but remove trailing .exe if any 47285 new_path="${new_path/%.exe/}" 47286 # Do not save /bin paths to all_fixpath_prefixes! 47287 else 47288 # Not in mixed or Windows style, start by that. 47289 new_path=`cmd //c echo $new_path` 47290 47291 input_path="$new_path" 47292 # Check if we need to convert this using DOS-style short mode. If the path 47293 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47294 # take no chances and rewrite it. 47295 # Note: m4 eats our [], so we need to use [ and ] instead. 47296 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47297 if test "x$has_forbidden_chars" != x; then 47298 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47299 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47300 fi 47301 47302 # Output is in $new_path 47303 47304 windows_path="$new_path" 47305 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47306 unix_path=`$CYGPATH -u "$windows_path"` 47307 new_path="$unix_path" 47308 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47309 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47310 new_path="$unix_path" 47311 fi 47312 47313 # remove trailing .exe if any 47314 new_path="${new_path/%.exe/}" 47315 47316 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47317 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47318 fi 47319 47320 else 47321 # We're on a unix platform. Hooray! :) 47322 # First separate the path from the arguments. This will split at the first 47323 # space. 47324 complete="$BUILD_OBJCOPY" 47325 path="${complete%% *}" 47326 tmp="$complete EOL" 47327 arguments="${tmp#* }" 47328 47329 # Cannot rely on the command "which" here since it doesn't always work. 47330 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47331 if test -z "$is_absolute_path"; then 47332 # Path to executable is not absolute. Find it. 47333 IFS_save="$IFS" 47334 IFS=: 47335 for p in $PATH; do 47336 if test -f "$p/$path" && test -x "$p/$path"; then 47337 new_path="$p/$path" 47338 break 47339 fi 47340 done 47341 IFS="$IFS_save" 47342 else 47343 # This is an absolute path, we can use it without further modifications. 47344 new_path="$path" 47345 fi 47346 47347 if test "x$new_path" = x; then 47348 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 47349 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 47350 has_space=`$ECHO "$complete" | $GREP " "` 47351 if test "x$has_space" != x; then 47352 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47353 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47354 fi 47355 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 47356 fi 47357 fi 47358 47359 # Now join together the path and the arguments once again 47360 if test "x$arguments" != xEOL; then 47361 new_complete="$new_path ${arguments% *}" 47362 else 47363 new_complete="$new_path" 47364 fi 47365 47366 if test "x$complete" != "x$new_complete"; then 47367 BUILD_OBJCOPY="$new_complete" 47368 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 47369 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 47370 fi 47371 fi 47372 47373 47374 47375 # Publish this variable in the help. 47376 47377 47378 if [ -z "${BUILD_STRIP+x}" ]; then 47379 # The variable is not set by user, try to locate tool using the code snippet 47380 for ac_prog in strip 47381 do 47382 # Extract the first word of "$ac_prog", so it can be a program name with args. 47383 set dummy $ac_prog; ac_word=$2 47384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47385 $as_echo_n "checking for $ac_word... " >&6; } 47386 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47387 $as_echo_n "(cached) " >&6 47388 else 47389 case $BUILD_STRIP in 47390 [\\/]* | ?:[\\/]*) 47391 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47392 ;; 47393 *) 47394 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47395 for as_dir in $PATH 47396 do 47397 IFS=$as_save_IFS 47398 test -z "$as_dir" && as_dir=. 47399 for ac_exec_ext in '' $ac_executable_extensions; do 47400 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47401 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47402 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47403 break 2 47404 fi 47405 done 47406 done 47407 IFS=$as_save_IFS 47408 47409 ;; 47410 esac 47411 fi 47412 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47413 if test -n "$BUILD_STRIP"; then 47414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47415 $as_echo "$BUILD_STRIP" >&6; } 47416 else 47417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47418 $as_echo "no" >&6; } 47419 fi 47420 47421 47422 test -n "$BUILD_STRIP" && break 47423 done 47424 47425 else 47426 # The variable is set, but is it from the command line or the environment? 47427 47428 # Try to remove the string !BUILD_STRIP! from our list. 47429 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 47430 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 47431 # If it failed, the variable was not from the command line. Ignore it, 47432 # but warn the user (except for BASH, which is always set by the calling BASH). 47433 if test "xBUILD_STRIP" != xBASH; then 47434 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 47435 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 47436 fi 47437 # Try to locate tool using the code snippet 47438 for ac_prog in strip 47439 do 47440 # Extract the first word of "$ac_prog", so it can be a program name with args. 47441 set dummy $ac_prog; ac_word=$2 47442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47443 $as_echo_n "checking for $ac_word... " >&6; } 47444 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47445 $as_echo_n "(cached) " >&6 47446 else 47447 case $BUILD_STRIP in 47448 [\\/]* | ?:[\\/]*) 47449 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47450 ;; 47451 *) 47452 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47453 for as_dir in $PATH 47454 do 47455 IFS=$as_save_IFS 47456 test -z "$as_dir" && as_dir=. 47457 for ac_exec_ext in '' $ac_executable_extensions; do 47458 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47459 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47460 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47461 break 2 47462 fi 47463 done 47464 done 47465 IFS=$as_save_IFS 47466 47467 ;; 47468 esac 47469 fi 47470 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47471 if test -n "$BUILD_STRIP"; then 47472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47473 $as_echo "$BUILD_STRIP" >&6; } 47474 else 47475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47476 $as_echo "no" >&6; } 47477 fi 47478 47479 47480 test -n "$BUILD_STRIP" && break 47481 done 47482 47483 else 47484 # If it succeeded, then it was overridden by the user. We will use it 47485 # for the tool. 47486 47487 # First remove it from the list of overridden variables, so we can test 47488 # for unknown variables in the end. 47489 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47490 47491 # Check if we try to supply an empty value 47492 if test "x$BUILD_STRIP" = x; then 47493 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 47494 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 47495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 47496 $as_echo_n "checking for BUILD_STRIP... " >&6; } 47497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47498 $as_echo "disabled" >&6; } 47499 else 47500 # Check if the provided tool contains a complete path. 47501 tool_specified="$BUILD_STRIP" 47502 tool_basename="${tool_specified##*/}" 47503 if test "x$tool_basename" = "x$tool_specified"; then 47504 # A command without a complete path is provided, search $PATH. 47505 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 47506 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 47507 # Extract the first word of "$tool_basename", so it can be a program name with args. 47508 set dummy $tool_basename; ac_word=$2 47509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47510 $as_echo_n "checking for $ac_word... " >&6; } 47511 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47512 $as_echo_n "(cached) " >&6 47513 else 47514 case $BUILD_STRIP in 47515 [\\/]* | ?:[\\/]*) 47516 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47517 ;; 47518 *) 47519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47520 for as_dir in $PATH 47521 do 47522 IFS=$as_save_IFS 47523 test -z "$as_dir" && as_dir=. 47524 for ac_exec_ext in '' $ac_executable_extensions; do 47525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47526 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47528 break 2 47529 fi 47530 done 47531 done 47532 IFS=$as_save_IFS 47533 47534 ;; 47535 esac 47536 fi 47537 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47538 if test -n "$BUILD_STRIP"; then 47539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47540 $as_echo "$BUILD_STRIP" >&6; } 47541 else 47542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47543 $as_echo "no" >&6; } 47544 fi 47545 47546 47547 if test "x$BUILD_STRIP" = x; then 47548 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47549 fi 47550 else 47551 # Otherwise we believe it is a complete path. Use it as it is. 47552 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 47553 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 47554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 47555 $as_echo_n "checking for BUILD_STRIP... " >&6; } 47556 if test ! -x "$tool_specified"; then 47557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47558 $as_echo "not found" >&6; } 47559 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 47560 fi 47561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47562 $as_echo "$tool_specified" >&6; } 47563 fi 47564 fi 47565 fi 47566 47567 fi 47568 47569 47570 47571 # Only process if variable expands to non-empty 47572 47573 if test "x$BUILD_STRIP" != x; then 47574 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47575 47576 # First separate the path from the arguments. This will split at the first 47577 # space. 47578 complete="$BUILD_STRIP" 47579 path="${complete%% *}" 47580 tmp="$complete EOL" 47581 arguments="${tmp#* }" 47582 47583 # Input might be given as Windows format, start by converting to 47584 # unix format. 47585 new_path=`$CYGPATH -u "$path"` 47586 47587 # Now try to locate executable using which 47588 new_path=`$WHICH "$new_path" 2> /dev/null` 47589 # bat and cmd files are not always considered executable in cygwin causing which 47590 # to not find them 47591 if test "x$new_path" = x \ 47592 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47593 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47594 new_path=`$CYGPATH -u "$path"` 47595 fi 47596 if test "x$new_path" = x; then 47597 # Oops. Which didn't find the executable. 47598 # The splitting of arguments from the executable at a space might have been incorrect, 47599 # since paths with space are more likely in Windows. Give it another try with the whole 47600 # argument. 47601 path="$complete" 47602 arguments="EOL" 47603 new_path=`$CYGPATH -u "$path"` 47604 new_path=`$WHICH "$new_path" 2> /dev/null` 47605 # bat and cmd files are not always considered executable in cygwin causing which 47606 # to not find them 47607 if test "x$new_path" = x \ 47608 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47609 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47610 new_path=`$CYGPATH -u "$path"` 47611 fi 47612 if test "x$new_path" = x; then 47613 # It's still not found. Now this is an unrecoverable error. 47614 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47615 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47616 has_space=`$ECHO "$complete" | $GREP " "` 47617 if test "x$has_space" != x; then 47618 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47619 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47620 fi 47621 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47622 fi 47623 fi 47624 47625 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47626 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47627 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47628 # "foo.exe" is OK but "foo" is an error. 47629 # 47630 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47631 # It is also a way to make sure we got the proper file name for the real test later on. 47632 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47633 if test "x$test_shortpath" = x; then 47634 # Short path failed, file does not exist as specified. 47635 # Try adding .exe or .cmd 47636 if test -f "${new_path}.exe"; then 47637 input_to_shortpath="${new_path}.exe" 47638 elif test -f "${new_path}.cmd"; then 47639 input_to_shortpath="${new_path}.cmd" 47640 else 47641 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 47642 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 47643 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47644 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47645 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47646 fi 47647 else 47648 input_to_shortpath="$new_path" 47649 fi 47650 47651 # Call helper function which possibly converts this using DOS-style short mode. 47652 # If so, the updated path is stored in $new_path. 47653 new_path="$input_to_shortpath" 47654 47655 input_path="$input_to_shortpath" 47656 # Check if we need to convert this using DOS-style short mode. If the path 47657 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47658 # take no chances and rewrite it. 47659 # Note: m4 eats our [], so we need to use [ and ] instead. 47660 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47661 if test "x$has_forbidden_chars" != x; then 47662 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47663 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47664 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47665 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47666 # Going to short mode and back again did indeed matter. Since short mode is 47667 # case insensitive, let's make it lowercase to improve readability. 47668 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47669 # Now convert it back to Unix-style (cygpath) 47670 input_path=`$CYGPATH -u "$shortmode_path"` 47671 new_path="$input_path" 47672 fi 47673 fi 47674 47675 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47676 if test "x$test_cygdrive_prefix" = x; then 47677 # As a simple fix, exclude /usr/bin since it's not a real path. 47678 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47679 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47680 # a path prefixed by /cygdrive for fixpath to work. 47681 new_path="$CYGWIN_ROOT_PATH$input_path" 47682 fi 47683 fi 47684 47685 # remove trailing .exe if any 47686 new_path="${new_path/%.exe/}" 47687 47688 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47689 47690 # First separate the path from the arguments. This will split at the first 47691 # space. 47692 complete="$BUILD_STRIP" 47693 path="${complete%% *}" 47694 tmp="$complete EOL" 47695 arguments="${tmp#* }" 47696 47697 # Input might be given as Windows format, start by converting to 47698 # unix format. 47699 new_path="$path" 47700 47701 windows_path="$new_path" 47702 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47703 unix_path=`$CYGPATH -u "$windows_path"` 47704 new_path="$unix_path" 47705 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47706 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47707 new_path="$unix_path" 47708 fi 47709 47710 47711 # Now try to locate executable using which 47712 new_path=`$WHICH "$new_path" 2> /dev/null` 47713 47714 if test "x$new_path" = x; then 47715 # Oops. Which didn't find the executable. 47716 # The splitting of arguments from the executable at a space might have been incorrect, 47717 # since paths with space are more likely in Windows. Give it another try with the whole 47718 # argument. 47719 path="$complete" 47720 arguments="EOL" 47721 new_path="$path" 47722 47723 windows_path="$new_path" 47724 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47725 unix_path=`$CYGPATH -u "$windows_path"` 47726 new_path="$unix_path" 47727 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47728 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47729 new_path="$unix_path" 47730 fi 47731 47732 47733 new_path=`$WHICH "$new_path" 2> /dev/null` 47734 # bat and cmd files are not always considered executable in MSYS causing which 47735 # to not find them 47736 if test "x$new_path" = x \ 47737 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47738 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47739 new_path="$path" 47740 47741 windows_path="$new_path" 47742 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47743 unix_path=`$CYGPATH -u "$windows_path"` 47744 new_path="$unix_path" 47745 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47746 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47747 new_path="$unix_path" 47748 fi 47749 47750 fi 47751 47752 if test "x$new_path" = x; then 47753 # It's still not found. Now this is an unrecoverable error. 47754 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47755 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47756 has_space=`$ECHO "$complete" | $GREP " "` 47757 if test "x$has_space" != x; then 47758 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47759 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47760 fi 47761 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47762 fi 47763 fi 47764 47765 # Now new_path has a complete unix path to the binary 47766 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47767 # Keep paths in /bin as-is, but remove trailing .exe if any 47768 new_path="${new_path/%.exe/}" 47769 # Do not save /bin paths to all_fixpath_prefixes! 47770 else 47771 # Not in mixed or Windows style, start by that. 47772 new_path=`cmd //c echo $new_path` 47773 47774 input_path="$new_path" 47775 # Check if we need to convert this using DOS-style short mode. If the path 47776 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47777 # take no chances and rewrite it. 47778 # Note: m4 eats our [], so we need to use [ and ] instead. 47779 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47780 if test "x$has_forbidden_chars" != x; then 47781 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47782 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47783 fi 47784 47785 # Output is in $new_path 47786 47787 windows_path="$new_path" 47788 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47789 unix_path=`$CYGPATH -u "$windows_path"` 47790 new_path="$unix_path" 47791 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47792 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47793 new_path="$unix_path" 47794 fi 47795 47796 # remove trailing .exe if any 47797 new_path="${new_path/%.exe/}" 47798 47799 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47800 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47801 fi 47802 47803 else 47804 # We're on a unix platform. Hooray! :) 47805 # First separate the path from the arguments. This will split at the first 47806 # space. 47807 complete="$BUILD_STRIP" 47808 path="${complete%% *}" 47809 tmp="$complete EOL" 47810 arguments="${tmp#* }" 47811 47812 # Cannot rely on the command "which" here since it doesn't always work. 47813 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47814 if test -z "$is_absolute_path"; then 47815 # Path to executable is not absolute. Find it. 47816 IFS_save="$IFS" 47817 IFS=: 47818 for p in $PATH; do 47819 if test -f "$p/$path" && test -x "$p/$path"; then 47820 new_path="$p/$path" 47821 break 47822 fi 47823 done 47824 IFS="$IFS_save" 47825 else 47826 # This is an absolute path, we can use it without further modifications. 47827 new_path="$path" 47828 fi 47829 47830 if test "x$new_path" = x; then 47831 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47832 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47833 has_space=`$ECHO "$complete" | $GREP " "` 47834 if test "x$has_space" != x; then 47835 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47836 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47837 fi 47838 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47839 fi 47840 fi 47841 47842 # Now join together the path and the arguments once again 47843 if test "x$arguments" != xEOL; then 47844 new_complete="$new_path ${arguments% *}" 47845 else 47846 new_complete="$new_path" 47847 fi 47848 47849 if test "x$complete" != "x$new_complete"; then 47850 BUILD_STRIP="$new_complete" 47851 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 47852 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 47853 fi 47854 fi 47855 47856 # Assume the C compiler is the assembler 47857 BUILD_AS="$BUILD_CC -c" 47858 # Just like for the target compiler, use the compiler as linker 47859 BUILD_LD="$BUILD_CC" 47860 BUILD_LDCXX="$BUILD_CXX" 47861 47862 PATH="$OLDPATH" 47863 47864 47865 COMPILER=$BUILD_CC 47866 COMPILER_NAME=BuildC 47867 47868 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47869 # cc -V output typically looks like 47870 # cc: Sun C 5.12 Linux_i386 2011/11/16 47871 # or 47872 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 47873 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47874 # Check that this is likely to be the Solaris Studio cc. 47875 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 47876 if test $? -ne 0; then 47877 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47878 { $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 47879 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47880 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47881 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47882 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47883 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47884 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47885 fi 47886 # Remove usage instructions (if present), and 47887 # collapse compiler output into a single line 47888 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47889 $SED -e 's/ *[Uu]sage:.*//'` 47890 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47891 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47892 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47893 # xlc -qversion output typically looks like 47894 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47895 # Version: 11.01.0000.0015 47896 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47897 # Check that this is likely to be the IBM XL C compiler. 47898 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47899 if test $? -ne 0; then 47900 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47901 { $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 47902 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47903 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47904 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47905 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47906 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47907 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47908 fi 47909 # Collapse compiler output into a single line 47910 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47911 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47912 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47913 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47914 # There is no specific version flag, but all output starts with a version string. 47915 # First line typically looks something like: 47916 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47917 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47918 # Check that this is likely to be Microsoft CL.EXE. 47919 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47920 if test $? -ne 0; then 47921 { $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 47922 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47923 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47924 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47925 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47926 fi 47927 # Collapse compiler output into a single line 47928 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47929 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47930 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47931 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47932 # gcc --version output typically looks like 47933 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47934 # Copyright (C) 2013 Free Software Foundation, Inc. 47935 # This is free software; see the source for copying conditions. There is NO 47936 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47937 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47938 # Check that this is likely to be GCC. 47939 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47940 if test $? -ne 0; then 47941 { $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 47942 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47943 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47944 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47945 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47946 fi 47947 # Remove Copyright and legalese from version string, and 47948 # collapse into a single line 47949 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47950 $SED -e 's/ *Copyright .*//'` 47951 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47952 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47953 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47954 # clang --version output typically looks like 47955 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47956 # clang version 3.3 (tags/RELEASE_33/final) 47957 # or 47958 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47959 # Target: x86_64-pc-linux-gnu 47960 # Thread model: posix 47961 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47962 # Check that this is likely to be clang 47963 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47964 if test $? -ne 0; then 47965 { $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 47966 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47967 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47968 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47969 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47970 fi 47971 # Collapse compiler output into a single line 47972 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47973 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47974 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47975 else 47976 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47977 fi 47978 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47979 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47980 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47981 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 47982 47983 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47984 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47985 47986 47987 COMPILER=$BUILD_CXX 47988 COMPILER_NAME=BuildC++ 47989 47990 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47991 # cc -V output typically looks like 47992 # cc: Sun C 5.12 Linux_i386 2011/11/16 47993 # or 47994 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 47995 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47996 # Check that this is likely to be the Solaris Studio cc. 47997 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 47998 if test $? -ne 0; then 47999 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48000 { $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 48001 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48002 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48003 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48004 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 48005 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 48006 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48007 fi 48008 # Remove usage instructions (if present), and 48009 # collapse compiler output into a single line 48010 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48011 $SED -e 's/ *[Uu]sage:.*//'` 48012 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48013 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 48014 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 48015 # xlc -qversion output typically looks like 48016 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 48017 # Version: 11.01.0000.0015 48018 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 48019 # Check that this is likely to be the IBM XL C compiler. 48020 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 48021 if test $? -ne 0; then 48022 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48023 { $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 48024 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48025 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48026 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48027 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 48028 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 48029 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48030 fi 48031 # Collapse compiler output into a single line 48032 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48033 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48034 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 48035 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48036 # There is no specific version flag, but all output starts with a version string. 48037 # First line typically looks something like: 48038 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 48039 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 48040 # Check that this is likely to be Microsoft CL.EXE. 48041 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 48042 if test $? -ne 0; then 48043 { $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 48044 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48045 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48046 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48047 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48048 fi 48049 # Collapse compiler output into a single line 48050 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48051 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48052 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 48053 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 48054 # gcc --version output typically looks like 48055 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 48056 # Copyright (C) 2013 Free Software Foundation, Inc. 48057 # This is free software; see the source for copying conditions. There is NO 48058 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 48059 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48060 # Check that this is likely to be GCC. 48061 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 48062 if test $? -ne 0; then 48063 { $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 48064 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48065 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 48066 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 48067 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48068 fi 48069 # Remove Copyright and legalese from version string, and 48070 # collapse into a single line 48071 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48072 $SED -e 's/ *Copyright .*//'` 48073 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48074 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 48075 elif test "x$TOOLCHAIN_TYPE" = xclang; then 48076 # clang --version output typically looks like 48077 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 48078 # clang version 3.3 (tags/RELEASE_33/final) 48079 # or 48080 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 48081 # Target: x86_64-pc-linux-gnu 48082 # Thread model: posix 48083 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 48084 # Check that this is likely to be clang 48085 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 48086 if test $? -ne 0; then 48087 { $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 48088 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 48089 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 48090 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 48091 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 48092 fi 48093 # Collapse compiler output into a single line 48094 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 48095 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 48096 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 48097 else 48098 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 48099 fi 48100 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 48101 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 48102 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 48103 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 48104 48105 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 48106 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 48107 48108 48109 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 48110 { $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 48111 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 48112 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 48113 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 48114 fi 48115 48116 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 48117 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 48118 { $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 48119 $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;} 48120 fi 48121 48122 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 48123 { $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 48124 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 48125 fi 48126 48127 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$BUILD_CC_VERSION_NUMBER"` 48128 48129 else 48130 # If we are not cross compiling, use the normal target compilers for 48131 # building the build platform executables. 48132 BUILD_CC="$CC" 48133 BUILD_CXX="$CXX" 48134 BUILD_LD="$LD" 48135 BUILD_LDCXX="$LDCXX" 48136 BUILD_NM="$NM" 48137 BUILD_AS="$AS" 48138 BUILD_OBJCOPY="$OBJCOPY" 48139 BUILD_STRIP="$STRIP" 48140 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 48141 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 48142 BUILD_AR="$AR" 48143 48144 48145 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 48146 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 48147 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 48148 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 48149 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 48150 fi 48151 48152 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 48153 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 48154 { $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 48155 $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;} 48156 fi 48157 48158 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 48159 { $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 48160 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 48161 fi 48162 48163 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 48164 48165 fi 48166 48167 48168 48169 48170 48171 48172 48173 48174 48175 48176 48177 48178 48179 48180 # The package path is used only on macosx? 48181 # FIXME: clean this up, and/or move it elsewhere. 48182 PACKAGE_PATH=/opt/local 48183 48184 48185 # Check for extra potential brokenness. 48186 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48187 # On Windows, double-check that we got the right compiler. 48188 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 48189 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 48190 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 48191 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 48192 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 48193 fi 48194 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 48195 if test "x$COMPILER_CPU_TEST" != "xx64"; then 48196 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 48197 fi 48198 fi 48199 fi 48200 48201 if test "x$TOOLCHAIN_TYPE" = xgcc; then 48202 # If this is a --hash-style=gnu system, use --hash-style=both, why? 48203 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 48204 # This is later checked when setting flags. 48205 48206 # "-Og" suppported for GCC 4.8 and later 48207 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 48208 48209 48210 48211 48212 48213 48214 48215 48216 48217 48218 48219 48220 48221 48222 48223 48224 48225 48226 48227 48228 48229 48230 48231 48232 48233 48234 48235 48236 48237 48238 48239 48240 48241 48242 48243 48244 48245 48246 48247 48248 48249 48250 48251 48252 48253 48254 48255 # Execute function body 48256 48257 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 # Execute function body 48305 48306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48307 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48308 supports=yes 48309 48310 saved_cflags="$CFLAGS" 48311 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 48312 ac_ext=c 48313 ac_cpp='$CPP $CPPFLAGS' 48314 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48315 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48316 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48317 48318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48319 /* end confdefs.h. */ 48320 int i; 48321 _ACEOF 48322 if ac_fn_c_try_compile "$LINENO"; then : 48323 48324 else 48325 supports=no 48326 fi 48327 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48328 ac_ext=cpp 48329 ac_cpp='$CXXCPP $CPPFLAGS' 48330 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48331 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48332 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48333 48334 CFLAGS="$saved_cflags" 48335 48336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48337 $as_echo "$supports" >&6; } 48338 if test "x$supports" = "xyes" ; then 48339 : 48340 C_COMP_SUPPORTS="yes" 48341 else 48342 : 48343 C_COMP_SUPPORTS="no" 48344 fi 48345 48346 48347 48348 48349 48350 48351 48352 48353 48354 48355 48356 48357 48358 48359 48360 48361 48362 48363 48364 48365 48366 48367 48368 48369 48370 48371 48372 48373 48374 48375 48376 48377 48378 48379 48380 48381 48382 48383 48384 48385 48386 48387 48388 48389 48390 48391 48392 48393 48394 48395 48396 48397 48398 48399 48400 48401 48402 48403 48404 # Execute function body 48405 48406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48407 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48408 supports=yes 48409 48410 saved_cxxflags="$CXXFLAGS" 48411 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 48412 ac_ext=cpp 48413 ac_cpp='$CXXCPP $CPPFLAGS' 48414 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48415 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48416 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48417 48418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48419 /* end confdefs.h. */ 48420 int i; 48421 _ACEOF 48422 if ac_fn_cxx_try_compile "$LINENO"; then : 48423 48424 else 48425 supports=no 48426 fi 48427 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48428 ac_ext=cpp 48429 ac_cpp='$CXXCPP $CPPFLAGS' 48430 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48431 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48432 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48433 48434 CXXFLAGS="$saved_cxxflags" 48435 48436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48437 $as_echo "$supports" >&6; } 48438 if test "x$supports" = "xyes" ; then 48439 : 48440 CXX_COMP_SUPPORTS="yes" 48441 else 48442 : 48443 CXX_COMP_SUPPORTS="no" 48444 fi 48445 48446 48447 48448 48449 48450 48451 48452 48453 48454 48455 48456 48457 48458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48459 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48460 supports=no 48461 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 48462 48463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48464 $as_echo "$supports" >&6; } 48465 if test "x$supports" = "xyes" ; then 48466 : 48467 HAS_CFLAG_OPTIMIZE_DEBUG=true 48468 else 48469 : 48470 HAS_CFLAG_OPTIMIZE_DEBUG=false 48471 fi 48472 48473 48474 48475 48476 48477 48478 48479 # "-z relro" supported in GNU binutils 2.17 and later 48480 LINKER_RELRO_FLAG="-Wl,-z,relro" 48481 48482 48483 48484 48485 48486 48487 48488 48489 48490 48491 48492 48493 48494 48495 48496 48497 48498 48499 48500 48501 48502 48503 48504 48505 48506 48507 48508 48509 48510 48511 48512 48513 48514 48515 48516 48517 48518 48519 48520 48521 48522 48523 48524 48525 48526 48527 48528 # Execute function body 48529 48530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 48531 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 48532 supports=yes 48533 48534 saved_ldflags="$LDFLAGS" 48535 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 48536 ac_ext=c 48537 ac_cpp='$CPP $CPPFLAGS' 48538 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48539 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48540 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48541 48542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48543 /* end confdefs.h. */ 48544 48545 int 48546 main () 48547 { 48548 48549 ; 48550 return 0; 48551 } 48552 _ACEOF 48553 if ac_fn_c_try_link "$LINENO"; then : 48554 48555 else 48556 supports=no 48557 fi 48558 rm -f core conftest.err conftest.$ac_objext \ 48559 conftest$ac_exeext conftest.$ac_ext 48560 ac_ext=cpp 48561 ac_cpp='$CXXCPP $CPPFLAGS' 48562 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48563 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48564 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48565 48566 LDFLAGS="$saved_ldflags" 48567 48568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48569 $as_echo "$supports" >&6; } 48570 if test "x$supports" = "xyes" ; then 48571 : 48572 HAS_LINKER_RELRO=true 48573 else 48574 : 48575 HAS_LINKER_RELRO=false 48576 fi 48577 48578 48579 48580 48581 48582 48583 48584 48585 48586 48587 48588 48589 48590 # "-z now" supported in GNU binutils 2.11 and later 48591 LINKER_NOW_FLAG="-Wl,-z,now" 48592 48593 48594 48595 48596 48597 48598 48599 48600 48601 48602 48603 48604 48605 48606 48607 48608 48609 48610 48611 48612 48613 48614 48615 48616 48617 48618 48619 48620 48621 48622 48623 48624 48625 48626 48627 48628 48629 48630 48631 48632 48633 48634 48635 48636 48637 48638 48639 # Execute function body 48640 48641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 48642 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 48643 supports=yes 48644 48645 saved_ldflags="$LDFLAGS" 48646 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 48647 ac_ext=c 48648 ac_cpp='$CPP $CPPFLAGS' 48649 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48650 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48651 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48652 48653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48654 /* end confdefs.h. */ 48655 48656 int 48657 main () 48658 { 48659 48660 ; 48661 return 0; 48662 } 48663 _ACEOF 48664 if ac_fn_c_try_link "$LINENO"; then : 48665 48666 else 48667 supports=no 48668 fi 48669 rm -f core conftest.err conftest.$ac_objext \ 48670 conftest$ac_exeext conftest.$ac_ext 48671 ac_ext=cpp 48672 ac_cpp='$CXXCPP $CPPFLAGS' 48673 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48674 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48675 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48676 48677 LDFLAGS="$saved_ldflags" 48678 48679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48680 $as_echo "$supports" >&6; } 48681 if test "x$supports" = "xyes" ; then 48682 : 48683 HAS_LINKER_NOW=true 48684 else 48685 : 48686 HAS_LINKER_NOW=false 48687 fi 48688 48689 48690 48691 48692 48693 48694 48695 48696 48697 48698 48699 48700 fi 48701 48702 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 48703 # in executable.' 48704 USING_BROKEN_SUSE_LD=no 48705 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 48706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 48707 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 48708 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 48709 $ECHO "int main() { }" > main.c 48710 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 48711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48712 $as_echo "no" >&6; } 48713 USING_BROKEN_SUSE_LD=no 48714 else 48715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48716 $as_echo "yes" >&6; } 48717 USING_BROKEN_SUSE_LD=yes 48718 fi 48719 $RM version-script.map main.c a.out 48720 fi 48721 48722 48723 # Setup hotspot lecagy names for toolchains 48724 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 48725 if test "x$TOOLCHAIN_TYPE" = xclang; then 48726 HOTSPOT_TOOLCHAIN_TYPE=gcc 48727 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48728 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 48729 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48730 HOTSPOT_TOOLCHAIN_TYPE=visCPP 48731 fi 48732 48733 48734 48735 # Setup the JTReg Regression Test Harness. 48736 48737 48738 # Check whether --with-jtreg was given. 48739 if test "${with_jtreg+set}" = set; then : 48740 withval=$with_jtreg; 48741 fi 48742 48743 48744 if test "x$with_jtreg" = xno; then 48745 # jtreg disabled 48746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 48747 $as_echo_n "checking for jtreg test harness... " >&6; } 48748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabled" >&5 48749 $as_echo "no, disabled" >&6; } 48750 elif test "x$with_jtreg" != xyes && test "x$with_jtreg" != x; then 48751 # An explicit path is specified, use it. 48752 JT_HOME="$with_jtreg" 48753 if test ! -d "$JT_HOME"; then 48754 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not exist" "$LINENO" 5 48755 fi 48756 48757 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 48758 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg is not a valid jtreg home" "$LINENO" 5 48759 fi 48760 48761 JTREGEXE="$JT_HOME/bin/jtreg" 48762 if test ! -x "$JTREGEXE"; then 48763 as_fn_error $? "jtreg home directory from --with-jtreg=$with_jtreg does not contain valid jtreg executable" "$LINENO" 5 48764 fi 48765 48766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 48767 $as_echo_n "checking for jtreg test harness... " >&6; } 48768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 48769 $as_echo "$JT_HOME" >&6; } 48770 else 48771 # Try to locate jtreg 48772 if test "x$JT_HOME" != x; then 48773 # JT_HOME set in environment, use it 48774 if test ! -d "$JT_HOME"; then 48775 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&5 48776 $as_echo "$as_me: WARNING: Ignoring JT_HOME pointing to invalid directory: $JT_HOME" >&2;} 48777 JT_HOME= 48778 else 48779 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 48780 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&5 48781 $as_echo "$as_me: WARNING: Ignoring JT_HOME which is not a valid jtreg home: $JT_HOME" >&2;} 48782 JT_HOME= 48783 elif test ! -x "$JT_HOME/bin/jtreg"; then 48784 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&5 48785 $as_echo "$as_me: WARNING: Ignoring JT_HOME which does not contain valid jtreg executable: $JT_HOME" >&2;} 48786 JT_HOME= 48787 else 48788 JTREGEXE="$JT_HOME/bin/jtreg" 48789 { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using JT_HOME from environment" >&5 48790 $as_echo "$as_me: Located jtreg using JT_HOME from environment" >&6;} 48791 fi 48792 fi 48793 fi 48794 48795 if test "x$JT_HOME" = x; then 48796 # JT_HOME is not set in environment, or was deemed invalid. 48797 # Try to find jtreg on path 48798 48799 48800 # Publish this variable in the help. 48801 48802 48803 if [ -z "${JTREGEXE+x}" ]; then 48804 # The variable is not set by user, try to locate tool using the code snippet 48805 for ac_prog in jtreg 48806 do 48807 # Extract the first word of "$ac_prog", so it can be a program name with args. 48808 set dummy $ac_prog; ac_word=$2 48809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48810 $as_echo_n "checking for $ac_word... " >&6; } 48811 if ${ac_cv_path_JTREGEXE+:} false; then : 48812 $as_echo_n "(cached) " >&6 48813 else 48814 case $JTREGEXE in 48815 [\\/]* | ?:[\\/]*) 48816 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48817 ;; 48818 *) 48819 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48820 for as_dir in $PATH 48821 do 48822 IFS=$as_save_IFS 48823 test -z "$as_dir" && as_dir=. 48824 for ac_exec_ext in '' $ac_executable_extensions; do 48825 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48826 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48827 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48828 break 2 48829 fi 48830 done 48831 done 48832 IFS=$as_save_IFS 48833 48834 ;; 48835 esac 48836 fi 48837 JTREGEXE=$ac_cv_path_JTREGEXE 48838 if test -n "$JTREGEXE"; then 48839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48840 $as_echo "$JTREGEXE" >&6; } 48841 else 48842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48843 $as_echo "no" >&6; } 48844 fi 48845 48846 48847 test -n "$JTREGEXE" && break 48848 done 48849 48850 else 48851 # The variable is set, but is it from the command line or the environment? 48852 48853 # Try to remove the string !JTREGEXE! from our list. 48854 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 48855 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 48856 # If it failed, the variable was not from the command line. Ignore it, 48857 # but warn the user (except for BASH, which is always set by the calling BASH). 48858 if test "xJTREGEXE" != xBASH; then 48859 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 48860 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 48861 fi 48862 # Try to locate tool using the code snippet 48863 for ac_prog in jtreg 48864 do 48865 # Extract the first word of "$ac_prog", so it can be a program name with args. 48866 set dummy $ac_prog; ac_word=$2 48867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48868 $as_echo_n "checking for $ac_word... " >&6; } 48869 if ${ac_cv_path_JTREGEXE+:} false; then : 48870 $as_echo_n "(cached) " >&6 48871 else 48872 case $JTREGEXE in 48873 [\\/]* | ?:[\\/]*) 48874 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48875 ;; 48876 *) 48877 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48878 for as_dir in $PATH 48879 do 48880 IFS=$as_save_IFS 48881 test -z "$as_dir" && as_dir=. 48882 for ac_exec_ext in '' $ac_executable_extensions; do 48883 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48884 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48885 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48886 break 2 48887 fi 48888 done 48889 done 48890 IFS=$as_save_IFS 48891 48892 ;; 48893 esac 48894 fi 48895 JTREGEXE=$ac_cv_path_JTREGEXE 48896 if test -n "$JTREGEXE"; then 48897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48898 $as_echo "$JTREGEXE" >&6; } 48899 else 48900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48901 $as_echo "no" >&6; } 48902 fi 48903 48904 48905 test -n "$JTREGEXE" && break 48906 done 48907 48908 else 48909 # If it succeeded, then it was overridden by the user. We will use it 48910 # for the tool. 48911 48912 # First remove it from the list of overridden variables, so we can test 48913 # for unknown variables in the end. 48914 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48915 48916 # Check if we try to supply an empty value 48917 if test "x$JTREGEXE" = x; then 48918 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 48919 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 48920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48921 $as_echo_n "checking for JTREGEXE... " >&6; } 48922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48923 $as_echo "disabled" >&6; } 48924 else 48925 # Check if the provided tool contains a complete path. 48926 tool_specified="$JTREGEXE" 48927 tool_basename="${tool_specified##*/}" 48928 if test "x$tool_basename" = "x$tool_specified"; then 48929 # A command without a complete path is provided, search $PATH. 48930 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 48931 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 48932 # Extract the first word of "$tool_basename", so it can be a program name with args. 48933 set dummy $tool_basename; ac_word=$2 48934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48935 $as_echo_n "checking for $ac_word... " >&6; } 48936 if ${ac_cv_path_JTREGEXE+:} false; then : 48937 $as_echo_n "(cached) " >&6 48938 else 48939 case $JTREGEXE in 48940 [\\/]* | ?:[\\/]*) 48941 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48942 ;; 48943 *) 48944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48945 for as_dir in $PATH 48946 do 48947 IFS=$as_save_IFS 48948 test -z "$as_dir" && as_dir=. 48949 for ac_exec_ext in '' $ac_executable_extensions; do 48950 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48951 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48952 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48953 break 2 48954 fi 48955 done 48956 done 48957 IFS=$as_save_IFS 48958 48959 ;; 48960 esac 48961 fi 48962 JTREGEXE=$ac_cv_path_JTREGEXE 48963 if test -n "$JTREGEXE"; then 48964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48965 $as_echo "$JTREGEXE" >&6; } 48966 else 48967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48968 $as_echo "no" >&6; } 48969 fi 48970 48971 48972 if test "x$JTREGEXE" = x; then 48973 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48974 fi 48975 else 48976 # Otherwise we believe it is a complete path. Use it as it is. 48977 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 48978 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 48979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48980 $as_echo_n "checking for JTREGEXE... " >&6; } 48981 if test ! -x "$tool_specified"; then 48982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48983 $as_echo "not found" >&6; } 48984 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 48985 fi 48986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48987 $as_echo "$tool_specified" >&6; } 48988 fi 48989 fi 48990 fi 48991 48992 fi 48993 48994 48995 if test "x$JTREGEXE" != x; then 48996 # That's good, now try to derive JT_HOME 48997 JT_HOME=`(cd $($DIRNAME $JTREGEXE)/.. && pwd)` 48998 if test ! -e "$JT_HOME/lib/jtreg.jar"; then 48999 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&5 49000 $as_echo "$as_me: WARNING: Ignoring jtreg from path since a valid jtreg home cannot be found" >&2;} 49001 JT_HOME= 49002 JTREGEXE= 49003 else 49004 { $as_echo "$as_me:${as_lineno-$LINENO}: Located jtreg using jtreg executable in path" >&5 49005 $as_echo "$as_me: Located jtreg using jtreg executable in path" >&6;} 49006 fi 49007 fi 49008 fi 49009 49010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg test harness" >&5 49011 $as_echo_n "checking for jtreg test harness... " >&6; } 49012 if test "x$JT_HOME" != x; then 49013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JT_HOME" >&5 49014 $as_echo "$JT_HOME" >&6; } 49015 else 49016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found" >&5 49017 $as_echo "no, not found" >&6; } 49018 49019 if test "x$with_jtreg" = xyes; then 49020 as_fn_error $? "--with-jtreg was specified, but no jtreg found." "$LINENO" 5 49021 fi 49022 fi 49023 fi 49024 49025 49026 # Only process if variable expands to non-empty 49027 49028 if test "x$JTREGEXE" != x; then 49029 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49030 49031 # First separate the path from the arguments. This will split at the first 49032 # space. 49033 complete="$JTREGEXE" 49034 path="${complete%% *}" 49035 tmp="$complete EOL" 49036 arguments="${tmp#* }" 49037 49038 # Input might be given as Windows format, start by converting to 49039 # unix format. 49040 new_path=`$CYGPATH -u "$path"` 49041 49042 # Now try to locate executable using which 49043 new_path=`$WHICH "$new_path" 2> /dev/null` 49044 # bat and cmd files are not always considered executable in cygwin causing which 49045 # to not find them 49046 if test "x$new_path" = x \ 49047 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 49048 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 49049 new_path=`$CYGPATH -u "$path"` 49050 fi 49051 if test "x$new_path" = x; then 49052 # Oops. Which didn't find the executable. 49053 # The splitting of arguments from the executable at a space might have been incorrect, 49054 # since paths with space are more likely in Windows. Give it another try with the whole 49055 # argument. 49056 path="$complete" 49057 arguments="EOL" 49058 new_path=`$CYGPATH -u "$path"` 49059 new_path=`$WHICH "$new_path" 2> /dev/null` 49060 # bat and cmd files are not always considered executable in cygwin causing which 49061 # to not find them 49062 if test "x$new_path" = x \ 49063 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 49064 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 49065 new_path=`$CYGPATH -u "$path"` 49066 fi 49067 if test "x$new_path" = x; then 49068 # It's still not found. Now this is an unrecoverable error. 49069 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 49070 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 49071 has_space=`$ECHO "$complete" | $GREP " "` 49072 if test "x$has_space" != x; then 49073 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 49074 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 49075 fi 49076 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49077 fi 49078 fi 49079 49080 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49081 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49082 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49083 # "foo.exe" is OK but "foo" is an error. 49084 # 49085 # This test is therefore slightly more accurate than "test -f" to check for file presence. 49086 # It is also a way to make sure we got the proper file name for the real test later on. 49087 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49088 if test "x$test_shortpath" = x; then 49089 # Short path failed, file does not exist as specified. 49090 # Try adding .exe or .cmd 49091 if test -f "${new_path}.exe"; then 49092 input_to_shortpath="${new_path}.exe" 49093 elif test -f "${new_path}.cmd"; then 49094 input_to_shortpath="${new_path}.cmd" 49095 else 49096 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&5 49097 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$new_path\", is invalid." >&6;} 49098 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 49099 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 49100 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49101 fi 49102 else 49103 input_to_shortpath="$new_path" 49104 fi 49105 49106 # Call helper function which possibly converts this using DOS-style short mode. 49107 # If so, the updated path is stored in $new_path. 49108 new_path="$input_to_shortpath" 49109 49110 input_path="$input_to_shortpath" 49111 # Check if we need to convert this using DOS-style short mode. If the path 49112 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49113 # take no chances and rewrite it. 49114 # Note: m4 eats our [], so we need to use [ and ] instead. 49115 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49116 if test "x$has_forbidden_chars" != x; then 49117 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49118 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49119 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49120 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49121 # Going to short mode and back again did indeed matter. Since short mode is 49122 # case insensitive, let's make it lowercase to improve readability. 49123 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49124 # Now convert it back to Unix-style (cygpath) 49125 input_path=`$CYGPATH -u "$shortmode_path"` 49126 new_path="$input_path" 49127 fi 49128 fi 49129 49130 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49131 if test "x$test_cygdrive_prefix" = x; then 49132 # As a simple fix, exclude /usr/bin since it's not a real path. 49133 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 49134 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49135 # a path prefixed by /cygdrive for fixpath to work. 49136 new_path="$CYGWIN_ROOT_PATH$input_path" 49137 fi 49138 fi 49139 49140 # remove trailing .exe if any 49141 new_path="${new_path/%.exe/}" 49142 49143 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49144 49145 # First separate the path from the arguments. This will split at the first 49146 # space. 49147 complete="$JTREGEXE" 49148 path="${complete%% *}" 49149 tmp="$complete EOL" 49150 arguments="${tmp#* }" 49151 49152 # Input might be given as Windows format, start by converting to 49153 # unix format. 49154 new_path="$path" 49155 49156 windows_path="$new_path" 49157 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49158 unix_path=`$CYGPATH -u "$windows_path"` 49159 new_path="$unix_path" 49160 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49161 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49162 new_path="$unix_path" 49163 fi 49164 49165 49166 # Now try to locate executable using which 49167 new_path=`$WHICH "$new_path" 2> /dev/null` 49168 49169 if test "x$new_path" = x; then 49170 # Oops. Which didn't find the executable. 49171 # The splitting of arguments from the executable at a space might have been incorrect, 49172 # since paths with space are more likely in Windows. Give it another try with the whole 49173 # argument. 49174 path="$complete" 49175 arguments="EOL" 49176 new_path="$path" 49177 49178 windows_path="$new_path" 49179 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49180 unix_path=`$CYGPATH -u "$windows_path"` 49181 new_path="$unix_path" 49182 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49183 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49184 new_path="$unix_path" 49185 fi 49186 49187 49188 new_path=`$WHICH "$new_path" 2> /dev/null` 49189 # bat and cmd files are not always considered executable in MSYS causing which 49190 # to not find them 49191 if test "x$new_path" = x \ 49192 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 49193 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 49194 new_path="$path" 49195 49196 windows_path="$new_path" 49197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49198 unix_path=`$CYGPATH -u "$windows_path"` 49199 new_path="$unix_path" 49200 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49201 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49202 new_path="$unix_path" 49203 fi 49204 49205 fi 49206 49207 if test "x$new_path" = x; then 49208 # It's still not found. Now this is an unrecoverable error. 49209 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 49210 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 49211 has_space=`$ECHO "$complete" | $GREP " "` 49212 if test "x$has_space" != x; then 49213 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 49214 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 49215 fi 49216 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49217 fi 49218 fi 49219 49220 # Now new_path has a complete unix path to the binary 49221 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 49222 # Keep paths in /bin as-is, but remove trailing .exe if any 49223 new_path="${new_path/%.exe/}" 49224 # Do not save /bin paths to all_fixpath_prefixes! 49225 else 49226 # Not in mixed or Windows style, start by that. 49227 new_path=`cmd //c echo $new_path` 49228 49229 input_path="$new_path" 49230 # Check if we need to convert this using DOS-style short mode. If the path 49231 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49232 # take no chances and rewrite it. 49233 # Note: m4 eats our [], so we need to use [ and ] instead. 49234 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49235 if test "x$has_forbidden_chars" != x; then 49236 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49237 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49238 fi 49239 49240 # Output is in $new_path 49241 49242 windows_path="$new_path" 49243 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49244 unix_path=`$CYGPATH -u "$windows_path"` 49245 new_path="$unix_path" 49246 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49247 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49248 new_path="$unix_path" 49249 fi 49250 49251 # remove trailing .exe if any 49252 new_path="${new_path/%.exe/}" 49253 49254 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49255 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49256 fi 49257 49258 else 49259 # We're on a unix platform. Hooray! :) 49260 # First separate the path from the arguments. This will split at the first 49261 # space. 49262 complete="$JTREGEXE" 49263 path="${complete%% *}" 49264 tmp="$complete EOL" 49265 arguments="${tmp#* }" 49266 49267 # Cannot rely on the command "which" here since it doesn't always work. 49268 is_absolute_path=`$ECHO "$path" | $GREP ^/` 49269 if test -z "$is_absolute_path"; then 49270 # Path to executable is not absolute. Find it. 49271 IFS_save="$IFS" 49272 IFS=: 49273 for p in $PATH; do 49274 if test -f "$p/$path" && test -x "$p/$path"; then 49275 new_path="$p/$path" 49276 break 49277 fi 49278 done 49279 IFS="$IFS_save" 49280 else 49281 # This is an absolute path, we can use it without further modifications. 49282 new_path="$path" 49283 fi 49284 49285 if test "x$new_path" = x; then 49286 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&5 49287 $as_echo "$as_me: The path of JTREGEXE, which resolves as \"$complete\", is not found." >&6;} 49288 has_space=`$ECHO "$complete" | $GREP " "` 49289 if test "x$has_space" != x; then 49290 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 49291 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 49292 fi 49293 as_fn_error $? "Cannot locate the the path of JTREGEXE" "$LINENO" 5 49294 fi 49295 fi 49296 49297 # Now join together the path and the arguments once again 49298 if test "x$arguments" != xEOL; then 49299 new_complete="$new_path ${arguments% *}" 49300 else 49301 new_complete="$new_path" 49302 fi 49303 49304 if test "x$complete" != "x$new_complete"; then 49305 JTREGEXE="$new_complete" 49306 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JTREGEXE to \"$new_complete\"" >&5 49307 $as_echo "$as_me: Rewriting JTREGEXE to \"$new_complete\"" >&6;} 49308 fi 49309 fi 49310 49311 49312 # Only process if variable expands to non-empty 49313 49314 if test "x$JT_HOME" != x; then 49315 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49316 49317 # Input might be given as Windows format, start by converting to 49318 # unix format. 49319 path="$JT_HOME" 49320 new_path=`$CYGPATH -u "$path"` 49321 49322 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49323 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49324 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49325 # "foo.exe" is OK but "foo" is an error. 49326 # 49327 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49328 # It is also a way to make sure we got the proper file name for the real test later on. 49329 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49330 if test "x$test_shortpath" = x; then 49331 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 49332 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 49333 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 49334 fi 49335 49336 # Call helper function which possibly converts this using DOS-style short mode. 49337 # If so, the updated path is stored in $new_path. 49338 49339 input_path="$new_path" 49340 # Check if we need to convert this using DOS-style short mode. If the path 49341 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49342 # take no chances and rewrite it. 49343 # Note: m4 eats our [], so we need to use [ and ] instead. 49344 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49345 if test "x$has_forbidden_chars" != x; then 49346 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49347 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49348 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49349 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49350 # Going to short mode and back again did indeed matter. Since short mode is 49351 # case insensitive, let's make it lowercase to improve readability. 49352 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49353 # Now convert it back to Unix-style (cygpath) 49354 input_path=`$CYGPATH -u "$shortmode_path"` 49355 new_path="$input_path" 49356 fi 49357 fi 49358 49359 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49360 if test "x$test_cygdrive_prefix" = x; then 49361 # As a simple fix, exclude /usr/bin since it's not a real path. 49362 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49363 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49364 # a path prefixed by /cygdrive for fixpath to work. 49365 new_path="$CYGWIN_ROOT_PATH$input_path" 49366 fi 49367 fi 49368 49369 49370 if test "x$path" != "x$new_path"; then 49371 JT_HOME="$new_path" 49372 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 49373 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 49374 fi 49375 49376 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49377 49378 path="$JT_HOME" 49379 has_colon=`$ECHO $path | $GREP ^.:` 49380 new_path="$path" 49381 if test "x$has_colon" = x; then 49382 # Not in mixed or Windows style, start by that. 49383 new_path=`cmd //c echo $path` 49384 fi 49385 49386 49387 input_path="$new_path" 49388 # Check if we need to convert this using DOS-style short mode. If the path 49389 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49390 # take no chances and rewrite it. 49391 # Note: m4 eats our [], so we need to use [ and ] instead. 49392 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49393 if test "x$has_forbidden_chars" != x; then 49394 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49395 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49396 fi 49397 49398 49399 windows_path="$new_path" 49400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49401 unix_path=`$CYGPATH -u "$windows_path"` 49402 new_path="$unix_path" 49403 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49404 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49405 new_path="$unix_path" 49406 fi 49407 49408 if test "x$path" != "x$new_path"; then 49409 JT_HOME="$new_path" 49410 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 49411 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 49412 fi 49413 49414 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49415 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49416 49417 else 49418 # We're on a unix platform. Hooray! :) 49419 path="$JT_HOME" 49420 has_space=`$ECHO "$path" | $GREP " "` 49421 if test "x$has_space" != x; then 49422 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 49423 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 49424 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49425 fi 49426 49427 # Use eval to expand a potential ~ 49428 eval path="$path" 49429 if test ! -f "$path" && test ! -d "$path"; then 49430 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 49431 fi 49432 49433 if test -d "$path"; then 49434 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 49435 else 49436 dir="`$DIRNAME "$path"`" 49437 base="`$BASENAME "$path"`" 49438 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 49439 fi 49440 fi 49441 fi 49442 49443 49444 49445 49446 49447 # Setup Jib dependency tool 49448 49449 49450 # Check whether --with-jib was given. 49451 if test "${with_jib+set}" = set; then : 49452 withval=$with_jib; 49453 fi 49454 49455 49456 if test "x$with_jib" = xno || test "x$with_jib" = x; then 49457 # jib disabled 49458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jib" >&5 49459 $as_echo_n "checking for jib... " >&6; } 49460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49461 $as_echo "no" >&6; } 49462 elif test "x$with_jib" = xyes; then 49463 as_fn_error $? "Must supply a value to --with-jib" "$LINENO" 5 49464 else 49465 JIB_HOME="${with_jib}" 49466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jib" >&5 49467 $as_echo_n "checking for jib... " >&6; } 49468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${JIB_HOME}" >&5 49469 $as_echo "${JIB_HOME}" >&6; } 49470 if test ! -d "${JIB_HOME}"; then 49471 as_fn_error $? "--with-jib must be a directory" "$LINENO" 5 49472 fi 49473 JIB_JAR=$(ls ${JIB_HOME}/lib/jib-*.jar) 49474 if test ! -f "${JIB_JAR}"; then 49475 as_fn_error $? "Could not find jib jar file in ${JIB_HOME}" "$LINENO" 5 49476 fi 49477 fi 49478 49479 49480 49481 49482 49483 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 49484 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 49485 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 49486 # commands produced by the link step (currently AIX only) 49487 if test "x$TOOLCHAIN_TYPE" = xxlc; then 49488 COMPILER_TARGET_BITS_FLAG="-q" 49489 COMPILER_COMMAND_FILE_FLAG="-f" 49490 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 49491 else 49492 COMPILER_TARGET_BITS_FLAG="-m" 49493 COMPILER_COMMAND_FILE_FLAG="@" 49494 COMPILER_BINDCMD_FILE_FLAG="" 49495 49496 # The solstudio linker does not support @-files. 49497 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49498 COMPILER_COMMAND_FILE_FLAG= 49499 fi 49500 49501 # Check if @file is supported by gcc 49502 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 49504 $as_echo_n "checking if @file is supported by gcc... " >&6; } 49505 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 49506 $ECHO "" "--version" > command.file 49507 if $CXX @command.file 2>&5 >&5; then 49508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 49509 $as_echo "yes" >&6; } 49510 COMPILER_COMMAND_FILE_FLAG="@" 49511 else 49512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49513 $as_echo "no" >&6; } 49514 COMPILER_COMMAND_FILE_FLAG= 49515 fi 49516 $RM command.file 49517 fi 49518 fi 49519 49520 49521 49522 49523 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 49524 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49525 ARFLAGS="-r" 49526 elif test "x$OPENJDK_TARGET_OS" = xaix; then 49527 ARFLAGS="-X64" 49528 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 49529 # lib.exe is used as AR to create static libraries. 49530 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 49531 else 49532 ARFLAGS="" 49533 fi 49534 49535 49536 ## Setup strip. 49537 # FIXME: should this really be per platform, or should it be per toolchain type? 49538 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 49539 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 49540 if test "x$OPENJDK_TARGET_OS" = xlinux; then 49541 STRIPFLAGS="-g" 49542 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 49543 STRIPFLAGS="-x" 49544 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 49545 STRIPFLAGS="-S" 49546 elif test "x$OPENJDK_TARGET_OS" = xaix; then 49547 STRIPFLAGS="-X32_64" 49548 fi 49549 49550 49551 49552 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49553 CC_OUT_OPTION=-Fo 49554 EXE_OUT_OPTION=-out: 49555 LD_OUT_OPTION=-out: 49556 AR_OUT_OPTION=-out: 49557 else 49558 # The option used to specify the target .o,.a or .so file. 49559 # When compiling, how to specify the to be created object file. 49560 CC_OUT_OPTION='-o$(SPACE)' 49561 # When linking, how to specify the to be created executable. 49562 EXE_OUT_OPTION='-o$(SPACE)' 49563 # When linking, how to specify the to be created dynamically linkable library. 49564 LD_OUT_OPTION='-o$(SPACE)' 49565 # When archiving, how to specify the to be create static archive for object files. 49566 AR_OUT_OPTION='rcs$(SPACE)' 49567 fi 49568 49569 49570 49571 49572 49573 # On Windows, we need to set RC flags. 49574 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49575 RC_FLAGS="-nologo -l0x409" 49576 JVM_RCFLAGS="-nologo" 49577 if test "x$DEBUG_LEVEL" = xrelease; then 49578 RC_FLAGS="$RC_FLAGS -DNDEBUG" 49579 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 49580 fi 49581 49582 # The version variables used to create RC_FLAGS may be overridden 49583 # in a custom configure script, or possibly the command line. 49584 # Let those variables be expanded at make time in spec.gmk. 49585 # The \$ are escaped to the shell, and the $(...) variables 49586 # are evaluated by make. 49587 RC_FLAGS="$RC_FLAGS \ 49588 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 49589 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 49590 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 49591 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 49592 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 49593 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 49594 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 49595 49596 JVM_RCFLAGS="$JVM_RCFLAGS \ 49597 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 49598 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 49599 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 49600 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 49601 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 49602 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 49603 -D\"HS_FNAME=jvm.dll\" \ 49604 -D\"HS_INTERNAL_NAME=jvm\"" 49605 fi 49606 49607 49608 49609 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49610 # silence copyright notice and other headers. 49611 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 49612 fi 49613 49614 49615 # Now we can test some aspects on the target using configure macros. 49616 49617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 49618 $as_echo_n "checking for ANSI C header files... " >&6; } 49619 if ${ac_cv_header_stdc+:} false; then : 49620 $as_echo_n "(cached) " >&6 49621 else 49622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49623 /* end confdefs.h. */ 49624 #include <stdlib.h> 49625 #include <stdarg.h> 49626 #include <string.h> 49627 #include <float.h> 49628 49629 int 49630 main () 49631 { 49632 49633 ; 49634 return 0; 49635 } 49636 _ACEOF 49637 if ac_fn_cxx_try_compile "$LINENO"; then : 49638 ac_cv_header_stdc=yes 49639 else 49640 ac_cv_header_stdc=no 49641 fi 49642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49643 49644 if test $ac_cv_header_stdc = yes; then 49645 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 49646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49647 /* end confdefs.h. */ 49648 #include <string.h> 49649 49650 _ACEOF 49651 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 49652 $EGREP "memchr" >/dev/null 2>&1; then : 49653 49654 else 49655 ac_cv_header_stdc=no 49656 fi 49657 rm -f conftest* 49658 49659 fi 49660 49661 if test $ac_cv_header_stdc = yes; then 49662 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 49663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49664 /* end confdefs.h. */ 49665 #include <stdlib.h> 49666 49667 _ACEOF 49668 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 49669 $EGREP "free" >/dev/null 2>&1; then : 49670 49671 else 49672 ac_cv_header_stdc=no 49673 fi 49674 rm -f conftest* 49675 49676 fi 49677 49678 if test $ac_cv_header_stdc = yes; then 49679 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 49680 if test "$cross_compiling" = yes; then : 49681 : 49682 else 49683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49684 /* end confdefs.h. */ 49685 #include <ctype.h> 49686 #include <stdlib.h> 49687 #if ((' ' & 0x0FF) == 0x020) 49688 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 49689 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 49690 #else 49691 # define ISLOWER(c) \ 49692 (('a' <= (c) && (c) <= 'i') \ 49693 || ('j' <= (c) && (c) <= 'r') \ 49694 || ('s' <= (c) && (c) <= 'z')) 49695 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 49696 #endif 49697 49698 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 49699 int 49700 main () 49701 { 49702 int i; 49703 for (i = 0; i < 256; i++) 49704 if (XOR (islower (i), ISLOWER (i)) 49705 || toupper (i) != TOUPPER (i)) 49706 return 2; 49707 return 0; 49708 } 49709 _ACEOF 49710 if ac_fn_cxx_try_run "$LINENO"; then : 49711 49712 else 49713 ac_cv_header_stdc=no 49714 fi 49715 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 49716 conftest.$ac_objext conftest.beam conftest.$ac_ext 49717 fi 49718 49719 fi 49720 fi 49721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 49722 $as_echo "$ac_cv_header_stdc" >&6; } 49723 if test $ac_cv_header_stdc = yes; then 49724 49725 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 49726 49727 fi 49728 49729 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 49730 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 49731 inttypes.h stdint.h unistd.h 49732 do : 49733 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 49734 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 49735 " 49736 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 49737 cat >>confdefs.h <<_ACEOF 49738 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 49739 _ACEOF 49740 49741 fi 49742 49743 done 49744 49745 49746 49747 ############################################################################### 49748 # 49749 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 49750 # (The JVM can use 32 or 64 bit Java pointers but that decision 49751 # is made at runtime.) 49752 # 49753 49754 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 49755 # Always specify -m flag on Solaris 49756 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 49757 49758 # When we add flags to the "official" CFLAGS etc, we need to 49759 # keep track of these additions in ADDED_CFLAGS etc. These 49760 # will later be checked to make sure only controlled additions 49761 # have been made to CFLAGS etc. 49762 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49763 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49764 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49765 49766 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 49767 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 49768 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 49769 49770 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 49771 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 49772 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 49773 49774 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 49775 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 49776 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 49777 49778 elif test "x$COMPILE_TYPE" = xreduced; then 49779 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 49780 # Specify -m if running reduced on unix platforms 49781 49782 # When we add flags to the "official" CFLAGS etc, we need to 49783 # keep track of these additions in ADDED_CFLAGS etc. These 49784 # will later be checked to make sure only controlled additions 49785 # have been made to CFLAGS etc. 49786 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49787 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49788 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49789 49790 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 49791 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 49792 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 49793 49794 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 49795 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 49796 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 49797 49798 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 49799 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 49800 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 49801 49802 fi 49803 fi 49804 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49805 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49806 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49807 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49808 fi 49809 49810 # Make compilation sanity check 49811 for ac_header in stdio.h 49812 do : 49813 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 49814 if test "x$ac_cv_header_stdio_h" = xyes; then : 49815 cat >>confdefs.h <<_ACEOF 49816 #define HAVE_STDIO_H 1 49817 _ACEOF 49818 49819 else 49820 49821 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 49822 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 49823 if test "x$COMPILE_TYPE" = xreduced; then 49824 49825 # Print a helpful message on how to acquire the necessary build dependency. 49826 # reduced is the help tag: freetype, cups, alsa etc 49827 MISSING_DEPENDENCY=reduced 49828 49829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49830 cygwin_help $MISSING_DEPENDENCY 49831 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49832 msys_help $MISSING_DEPENDENCY 49833 else 49834 PKGHANDLER_COMMAND= 49835 49836 case $PKGHANDLER in 49837 apt-get) 49838 apt_help $MISSING_DEPENDENCY ;; 49839 yum) 49840 yum_help $MISSING_DEPENDENCY ;; 49841 brew) 49842 brew_help $MISSING_DEPENDENCY ;; 49843 port) 49844 port_help $MISSING_DEPENDENCY ;; 49845 pkgutil) 49846 pkgutil_help $MISSING_DEPENDENCY ;; 49847 pkgadd) 49848 pkgadd_help $MISSING_DEPENDENCY ;; 49849 esac 49850 49851 if test "x$PKGHANDLER_COMMAND" != x; then 49852 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 49853 fi 49854 fi 49855 49856 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 49857 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 49858 elif test "x$COMPILE_TYPE" = xcross; then 49859 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 49860 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 49861 fi 49862 as_fn_error $? "Cannot continue." "$LINENO" 5 49863 49864 fi 49865 49866 done 49867 49868 49869 # The cast to long int works around a bug in the HP C Compiler 49870 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 49871 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 49872 # This bug is HP SR number 8606223364. 49873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 49874 $as_echo_n "checking size of int *... " >&6; } 49875 if ${ac_cv_sizeof_int_p+:} false; then : 49876 $as_echo_n "(cached) " >&6 49877 else 49878 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 49879 49880 else 49881 if test "$ac_cv_type_int_p" = yes; then 49882 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 49883 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 49884 as_fn_error 77 "cannot compute sizeof (int *) 49885 See \`config.log' for more details" "$LINENO" 5; } 49886 else 49887 ac_cv_sizeof_int_p=0 49888 fi 49889 fi 49890 49891 fi 49892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 49893 $as_echo "$ac_cv_sizeof_int_p" >&6; } 49894 49895 49896 49897 cat >>confdefs.h <<_ACEOF 49898 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 49899 _ACEOF 49900 49901 49902 49903 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 49904 if test "x$ac_cv_sizeof_int_p" = x; then 49905 # The test failed, lets stick to the assumed value. 49906 { $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 49907 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 49908 else 49909 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 49910 49911 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 49912 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 49913 # Let's try to implicitely set the compilers target architecture and retry the test 49914 { $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 49915 $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;} 49916 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 49917 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 49918 49919 # When we add flags to the "official" CFLAGS etc, we need to 49920 # keep track of these additions in ADDED_CFLAGS etc. These 49921 # will later be checked to make sure only controlled additions 49922 # have been made to CFLAGS etc. 49923 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49924 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49925 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49926 49927 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 49928 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 49929 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 49930 49931 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 49932 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 49933 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 49934 49935 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 49936 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 49937 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 49938 49939 49940 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 49941 unset ac_cv_sizeof_int_p 49942 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 49943 cat >>confdefs.h <<_ACEOF 49944 #undef SIZEOF_INT_P 49945 _ACEOF 49946 49947 # The cast to long int works around a bug in the HP C Compiler 49948 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 49949 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 49950 # This bug is HP SR number 8606223364. 49951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 49952 $as_echo_n "checking size of int *... " >&6; } 49953 if ${ac_cv_sizeof_int_p+:} false; then : 49954 $as_echo_n "(cached) " >&6 49955 else 49956 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 49957 49958 else 49959 if test "$ac_cv_type_int_p" = yes; then 49960 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 49961 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 49962 as_fn_error 77 "cannot compute sizeof (int *) 49963 See \`config.log' for more details" "$LINENO" 5; } 49964 else 49965 ac_cv_sizeof_int_p=0 49966 fi 49967 fi 49968 49969 fi 49970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 49971 $as_echo "$ac_cv_sizeof_int_p" >&6; } 49972 49973 49974 49975 cat >>confdefs.h <<_ACEOF 49976 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 49977 _ACEOF 49978 49979 49980 49981 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 49982 49983 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 49984 { $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 49985 $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;} 49986 if test "x$COMPILE_TYPE" = xreduced; then 49987 49988 # Print a helpful message on how to acquire the necessary build dependency. 49989 # reduced is the help tag: freetype, cups, alsa etc 49990 MISSING_DEPENDENCY=reduced 49991 49992 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49993 cygwin_help $MISSING_DEPENDENCY 49994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49995 msys_help $MISSING_DEPENDENCY 49996 else 49997 PKGHANDLER_COMMAND= 49998 49999 case $PKGHANDLER in 50000 apt-get) 50001 apt_help $MISSING_DEPENDENCY ;; 50002 yum) 50003 yum_help $MISSING_DEPENDENCY ;; 50004 brew) 50005 brew_help $MISSING_DEPENDENCY ;; 50006 port) 50007 port_help $MISSING_DEPENDENCY ;; 50008 pkgutil) 50009 pkgutil_help $MISSING_DEPENDENCY ;; 50010 pkgadd) 50011 pkgadd_help $MISSING_DEPENDENCY ;; 50012 esac 50013 50014 if test "x$PKGHANDLER_COMMAND" != x; then 50015 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 50016 fi 50017 fi 50018 50019 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 50020 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 50021 elif test "x$COMPILE_TYPE" = xcross; then 50022 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 50023 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 50024 fi 50025 as_fn_error $? "Cannot continue." "$LINENO" 5 50026 fi 50027 fi 50028 fi 50029 50030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 50031 $as_echo_n "checking for target address size... " >&6; } 50032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 50033 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 50034 50035 50036 ############################################################################### 50037 # 50038 # Is the target little of big endian? 50039 # 50040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 50041 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 50042 if ${ac_cv_c_bigendian+:} false; then : 50043 $as_echo_n "(cached) " >&6 50044 else 50045 ac_cv_c_bigendian=unknown 50046 # See if we're dealing with a universal compiler. 50047 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50048 /* end confdefs.h. */ 50049 #ifndef __APPLE_CC__ 50050 not a universal capable compiler 50051 #endif 50052 typedef int dummy; 50053 50054 _ACEOF 50055 if ac_fn_cxx_try_compile "$LINENO"; then : 50056 50057 # Check for potential -arch flags. It is not universal unless 50058 # there are at least two -arch flags with different values. 50059 ac_arch= 50060 ac_prev= 50061 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 50062 if test -n "$ac_prev"; then 50063 case $ac_word in 50064 i?86 | x86_64 | ppc | ppc64) 50065 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 50066 ac_arch=$ac_word 50067 else 50068 ac_cv_c_bigendian=universal 50069 break 50070 fi 50071 ;; 50072 esac 50073 ac_prev= 50074 elif test "x$ac_word" = "x-arch"; then 50075 ac_prev=arch 50076 fi 50077 done 50078 fi 50079 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50080 if test $ac_cv_c_bigendian = unknown; then 50081 # See if sys/param.h defines the BYTE_ORDER macro. 50082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50083 /* end confdefs.h. */ 50084 #include <sys/types.h> 50085 #include <sys/param.h> 50086 50087 int 50088 main () 50089 { 50090 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 50091 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 50092 && LITTLE_ENDIAN) 50093 bogus endian macros 50094 #endif 50095 50096 ; 50097 return 0; 50098 } 50099 _ACEOF 50100 if ac_fn_cxx_try_compile "$LINENO"; then : 50101 # It does; now see whether it defined to BIG_ENDIAN or not. 50102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50103 /* end confdefs.h. */ 50104 #include <sys/types.h> 50105 #include <sys/param.h> 50106 50107 int 50108 main () 50109 { 50110 #if BYTE_ORDER != BIG_ENDIAN 50111 not big endian 50112 #endif 50113 50114 ; 50115 return 0; 50116 } 50117 _ACEOF 50118 if ac_fn_cxx_try_compile "$LINENO"; then : 50119 ac_cv_c_bigendian=yes 50120 else 50121 ac_cv_c_bigendian=no 50122 fi 50123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50124 fi 50125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50126 fi 50127 if test $ac_cv_c_bigendian = unknown; then 50128 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 50129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50130 /* end confdefs.h. */ 50131 #include <limits.h> 50132 50133 int 50134 main () 50135 { 50136 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 50137 bogus endian macros 50138 #endif 50139 50140 ; 50141 return 0; 50142 } 50143 _ACEOF 50144 if ac_fn_cxx_try_compile "$LINENO"; then : 50145 # It does; now see whether it defined to _BIG_ENDIAN or not. 50146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50147 /* end confdefs.h. */ 50148 #include <limits.h> 50149 50150 int 50151 main () 50152 { 50153 #ifndef _BIG_ENDIAN 50154 not big endian 50155 #endif 50156 50157 ; 50158 return 0; 50159 } 50160 _ACEOF 50161 if ac_fn_cxx_try_compile "$LINENO"; then : 50162 ac_cv_c_bigendian=yes 50163 else 50164 ac_cv_c_bigendian=no 50165 fi 50166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50167 fi 50168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50169 fi 50170 if test $ac_cv_c_bigendian = unknown; then 50171 # Compile a test program. 50172 if test "$cross_compiling" = yes; then : 50173 # Try to guess by grepping values from an object file. 50174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50175 /* end confdefs.h. */ 50176 short int ascii_mm[] = 50177 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 50178 short int ascii_ii[] = 50179 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 50180 int use_ascii (int i) { 50181 return ascii_mm[i] + ascii_ii[i]; 50182 } 50183 short int ebcdic_ii[] = 50184 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 50185 short int ebcdic_mm[] = 50186 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 50187 int use_ebcdic (int i) { 50188 return ebcdic_mm[i] + ebcdic_ii[i]; 50189 } 50190 extern int foo; 50191 50192 int 50193 main () 50194 { 50195 return use_ascii (foo) == use_ebcdic (foo); 50196 ; 50197 return 0; 50198 } 50199 _ACEOF 50200 if ac_fn_cxx_try_compile "$LINENO"; then : 50201 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 50202 ac_cv_c_bigendian=yes 50203 fi 50204 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 50205 if test "$ac_cv_c_bigendian" = unknown; then 50206 ac_cv_c_bigendian=no 50207 else 50208 # finding both strings is unlikely to happen, but who knows? 50209 ac_cv_c_bigendian=unknown 50210 fi 50211 fi 50212 fi 50213 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50214 else 50215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50216 /* end confdefs.h. */ 50217 $ac_includes_default 50218 int 50219 main () 50220 { 50221 50222 /* Are we little or big endian? From Harbison&Steele. */ 50223 union 50224 { 50225 long int l; 50226 char c[sizeof (long int)]; 50227 } u; 50228 u.l = 1; 50229 return u.c[sizeof (long int) - 1] == 1; 50230 50231 ; 50232 return 0; 50233 } 50234 _ACEOF 50235 if ac_fn_cxx_try_run "$LINENO"; then : 50236 ac_cv_c_bigendian=no 50237 else 50238 ac_cv_c_bigendian=yes 50239 fi 50240 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 50241 conftest.$ac_objext conftest.beam conftest.$ac_ext 50242 fi 50243 50244 fi 50245 fi 50246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 50247 $as_echo "$ac_cv_c_bigendian" >&6; } 50248 case $ac_cv_c_bigendian in #( 50249 yes) 50250 ENDIAN="big";; #( 50251 no) 50252 ENDIAN="little" ;; #( 50253 universal) 50254 ENDIAN="universal_endianness" 50255 ;; #( 50256 *) 50257 ENDIAN="unknown" ;; 50258 esac 50259 50260 50261 if test "x$ENDIAN" = xuniversal_endianness; then 50262 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 50263 fi 50264 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 50265 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 50266 fi 50267 50268 50269 # Configure flags for the tools 50270 50271 ############################################################################### 50272 # 50273 # How to compile shared libraries. 50274 # 50275 50276 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50277 PICFLAG="-fPIC" 50278 C_FLAG_REORDER='' 50279 CXX_FLAG_REORDER='' 50280 50281 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50282 # Linking is different on MacOSX 50283 if test "x$STATIC_BUILD" = xtrue; then 50284 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 50285 else 50286 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 50287 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 50288 fi 50289 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 50290 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 50291 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 50292 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 50293 else 50294 # Default works for linux, might work on other platforms as well. 50295 SHARED_LIBRARY_FLAGS='-shared' 50296 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 50297 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 50298 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 50299 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 50300 fi 50301 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50302 C_FLAG_REORDER='' 50303 CXX_FLAG_REORDER='' 50304 50305 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50306 # Linking is different on MacOSX 50307 PICFLAG='' 50308 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 50309 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 50310 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 50311 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 50312 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 50313 50314 if test "x$STATIC_BUILD" = xfalse; then 50315 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 50316 fi 50317 else 50318 # Default works for linux, might work on other platforms as well. 50319 PICFLAG='-fPIC' 50320 SHARED_LIBRARY_FLAGS='-shared' 50321 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 50322 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 50323 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 50324 50325 # arm specific settings 50326 if test "x$OPENJDK_TARGET_CPU" = "xarm"; then 50327 # '-Wl,-z,origin' isn't used on arm. 50328 SET_SHARED_LIBRARY_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 50329 else 50330 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 50331 fi 50332 50333 fi 50334 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50335 if test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50336 PICFLAG="-xcode=pic32" 50337 else 50338 PICFLAG="-KPIC" 50339 fi 50340 C_FLAG_REORDER='-xF' 50341 CXX_FLAG_REORDER='-xF' 50342 SHARED_LIBRARY_FLAGS="-G" 50343 SET_EXECUTABLE_ORIGIN='-R\$$ORIGIN$1' 50344 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 50345 SET_SHARED_LIBRARY_NAME='-h $1' 50346 SET_SHARED_LIBRARY_MAPFILE='-M$1' 50347 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50348 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 50349 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 50350 # will have to patch this single instruction with a call to some out-of-order code which 50351 # does the load from the TOC. This is of course slow. But in that case we also would have 50352 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 50353 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 50354 # can be patched directly by the linker and does not require a jump to out-of-order code. 50355 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 50356 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 50357 # loads for accessing a global variable). But there are rumors that this may be seen as a 50358 # 'performance feature' because of improved code locality of the symbols used in a 50359 # compilation unit. 50360 PICFLAG="-qpic" 50361 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 50362 C_FLAG_REORDER='' 50363 CXX_FLAG_REORDER='' 50364 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 50365 SET_EXECUTABLE_ORIGIN="" 50366 SET_SHARED_LIBRARY_ORIGIN='' 50367 SET_SHARED_LIBRARY_NAME='' 50368 SET_SHARED_LIBRARY_MAPFILE='' 50369 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50370 PICFLAG="" 50371 C_FLAG_REORDER='' 50372 CXX_FLAG_REORDER='' 50373 SHARED_LIBRARY_FLAGS="-dll" 50374 SET_EXECUTABLE_ORIGIN='' 50375 SET_SHARED_LIBRARY_ORIGIN='' 50376 SET_SHARED_LIBRARY_NAME='' 50377 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 50378 fi 50379 50380 50381 50382 50383 50384 50385 50386 50387 50388 # The (cross) compiler is now configured, we can now test capabilities 50389 # of the target platform. 50390 50391 50392 50393 ############################################################################### 50394 # 50395 # Setup the opt flags for different compilers 50396 # and different operating systems. 50397 # 50398 50399 # FIXME: this was indirectly the old default, but just inherited. 50400 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50401 # C_FLAG_DEPS="-MMD -MF" 50402 # fi 50403 50404 # Generate make dependency files 50405 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50406 C_FLAG_DEPS="-MMD -MF" 50407 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50408 C_FLAG_DEPS="-MMD -MF" 50409 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50410 C_FLAG_DEPS="-xMMD -xMF" 50411 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50412 C_FLAG_DEPS="-qmakedep=gcc -MF" 50413 fi 50414 CXX_FLAG_DEPS="$C_FLAG_DEPS" 50415 50416 50417 50418 # Debug symbols 50419 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50420 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 50421 # reduce from default "-g2" option to save space 50422 CFLAGS_DEBUG_SYMBOLS="-g1" 50423 CXXFLAGS_DEBUG_SYMBOLS="-g1" 50424 else 50425 CFLAGS_DEBUG_SYMBOLS="-g" 50426 CXXFLAGS_DEBUG_SYMBOLS="-g" 50427 fi 50428 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50429 CFLAGS_DEBUG_SYMBOLS="-g" 50430 CXXFLAGS_DEBUG_SYMBOLS="-g" 50431 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50432 CFLAGS_DEBUG_SYMBOLS="-g -xs" 50433 # -g0 enables debug symbols without disabling inlining. 50434 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 50435 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50436 CFLAGS_DEBUG_SYMBOLS="-g" 50437 CXXFLAGS_DEBUG_SYMBOLS="-g" 50438 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50439 CFLAGS_DEBUG_SYMBOLS="-Zi" 50440 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 50441 fi 50442 50443 50444 50445 # Debug symbols for JVM_CFLAGS 50446 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50447 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 50448 if test "x$DEBUG_LEVEL" = xslowdebug; then 50449 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 50450 else 50451 # -g0 does not disable inlining, which -g does. 50452 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 50453 fi 50454 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50455 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 50456 else 50457 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 50458 fi 50459 50460 50461 # bounds, memory and behavior checking options 50462 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50463 case $DEBUG_LEVEL in 50464 release ) 50465 # no adjustment 50466 ;; 50467 fastdebug ) 50468 # no adjustment 50469 ;; 50470 slowdebug ) 50471 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 50472 # get's added conditionally on whether we produce debug symbols or not. 50473 # This is most likely not really correct. 50474 50475 # Add runtime stack smashing and undefined behavior checks. 50476 # Not all versions of gcc support -fstack-protector 50477 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 50478 50479 50480 50481 50482 50483 50484 50485 50486 50487 50488 50489 50490 50491 50492 50493 50494 50495 50496 50497 50498 50499 50500 50501 50502 50503 50504 50505 50506 50507 50508 50509 50510 50511 50512 50513 50514 50515 50516 50517 50518 50519 50520 # Execute function body 50521 50522 50523 50524 50525 50526 50527 50528 50529 50530 50531 50532 50533 50534 50535 50536 50537 50538 50539 50540 50541 50542 50543 50544 50545 50546 50547 50548 50549 50550 50551 50552 50553 50554 50555 50556 50557 50558 50559 50560 50561 50562 50563 50564 50565 50566 50567 50568 50569 # Execute function body 50570 50571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 50572 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 50573 supports=yes 50574 50575 saved_cflags="$CFLAGS" 50576 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 50577 ac_ext=c 50578 ac_cpp='$CPP $CPPFLAGS' 50579 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50580 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50581 ac_compiler_gnu=$ac_cv_c_compiler_gnu 50582 50583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50584 /* end confdefs.h. */ 50585 int i; 50586 _ACEOF 50587 if ac_fn_c_try_compile "$LINENO"; then : 50588 50589 else 50590 supports=no 50591 fi 50592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50593 ac_ext=cpp 50594 ac_cpp='$CXXCPP $CPPFLAGS' 50595 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50596 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50597 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50598 50599 CFLAGS="$saved_cflags" 50600 50601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50602 $as_echo "$supports" >&6; } 50603 if test "x$supports" = "xyes" ; then 50604 : 50605 C_COMP_SUPPORTS="yes" 50606 else 50607 : 50608 C_COMP_SUPPORTS="no" 50609 fi 50610 50611 50612 50613 50614 50615 50616 50617 50618 50619 50620 50621 50622 50623 50624 50625 50626 50627 50628 50629 50630 50631 50632 50633 50634 50635 50636 50637 50638 50639 50640 50641 50642 50643 50644 50645 50646 50647 50648 50649 50650 50651 50652 50653 50654 50655 50656 50657 50658 50659 50660 50661 50662 50663 50664 50665 50666 50667 50668 50669 # Execute function body 50670 50671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 50672 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 50673 supports=yes 50674 50675 saved_cxxflags="$CXXFLAGS" 50676 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 50677 ac_ext=cpp 50678 ac_cpp='$CXXCPP $CPPFLAGS' 50679 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50680 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50681 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50682 50683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50684 /* end confdefs.h. */ 50685 int i; 50686 _ACEOF 50687 if ac_fn_cxx_try_compile "$LINENO"; then : 50688 50689 else 50690 supports=no 50691 fi 50692 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50693 ac_ext=cpp 50694 ac_cpp='$CXXCPP $CPPFLAGS' 50695 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50696 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50697 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50698 50699 CXXFLAGS="$saved_cxxflags" 50700 50701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50702 $as_echo "$supports" >&6; } 50703 if test "x$supports" = "xyes" ; then 50704 : 50705 CXX_COMP_SUPPORTS="yes" 50706 else 50707 : 50708 CXX_COMP_SUPPORTS="no" 50709 fi 50710 50711 50712 50713 50714 50715 50716 50717 50718 50719 50720 50721 50722 50723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 50724 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 50725 supports=no 50726 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 50727 50728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50729 $as_echo "$supports" >&6; } 50730 if test "x$supports" = "xyes" ; then 50731 : 50732 50733 else 50734 : 50735 STACK_PROTECTOR_CFLAG="" 50736 fi 50737 50738 50739 50740 50741 50742 50743 50744 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 50745 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 50746 if test "x$STACK_PROTECTOR_CFLAG" != x; then 50747 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 50748 fi 50749 ;; 50750 esac 50751 fi 50752 50753 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50754 if test "x$DEBUG_LEVEL" != xrelease; then 50755 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50756 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 50757 fi 50758 fi 50759 fi 50760 50761 # Optimization levels 50762 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50763 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 50764 50765 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 50766 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 50767 C_O_FLAG_HIGHEST_JVM="-xO4" 50768 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 50769 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 50770 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 50771 C_O_FLAG_DEBUG="-xregs=no%frameptr" 50772 C_O_FLAG_DEBUG_JVM="" 50773 C_O_FLAG_NONE="-xregs=no%frameptr" 50774 CXX_O_FLAG_HIGHEST_JVM="-xO4" 50775 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 50776 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 50777 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 50778 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 50779 CXX_O_FLAG_DEBUG_JVM="" 50780 CXX_O_FLAG_NONE="-xregs=no%frameptr" 50781 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50782 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 50783 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 50784 fi 50785 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50786 C_O_FLAG_HIGHEST_JVM="-xO4" 50787 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 50788 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 50789 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 50790 C_O_FLAG_DEBUG="" 50791 C_O_FLAG_DEBUG_JVM="" 50792 C_O_FLAG_NONE="" 50793 CXX_O_FLAG_HIGHEST_JVM="-xO4" 50794 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 50795 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 50796 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 50797 CXX_O_FLAG_DEBUG="" 50798 CXX_O_FLAG_DEBUG_JVM="" 50799 CXX_O_FLAG_NONE="" 50800 fi 50801 else 50802 # The remaining toolchains share opt flags between CC and CXX; 50803 # setup for C and duplicate afterwards. 50804 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50805 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50806 # On MacOSX we optimize for size, something 50807 # we should do for all platforms? 50808 C_O_FLAG_HIGHEST_JVM="-Os" 50809 C_O_FLAG_HIGHEST="-Os" 50810 C_O_FLAG_HI="-Os" 50811 C_O_FLAG_NORM="-Os" 50812 C_O_FLAG_SIZE="-Os" 50813 else 50814 C_O_FLAG_HIGHEST_JVM="-O3" 50815 C_O_FLAG_HIGHEST="-O3" 50816 C_O_FLAG_HI="-O3" 50817 C_O_FLAG_NORM="-O2" 50818 C_O_FLAG_SIZE="-Os" 50819 fi 50820 C_O_FLAG_DEBUG="-O0" 50821 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50822 C_O_FLAG_DEBUG_JVM="" 50823 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50824 C_O_FLAG_DEBUG_JVM="-O0" 50825 fi 50826 C_O_FLAG_NONE="-O0" 50827 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50828 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50829 # On MacOSX we optimize for size, something 50830 # we should do for all platforms? 50831 C_O_FLAG_HIGHEST_JVM="-Os" 50832 C_O_FLAG_HIGHEST="-Os" 50833 C_O_FLAG_HI="-Os" 50834 C_O_FLAG_NORM="-Os" 50835 C_O_FLAG_SIZE="-Os" 50836 else 50837 C_O_FLAG_HIGHEST_JVM="-O3" 50838 C_O_FLAG_HIGHEST="-O3" 50839 C_O_FLAG_HI="-O3" 50840 C_O_FLAG_NORM="-O2" 50841 C_O_FLAG_SIZE="-Os" 50842 fi 50843 C_O_FLAG_DEBUG="-O0" 50844 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50845 C_O_FLAG_DEBUG_JVM="" 50846 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50847 C_O_FLAG_DEBUG_JVM="-O0" 50848 fi 50849 C_O_FLAG_NONE="-O0" 50850 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50851 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 50852 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 50853 C_O_FLAG_HI="-O3 -qinline -qinlglue" 50854 C_O_FLAG_NORM="-O2" 50855 C_O_FLAG_DEBUG="-qnoopt" 50856 # FIXME: Value below not verified. 50857 C_O_FLAG_DEBUG_JVM="" 50858 C_O_FLAG_NONE="-qnoopt" 50859 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50860 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 50861 C_O_FLAG_HIGHEST="-O2" 50862 C_O_FLAG_HI="-O1" 50863 C_O_FLAG_NORM="-O1" 50864 C_O_FLAG_DEBUG="-Od" 50865 C_O_FLAG_DEBUG_JVM="" 50866 C_O_FLAG_NONE="-Od" 50867 C_O_FLAG_SIZE="-Os" 50868 fi 50869 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 50870 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 50871 CXX_O_FLAG_HI="$C_O_FLAG_HI" 50872 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 50873 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 50874 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 50875 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 50876 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 50877 fi 50878 50879 # Adjust optimization flags according to debug level. 50880 case $DEBUG_LEVEL in 50881 release ) 50882 # no adjustment 50883 ;; 50884 fastdebug ) 50885 # Not quite so much optimization 50886 C_O_FLAG_HI="$C_O_FLAG_NORM" 50887 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 50888 ;; 50889 slowdebug ) 50890 # Disable optimization 50891 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 50892 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 50893 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 50894 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 50895 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 50896 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 50897 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 50898 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 50899 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 50900 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 50901 ;; 50902 esac 50903 50904 50905 50906 50907 50908 50909 50910 50911 50912 50913 50914 50915 50916 50917 50918 50919 50920 50921 50922 50923 # Check whether --with-abi-profile was given. 50924 if test "${with_abi_profile+set}" = set; then : 50925 withval=$with_abi_profile; 50926 fi 50927 50928 50929 if test "x$with_abi_profile" != x; then 50930 if test "x$OPENJDK_TARGET_CPU" != xarm && \ 50931 test "x$OPENJDK_TARGET_CPU" != xaarch64; then 50932 as_fn_error $? "--with-abi-profile only available on arm/aarch64" "$LINENO" 5 50933 fi 50934 50935 OPENJDK_TARGET_ABI_PROFILE=$with_abi_profile 50936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI profle" >&5 50937 $as_echo_n "checking for ABI profle... " >&6; } 50938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_ABI_PROFILE" >&5 50939 $as_echo "$OPENJDK_TARGET_ABI_PROFILE" >&6; } 50940 50941 if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-sflt; then 50942 ARM_FLOAT_TYPE=vfp-sflt 50943 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 50944 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-hflt; then 50945 ARM_FLOAT_TYPE=vfp-hflt 50946 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 50947 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-sflt; then 50948 ARM_FLOAT_TYPE=sflt 50949 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 50950 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv5-vfp-sflt; then 50951 ARM_FLOAT_TYPE=vfp-sflt 50952 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 50953 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv6-vfp-hflt; then 50954 ARM_FLOAT_TYPE=vfp-hflt 50955 ARM_ARCH_TYPE_FLAGS='-march=armv6 -marm' 50956 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm64; then 50957 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 50958 ARM_FLOAT_TYPE= 50959 ARM_ARCH_TYPE_FLAGS= 50960 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xaarch64; then 50961 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 50962 ARM_FLOAT_TYPE= 50963 ARM_ARCH_TYPE_FLAGS= 50964 else 50965 as_fn_error $? "Invalid ABI profile: \"$OPENJDK_TARGET_ABI_PROFILE\"" "$LINENO" 5 50966 fi 50967 50968 if test "x$ARM_FLOAT_TYPE" = xvfp-sflt; then 50969 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=softfp -mfpu=vfp -DFLOAT_ARCH=-vfp-sflt' 50970 elif test "x$ARM_FLOAT_TYPE" = xvfp-hflt; then 50971 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=hard -mfpu=vfp -DFLOAT_ARCH=-vfp-hflt' 50972 elif test "x$ARM_FLOAT_TYPE" = xsflt; then 50973 ARM_FLOAT_TYPE_FLAGS='-msoft-float -mfpu=vfp' 50974 fi 50975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ARM_FLOAT_TYPE floating point flags" >&5 50976 $as_echo_n "checking for $ARM_FLOAT_TYPE floating point flags... " >&6; } 50977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_FLOAT_TYPE_FLAGS" >&5 50978 $as_echo "$ARM_FLOAT_TYPE_FLAGS" >&6; } 50979 50980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for arch type flags" >&5 50981 $as_echo_n "checking for arch type flags... " >&6; } 50982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_ARCH_TYPE_FLAGS" >&5 50983 $as_echo "$ARM_ARCH_TYPE_FLAGS" >&6; } 50984 50985 # Now set JDK_ARCH_ABI_PROP_NAME. This is equivalent to the last part of the 50986 # autoconf target triplet. 50987 JDK_ARCH_ABI_PROP_NAME=`$ECHO $OPENJDK_TARGET_AUTOCONF_NAME | $SED -e 's/.*-\([^-]*\)$/\1/'` 50988 # Sanity check that it is a known ABI. 50989 if test "x$JDK_ARCH_ABI_PROP_NAME" != xgnu && \ 50990 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabi && \ 50991 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabihf; then 50992 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&5 50993 $as_echo "$as_me: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&2;} 50994 fi 50995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI property name" >&5 50996 $as_echo_n "checking for ABI property name... " >&6; } 50997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_ARCH_ABI_PROP_NAME" >&5 50998 $as_echo "$JDK_ARCH_ABI_PROP_NAME" >&6; } 50999 51000 51001 # Pass these on to the open part of configure as if they were set using 51002 # --with-extra-c[xx]flags. 51003 EXTRA_CFLAGS="$EXTRA_CFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 51004 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 51005 # Get rid of annoying "note: the mangling of 'va_list' has changed in GCC 4.4" 51006 # FIXME: This should not really be set using extra_cflags. 51007 if test "x$OPENJDK_TARGET_CPU" = xarm; then 51008 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wno-psabi" 51009 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -Wno-psabi" 51010 fi 51011 # Also add JDK_ARCH_ABI_PROP_NAME define, but only to CFLAGS. 51012 EXTRA_CFLAGS="$EXTRA_CFLAGS -DJDK_ARCH_ABI_PROP_NAME='\"\$(JDK_ARCH_ABI_PROP_NAME)\"'" 51013 # And pass the architecture flags to the linker as well 51014 EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 51015 fi 51016 51017 # When building with an abi profile, the name of that profile is appended on the 51018 # bundle platform, which is used in bundle names. 51019 if test "x$OPENJDK_TARGET_ABI_PROFILE" != x; then 51020 OPENJDK_TARGET_BUNDLE_PLATFORM="$OPENJDK_TARGET_OS_BUNDLE-$OPENJDK_TARGET_ABI_PROFILE" 51021 fi 51022 51023 51024 # Optional POSIX functionality needed by the JVM 51025 # 51026 # Check if clock_gettime is available and in which library. This indicates 51027 # availability of CLOCK_MONOTONIC for hotspot. But we don't need to link, so 51028 # don't let it update LIBS. 51029 save_LIBS="$LIBS" 51030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 51031 $as_echo_n "checking for library containing clock_gettime... " >&6; } 51032 if ${ac_cv_search_clock_gettime+:} false; then : 51033 $as_echo_n "(cached) " >&6 51034 else 51035 ac_func_search_save_LIBS=$LIBS 51036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51037 /* end confdefs.h. */ 51038 51039 /* Override any GCC internal prototype to avoid an error. 51040 Use char because int might match the return type of a GCC 51041 builtin and then its argument prototype would still apply. */ 51042 #ifdef __cplusplus 51043 extern "C" 51044 #endif 51045 char clock_gettime (); 51046 int 51047 main () 51048 { 51049 return clock_gettime (); 51050 ; 51051 return 0; 51052 } 51053 _ACEOF 51054 for ac_lib in '' rt; do 51055 if test -z "$ac_lib"; then 51056 ac_res="none required" 51057 else 51058 ac_res=-l$ac_lib 51059 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 51060 fi 51061 if ac_fn_cxx_try_link "$LINENO"; then : 51062 ac_cv_search_clock_gettime=$ac_res 51063 fi 51064 rm -f core conftest.err conftest.$ac_objext \ 51065 conftest$ac_exeext 51066 if ${ac_cv_search_clock_gettime+:} false; then : 51067 break 51068 fi 51069 done 51070 if ${ac_cv_search_clock_gettime+:} false; then : 51071 51072 else 51073 ac_cv_search_clock_gettime=no 51074 fi 51075 rm conftest.$ac_ext 51076 LIBS=$ac_func_search_save_LIBS 51077 fi 51078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 51079 $as_echo "$ac_cv_search_clock_gettime" >&6; } 51080 ac_res=$ac_cv_search_clock_gettime 51081 if test "$ac_res" != no; then : 51082 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 51083 HAS_CLOCK_GETTIME=true 51084 fi 51085 51086 if test "x$LIBS" = "x-lrt "; then 51087 CLOCK_GETTIME_IN_LIBRT=true 51088 fi 51089 LIBS="$save_LIBS" 51090 51091 51092 # Special extras... 51093 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51094 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 51095 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51096 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51097 fi 51098 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51099 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51100 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51101 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51102 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51103 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51104 CXXSTD_CXXFLAG="-std=gnu++98" 51105 51106 51107 51108 51109 51110 51111 51112 51113 51114 51115 51116 51117 51118 51119 51120 51121 51122 51123 51124 51125 51126 51127 51128 51129 51130 51131 51132 51133 51134 51135 51136 51137 51138 51139 51140 51141 51142 51143 51144 51145 51146 51147 # Execute function body 51148 51149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 51150 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 51151 supports=yes 51152 51153 saved_cxxflags="$CXXFLAGS" 51154 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 51155 ac_ext=cpp 51156 ac_cpp='$CXXCPP $CPPFLAGS' 51157 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51158 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51159 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51160 51161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51162 /* end confdefs.h. */ 51163 int i; 51164 _ACEOF 51165 if ac_fn_cxx_try_compile "$LINENO"; then : 51166 51167 else 51168 supports=no 51169 fi 51170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51171 ac_ext=cpp 51172 ac_cpp='$CXXCPP $CPPFLAGS' 51173 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51174 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51175 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51176 51177 CXXFLAGS="$saved_cxxflags" 51178 51179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51180 $as_echo "$supports" >&6; } 51181 if test "x$supports" = "xyes" ; then 51182 : 51183 51184 else 51185 : 51186 CXXSTD_CXXFLAG="" 51187 fi 51188 51189 51190 51191 51192 51193 51194 51195 51196 51197 51198 51199 51200 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 51201 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 51202 51203 fi 51204 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51205 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 51206 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 51207 fi 51208 51209 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 51210 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 51211 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 51212 51213 ############################################################################### 51214 # 51215 # Now setup the CFLAGS and LDFLAGS for the JDK build. 51216 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 51217 # 51218 51219 # Setup compiler/platform specific flags into 51220 # CFLAGS_JDK - C Compiler flags 51221 # CXXFLAGS_JDK - C++ Compiler flags 51222 # COMMON_CCXXFLAGS_JDK - common to C and C++ 51223 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51224 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 51225 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 51226 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 51227 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51228 # Force compatibility with i586 on 32 bit intel platforms. 51229 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 51230 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 51231 fi 51232 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 51233 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 51234 case $OPENJDK_TARGET_CPU_ARCH in 51235 arm ) 51236 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51237 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51238 COMMON_CCXXFLAGS_JDK="${COMMON_CCXXFLAGS_JDK} -fsigned-char" 51239 ;; 51240 ppc ) 51241 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51242 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51243 ;; 51244 s390 ) 51245 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 51246 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51247 ;; 51248 * ) 51249 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 51250 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51251 ;; 51252 esac 51253 51254 51255 51256 51257 51258 51259 51260 51261 51262 51263 51264 51265 51266 51267 51268 51269 51270 51271 51272 51273 51274 51275 51276 51277 51278 51279 51280 51281 51282 51283 51284 51285 51286 51287 51288 51289 51290 51291 51292 51293 51294 51295 51296 51297 51298 51299 51300 51301 51302 51303 51304 51305 51306 51307 # Execute function body 51308 51309 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51310 REFERENCE_VERSION=6 51311 51312 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 51313 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 51314 fi 51315 51316 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51317 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 51318 fi 51319 51320 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51321 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 51322 51323 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51324 : 51325 51326 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 51327 # runs afoul of the more aggressive versions of these optimisations. 51328 # Notably, value range propagation now assumes that the this pointer of C++ 51329 # member functions is non-null. 51330 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 51331 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 51332 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 51333 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 51334 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 51335 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 51336 51337 else 51338 : 51339 51340 fi 51341 51342 51343 51344 51345 51346 51347 51348 51349 51350 51351 51352 51353 51354 51355 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51356 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 51357 51358 # Restrict the debug information created by Clang to avoid 51359 # too big object files and speed the build up a little bit 51360 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 51361 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 51362 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51363 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51364 # Force compatibility with i586 on 32 bit intel platforms. 51365 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 51366 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 51367 fi 51368 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 51369 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 51370 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 51371 case $OPENJDK_TARGET_CPU_ARCH in 51372 ppc ) 51373 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51374 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51375 ;; 51376 * ) 51377 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 51378 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 51379 ;; 51380 esac 51381 fi 51382 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51383 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 51384 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 51385 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 51386 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 51387 fi 51388 51389 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 51390 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 51391 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51392 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 51393 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 51394 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 51395 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51396 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 51397 -MD -Zc:wchar_t- -W3 -wd4800 \ 51398 -DWIN32_LEAN_AND_MEAN \ 51399 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 51400 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 51401 -DWIN32 -DIAL" 51402 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 51403 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 51404 else 51405 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 51406 fi 51407 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 51408 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 51409 # studio. 51410 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 51411 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 51412 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 51413 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 51414 fi 51415 fi 51416 51417 ############################################################################### 51418 51419 # Adjust flags according to debug level. 51420 case $DEBUG_LEVEL in 51421 fastdebug | slowdebug ) 51422 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 51423 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 51424 ;; 51425 release ) 51426 ;; 51427 * ) 51428 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51429 ;; 51430 esac 51431 51432 # Set some common defines. These works for all compilers, but assume 51433 # -D is universally accepted. 51434 51435 # Setup endianness 51436 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 51437 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 51438 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 51439 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 51440 # Note: -Dmacro is the same as #define macro 1 51441 # -Dmacro= is the same as #define macro 51442 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51443 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 51444 else 51445 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 51446 fi 51447 else 51448 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 51449 # are defined in the system? 51450 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51451 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 51452 else 51453 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 51454 fi 51455 fi 51456 51457 # Always enable optional macros for VM. 51458 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_FORMAT_MACROS" 51459 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_LIMIT_MACROS" 51460 JVM_CFLAGS="$JVM_CFLAGS -D__STDC_CONSTANT_MACROS" 51461 51462 # Setup target OS define. Use OS target name but in upper case. 51463 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 51464 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 51465 51466 # Setup target CPU 51467 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51468 $OPENJDK_TARGET_ADD_LP64 \ 51469 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 51470 51471 # Setup debug/release defines 51472 if test "x$DEBUG_LEVEL" = xrelease; then 51473 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 51474 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51475 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 51476 fi 51477 else 51478 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 51479 fi 51480 51481 # Optional POSIX functionality needed by the VM 51482 51483 if test "x$HAS_CLOCK_GETTIME" = "xtrue"; then 51484 JVM_CFLAGS="$JVM_CFLAGS -DSUPPORTS_CLOCK_MONOTONIC" 51485 if test "x$CLOCK_GETTIME_IN_LIBRT" = "xtrue"; then 51486 JVM_CFLAGS="$JVM_CFLAGS -DNEEDS_LIBRT" 51487 fi 51488 fi 51489 51490 51491 # Set some additional per-OS defines. 51492 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51493 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 51494 JVM_CFLAGS="$JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 51495 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 51496 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 51497 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 51498 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 51499 -D_Crun_inline_placement -library=stlport4 $PICFLAG -mt -features=no%except" 51500 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51501 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 51502 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 51503 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 51504 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 51505 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 51506 -fno-omit-frame-pointer" 51507 elif test "x$OPENJDK_TARGET_OS" = xaix; then 51508 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 51509 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 51510 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 51511 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 51512 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 51513 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 51514 # so for slowdebug we build with '-qpic=large -bbigtoc'. 51515 if test "x$DEBUG_LEVEL" = xslowdebug; then 51516 JVM_CFLAGS="$JVM_CFLAGS -qpic=large" 51517 fi 51518 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 51519 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 51520 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 51521 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 51522 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 51523 fi 51524 51525 # Set some additional per-CPU defines. 51526 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 51527 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 51528 elif test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xsolaris-sparcv9; then 51529 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 51530 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 51531 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51532 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 51533 # fixes `relocation truncated to fit' error for gcc 4.1. 51534 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 51535 # Use ppc64 instructions, but schedule for power5 51536 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 51537 elif test "x$OPENJDK_TARGET_OS" = xaix; then 51538 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 51539 fi 51540 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 51541 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51542 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 51543 # Little endian machine uses ELFv2 ABI. 51544 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 51545 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 51546 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power8 -mtune=power8" 51547 fi 51548 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 51549 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51550 JVM_CFLAGS="$JVM_CFLAGS -mbackchain -march=z10" 51551 fi 51552 fi 51553 51554 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 51555 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 51556 fi 51557 51558 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 51559 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 51560 # Solaris does not have _LP64=1 in the old build. 51561 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 51562 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 51563 fi 51564 fi 51565 51566 # Set JVM_CFLAGS warning handling 51567 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51568 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 51569 -Wunused-value -Woverloaded-virtual" 51570 51571 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51572 51573 51574 51575 51576 51577 51578 51579 51580 51581 51582 51583 51584 51585 51586 51587 51588 51589 51590 51591 51592 51593 51594 51595 51596 51597 51598 51599 51600 51601 51602 51603 51604 51605 51606 51607 51608 51609 51610 51611 51612 51613 51614 51615 51616 51617 51618 51619 51620 51621 51622 51623 51624 51625 51626 # Execute function body 51627 51628 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51629 REFERENCE_VERSION=4.8 51630 51631 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 51632 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 51633 fi 51634 51635 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51636 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51637 fi 51638 51639 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51640 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 51641 51642 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51643 : 51644 51645 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51646 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51647 51648 51649 else 51650 : 51651 51652 fi 51653 51654 51655 51656 51657 51658 51659 51660 51661 51662 51663 51664 51665 51666 51667 fi 51668 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51669 # Non-zero builds have stricter warnings 51670 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51671 else 51672 if test "x$TOOLCHAIN_TYPE" = xclang; then 51673 # Some versions of llvm do not like -Wundef 51674 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 51675 fi 51676 fi 51677 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51678 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51679 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51680 fi 51681 51682 # Additional macosx handling 51683 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51684 # MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected 51685 # format is X.Y.Z. It's hard-coded to the minimum OSX version on which the 51686 # JDK can be built and makes the linked binaries compatible even if built on 51687 # a newer version of the OS. 51688 MACOSX_VERSION_MIN=10.7.0 51689 51690 51691 # Setting --with-macosx-version-max=<version> makes it an error to build or 51692 # link to macosx APIs that are newer than the given OS version. The expected 51693 # format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h. 51694 51695 # Check whether --with-macosx-version-max was given. 51696 if test "${with_macosx_version_max+set}" = set; then : 51697 withval=$with_macosx_version_max; 51698 if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then 51699 MACOSX_VERSION_MAX=$with_macosx_version_max 51700 elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then 51701 MACOSX_VERSION_MAX=$with_macosx_version_max 51702 elif test "x$with_macosx_version_max" = "xno"; then 51703 # Use build system default 51704 MACOSX_VERSION_MAX= 51705 else 51706 as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5 51707 fi 51708 51709 else 51710 MACOSX_VERSION_MAX= 51711 51712 fi 51713 51714 51715 51716 # Let the flags variables get resolved in make for easier override on make 51717 # command line. AvailabilityMacros.h versions have no dots, ex: 1070. 51718 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51719 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 51720 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51721 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51722 JVM_CFLAGS="$JVM_CFLAGS \ 51723 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 51724 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51725 51726 if test -n "$MACOSX_VERSION_MAX"; then 51727 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51728 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 51729 JVM_CFLAGS="$JVM_CFLAGS \ 51730 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 51731 fi 51732 fi 51733 51734 # Setup some hard coded includes 51735 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 51736 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 51737 -I${TOPDIR}/src/java.base/share/native/include \ 51738 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 51739 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 51740 -I${TOPDIR}/src/java.base/share/native/libjava \ 51741 -I${TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 51742 51743 # The shared libraries are compiled using the picflag. 51744 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 51745 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51746 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 51747 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51748 51749 # Executable flags 51750 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 51751 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 51752 51753 51754 51755 51756 51757 51758 # Setup LDFLAGS et al. 51759 # 51760 51761 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51762 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51763 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51764 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51765 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 51766 LDFLAGS_SAFESH="-safeseh" 51767 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 51768 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 51769 # NOTE: Old build added -machine. Probably not needed. 51770 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 51771 else 51772 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 51773 fi 51774 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51775 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51776 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51777 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51778 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51779 fi 51780 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51781 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51782 # We have previously set HAS_GNU_HASH if this is the case 51783 if test -n "$HAS_GNU_HASH"; then 51784 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51785 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 51786 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 51787 fi 51788 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 51789 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51790 fi 51791 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51792 # And since we now know that the linker is gnu, then add -z defs, to forbid 51793 # undefined symbols in object files. 51794 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51795 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51796 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51797 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51798 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51799 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51800 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 51801 fi 51802 case $DEBUG_LEVEL in 51803 release ) 51804 # tell linker to optimize libraries. 51805 # Should this be supplied to the OSS linker as well? 51806 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51807 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51808 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51809 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51810 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 51811 fi 51812 ;; 51813 slowdebug ) 51814 # Hotspot always let the linker optimize 51815 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 51816 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51817 # do relocations at load 51818 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 51819 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 51820 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 51821 fi 51822 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51823 # mark relocations read only 51824 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 51825 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51826 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 51827 fi 51828 ;; 51829 fastdebug ) 51830 # Hotspot always let the linker optimize 51831 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 51832 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51833 # mark relocations read only 51834 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 51835 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51836 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 51837 fi 51838 ;; 51839 * ) 51840 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51841 ;; 51842 esac 51843 fi 51844 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51845 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 51846 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 51847 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 51848 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 51849 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 51850 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 51851 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 51852 fi 51853 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51854 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 51855 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 51856 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 51857 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 51858 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 51859 # so for slowdebug we build with '-qpic=large -bbigtoc'. 51860 if test "x$DEBUG_LEVEL" = xslowdebug; then 51861 JVM_LDFLAGS="$JVM_LDFLAGS -bbigtoc" 51862 fi 51863 fi 51864 51865 # Customize LDFLAGS for executables 51866 51867 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 51868 51869 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51870 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 51871 LDFLAGS_STACK_SIZE=1048576 51872 else 51873 LDFLAGS_STACK_SIZE=327680 51874 fi 51875 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 51876 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 51877 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 51878 fi 51879 51880 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 51881 51882 # Customize LDFLAGS for libs 51883 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 51884 51885 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 51886 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51887 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 51888 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 51889 JDKLIB_LIBS="" 51890 else 51891 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 51892 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 51893 51894 if test "xTARGET" = "xTARGET"; then 51895 # On some platforms (mac) the linker warns about non existing -L dirs. 51896 # For any of the variants server, client or minimal, the dir matches the 51897 # variant name. The "main" variant should be used for linking. For the 51898 # rest, the dir is just server. 51899 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 51900 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 51901 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 51902 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 51903 else 51904 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 51905 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 51906 fi 51907 elif test "xTARGET" = "xBUILD"; then 51908 # When building a buildjdk, it's always only the server variant 51909 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 51910 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 51911 fi 51912 51913 JDKLIB_LIBS="-ljava -ljvm" 51914 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51915 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 51916 fi 51917 51918 fi 51919 51920 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 51921 51922 # Set JVM_LIBS (per os) 51923 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51924 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 51925 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 51926 # FIXME: This hard-coded path is not really proper. 51927 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 51928 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 51929 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 51930 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 51931 fi 51932 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 51933 -lthread -ldoor -lc -ldemangle -lnsl -lrt" 51934 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51935 JVM_LIBS="$JVM_LIBS -lm" 51936 elif test "x$OPENJDK_TARGET_OS" = xaix; then 51937 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 51938 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 51939 JVM_LIBS="$JVM_LIBS -lm" 51940 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 51941 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51942 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51943 wsock32.lib winmm.lib version.lib psapi.lib" 51944 fi 51945 51946 # Set JVM_ASFLAGS 51947 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51948 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51949 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 51950 fi 51951 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51952 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51953 fi 51954 51955 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 51956 51957 51958 51959 51960 51961 51962 51963 51964 51965 51966 51967 51968 51969 51970 51971 # Special extras... 51972 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51973 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51974 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51975 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51976 fi 51977 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51978 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51979 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51980 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51981 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51982 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51983 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 51984 51985 51986 51987 51988 51989 51990 51991 51992 51993 51994 51995 51996 51997 51998 51999 52000 52001 52002 52003 52004 52005 52006 52007 52008 52009 52010 52011 52012 52013 52014 52015 52016 52017 52018 52019 52020 52021 52022 52023 52024 52025 52026 # Execute function body 52027 52028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 52029 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 52030 supports=yes 52031 52032 saved_cxxflags="$CXXFLAGS" 52033 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 52034 ac_ext=cpp 52035 ac_cpp='$CXXCPP $CPPFLAGS' 52036 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52037 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52038 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52039 52040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52041 /* end confdefs.h. */ 52042 int i; 52043 _ACEOF 52044 if ac_fn_cxx_try_compile "$LINENO"; then : 52045 52046 else 52047 supports=no 52048 fi 52049 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52050 ac_ext=cpp 52051 ac_cpp='$CXXCPP $CPPFLAGS' 52052 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52053 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52054 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52055 52056 CXXFLAGS="$saved_cxxflags" 52057 52058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52059 $as_echo "$supports" >&6; } 52060 if test "x$supports" = "xyes" ; then 52061 : 52062 52063 else 52064 : 52065 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 52066 fi 52067 52068 52069 52070 52071 52072 52073 52074 52075 52076 52077 52078 52079 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 52080 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 52081 52082 fi 52083 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 52084 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 52085 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 52086 fi 52087 52088 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 52089 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 52090 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 52091 52092 ############################################################################### 52093 # 52094 # Now setup the CFLAGS and LDFLAGS for the JDK build. 52095 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 52096 # 52097 52098 # Setup compiler/platform specific flags into 52099 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 52100 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 52101 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 52102 if test "x$TOOLCHAIN_TYPE" = xgcc; then 52103 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 52104 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 52105 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 52106 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52107 # Force compatibility with i586 on 32 bit intel platforms. 52108 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 52109 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 52110 fi 52111 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 52112 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 52113 case $OPENJDK_BUILD_CPU_ARCH in 52114 arm ) 52115 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52116 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52117 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="${OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK} -fsigned-char" 52118 ;; 52119 ppc ) 52120 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52121 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52122 ;; 52123 s390 ) 52124 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 52125 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52126 ;; 52127 * ) 52128 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 52129 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52130 ;; 52131 esac 52132 52133 52134 52135 52136 52137 52138 52139 52140 52141 52142 52143 52144 52145 52146 52147 52148 52149 52150 52151 52152 52153 52154 52155 52156 52157 52158 52159 52160 52161 52162 52163 52164 52165 52166 52167 52168 52169 52170 52171 52172 52173 52174 52175 52176 52177 52178 52179 52180 52181 52182 52183 52184 52185 52186 # Execute function body 52187 52188 # Need to assign to a variable since m4 is blocked from modifying parts in []. 52189 REFERENCE_VERSION=6 52190 52191 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 52192 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 52193 fi 52194 52195 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 52196 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 52197 fi 52198 52199 # Version comparison method inspired by http://stackoverflow.com/a/24067243 52200 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 52201 52202 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 52203 : 52204 52205 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 52206 # runs afoul of the more aggressive versions of these optimisations. 52207 # Notably, value range propagation now assumes that the this pointer of C++ 52208 # member functions is non-null. 52209 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 52210 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 52211 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 52212 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 52213 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 52214 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 52215 52216 else 52217 : 52218 52219 fi 52220 52221 52222 52223 52224 52225 52226 52227 52228 52229 52230 52231 52232 52233 52234 elif test "x$TOOLCHAIN_TYPE" = xclang; then 52235 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 52236 52237 # Restrict the debug information created by Clang to avoid 52238 # too big object files and speed the build up a little bit 52239 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 52240 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 52241 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52242 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52243 # Force compatibility with i586 on 32 bit intel platforms. 52244 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 52245 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 52246 fi 52247 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 52248 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 52249 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 52250 case $OPENJDK_BUILD_CPU_ARCH in 52251 ppc ) 52252 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 52253 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52254 ;; 52255 * ) 52256 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 52257 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 52258 ;; 52259 esac 52260 fi 52261 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52262 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 52263 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 52264 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 52265 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 52266 fi 52267 52268 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 52269 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 52270 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52271 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 52272 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 52273 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 52274 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52275 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52276 -MD -Zc:wchar_t- -W3 -wd4800 \ 52277 -DWIN32_LEAN_AND_MEAN \ 52278 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 52279 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 52280 -DWIN32 -DIAL" 52281 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 52282 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 52283 else 52284 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 52285 fi 52286 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 52287 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 52288 # studio. 52289 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 52290 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 52291 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 52292 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 52293 fi 52294 fi 52295 52296 ############################################################################### 52297 52298 # Adjust flags according to debug level. 52299 case $DEBUG_LEVEL in 52300 fastdebug | slowdebug ) 52301 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 52302 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 52303 ;; 52304 release ) 52305 ;; 52306 * ) 52307 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 52308 ;; 52309 esac 52310 52311 # Set some common defines. These works for all compilers, but assume 52312 # -D is universally accepted. 52313 52314 # Setup endianness 52315 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 52316 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 52317 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 52318 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 52319 # Note: -Dmacro is the same as #define macro 1 52320 # -Dmacro= is the same as #define macro 52321 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 52322 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 52323 else 52324 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 52325 fi 52326 else 52327 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 52328 # are defined in the system? 52329 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 52330 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 52331 else 52332 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 52333 fi 52334 fi 52335 52336 # Always enable optional macros for VM. 52337 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_FORMAT_MACROS" 52338 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_LIMIT_MACROS" 52339 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D__STDC_CONSTANT_MACROS" 52340 52341 # Setup target OS define. Use OS target name but in upper case. 52342 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 52343 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 52344 52345 # Setup target CPU 52346 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52347 $OPENJDK_BUILD_ADD_LP64 \ 52348 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 52349 52350 # Setup debug/release defines 52351 if test "x$DEBUG_LEVEL" = xrelease; then 52352 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 52353 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 52354 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 52355 fi 52356 else 52357 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 52358 fi 52359 52360 # Optional POSIX functionality needed by the VM 52361 52362 if test "x$HAS_CLOCK_GETTIME" = "xtrue"; then 52363 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSUPPORTS_CLOCK_MONOTONIC" 52364 if test "x$CLOCK_GETTIME_IN_LIBRT" = "xtrue"; then 52365 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DNEEDS_LIBRT" 52366 fi 52367 fi 52368 52369 52370 # Set some additional per-OS defines. 52371 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52372 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 52373 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 52374 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 52375 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 52376 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 52377 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 52378 -D_Crun_inline_placement -library=stlport4 $PICFLAG -mt -features=no%except" 52379 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52380 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 52381 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 52382 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 52383 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 52384 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 52385 -fno-omit-frame-pointer" 52386 elif test "x$OPENJDK_BUILD_OS" = xaix; then 52387 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 52388 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 52389 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 52390 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 52391 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 52392 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 52393 # so for slowdebug we build with '-qpic=large -bbigtoc'. 52394 if test "x$DEBUG_LEVEL" = xslowdebug; then 52395 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qpic=large" 52396 fi 52397 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 52398 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 52399 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 52400 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 52401 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 52402 fi 52403 52404 # Set some additional per-CPU defines. 52405 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 52406 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 52407 elif test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xsolaris-sparcv9; then 52408 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 52409 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 52410 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52411 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 52412 # fixes `relocation truncated to fit' error for gcc 4.1. 52413 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 52414 # Use ppc64 instructions, but schedule for power5 52415 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 52416 elif test "x$OPENJDK_BUILD_OS" = xaix; then 52417 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 52418 fi 52419 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 52420 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52421 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 52422 # Little endian machine uses ELFv2 ABI. 52423 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 52424 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 52425 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power8 -mtune=power8" 52426 fi 52427 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 52428 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52429 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mbackchain -march=z10" 52430 fi 52431 fi 52432 52433 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 52434 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 52435 fi 52436 52437 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 52438 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 52439 # Solaris does not have _LP64=1 in the old build. 52440 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 52441 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 52442 fi 52443 fi 52444 52445 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 52446 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52447 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 52448 -Wunused-value -Woverloaded-virtual" 52449 52450 if test "x$TOOLCHAIN_TYPE" = xgcc; then 52451 52452 52453 52454 52455 52456 52457 52458 52459 52460 52461 52462 52463 52464 52465 52466 52467 52468 52469 52470 52471 52472 52473 52474 52475 52476 52477 52478 52479 52480 52481 52482 52483 52484 52485 52486 52487 52488 52489 52490 52491 52492 52493 52494 52495 52496 52497 52498 52499 52500 52501 52502 52503 52504 52505 # Execute function body 52506 52507 # Need to assign to a variable since m4 is blocked from modifying parts in []. 52508 REFERENCE_VERSION=4.8 52509 52510 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 52511 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 52512 fi 52513 52514 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 52515 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 52516 fi 52517 52518 # Version comparison method inspired by http://stackoverflow.com/a/24067243 52519 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 52520 52521 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 52522 : 52523 52524 # These flags either do not work or give spurious warnings prior to gcc 4.8. 52525 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 52526 52527 52528 else 52529 : 52530 52531 fi 52532 52533 52534 52535 52536 52537 52538 52539 52540 52541 52542 52543 52544 52545 52546 fi 52547 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52548 # Non-zero builds have stricter warnings 52549 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 52550 else 52551 if test "x$TOOLCHAIN_TYPE" = xclang; then 52552 # Some versions of llvm do not like -Wundef 52553 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 52554 fi 52555 fi 52556 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52557 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 52558 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 52559 fi 52560 52561 # Additional macosx handling 52562 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 52563 # MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected 52564 # format is X.Y.Z. It's hard-coded to the minimum OSX version on which the 52565 # JDK can be built and makes the linked binaries compatible even if built on 52566 # a newer version of the OS. 52567 MACOSX_VERSION_MIN=10.7.0 52568 52569 52570 # Setting --with-macosx-version-max=<version> makes it an error to build or 52571 # link to macosx APIs that are newer than the given OS version. The expected 52572 # format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h. 52573 52574 # Check whether --with-macosx-version-max was given. 52575 if test "${with_macosx_version_max+set}" = set; then : 52576 withval=$with_macosx_version_max; 52577 if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then 52578 MACOSX_VERSION_MAX=$with_macosx_version_max 52579 elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then 52580 MACOSX_VERSION_MAX=$with_macosx_version_max 52581 elif test "x$with_macosx_version_max" = "xno"; then 52582 # Use build system default 52583 MACOSX_VERSION_MAX= 52584 else 52585 as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5 52586 fi 52587 52588 else 52589 MACOSX_VERSION_MAX= 52590 52591 fi 52592 52593 52594 52595 # Let the flags variables get resolved in make for easier override on make 52596 # command line. AvailabilityMacros.h versions have no dots, ex: 1070. 52597 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52598 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 52599 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52600 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52601 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \ 52602 -DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \ 52603 -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 52604 52605 if test -n "$MACOSX_VERSION_MAX"; then 52606 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52607 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 52608 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \ 52609 -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))" 52610 fi 52611 fi 52612 52613 # Setup some hard coded includes 52614 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52615 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 52616 -I${TOPDIR}/src/java.base/share/native/include \ 52617 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 52618 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 52619 -I${TOPDIR}/src/java.base/share/native/libjava \ 52620 -I${TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 52621 52622 # The shared libraries are compiled using the picflag. 52623 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52624 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 52625 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 52626 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 52627 52628 # Executable flags 52629 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 52630 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 52631 52632 52633 52634 52635 52636 52637 # Setup LDFLAGS et al. 52638 # 52639 52640 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52641 LDFLAGS_MICROSOFT="-nologo -opt:ref" 52642 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 52643 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 52644 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 52645 LDFLAGS_SAFESH="-safeseh" 52646 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 52647 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 52648 # NOTE: Old build added -machine. Probably not needed. 52649 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 52650 else 52651 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 52652 fi 52653 elif test "x$TOOLCHAIN_TYPE" = xclang; then 52654 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 52655 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 52656 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 52657 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 52658 fi 52659 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 52660 # If this is a --hash-style=gnu system, use --hash-style=both, why? 52661 # We have previously set HAS_GNU_HASH if this is the case 52662 if test -n "$HAS_GNU_HASH"; then 52663 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 52664 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 52665 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 52666 fi 52667 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 52668 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 52669 fi 52670 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52671 # And since we now know that the linker is gnu, then add -z defs, to forbid 52672 # undefined symbols in object files. 52673 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 52674 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 52675 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 52676 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 52677 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 52678 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52679 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 52680 fi 52681 case $DEBUG_LEVEL in 52682 release ) 52683 # tell linker to optimize libraries. 52684 # Should this be supplied to the OSS linker as well? 52685 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 52686 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 52687 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 52688 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52689 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 52690 fi 52691 ;; 52692 slowdebug ) 52693 # Hotspot always let the linker optimize 52694 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 52695 if test "x$HAS_LINKER_NOW" = "xtrue"; then 52696 # do relocations at load 52697 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 52698 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 52699 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 52700 fi 52701 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52702 # mark relocations read only 52703 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 52704 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52705 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 52706 fi 52707 ;; 52708 fastdebug ) 52709 # Hotspot always let the linker optimize 52710 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 52711 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 52712 # mark relocations read only 52713 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 52714 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 52715 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 52716 fi 52717 ;; 52718 * ) 52719 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 52720 ;; 52721 esac 52722 fi 52723 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52724 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 52725 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 52726 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 52727 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 52728 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 52729 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 52730 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 52731 fi 52732 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 52733 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 52734 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 52735 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 52736 # We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 52737 # Hotspot now overflows its 64K TOC (currently only for slowdebug), 52738 # so for slowdebug we build with '-qpic=large -bbigtoc'. 52739 if test "x$DEBUG_LEVEL" = xslowdebug; then 52740 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -bbigtoc" 52741 fi 52742 fi 52743 52744 # Customize LDFLAGS for executables 52745 52746 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 52747 52748 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52749 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 52750 LDFLAGS_STACK_SIZE=1048576 52751 else 52752 LDFLAGS_STACK_SIZE=327680 52753 fi 52754 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 52755 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 52756 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 52757 fi 52758 52759 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 52760 52761 # Customize LDFLAGS for libs 52762 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 52763 52764 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 52765 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 52766 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52767 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 52768 OPENJDK_BUILD_JDKLIB_LIBS="" 52769 else 52770 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52771 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 52772 52773 if test "xBUILD" = "xTARGET"; then 52774 # On some platforms (mac) the linker warns about non existing -L dirs. 52775 # For any of the variants server, client or minimal, the dir matches the 52776 # variant name. The "main" variant should be used for linking. For the 52777 # rest, the dir is just server. 52778 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 52779 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 52780 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52781 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 52782 else 52783 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52784 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 52785 fi 52786 elif test "xBUILD" = "xBUILD"; then 52787 # When building a buildjdk, it's always only the server variant 52788 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 52789 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 52790 fi 52791 52792 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 52793 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 52794 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 52795 fi 52796 52797 fi 52798 52799 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 52800 52801 # Set OPENJDK_BUILD_JVM_LIBS (per os) 52802 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52803 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 52804 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 52805 # FIXME: This hard-coded path is not really proper. 52806 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 52807 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 52808 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 52809 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 52810 fi 52811 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 52812 -lthread -ldoor -lc -ldemangle -lnsl -lrt" 52813 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52814 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 52815 elif test "x$OPENJDK_BUILD_OS" = xaix; then 52816 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 52817 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 52818 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 52819 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 52820 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 52821 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 52822 wsock32.lib winmm.lib version.lib psapi.lib" 52823 fi 52824 52825 # Set OPENJDK_BUILD_JVM_ASFLAGS 52826 if test "x$OPENJDK_BUILD_OS" = xlinux; then 52827 if test "x$OPENJDK_BUILD_CPU" = xx86; then 52828 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 52829 fi 52830 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 52831 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 52832 fi 52833 52834 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 52835 52836 52837 52838 52839 52840 52841 52842 52843 52844 52845 52846 52847 52848 52849 52850 # Tests are only ever compiled for TARGET 52851 # Flags for compiling test libraries 52852 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 52853 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 52854 52855 # Flags for compiling test executables 52856 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 52857 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 52858 52859 52860 52861 52862 52863 52864 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 52865 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 52866 52867 52868 52869 52870 52871 52872 # Check that the compiler supports -mX (or -qX on AIX) flags 52873 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 52874 52875 52876 52877 52878 52879 52880 52881 52882 52883 52884 52885 52886 52887 52888 52889 52890 52891 52892 52893 52894 52895 52896 52897 52898 52899 52900 52901 52902 52903 52904 52905 52906 52907 52908 52909 52910 52911 52912 52913 52914 52915 52916 52917 52918 52919 52920 52921 # Execute function body 52922 52923 52924 52925 52926 52927 52928 52929 52930 52931 52932 52933 52934 52935 52936 52937 52938 52939 52940 52941 52942 52943 52944 52945 52946 52947 52948 52949 52950 52951 52952 52953 52954 52955 52956 52957 52958 52959 52960 52961 52962 52963 52964 52965 52966 52967 52968 52969 52970 # Execute function body 52971 52972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 52973 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 52974 supports=yes 52975 52976 saved_cflags="$CFLAGS" 52977 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 52978 ac_ext=c 52979 ac_cpp='$CPP $CPPFLAGS' 52980 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52981 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52982 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52983 52984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52985 /* end confdefs.h. */ 52986 int i; 52987 _ACEOF 52988 if ac_fn_c_try_compile "$LINENO"; then : 52989 52990 else 52991 supports=no 52992 fi 52993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52994 ac_ext=cpp 52995 ac_cpp='$CXXCPP $CPPFLAGS' 52996 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52997 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52998 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52999 53000 CFLAGS="$saved_cflags" 53001 53002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53003 $as_echo "$supports" >&6; } 53004 if test "x$supports" = "xyes" ; then 53005 : 53006 C_COMP_SUPPORTS="yes" 53007 else 53008 : 53009 C_COMP_SUPPORTS="no" 53010 fi 53011 53012 53013 53014 53015 53016 53017 53018 53019 53020 53021 53022 53023 53024 53025 53026 53027 53028 53029 53030 53031 53032 53033 53034 53035 53036 53037 53038 53039 53040 53041 53042 53043 53044 53045 53046 53047 53048 53049 53050 53051 53052 53053 53054 53055 53056 53057 53058 53059 53060 53061 53062 53063 53064 53065 53066 53067 53068 53069 53070 # Execute function body 53071 53072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 53073 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 53074 supports=yes 53075 53076 saved_cxxflags="$CXXFLAGS" 53077 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 53078 ac_ext=cpp 53079 ac_cpp='$CXXCPP $CPPFLAGS' 53080 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53081 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53082 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53083 53084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53085 /* end confdefs.h. */ 53086 int i; 53087 _ACEOF 53088 if ac_fn_cxx_try_compile "$LINENO"; then : 53089 53090 else 53091 supports=no 53092 fi 53093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53094 ac_ext=cpp 53095 ac_cpp='$CXXCPP $CPPFLAGS' 53096 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53097 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53098 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53099 53100 CXXFLAGS="$saved_cxxflags" 53101 53102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53103 $as_echo "$supports" >&6; } 53104 if test "x$supports" = "xyes" ; then 53105 : 53106 CXX_COMP_SUPPORTS="yes" 53107 else 53108 : 53109 CXX_COMP_SUPPORTS="no" 53110 fi 53111 53112 53113 53114 53115 53116 53117 53118 53119 53120 53121 53122 53123 53124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 53125 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 53126 supports=no 53127 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 53128 53129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53130 $as_echo "$supports" >&6; } 53131 if test "x$supports" = "xyes" ; then 53132 : 53133 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 53134 else 53135 : 53136 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 53137 fi 53138 53139 53140 53141 53142 53143 53144 53145 53146 # Check whether --enable-warnings-as-errors was given. 53147 if test "${enable_warnings_as_errors+set}" = set; then : 53148 enableval=$enable_warnings_as_errors; 53149 fi 53150 53151 53152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 53153 $as_echo_n "checking if native warnings are errors... " >&6; } 53154 if test "x$enable_warnings_as_errors" = "xyes"; then 53155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitly set)" >&5 53156 $as_echo "yes (explicitly set)" >&6; } 53157 WARNINGS_AS_ERRORS=true 53158 elif test "x$enable_warnings_as_errors" = "xno"; then 53159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53160 $as_echo "no" >&6; } 53161 WARNINGS_AS_ERRORS=false 53162 elif test "x$enable_warnings_as_errors" = "x"; then 53163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 53164 $as_echo "yes (default)" >&6; } 53165 WARNINGS_AS_ERRORS=true 53166 else 53167 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 53168 fi 53169 53170 53171 53172 case "${TOOLCHAIN_TYPE}" in 53173 microsoft) 53174 DISABLE_WARNING_PREFIX="-wd" 53175 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 53176 ;; 53177 solstudio) 53178 DISABLE_WARNING_PREFIX="-erroff=" 53179 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 53180 ;; 53181 gcc) 53182 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 53183 53184 53185 53186 53187 53188 53189 53190 53191 53192 53193 53194 53195 53196 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 # Execute function body 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 53257 53258 53259 53260 53261 53262 53263 53264 53265 53266 53267 53268 53269 53270 53271 53272 53273 53274 53275 53276 53277 53278 53279 # Execute function body 53280 53281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53282 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53283 supports=yes 53284 53285 saved_cflags="$CFLAGS" 53286 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 53287 ac_ext=c 53288 ac_cpp='$CPP $CPPFLAGS' 53289 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53290 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53291 ac_compiler_gnu=$ac_cv_c_compiler_gnu 53292 53293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53294 /* end confdefs.h. */ 53295 int i; 53296 _ACEOF 53297 if ac_fn_c_try_compile "$LINENO"; then : 53298 53299 else 53300 supports=no 53301 fi 53302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53303 ac_ext=cpp 53304 ac_cpp='$CXXCPP $CPPFLAGS' 53305 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53306 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53307 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53308 53309 CFLAGS="$saved_cflags" 53310 53311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53312 $as_echo "$supports" >&6; } 53313 if test "x$supports" = "xyes" ; then 53314 : 53315 C_COMP_SUPPORTS="yes" 53316 else 53317 : 53318 C_COMP_SUPPORTS="no" 53319 fi 53320 53321 53322 53323 53324 53325 53326 53327 53328 53329 53330 53331 53332 53333 53334 53335 53336 53337 53338 53339 53340 53341 53342 53343 53344 53345 53346 53347 53348 53349 53350 53351 53352 53353 53354 53355 53356 53357 53358 53359 53360 53361 53362 53363 53364 53365 53366 53367 53368 53369 53370 53371 53372 53373 53374 53375 53376 53377 53378 53379 # Execute function body 53380 53381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53382 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53383 supports=yes 53384 53385 saved_cxxflags="$CXXFLAGS" 53386 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 53387 ac_ext=cpp 53388 ac_cpp='$CXXCPP $CPPFLAGS' 53389 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53390 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53391 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53392 53393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53394 /* end confdefs.h. */ 53395 int i; 53396 _ACEOF 53397 if ac_fn_cxx_try_compile "$LINENO"; then : 53398 53399 else 53400 supports=no 53401 fi 53402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53403 ac_ext=cpp 53404 ac_cpp='$CXXCPP $CPPFLAGS' 53405 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53406 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53407 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53408 53409 CXXFLAGS="$saved_cxxflags" 53410 53411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53412 $as_echo "$supports" >&6; } 53413 if test "x$supports" = "xyes" ; then 53414 : 53415 CXX_COMP_SUPPORTS="yes" 53416 else 53417 : 53418 CXX_COMP_SUPPORTS="no" 53419 fi 53420 53421 53422 53423 53424 53425 53426 53427 53428 53429 53430 53431 53432 53433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53434 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53435 supports=no 53436 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 53437 53438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53439 $as_echo "$supports" >&6; } 53440 if test "x$supports" = "xyes" ; then 53441 : 53442 GCC_CAN_DISABLE_WARNINGS=true 53443 else 53444 : 53445 GCC_CAN_DISABLE_WARNINGS=false 53446 53447 fi 53448 53449 53450 53451 53452 53453 53454 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 53455 DISABLE_WARNING_PREFIX="-Wno-" 53456 else 53457 DISABLE_WARNING_PREFIX= 53458 fi 53459 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 53460 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 53461 # CFLAGS since any target specific flags will likely not work with the 53462 # build compiler 53463 CC_OLD="$CC" 53464 CXX_OLD="$CXX" 53465 CC="$BUILD_CC" 53466 CXX="$BUILD_CXX" 53467 CFLAGS_OLD="$CFLAGS" 53468 CFLAGS="" 53469 53470 53471 53472 53473 53474 53475 53476 53477 53478 53479 53480 53481 53482 53483 53484 53485 53486 53487 53488 53489 53490 53491 53492 53493 53494 53495 53496 53497 53498 53499 53500 53501 53502 53503 53504 53505 53506 53507 53508 53509 53510 53511 53512 53513 53514 53515 53516 # Execute function body 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_cflags="$CFLAGS" 53572 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 53573 ac_ext=c 53574 ac_cpp='$CPP $CPPFLAGS' 53575 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53576 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53577 ac_compiler_gnu=$ac_cv_c_compiler_gnu 53578 53579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53580 /* end confdefs.h. */ 53581 int i; 53582 _ACEOF 53583 if ac_fn_c_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 CFLAGS="$saved_cflags" 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 C_COMP_SUPPORTS="yes" 53602 else 53603 : 53604 C_COMP_SUPPORTS="no" 53605 fi 53606 53607 53608 53609 53610 53611 53612 53613 53614 53615 53616 53617 53618 53619 53620 53621 53622 53623 53624 53625 53626 53627 53628 53629 53630 53631 53632 53633 53634 53635 53636 53637 53638 53639 53640 53641 53642 53643 53644 53645 53646 53647 53648 53649 53650 53651 53652 53653 53654 53655 53656 53657 53658 53659 53660 53661 53662 53663 53664 53665 # Execute function body 53666 53667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53668 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53669 supports=yes 53670 53671 saved_cxxflags="$CXXFLAGS" 53672 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 53673 ac_ext=cpp 53674 ac_cpp='$CXXCPP $CPPFLAGS' 53675 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53676 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53677 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53678 53679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53680 /* end confdefs.h. */ 53681 int i; 53682 _ACEOF 53683 if ac_fn_cxx_try_compile "$LINENO"; then : 53684 53685 else 53686 supports=no 53687 fi 53688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 53689 ac_ext=cpp 53690 ac_cpp='$CXXCPP $CPPFLAGS' 53691 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53692 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53693 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53694 53695 CXXFLAGS="$saved_cxxflags" 53696 53697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53698 $as_echo "$supports" >&6; } 53699 if test "x$supports" = "xyes" ; then 53700 : 53701 CXX_COMP_SUPPORTS="yes" 53702 else 53703 : 53704 CXX_COMP_SUPPORTS="no" 53705 fi 53706 53707 53708 53709 53710 53711 53712 53713 53714 53715 53716 53717 53718 53719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 53720 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 53721 supports=no 53722 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 53723 53724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 53725 $as_echo "$supports" >&6; } 53726 if test "x$supports" = "xyes" ; then 53727 : 53728 BUILD_CC_CAN_DISABLE_WARNINGS=true 53729 else 53730 : 53731 BUILD_CC_CAN_DISABLE_WARNINGS=false 53732 53733 fi 53734 53735 53736 53737 53738 53739 53740 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 53741 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 53742 else 53743 BUILD_CC_DISABLE_WARNING_PREFIX= 53744 fi 53745 CC="$CC_OLD" 53746 CXX="$CXX_OLD" 53747 CFLAGS="$CFLAGS_OLD" 53748 ;; 53749 clang) 53750 DISABLE_WARNING_PREFIX="-Wno-" 53751 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 53752 ;; 53753 xlc) 53754 DISABLE_WARNING_PREFIX="-qsuppress=" 53755 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 53756 ;; 53757 esac 53758 53759 53760 53761 53762 53763 # Setup debug symbols (need objcopy from the toolchain for that) 53764 53765 # 53766 # NATIVE_DEBUG_SYMBOLS 53767 # This must be done after the toolchain is setup, since we're looking at objcopy. 53768 # 53769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 53770 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 53771 53772 # Check whether --with-native-debug-symbols was given. 53773 if test "${with_native_debug_symbols+set}" = set; then : 53774 withval=$with_native_debug_symbols; 53775 if test "x$OPENJDK_TARGET_OS" = xaix; then 53776 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 53777 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 53778 fi 53779 fi 53780 53781 else 53782 53783 if test "x$OPENJDK_TARGET_OS" = xaix; then 53784 # AIX doesn't support 'zipped' so use 'internal' as default 53785 with_native_debug_symbols="internal" 53786 else 53787 if test "x$STATIC_BUILD" = xtrue; then 53788 with_native_debug_symbols="none" 53789 else 53790 with_native_debug_symbols="zipped" 53791 fi 53792 fi 53793 53794 fi 53795 53796 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 53797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 53798 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 53799 53800 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 53801 53802 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 53803 if test "x$OBJCOPY" = x; then 53804 # enabling of enable-debug-symbols and can't find objcopy 53805 # this is an error 53806 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 53807 fi 53808 fi 53809 53810 COMPILE_WITH_DEBUG_SYMBOLS=true 53811 COPY_DEBUG_SYMBOLS=true 53812 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 53813 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 53814 COMPILE_WITH_DEBUG_SYMBOLS=false 53815 COPY_DEBUG_SYMBOLS=false 53816 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 53817 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 53818 COMPILE_WITH_DEBUG_SYMBOLS=true 53819 COPY_DEBUG_SYMBOLS=false 53820 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 53821 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 53822 53823 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 53824 if test "x$OBJCOPY" = x; then 53825 # enabling of enable-debug-symbols and can't find objcopy 53826 # this is an error 53827 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 53828 fi 53829 fi 53830 53831 COMPILE_WITH_DEBUG_SYMBOLS=true 53832 COPY_DEBUG_SYMBOLS=true 53833 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 53834 else 53835 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 53836 fi 53837 53838 # --enable-debug-symbols is deprecated. 53839 # Please use --with-native-debug-symbols=[internal,external,zipped] . 53840 53841 # Check whether --enable-debug-symbols was given. 53842 if test "${enable_debug_symbols+set}" = set; then : 53843 enableval=$enable_debug_symbols; 53844 fi 53845 53846 if test "x$enable_debug_symbols" != x; then 53847 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 53848 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 53849 53850 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 53851 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 53852 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 53853 fi 53854 53855 fi 53856 53857 53858 # --enable-zip-debug-info is deprecated. 53859 # Please use --with-native-debug-symbols=zipped . 53860 53861 # Check whether --enable-zip-debug-info was given. 53862 if test "${enable_zip_debug_info+set}" = set; then : 53863 enableval=$enable_zip_debug_info; 53864 fi 53865 53866 if test "x$enable_zip_debug_info" != x; then 53867 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 53868 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 53869 53870 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 53871 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 53872 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 53873 fi 53874 53875 fi 53876 53877 53878 53879 53880 53881 53882 53883 # Check whether --enable-native-coverage was given. 53884 if test "${enable_native_coverage+set}" = set; then : 53885 enableval=$enable_native_coverage; 53886 fi 53887 53888 GCOV_ENABLED="false" 53889 if test "x$enable_native_coverage" = "xyes"; then 53890 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 53891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 53892 $as_echo_n "checking if native coverage is enabled... " >&6; } 53893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53894 $as_echo "yes" >&6; } 53895 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 53896 GCOV_LDFLAGS="-fprofile-arcs" 53897 JVM_CFLAGS="$JVM_CFLAGS $GCOV_CFLAGS" 53898 JVM_LDFLAGS="$JVM_LDFLAGS $GCOV_LDFLAGS" 53899 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 53900 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 53901 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 53902 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 53903 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 53904 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 53905 GCOV_ENABLED="true" 53906 else 53907 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 53908 fi 53909 elif test "x$enable_native_coverage" = "xno"; then 53910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 53911 $as_echo_n "checking if native coverage is enabled... " >&6; } 53912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53913 $as_echo "no" >&6; } 53914 elif test "x$enable_native_coverage" != "x"; then 53915 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 53916 fi 53917 53918 53919 53920 53921 # Need toolchain to setup dtrace 53922 53923 # Test for dtrace dependencies 53924 # Check whether --enable-dtrace was given. 53925 if test "${enable_dtrace+set}" = set; then : 53926 enableval=$enable_dtrace; 53927 fi 53928 53929 53930 DTRACE_DEP_MISSING=false 53931 53932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 53933 $as_echo_n "checking for dtrace tool... " >&6; } 53934 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 53935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 53936 $as_echo "$DTRACE" >&6; } 53937 else 53938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 53939 $as_echo "not found, cannot build dtrace" >&6; } 53940 DTRACE_DEP_MISSING=true 53941 fi 53942 53943 for ac_header in sys/sdt.h 53944 do : 53945 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 53946 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 53947 cat >>confdefs.h <<_ACEOF 53948 #define HAVE_SYS_SDT_H 1 53949 _ACEOF 53950 DTRACE_HEADERS_OK=yes 53951 else 53952 DTRACE_HEADERS_OK=no 53953 fi 53954 53955 done 53956 53957 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 53958 DTRACE_DEP_MISSING=true 53959 fi 53960 53961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 53962 $as_echo_n "checking if dtrace should be built... " >&6; } 53963 if test "x$enable_dtrace" = "xyes"; then 53964 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 53965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 53966 $as_echo "no, missing dependencies" >&6; } 53967 53968 # Print a helpful message on how to acquire the necessary build dependency. 53969 # dtrace is the help tag: freetype, cups, alsa etc 53970 MISSING_DEPENDENCY=dtrace 53971 53972 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53973 cygwin_help $MISSING_DEPENDENCY 53974 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53975 msys_help $MISSING_DEPENDENCY 53976 else 53977 PKGHANDLER_COMMAND= 53978 53979 case $PKGHANDLER in 53980 apt-get) 53981 apt_help $MISSING_DEPENDENCY ;; 53982 yum) 53983 yum_help $MISSING_DEPENDENCY ;; 53984 brew) 53985 brew_help $MISSING_DEPENDENCY ;; 53986 port) 53987 port_help $MISSING_DEPENDENCY ;; 53988 pkgutil) 53989 pkgutil_help $MISSING_DEPENDENCY ;; 53990 pkgadd) 53991 pkgadd_help $MISSING_DEPENDENCY ;; 53992 esac 53993 53994 if test "x$PKGHANDLER_COMMAND" != x; then 53995 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 53996 fi 53997 fi 53998 53999 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 54000 else 54001 INCLUDE_DTRACE=true 54002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 54003 $as_echo "yes, forced" >&6; } 54004 fi 54005 elif test "x$enable_dtrace" = "xno"; then 54006 INCLUDE_DTRACE=false 54007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 54008 $as_echo "no, forced" >&6; } 54009 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 54010 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 54011 INCLUDE_DTRACE=false 54012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 54013 $as_echo "no, missing dependencies" >&6; } 54014 else 54015 INCLUDE_DTRACE=true 54016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 54017 $as_echo "yes, dependencies present" >&6; } 54018 fi 54019 else 54020 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 54021 fi 54022 54023 54024 # Check whether --enable-aot was given. 54025 if test "${enable_aot+set}" = set; then : 54026 enableval=$enable_aot; 54027 fi 54028 54029 54030 if test "x$enable_aot" = "x" || test "x$enable_aot" = "xauto"; then 54031 ENABLE_AOT="true" 54032 elif test "x$enable_aot" = "xyes"; then 54033 ENABLE_AOT="true" 54034 elif test "x$enable_aot" = "xno"; then 54035 ENABLE_AOT="false" 54036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 54037 $as_echo_n "checking if aot should be enabled... " >&6; } 54038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 54039 $as_echo "no, forced" >&6; } 54040 else 54041 as_fn_error $? "Invalid value for --enable-aot: $enable_aot" "$LINENO" 5 54042 fi 54043 54044 if test "x$ENABLE_AOT" = "xtrue"; then 54045 # Only enable AOT on X64 platforms. 54046 if test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 54047 if test -e "${TOPDIR}/src/jdk.aot"; then 54048 if test -e "${TOPDIR}/src/jdk.internal.vm.compiler"; then 54049 ENABLE_AOT="true" 54050 else 54051 ENABLE_AOT="false" 54052 if test "x$enable_aot" = "xyes"; then 54053 as_fn_error $? "Cannot build AOT without src/jdk.internal.vm.compiler sources. Remove --enable-aot." "$LINENO" 5 54054 fi 54055 fi 54056 else 54057 ENABLE_AOT="false" 54058 if test "x$enable_aot" = "xyes"; then 54059 as_fn_error $? "Cannot build AOT without src/jdk.aot sources. Remove --enable-aot." "$LINENO" 5 54060 fi 54061 fi 54062 else 54063 ENABLE_AOT="false" 54064 if test "x$enable_aot" = "xyes"; then 54065 as_fn_error $? "AOT is currently only supported on x86_64. Remove --enable-aot." "$LINENO" 5 54066 fi 54067 fi 54068 fi 54069 54070 54071 54072 54073 # Check whether --enable-cds was given. 54074 if test "${enable_cds+set}" = set; then : 54075 enableval=$enable_cds; 54076 fi 54077 54078 54079 if test "x$enable_cds" = "x" || test "x$enable_cds" = "xyes"; then 54080 ENABLE_CDS="true" 54081 elif test "x$enable_cds" = "xno"; then 54082 ENABLE_CDS="false" 54083 else 54084 as_fn_error $? "Invalid value for --enable-cds: $enable_cds" "$LINENO" 5 54085 fi 54086 54087 54088 54089 54090 # Check whether --enable-hotspot-gtest was given. 54091 if test "${enable_hotspot_gtest+set}" = set; then : 54092 enableval=$enable_hotspot_gtest; 54093 fi 54094 54095 54096 if test -e "${TOPDIR}/test/hotspot/gtest"; then 54097 GTEST_DIR_EXISTS="true" 54098 else 54099 GTEST_DIR_EXISTS="false" 54100 fi 54101 54102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 54103 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 54104 if test "x$enable_hotspot_gtest" = "xyes"; then 54105 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 54106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 54107 $as_echo "yes, forced" >&6; } 54108 BUILD_GTEST="true" 54109 else 54110 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 54111 fi 54112 elif test "x$enable_hotspot_gtest" = "xno"; then 54113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 54114 $as_echo "no, forced" >&6; } 54115 BUILD_GTEST="false" 54116 elif test "x$enable_hotspot_gtest" = "x"; then 54117 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 54118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54119 $as_echo "yes" >&6; } 54120 BUILD_GTEST="true" 54121 else 54122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54123 $as_echo "no" >&6; } 54124 BUILD_GTEST="false" 54125 fi 54126 else 54127 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 54128 fi 54129 54130 54131 54132 54133 ############################################################################### 54134 # 54135 # Check dependencies for external and internal libraries. 54136 # 54137 ############################################################################### 54138 54139 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 54140 54141 # When using cygwin or msys, we need a wrapper binary that renames 54142 # /cygdrive/c/ arguments into c:/ arguments and peeks into 54143 # @files and rewrites these too! This wrapper binary is 54144 # called fixpath. 54145 FIXPATH= 54146 if test "x$OPENJDK_BUILD_OS" = xwindows; then 54147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 54148 $as_echo_n "checking if fixpath can be created... " >&6; } 54149 FIXPATH_SRC="$SRC_ROOT/make/src/native/fixpath.c" 54150 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 54151 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 54152 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 54153 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 54154 FIXPATH="$FIXPATH_BIN -c" 54155 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 54156 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 54157 # @ was chosen as separator to minimize risk of other tools messing around with it 54158 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 54159 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 54160 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 54161 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 54162 fi 54163 FIXPATH_SRC_W="$FIXPATH_SRC" 54164 FIXPATH_BIN_W="$FIXPATH_BIN" 54165 54166 unix_path="$FIXPATH_SRC_W" 54167 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54168 windows_path=`$CYGPATH -m "$unix_path"` 54169 FIXPATH_SRC_W="$windows_path" 54170 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54171 windows_path=`cmd //c echo $unix_path` 54172 FIXPATH_SRC_W="$windows_path" 54173 fi 54174 54175 54176 unix_path="$FIXPATH_BIN_W" 54177 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54178 windows_path=`$CYGPATH -m "$unix_path"` 54179 FIXPATH_BIN_W="$windows_path" 54180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54181 windows_path=`cmd //c echo $unix_path` 54182 FIXPATH_BIN_W="$windows_path" 54183 fi 54184 54185 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 54186 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 54187 cd $FIXPATH_DIR 54188 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 54189 cd $CURDIR 54190 54191 if test ! -x $FIXPATH_BIN; then 54192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54193 $as_echo "no" >&6; } 54194 cat $FIXPATH_DIR/fixpath1.log 54195 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 54196 fi 54197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54198 $as_echo "yes" >&6; } 54199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 54200 $as_echo_n "checking if fixpath.exe works... " >&6; } 54201 cd $FIXPATH_DIR 54202 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 54203 > $FIXPATH_DIR/fixpath2.log 2>&1 54204 cd $CURDIR 54205 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 54206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54207 $as_echo "no" >&6; } 54208 cat $FIXPATH_DIR/fixpath2.log 54209 as_fn_error $? "fixpath did not work!" "$LINENO" 5 54210 fi 54211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 54212 $as_echo "yes" >&6; } 54213 54214 FIXPATH_DETACH_FLAG="--detach" 54215 fi 54216 54217 54218 54219 54220 54221 54222 # Check if X11 is needed 54223 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 54224 # No X11 support on windows or macosx 54225 NEEDS_LIB_X11=false 54226 else 54227 # All other instances need X11, even if building headless only, libawt still 54228 # needs X11 headers. 54229 NEEDS_LIB_X11=true 54230 fi 54231 54232 # Check if cups is needed 54233 if test "x$OPENJDK_TARGET_OS" = xwindows; then 54234 # Windows have a separate print system 54235 NEEDS_LIB_CUPS=false 54236 else 54237 NEEDS_LIB_CUPS=true 54238 fi 54239 54240 # A custom hook may have set this already 54241 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 54242 NEEDS_LIB_FREETYPE=true 54243 fi 54244 54245 # Check if alsa is needed 54246 if test "x$OPENJDK_TARGET_OS" = xlinux; then 54247 NEEDS_LIB_ALSA=true 54248 else 54249 NEEDS_LIB_ALSA=false 54250 fi 54251 54252 # Check if ffi is needed 54253 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 54254 NEEDS_LIB_FFI=true 54255 else 54256 NEEDS_LIB_FFI=false 54257 fi 54258 54259 54260 # statically link libstdc++ before C++ ABI is stablized on Linux unless 54261 # dynamic build is configured on command line. 54262 54263 # Check whether --with-stdc++lib was given. 54264 if test "${with_stdc__lib+set}" = set; then : 54265 withval=$with_stdc__lib; 54266 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 54267 && test "x$with_stdc__lib" != xdefault; then 54268 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 54269 fi 54270 54271 else 54272 with_stdc__lib=default 54273 54274 fi 54275 54276 54277 if test "x$OPENJDK_TARGET_OS" = xlinux; then 54278 # Test if stdc++ can be linked statically. 54279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 54280 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 54281 STATIC_STDCXX_FLAGS="-static-libstdc++ -static-libgcc" 54282 ac_ext=cpp 54283 ac_cpp='$CXXCPP $CPPFLAGS' 54284 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54285 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54286 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54287 54288 OLD_LIBS="$LIBS" 54289 LIBS="$STATIC_STDCXX_FLAGS" 54290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 54291 /* end confdefs.h. */ 54292 54293 int 54294 main () 54295 { 54296 return 0; 54297 ; 54298 return 0; 54299 } 54300 _ACEOF 54301 if ac_fn_cxx_try_link "$LINENO"; then : 54302 has_static_libstdcxx=yes 54303 else 54304 has_static_libstdcxx=no 54305 fi 54306 rm -f core conftest.err conftest.$ac_objext \ 54307 conftest$ac_exeext conftest.$ac_ext 54308 LIBS="$OLD_LIBS" 54309 ac_ext=cpp 54310 ac_cpp='$CXXCPP $CPPFLAGS' 54311 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 54312 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 54313 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 54314 54315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 54316 $as_echo "$has_static_libstdcxx" >&6; } 54317 54318 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 54319 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 54320 fi 54321 54322 # If dynamic was requested, it's available since it would fail above otherwise. 54323 # If dynamic wasn't requested, go with static unless it isn't available. 54324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 54325 $as_echo_n "checking how to link with libstdc++... " >&6; } 54326 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno \ 54327 || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 54328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 54329 $as_echo "dynamic" >&6; } 54330 else 54331 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 54332 JVM_LDFLAGS="$JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 54333 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 54334 # just use the same setting as for the TARGET toolchain. 54335 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 54336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 54337 $as_echo "static" >&6; } 54338 fi 54339 fi 54340 54341 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 54342 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 54343 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 54344 fi 54345 54346 54347 54348 # Setup Windows runtime dlls 54349 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 54350 54351 54352 # Check whether --with-msvcr-dll was given. 54353 if test "${with_msvcr_dll+set}" = set; then : 54354 withval=$with_msvcr_dll; 54355 fi 54356 54357 54358 if test "x$with_msvcr_dll" != x; then 54359 # If given explicitly by user, do not probe. If not present, fail directly. 54360 54361 DLL_NAME="$MSVCR_NAME" 54362 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 54363 METHOD="--with-msvcr-dll" 54364 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54365 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54366 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54367 54368 # Need to check if the found msvcr is correct architecture 54369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54370 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54371 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54372 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54373 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54374 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54375 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54376 CORRECT_MSVCR_ARCH="PE32 executable" 54377 else 54378 CORRECT_MSVCR_ARCH="PE32+ executable" 54379 fi 54380 else 54381 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54382 CORRECT_MSVCR_ARCH=386 54383 else 54384 CORRECT_MSVCR_ARCH=x86-64 54385 fi 54386 fi 54387 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54389 $as_echo "ok" >&6; } 54390 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54391 54392 # Only process if variable expands to non-empty 54393 54394 if test "x$MSVC_DLL" != x; then 54395 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54396 54397 # Input might be given as Windows format, start by converting to 54398 # unix format. 54399 path="$MSVC_DLL" 54400 new_path=`$CYGPATH -u "$path"` 54401 54402 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54403 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54404 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54405 # "foo.exe" is OK but "foo" is an error. 54406 # 54407 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54408 # It is also a way to make sure we got the proper file name for the real test later on. 54409 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54410 if test "x$test_shortpath" = x; then 54411 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54412 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54413 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54414 fi 54415 54416 # Call helper function which possibly converts this using DOS-style short mode. 54417 # If so, the updated path is stored in $new_path. 54418 54419 input_path="$new_path" 54420 # Check if we need to convert this using DOS-style short mode. If the path 54421 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54422 # take no chances and rewrite it. 54423 # Note: m4 eats our [], so we need to use [ and ] instead. 54424 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54425 if test "x$has_forbidden_chars" != x; then 54426 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54427 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54428 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54429 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54430 # Going to short mode and back again did indeed matter. Since short mode is 54431 # case insensitive, let's make it lowercase to improve readability. 54432 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54433 # Now convert it back to Unix-style (cygpath) 54434 input_path=`$CYGPATH -u "$shortmode_path"` 54435 new_path="$input_path" 54436 fi 54437 fi 54438 54439 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54440 if test "x$test_cygdrive_prefix" = x; then 54441 # As a simple fix, exclude /usr/bin since it's not a real path. 54442 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54443 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54444 # a path prefixed by /cygdrive for fixpath to work. 54445 new_path="$CYGWIN_ROOT_PATH$input_path" 54446 fi 54447 fi 54448 54449 54450 if test "x$path" != "x$new_path"; then 54451 MSVC_DLL="$new_path" 54452 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54453 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54454 fi 54455 54456 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54457 54458 path="$MSVC_DLL" 54459 has_colon=`$ECHO $path | $GREP ^.:` 54460 new_path="$path" 54461 if test "x$has_colon" = x; then 54462 # Not in mixed or Windows style, start by that. 54463 new_path=`cmd //c echo $path` 54464 fi 54465 54466 54467 input_path="$new_path" 54468 # Check if we need to convert this using DOS-style short mode. If the path 54469 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54470 # take no chances and rewrite it. 54471 # Note: m4 eats our [], so we need to use [ and ] instead. 54472 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54473 if test "x$has_forbidden_chars" != x; then 54474 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54475 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54476 fi 54477 54478 54479 windows_path="$new_path" 54480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54481 unix_path=`$CYGPATH -u "$windows_path"` 54482 new_path="$unix_path" 54483 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54484 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54485 new_path="$unix_path" 54486 fi 54487 54488 if test "x$path" != "x$new_path"; then 54489 MSVC_DLL="$new_path" 54490 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54491 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54492 fi 54493 54494 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54495 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54496 54497 else 54498 # We're on a unix platform. Hooray! :) 54499 path="$MSVC_DLL" 54500 has_space=`$ECHO "$path" | $GREP " "` 54501 if test "x$has_space" != x; then 54502 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54503 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54504 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54505 fi 54506 54507 # Use eval to expand a potential ~ 54508 eval path="$path" 54509 if test ! -f "$path" && test ! -d "$path"; then 54510 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54511 fi 54512 54513 if test -d "$path"; then 54514 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54515 else 54516 dir="`$DIRNAME "$path"`" 54517 base="`$BASENAME "$path"`" 54518 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54519 fi 54520 fi 54521 fi 54522 54523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54524 $as_echo_n "checking for $DLL_NAME... " >&6; } 54525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54526 $as_echo "$MSVC_DLL" >&6; } 54527 else 54528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54529 $as_echo "incorrect, ignoring" >&6; } 54530 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54531 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54532 fi 54533 fi 54534 54535 if test "x$MSVC_DLL" = x; then 54536 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 54537 fi 54538 MSVCR_DLL="$MSVC_DLL" 54539 elif test "x$DEVKIT_MSVCR_DLL" != x; then 54540 54541 DLL_NAME="$MSVCR_NAME" 54542 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 54543 METHOD="devkit" 54544 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54545 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54546 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54547 54548 # Need to check if the found msvcr is correct architecture 54549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54550 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54551 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54552 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54553 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54554 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54555 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54556 CORRECT_MSVCR_ARCH="PE32 executable" 54557 else 54558 CORRECT_MSVCR_ARCH="PE32+ executable" 54559 fi 54560 else 54561 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54562 CORRECT_MSVCR_ARCH=386 54563 else 54564 CORRECT_MSVCR_ARCH=x86-64 54565 fi 54566 fi 54567 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54569 $as_echo "ok" >&6; } 54570 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54571 54572 # Only process if variable expands to non-empty 54573 54574 if test "x$MSVC_DLL" != x; then 54575 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54576 54577 # Input might be given as Windows format, start by converting to 54578 # unix format. 54579 path="$MSVC_DLL" 54580 new_path=`$CYGPATH -u "$path"` 54581 54582 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54583 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54584 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54585 # "foo.exe" is OK but "foo" is an error. 54586 # 54587 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54588 # It is also a way to make sure we got the proper file name for the real test later on. 54589 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54590 if test "x$test_shortpath" = x; then 54591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54592 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54593 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54594 fi 54595 54596 # Call helper function which possibly converts this using DOS-style short mode. 54597 # If so, the updated path is stored in $new_path. 54598 54599 input_path="$new_path" 54600 # Check if we need to convert this using DOS-style short mode. If the path 54601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54602 # take no chances and rewrite it. 54603 # Note: m4 eats our [], so we need to use [ and ] instead. 54604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54605 if test "x$has_forbidden_chars" != x; then 54606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54607 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54608 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54609 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54610 # Going to short mode and back again did indeed matter. Since short mode is 54611 # case insensitive, let's make it lowercase to improve readability. 54612 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54613 # Now convert it back to Unix-style (cygpath) 54614 input_path=`$CYGPATH -u "$shortmode_path"` 54615 new_path="$input_path" 54616 fi 54617 fi 54618 54619 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54620 if test "x$test_cygdrive_prefix" = x; then 54621 # As a simple fix, exclude /usr/bin since it's not a real path. 54622 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54623 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54624 # a path prefixed by /cygdrive for fixpath to work. 54625 new_path="$CYGWIN_ROOT_PATH$input_path" 54626 fi 54627 fi 54628 54629 54630 if test "x$path" != "x$new_path"; then 54631 MSVC_DLL="$new_path" 54632 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54633 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54634 fi 54635 54636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54637 54638 path="$MSVC_DLL" 54639 has_colon=`$ECHO $path | $GREP ^.:` 54640 new_path="$path" 54641 if test "x$has_colon" = x; then 54642 # Not in mixed or Windows style, start by that. 54643 new_path=`cmd //c echo $path` 54644 fi 54645 54646 54647 input_path="$new_path" 54648 # Check if we need to convert this using DOS-style short mode. If the path 54649 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54650 # take no chances and rewrite it. 54651 # Note: m4 eats our [], so we need to use [ and ] instead. 54652 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54653 if test "x$has_forbidden_chars" != x; then 54654 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54655 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54656 fi 54657 54658 54659 windows_path="$new_path" 54660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54661 unix_path=`$CYGPATH -u "$windows_path"` 54662 new_path="$unix_path" 54663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54665 new_path="$unix_path" 54666 fi 54667 54668 if test "x$path" != "x$new_path"; then 54669 MSVC_DLL="$new_path" 54670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54671 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54672 fi 54673 54674 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54675 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54676 54677 else 54678 # We're on a unix platform. Hooray! :) 54679 path="$MSVC_DLL" 54680 has_space=`$ECHO "$path" | $GREP " "` 54681 if test "x$has_space" != x; then 54682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54683 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54684 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54685 fi 54686 54687 # Use eval to expand a potential ~ 54688 eval path="$path" 54689 if test ! -f "$path" && test ! -d "$path"; then 54690 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54691 fi 54692 54693 if test -d "$path"; then 54694 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54695 else 54696 dir="`$DIRNAME "$path"`" 54697 base="`$BASENAME "$path"`" 54698 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54699 fi 54700 fi 54701 fi 54702 54703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54704 $as_echo_n "checking for $DLL_NAME... " >&6; } 54705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54706 $as_echo "$MSVC_DLL" >&6; } 54707 else 54708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54709 $as_echo "incorrect, ignoring" >&6; } 54710 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54711 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54712 fi 54713 fi 54714 54715 if test "x$MSVC_DLL" = x; then 54716 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 54717 fi 54718 MSVCR_DLL="$MSVC_DLL" 54719 else 54720 54721 DLL_NAME="${MSVCR_NAME}" 54722 MSVC_DLL= 54723 54724 if test "x$MSVC_DLL" = x; then 54725 # Probe: Using well-known location from Visual Studio 10.0 54726 if test "x$VCINSTALLDIR" != x; then 54727 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 54728 54729 windows_path="$CYGWIN_VC_INSTALL_DIR" 54730 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54731 unix_path=`$CYGPATH -u "$windows_path"` 54732 CYGWIN_VC_INSTALL_DIR="$unix_path" 54733 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54734 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54735 CYGWIN_VC_INSTALL_DIR="$unix_path" 54736 fi 54737 54738 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54739 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54740 else 54741 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54742 fi 54743 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 54744 54745 DLL_NAME="$DLL_NAME" 54746 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54747 METHOD="well-known location in VCINSTALLDIR" 54748 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54749 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54750 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54751 54752 # Need to check if the found msvcr is correct architecture 54753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54754 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54755 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54756 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54757 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54758 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54759 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54760 CORRECT_MSVCR_ARCH="PE32 executable" 54761 else 54762 CORRECT_MSVCR_ARCH="PE32+ executable" 54763 fi 54764 else 54765 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54766 CORRECT_MSVCR_ARCH=386 54767 else 54768 CORRECT_MSVCR_ARCH=x86-64 54769 fi 54770 fi 54771 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54773 $as_echo "ok" >&6; } 54774 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54775 54776 # Only process if variable expands to non-empty 54777 54778 if test "x$MSVC_DLL" != x; then 54779 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54780 54781 # Input might be given as Windows format, start by converting to 54782 # unix format. 54783 path="$MSVC_DLL" 54784 new_path=`$CYGPATH -u "$path"` 54785 54786 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54787 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54788 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54789 # "foo.exe" is OK but "foo" is an error. 54790 # 54791 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54792 # It is also a way to make sure we got the proper file name for the real test later on. 54793 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54794 if test "x$test_shortpath" = x; then 54795 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54796 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54797 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54798 fi 54799 54800 # Call helper function which possibly converts this using DOS-style short mode. 54801 # If so, the updated path is stored in $new_path. 54802 54803 input_path="$new_path" 54804 # Check if we need to convert this using DOS-style short mode. If the path 54805 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54806 # take no chances and rewrite it. 54807 # Note: m4 eats our [], so we need to use [ and ] instead. 54808 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54809 if test "x$has_forbidden_chars" != x; then 54810 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54811 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54812 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54813 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54814 # Going to short mode and back again did indeed matter. Since short mode is 54815 # case insensitive, let's make it lowercase to improve readability. 54816 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54817 # Now convert it back to Unix-style (cygpath) 54818 input_path=`$CYGPATH -u "$shortmode_path"` 54819 new_path="$input_path" 54820 fi 54821 fi 54822 54823 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54824 if test "x$test_cygdrive_prefix" = x; then 54825 # As a simple fix, exclude /usr/bin since it's not a real path. 54826 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54827 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54828 # a path prefixed by /cygdrive for fixpath to work. 54829 new_path="$CYGWIN_ROOT_PATH$input_path" 54830 fi 54831 fi 54832 54833 54834 if test "x$path" != "x$new_path"; then 54835 MSVC_DLL="$new_path" 54836 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54837 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54838 fi 54839 54840 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54841 54842 path="$MSVC_DLL" 54843 has_colon=`$ECHO $path | $GREP ^.:` 54844 new_path="$path" 54845 if test "x$has_colon" = x; then 54846 # Not in mixed or Windows style, start by that. 54847 new_path=`cmd //c echo $path` 54848 fi 54849 54850 54851 input_path="$new_path" 54852 # Check if we need to convert this using DOS-style short mode. If the path 54853 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54854 # take no chances and rewrite it. 54855 # Note: m4 eats our [], so we need to use [ and ] instead. 54856 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54857 if test "x$has_forbidden_chars" != x; then 54858 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54859 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54860 fi 54861 54862 54863 windows_path="$new_path" 54864 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54865 unix_path=`$CYGPATH -u "$windows_path"` 54866 new_path="$unix_path" 54867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54868 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54869 new_path="$unix_path" 54870 fi 54871 54872 if test "x$path" != "x$new_path"; then 54873 MSVC_DLL="$new_path" 54874 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54875 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54876 fi 54877 54878 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54879 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54880 54881 else 54882 # We're on a unix platform. Hooray! :) 54883 path="$MSVC_DLL" 54884 has_space=`$ECHO "$path" | $GREP " "` 54885 if test "x$has_space" != x; then 54886 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54887 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54888 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54889 fi 54890 54891 # Use eval to expand a potential ~ 54892 eval path="$path" 54893 if test ! -f "$path" && test ! -d "$path"; then 54894 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54895 fi 54896 54897 if test -d "$path"; then 54898 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54899 else 54900 dir="`$DIRNAME "$path"`" 54901 base="`$BASENAME "$path"`" 54902 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54903 fi 54904 fi 54905 fi 54906 54907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54908 $as_echo_n "checking for $DLL_NAME... " >&6; } 54909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54910 $as_echo "$MSVC_DLL" >&6; } 54911 else 54912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54913 $as_echo "incorrect, ignoring" >&6; } 54914 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54915 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54916 fi 54917 fi 54918 54919 fi 54920 fi 54921 54922 if test "x$MSVC_DLL" = x; then 54923 # Probe: Check in the Boot JDK directory. 54924 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 54925 54926 DLL_NAME="$DLL_NAME" 54927 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54928 METHOD="well-known location in Boot JDK" 54929 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54930 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54931 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54932 54933 # Need to check if the found msvcr is correct architecture 54934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54935 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54936 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54937 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54938 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54939 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54940 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54941 CORRECT_MSVCR_ARCH="PE32 executable" 54942 else 54943 CORRECT_MSVCR_ARCH="PE32+ executable" 54944 fi 54945 else 54946 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54947 CORRECT_MSVCR_ARCH=386 54948 else 54949 CORRECT_MSVCR_ARCH=x86-64 54950 fi 54951 fi 54952 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54954 $as_echo "ok" >&6; } 54955 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54956 54957 # Only process if variable expands to non-empty 54958 54959 if test "x$MSVC_DLL" != x; then 54960 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54961 54962 # Input might be given as Windows format, start by converting to 54963 # unix format. 54964 path="$MSVC_DLL" 54965 new_path=`$CYGPATH -u "$path"` 54966 54967 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54968 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54969 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54970 # "foo.exe" is OK but "foo" is an error. 54971 # 54972 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54973 # It is also a way to make sure we got the proper file name for the real test later on. 54974 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54975 if test "x$test_shortpath" = x; then 54976 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54977 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54978 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54979 fi 54980 54981 # Call helper function which possibly converts this using DOS-style short mode. 54982 # If so, the updated path is stored in $new_path. 54983 54984 input_path="$new_path" 54985 # Check if we need to convert this using DOS-style short mode. If the path 54986 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54987 # take no chances and rewrite it. 54988 # Note: m4 eats our [], so we need to use [ and ] instead. 54989 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54990 if test "x$has_forbidden_chars" != x; then 54991 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54992 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54993 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54994 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54995 # Going to short mode and back again did indeed matter. Since short mode is 54996 # case insensitive, let's make it lowercase to improve readability. 54997 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54998 # Now convert it back to Unix-style (cygpath) 54999 input_path=`$CYGPATH -u "$shortmode_path"` 55000 new_path="$input_path" 55001 fi 55002 fi 55003 55004 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55005 if test "x$test_cygdrive_prefix" = x; then 55006 # As a simple fix, exclude /usr/bin since it's not a real path. 55007 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55008 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55009 # a path prefixed by /cygdrive for fixpath to work. 55010 new_path="$CYGWIN_ROOT_PATH$input_path" 55011 fi 55012 fi 55013 55014 55015 if test "x$path" != "x$new_path"; then 55016 MSVC_DLL="$new_path" 55017 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55018 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55019 fi 55020 55021 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55022 55023 path="$MSVC_DLL" 55024 has_colon=`$ECHO $path | $GREP ^.:` 55025 new_path="$path" 55026 if test "x$has_colon" = x; then 55027 # Not in mixed or Windows style, start by that. 55028 new_path=`cmd //c echo $path` 55029 fi 55030 55031 55032 input_path="$new_path" 55033 # Check if we need to convert this using DOS-style short mode. If the path 55034 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55035 # take no chances and rewrite it. 55036 # Note: m4 eats our [], so we need to use [ and ] instead. 55037 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55038 if test "x$has_forbidden_chars" != x; then 55039 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55040 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55041 fi 55042 55043 55044 windows_path="$new_path" 55045 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55046 unix_path=`$CYGPATH -u "$windows_path"` 55047 new_path="$unix_path" 55048 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55049 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55050 new_path="$unix_path" 55051 fi 55052 55053 if test "x$path" != "x$new_path"; then 55054 MSVC_DLL="$new_path" 55055 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55056 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55057 fi 55058 55059 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55060 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55061 55062 else 55063 # We're on a unix platform. Hooray! :) 55064 path="$MSVC_DLL" 55065 has_space=`$ECHO "$path" | $GREP " "` 55066 if test "x$has_space" != x; then 55067 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55068 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55069 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55070 fi 55071 55072 # Use eval to expand a potential ~ 55073 eval path="$path" 55074 if test ! -f "$path" && test ! -d "$path"; then 55075 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55076 fi 55077 55078 if test -d "$path"; then 55079 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55080 else 55081 dir="`$DIRNAME "$path"`" 55082 base="`$BASENAME "$path"`" 55083 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55084 fi 55085 fi 55086 fi 55087 55088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55089 $as_echo_n "checking for $DLL_NAME... " >&6; } 55090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55091 $as_echo "$MSVC_DLL" >&6; } 55092 else 55093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55094 $as_echo "incorrect, ignoring" >&6; } 55095 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55096 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55097 fi 55098 fi 55099 55100 fi 55101 55102 if test "x$MSVC_DLL" = x; then 55103 # Probe: Look in the Windows system32 directory 55104 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55105 55106 windows_path="$CYGWIN_SYSTEMROOT" 55107 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55108 unix_path=`$CYGPATH -u "$windows_path"` 55109 CYGWIN_SYSTEMROOT="$unix_path" 55110 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55111 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55112 CYGWIN_SYSTEMROOT="$unix_path" 55113 fi 55114 55115 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55116 55117 DLL_NAME="$DLL_NAME" 55118 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55119 METHOD="well-known location in SYSTEMROOT" 55120 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55121 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55122 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55123 55124 # Need to check if the found msvcr is correct architecture 55125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55126 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55127 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55128 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55129 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55130 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55131 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55132 CORRECT_MSVCR_ARCH="PE32 executable" 55133 else 55134 CORRECT_MSVCR_ARCH="PE32+ executable" 55135 fi 55136 else 55137 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55138 CORRECT_MSVCR_ARCH=386 55139 else 55140 CORRECT_MSVCR_ARCH=x86-64 55141 fi 55142 fi 55143 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55145 $as_echo "ok" >&6; } 55146 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55147 55148 # Only process if variable expands to non-empty 55149 55150 if test "x$MSVC_DLL" != x; then 55151 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55152 55153 # Input might be given as Windows format, start by converting to 55154 # unix format. 55155 path="$MSVC_DLL" 55156 new_path=`$CYGPATH -u "$path"` 55157 55158 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55159 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55160 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55161 # "foo.exe" is OK but "foo" is an error. 55162 # 55163 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55164 # It is also a way to make sure we got the proper file name for the real test later on. 55165 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55166 if test "x$test_shortpath" = x; then 55167 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55168 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55169 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55170 fi 55171 55172 # Call helper function which possibly converts this using DOS-style short mode. 55173 # If so, the updated path is stored in $new_path. 55174 55175 input_path="$new_path" 55176 # Check if we need to convert this using DOS-style short mode. If the path 55177 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55178 # take no chances and rewrite it. 55179 # Note: m4 eats our [], so we need to use [ and ] instead. 55180 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55181 if test "x$has_forbidden_chars" != x; then 55182 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55183 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55184 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55185 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55186 # Going to short mode and back again did indeed matter. Since short mode is 55187 # case insensitive, let's make it lowercase to improve readability. 55188 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55189 # Now convert it back to Unix-style (cygpath) 55190 input_path=`$CYGPATH -u "$shortmode_path"` 55191 new_path="$input_path" 55192 fi 55193 fi 55194 55195 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55196 if test "x$test_cygdrive_prefix" = x; then 55197 # As a simple fix, exclude /usr/bin since it's not a real path. 55198 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55199 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55200 # a path prefixed by /cygdrive for fixpath to work. 55201 new_path="$CYGWIN_ROOT_PATH$input_path" 55202 fi 55203 fi 55204 55205 55206 if test "x$path" != "x$new_path"; then 55207 MSVC_DLL="$new_path" 55208 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55209 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55210 fi 55211 55212 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55213 55214 path="$MSVC_DLL" 55215 has_colon=`$ECHO $path | $GREP ^.:` 55216 new_path="$path" 55217 if test "x$has_colon" = x; then 55218 # Not in mixed or Windows style, start by that. 55219 new_path=`cmd //c echo $path` 55220 fi 55221 55222 55223 input_path="$new_path" 55224 # Check if we need to convert this using DOS-style short mode. If the path 55225 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55226 # take no chances and rewrite it. 55227 # Note: m4 eats our [], so we need to use [ and ] instead. 55228 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55229 if test "x$has_forbidden_chars" != x; then 55230 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55231 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55232 fi 55233 55234 55235 windows_path="$new_path" 55236 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55237 unix_path=`$CYGPATH -u "$windows_path"` 55238 new_path="$unix_path" 55239 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55240 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55241 new_path="$unix_path" 55242 fi 55243 55244 if test "x$path" != "x$new_path"; then 55245 MSVC_DLL="$new_path" 55246 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55247 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55248 fi 55249 55250 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55251 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55252 55253 else 55254 # We're on a unix platform. Hooray! :) 55255 path="$MSVC_DLL" 55256 has_space=`$ECHO "$path" | $GREP " "` 55257 if test "x$has_space" != x; then 55258 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55259 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55260 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55261 fi 55262 55263 # Use eval to expand a potential ~ 55264 eval path="$path" 55265 if test ! -f "$path" && test ! -d "$path"; then 55266 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55267 fi 55268 55269 if test -d "$path"; then 55270 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55271 else 55272 dir="`$DIRNAME "$path"`" 55273 base="`$BASENAME "$path"`" 55274 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55275 fi 55276 fi 55277 fi 55278 55279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55280 $as_echo_n "checking for $DLL_NAME... " >&6; } 55281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55282 $as_echo "$MSVC_DLL" >&6; } 55283 else 55284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55285 $as_echo "incorrect, ignoring" >&6; } 55286 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55287 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55288 fi 55289 fi 55290 55291 fi 55292 55293 if test "x$MSVC_DLL" = x; then 55294 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55295 if test "x$VS100COMNTOOLS" != x; then 55296 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55297 55298 windows_path="$CYGWIN_VS_TOOLS_DIR" 55299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55300 unix_path=`$CYGPATH -u "$windows_path"` 55301 CYGWIN_VS_TOOLS_DIR="$unix_path" 55302 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55303 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55304 CYGWIN_VS_TOOLS_DIR="$unix_path" 55305 fi 55306 55307 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55308 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55309 | $GREP -i /x64/ | $HEAD --lines 1` 55310 else 55311 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55312 | $GREP -i /x86/ | $HEAD --lines 1` 55313 fi 55314 55315 DLL_NAME="$DLL_NAME" 55316 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55317 METHOD="search of VS100COMNTOOLS" 55318 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55319 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55320 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55321 55322 # Need to check if the found msvcr is correct architecture 55323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55324 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55325 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55326 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55327 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55328 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55329 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55330 CORRECT_MSVCR_ARCH="PE32 executable" 55331 else 55332 CORRECT_MSVCR_ARCH="PE32+ executable" 55333 fi 55334 else 55335 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55336 CORRECT_MSVCR_ARCH=386 55337 else 55338 CORRECT_MSVCR_ARCH=x86-64 55339 fi 55340 fi 55341 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55343 $as_echo "ok" >&6; } 55344 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55345 55346 # Only process if variable expands to non-empty 55347 55348 if test "x$MSVC_DLL" != x; then 55349 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55350 55351 # Input might be given as Windows format, start by converting to 55352 # unix format. 55353 path="$MSVC_DLL" 55354 new_path=`$CYGPATH -u "$path"` 55355 55356 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55357 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55358 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55359 # "foo.exe" is OK but "foo" is an error. 55360 # 55361 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55362 # It is also a way to make sure we got the proper file name for the real test later on. 55363 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55364 if test "x$test_shortpath" = x; then 55365 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55366 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55367 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55368 fi 55369 55370 # Call helper function which possibly converts this using DOS-style short mode. 55371 # If so, the updated path is stored in $new_path. 55372 55373 input_path="$new_path" 55374 # Check if we need to convert this using DOS-style short mode. If the path 55375 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55376 # take no chances and rewrite it. 55377 # Note: m4 eats our [], so we need to use [ and ] instead. 55378 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55379 if test "x$has_forbidden_chars" != x; then 55380 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55381 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55382 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55383 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55384 # Going to short mode and back again did indeed matter. Since short mode is 55385 # case insensitive, let's make it lowercase to improve readability. 55386 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55387 # Now convert it back to Unix-style (cygpath) 55388 input_path=`$CYGPATH -u "$shortmode_path"` 55389 new_path="$input_path" 55390 fi 55391 fi 55392 55393 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55394 if test "x$test_cygdrive_prefix" = x; then 55395 # As a simple fix, exclude /usr/bin since it's not a real path. 55396 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55397 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55398 # a path prefixed by /cygdrive for fixpath to work. 55399 new_path="$CYGWIN_ROOT_PATH$input_path" 55400 fi 55401 fi 55402 55403 55404 if test "x$path" != "x$new_path"; then 55405 MSVC_DLL="$new_path" 55406 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55407 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55408 fi 55409 55410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55411 55412 path="$MSVC_DLL" 55413 has_colon=`$ECHO $path | $GREP ^.:` 55414 new_path="$path" 55415 if test "x$has_colon" = x; then 55416 # Not in mixed or Windows style, start by that. 55417 new_path=`cmd //c echo $path` 55418 fi 55419 55420 55421 input_path="$new_path" 55422 # Check if we need to convert this using DOS-style short mode. If the path 55423 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55424 # take no chances and rewrite it. 55425 # Note: m4 eats our [], so we need to use [ and ] instead. 55426 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55427 if test "x$has_forbidden_chars" != x; then 55428 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55429 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55430 fi 55431 55432 55433 windows_path="$new_path" 55434 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55435 unix_path=`$CYGPATH -u "$windows_path"` 55436 new_path="$unix_path" 55437 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55438 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55439 new_path="$unix_path" 55440 fi 55441 55442 if test "x$path" != "x$new_path"; then 55443 MSVC_DLL="$new_path" 55444 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55445 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55446 fi 55447 55448 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55449 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55450 55451 else 55452 # We're on a unix platform. Hooray! :) 55453 path="$MSVC_DLL" 55454 has_space=`$ECHO "$path" | $GREP " "` 55455 if test "x$has_space" != x; then 55456 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55457 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55458 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55459 fi 55460 55461 # Use eval to expand a potential ~ 55462 eval path="$path" 55463 if test ! -f "$path" && test ! -d "$path"; then 55464 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55465 fi 55466 55467 if test -d "$path"; then 55468 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55469 else 55470 dir="`$DIRNAME "$path"`" 55471 base="`$BASENAME "$path"`" 55472 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55473 fi 55474 fi 55475 fi 55476 55477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55478 $as_echo_n "checking for $DLL_NAME... " >&6; } 55479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55480 $as_echo "$MSVC_DLL" >&6; } 55481 else 55482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55483 $as_echo "incorrect, ignoring" >&6; } 55484 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55485 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55486 fi 55487 fi 55488 55489 fi 55490 fi 55491 55492 if test "x$MSVC_DLL" = x; then 55493 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55494 # (This was the original behaviour; kept since it might turn something up) 55495 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55496 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55497 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55498 | $GREP x64 | $HEAD --lines 1` 55499 else 55500 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55501 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55502 if test "x$POSSIBLE_MSVC_DLL" = x; then 55503 # We're grasping at straws now... 55504 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55505 | $HEAD --lines 1` 55506 fi 55507 fi 55508 55509 55510 DLL_NAME="$DLL_NAME" 55511 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55512 METHOD="search of VCINSTALLDIR" 55513 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55514 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55515 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55516 55517 # Need to check if the found msvcr is correct architecture 55518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55519 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55520 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55521 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55522 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55523 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55524 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55525 CORRECT_MSVCR_ARCH="PE32 executable" 55526 else 55527 CORRECT_MSVCR_ARCH="PE32+ executable" 55528 fi 55529 else 55530 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55531 CORRECT_MSVCR_ARCH=386 55532 else 55533 CORRECT_MSVCR_ARCH=x86-64 55534 fi 55535 fi 55536 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55538 $as_echo "ok" >&6; } 55539 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55540 55541 # Only process if variable expands to non-empty 55542 55543 if test "x$MSVC_DLL" != x; then 55544 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55545 55546 # Input might be given as Windows format, start by converting to 55547 # unix format. 55548 path="$MSVC_DLL" 55549 new_path=`$CYGPATH -u "$path"` 55550 55551 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55552 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55553 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55554 # "foo.exe" is OK but "foo" is an error. 55555 # 55556 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55557 # It is also a way to make sure we got the proper file name for the real test later on. 55558 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55559 if test "x$test_shortpath" = x; then 55560 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55561 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55562 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55563 fi 55564 55565 # Call helper function which possibly converts this using DOS-style short mode. 55566 # If so, the updated path is stored in $new_path. 55567 55568 input_path="$new_path" 55569 # Check if we need to convert this using DOS-style short mode. If the path 55570 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55571 # take no chances and rewrite it. 55572 # Note: m4 eats our [], so we need to use [ and ] instead. 55573 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55574 if test "x$has_forbidden_chars" != x; then 55575 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55576 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55577 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55578 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55579 # Going to short mode and back again did indeed matter. Since short mode is 55580 # case insensitive, let's make it lowercase to improve readability. 55581 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55582 # Now convert it back to Unix-style (cygpath) 55583 input_path=`$CYGPATH -u "$shortmode_path"` 55584 new_path="$input_path" 55585 fi 55586 fi 55587 55588 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55589 if test "x$test_cygdrive_prefix" = x; then 55590 # As a simple fix, exclude /usr/bin since it's not a real path. 55591 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55592 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55593 # a path prefixed by /cygdrive for fixpath to work. 55594 new_path="$CYGWIN_ROOT_PATH$input_path" 55595 fi 55596 fi 55597 55598 55599 if test "x$path" != "x$new_path"; then 55600 MSVC_DLL="$new_path" 55601 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55602 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55603 fi 55604 55605 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55606 55607 path="$MSVC_DLL" 55608 has_colon=`$ECHO $path | $GREP ^.:` 55609 new_path="$path" 55610 if test "x$has_colon" = x; then 55611 # Not in mixed or Windows style, start by that. 55612 new_path=`cmd //c echo $path` 55613 fi 55614 55615 55616 input_path="$new_path" 55617 # Check if we need to convert this using DOS-style short mode. If the path 55618 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55619 # take no chances and rewrite it. 55620 # Note: m4 eats our [], so we need to use [ and ] instead. 55621 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55622 if test "x$has_forbidden_chars" != x; then 55623 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55624 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55625 fi 55626 55627 55628 windows_path="$new_path" 55629 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55630 unix_path=`$CYGPATH -u "$windows_path"` 55631 new_path="$unix_path" 55632 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55633 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55634 new_path="$unix_path" 55635 fi 55636 55637 if test "x$path" != "x$new_path"; then 55638 MSVC_DLL="$new_path" 55639 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55640 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55641 fi 55642 55643 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55644 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55645 55646 else 55647 # We're on a unix platform. Hooray! :) 55648 path="$MSVC_DLL" 55649 has_space=`$ECHO "$path" | $GREP " "` 55650 if test "x$has_space" != x; then 55651 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55652 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55653 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55654 fi 55655 55656 # Use eval to expand a potential ~ 55657 eval path="$path" 55658 if test ! -f "$path" && test ! -d "$path"; then 55659 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55660 fi 55661 55662 if test -d "$path"; then 55663 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55664 else 55665 dir="`$DIRNAME "$path"`" 55666 base="`$BASENAME "$path"`" 55667 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55668 fi 55669 fi 55670 fi 55671 55672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55673 $as_echo_n "checking for $DLL_NAME... " >&6; } 55674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55675 $as_echo "$MSVC_DLL" >&6; } 55676 else 55677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55678 $as_echo "incorrect, ignoring" >&6; } 55679 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55680 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55681 fi 55682 fi 55683 55684 fi 55685 fi 55686 55687 if test "x$MSVC_DLL" = x; then 55688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55689 $as_echo_n "checking for $DLL_NAME... " >&6; } 55690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55691 $as_echo "no" >&6; } 55692 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 55693 fi 55694 55695 MSVCR_DLL="$MSVC_DLL" 55696 fi 55697 55698 55699 55700 # Check whether --with-msvcp-dll was given. 55701 if test "${with_msvcp_dll+set}" = set; then : 55702 withval=$with_msvcp_dll; 55703 fi 55704 55705 55706 if test "x$MSVCP_NAME" != "x"; then 55707 if test "x$with_msvcp_dll" != x; then 55708 # If given explicitly by user, do not probe. If not present, fail directly. 55709 55710 DLL_NAME="$MSVCP_NAME" 55711 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 55712 METHOD="--with-msvcp-dll" 55713 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55714 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55715 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55716 55717 # Need to check if the found msvcr is correct architecture 55718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55719 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55720 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55721 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55722 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55723 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55724 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55725 CORRECT_MSVCR_ARCH="PE32 executable" 55726 else 55727 CORRECT_MSVCR_ARCH="PE32+ executable" 55728 fi 55729 else 55730 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55731 CORRECT_MSVCR_ARCH=386 55732 else 55733 CORRECT_MSVCR_ARCH=x86-64 55734 fi 55735 fi 55736 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55738 $as_echo "ok" >&6; } 55739 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55740 55741 # Only process if variable expands to non-empty 55742 55743 if test "x$MSVC_DLL" != x; then 55744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55745 55746 # Input might be given as Windows format, start by converting to 55747 # unix format. 55748 path="$MSVC_DLL" 55749 new_path=`$CYGPATH -u "$path"` 55750 55751 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55752 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55753 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55754 # "foo.exe" is OK but "foo" is an error. 55755 # 55756 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55757 # It is also a way to make sure we got the proper file name for the real test later on. 55758 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55759 if test "x$test_shortpath" = x; then 55760 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55761 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55762 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55763 fi 55764 55765 # Call helper function which possibly converts this using DOS-style short mode. 55766 # If so, the updated path is stored in $new_path. 55767 55768 input_path="$new_path" 55769 # Check if we need to convert this using DOS-style short mode. If the path 55770 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55771 # take no chances and rewrite it. 55772 # Note: m4 eats our [], so we need to use [ and ] instead. 55773 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55774 if test "x$has_forbidden_chars" != x; then 55775 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55776 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55777 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55778 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55779 # Going to short mode and back again did indeed matter. Since short mode is 55780 # case insensitive, let's make it lowercase to improve readability. 55781 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55782 # Now convert it back to Unix-style (cygpath) 55783 input_path=`$CYGPATH -u "$shortmode_path"` 55784 new_path="$input_path" 55785 fi 55786 fi 55787 55788 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55789 if test "x$test_cygdrive_prefix" = x; then 55790 # As a simple fix, exclude /usr/bin since it's not a real path. 55791 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55792 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55793 # a path prefixed by /cygdrive for fixpath to work. 55794 new_path="$CYGWIN_ROOT_PATH$input_path" 55795 fi 55796 fi 55797 55798 55799 if test "x$path" != "x$new_path"; then 55800 MSVC_DLL="$new_path" 55801 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55802 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55803 fi 55804 55805 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55806 55807 path="$MSVC_DLL" 55808 has_colon=`$ECHO $path | $GREP ^.:` 55809 new_path="$path" 55810 if test "x$has_colon" = x; then 55811 # Not in mixed or Windows style, start by that. 55812 new_path=`cmd //c echo $path` 55813 fi 55814 55815 55816 input_path="$new_path" 55817 # Check if we need to convert this using DOS-style short mode. If the path 55818 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55819 # take no chances and rewrite it. 55820 # Note: m4 eats our [], so we need to use [ and ] instead. 55821 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55822 if test "x$has_forbidden_chars" != x; then 55823 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55824 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55825 fi 55826 55827 55828 windows_path="$new_path" 55829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55830 unix_path=`$CYGPATH -u "$windows_path"` 55831 new_path="$unix_path" 55832 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55833 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55834 new_path="$unix_path" 55835 fi 55836 55837 if test "x$path" != "x$new_path"; then 55838 MSVC_DLL="$new_path" 55839 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55840 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55841 fi 55842 55843 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55844 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55845 55846 else 55847 # We're on a unix platform. Hooray! :) 55848 path="$MSVC_DLL" 55849 has_space=`$ECHO "$path" | $GREP " "` 55850 if test "x$has_space" != x; then 55851 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55852 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55853 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55854 fi 55855 55856 # Use eval to expand a potential ~ 55857 eval path="$path" 55858 if test ! -f "$path" && test ! -d "$path"; then 55859 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55860 fi 55861 55862 if test -d "$path"; then 55863 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55864 else 55865 dir="`$DIRNAME "$path"`" 55866 base="`$BASENAME "$path"`" 55867 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55868 fi 55869 fi 55870 fi 55871 55872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55873 $as_echo_n "checking for $DLL_NAME... " >&6; } 55874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55875 $as_echo "$MSVC_DLL" >&6; } 55876 else 55877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55878 $as_echo "incorrect, ignoring" >&6; } 55879 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55880 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55881 fi 55882 fi 55883 55884 if test "x$MSVC_DLL" = x; then 55885 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 55886 fi 55887 MSVCP_DLL="$MSVC_DLL" 55888 elif test "x$DEVKIT_MSVCP_DLL" != x; then 55889 55890 DLL_NAME="$MSVCP_NAME" 55891 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 55892 METHOD="devkit" 55893 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55894 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55895 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55896 55897 # Need to check if the found msvcr is correct architecture 55898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55899 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55900 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55901 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55902 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55903 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55904 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55905 CORRECT_MSVCR_ARCH="PE32 executable" 55906 else 55907 CORRECT_MSVCR_ARCH="PE32+ executable" 55908 fi 55909 else 55910 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55911 CORRECT_MSVCR_ARCH=386 55912 else 55913 CORRECT_MSVCR_ARCH=x86-64 55914 fi 55915 fi 55916 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55918 $as_echo "ok" >&6; } 55919 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55920 55921 # Only process if variable expands to non-empty 55922 55923 if test "x$MSVC_DLL" != x; then 55924 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55925 55926 # Input might be given as Windows format, start by converting to 55927 # unix format. 55928 path="$MSVC_DLL" 55929 new_path=`$CYGPATH -u "$path"` 55930 55931 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55932 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55933 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55934 # "foo.exe" is OK but "foo" is an error. 55935 # 55936 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55937 # It is also a way to make sure we got the proper file name for the real test later on. 55938 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55939 if test "x$test_shortpath" = x; then 55940 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55941 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55942 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55943 fi 55944 55945 # Call helper function which possibly converts this using DOS-style short mode. 55946 # If so, the updated path is stored in $new_path. 55947 55948 input_path="$new_path" 55949 # Check if we need to convert this using DOS-style short mode. If the path 55950 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55951 # take no chances and rewrite it. 55952 # Note: m4 eats our [], so we need to use [ and ] instead. 55953 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55954 if test "x$has_forbidden_chars" != x; then 55955 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55956 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55957 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55958 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55959 # Going to short mode and back again did indeed matter. Since short mode is 55960 # case insensitive, let's make it lowercase to improve readability. 55961 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55962 # Now convert it back to Unix-style (cygpath) 55963 input_path=`$CYGPATH -u "$shortmode_path"` 55964 new_path="$input_path" 55965 fi 55966 fi 55967 55968 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55969 if test "x$test_cygdrive_prefix" = x; then 55970 # As a simple fix, exclude /usr/bin since it's not a real path. 55971 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55972 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55973 # a path prefixed by /cygdrive for fixpath to work. 55974 new_path="$CYGWIN_ROOT_PATH$input_path" 55975 fi 55976 fi 55977 55978 55979 if test "x$path" != "x$new_path"; then 55980 MSVC_DLL="$new_path" 55981 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55982 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55983 fi 55984 55985 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55986 55987 path="$MSVC_DLL" 55988 has_colon=`$ECHO $path | $GREP ^.:` 55989 new_path="$path" 55990 if test "x$has_colon" = x; then 55991 # Not in mixed or Windows style, start by that. 55992 new_path=`cmd //c echo $path` 55993 fi 55994 55995 55996 input_path="$new_path" 55997 # Check if we need to convert this using DOS-style short mode. If the path 55998 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55999 # take no chances and rewrite it. 56000 # Note: m4 eats our [], so we need to use [ and ] instead. 56001 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56002 if test "x$has_forbidden_chars" != x; then 56003 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56004 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56005 fi 56006 56007 56008 windows_path="$new_path" 56009 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56010 unix_path=`$CYGPATH -u "$windows_path"` 56011 new_path="$unix_path" 56012 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56013 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56014 new_path="$unix_path" 56015 fi 56016 56017 if test "x$path" != "x$new_path"; then 56018 MSVC_DLL="$new_path" 56019 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56020 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56021 fi 56022 56023 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56024 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56025 56026 else 56027 # We're on a unix platform. Hooray! :) 56028 path="$MSVC_DLL" 56029 has_space=`$ECHO "$path" | $GREP " "` 56030 if test "x$has_space" != x; then 56031 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56032 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56033 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56034 fi 56035 56036 # Use eval to expand a potential ~ 56037 eval path="$path" 56038 if test ! -f "$path" && test ! -d "$path"; then 56039 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56040 fi 56041 56042 if test -d "$path"; then 56043 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56044 else 56045 dir="`$DIRNAME "$path"`" 56046 base="`$BASENAME "$path"`" 56047 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56048 fi 56049 fi 56050 fi 56051 56052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56053 $as_echo_n "checking for $DLL_NAME... " >&6; } 56054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56055 $as_echo "$MSVC_DLL" >&6; } 56056 else 56057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56058 $as_echo "incorrect, ignoring" >&6; } 56059 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56060 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56061 fi 56062 fi 56063 56064 if test "x$MSVC_DLL" = x; then 56065 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 56066 fi 56067 MSVCP_DLL="$MSVC_DLL" 56068 else 56069 56070 DLL_NAME="${MSVCP_NAME}" 56071 MSVC_DLL= 56072 56073 if test "x$MSVC_DLL" = x; then 56074 # Probe: Using well-known location from Visual Studio 10.0 56075 if test "x$VCINSTALLDIR" != x; then 56076 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 56077 56078 windows_path="$CYGWIN_VC_INSTALL_DIR" 56079 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56080 unix_path=`$CYGPATH -u "$windows_path"` 56081 CYGWIN_VC_INSTALL_DIR="$unix_path" 56082 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56083 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56084 CYGWIN_VC_INSTALL_DIR="$unix_path" 56085 fi 56086 56087 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56088 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 56089 else 56090 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 56091 fi 56092 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 56093 56094 DLL_NAME="$DLL_NAME" 56095 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56096 METHOD="well-known location in VCINSTALLDIR" 56097 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56098 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56099 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56100 56101 # Need to check if the found msvcr is correct architecture 56102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56103 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56104 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56105 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56106 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56107 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56108 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56109 CORRECT_MSVCR_ARCH="PE32 executable" 56110 else 56111 CORRECT_MSVCR_ARCH="PE32+ executable" 56112 fi 56113 else 56114 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56115 CORRECT_MSVCR_ARCH=386 56116 else 56117 CORRECT_MSVCR_ARCH=x86-64 56118 fi 56119 fi 56120 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56122 $as_echo "ok" >&6; } 56123 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56124 56125 # Only process if variable expands to non-empty 56126 56127 if test "x$MSVC_DLL" != x; then 56128 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56129 56130 # Input might be given as Windows format, start by converting to 56131 # unix format. 56132 path="$MSVC_DLL" 56133 new_path=`$CYGPATH -u "$path"` 56134 56135 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56136 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56137 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56138 # "foo.exe" is OK but "foo" is an error. 56139 # 56140 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56141 # It is also a way to make sure we got the proper file name for the real test later on. 56142 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56143 if test "x$test_shortpath" = x; then 56144 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56145 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56146 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56147 fi 56148 56149 # Call helper function which possibly converts this using DOS-style short mode. 56150 # If so, the updated path is stored in $new_path. 56151 56152 input_path="$new_path" 56153 # Check if we need to convert this using DOS-style short mode. If the path 56154 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56155 # take no chances and rewrite it. 56156 # Note: m4 eats our [], so we need to use [ and ] instead. 56157 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56158 if test "x$has_forbidden_chars" != x; then 56159 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56160 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56161 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56162 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56163 # Going to short mode and back again did indeed matter. Since short mode is 56164 # case insensitive, let's make it lowercase to improve readability. 56165 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56166 # Now convert it back to Unix-style (cygpath) 56167 input_path=`$CYGPATH -u "$shortmode_path"` 56168 new_path="$input_path" 56169 fi 56170 fi 56171 56172 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56173 if test "x$test_cygdrive_prefix" = x; then 56174 # As a simple fix, exclude /usr/bin since it's not a real path. 56175 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56176 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56177 # a path prefixed by /cygdrive for fixpath to work. 56178 new_path="$CYGWIN_ROOT_PATH$input_path" 56179 fi 56180 fi 56181 56182 56183 if test "x$path" != "x$new_path"; then 56184 MSVC_DLL="$new_path" 56185 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56186 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56187 fi 56188 56189 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56190 56191 path="$MSVC_DLL" 56192 has_colon=`$ECHO $path | $GREP ^.:` 56193 new_path="$path" 56194 if test "x$has_colon" = x; then 56195 # Not in mixed or Windows style, start by that. 56196 new_path=`cmd //c echo $path` 56197 fi 56198 56199 56200 input_path="$new_path" 56201 # Check if we need to convert this using DOS-style short mode. If the path 56202 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56203 # take no chances and rewrite it. 56204 # Note: m4 eats our [], so we need to use [ and ] instead. 56205 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56206 if test "x$has_forbidden_chars" != x; then 56207 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56208 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56209 fi 56210 56211 56212 windows_path="$new_path" 56213 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56214 unix_path=`$CYGPATH -u "$windows_path"` 56215 new_path="$unix_path" 56216 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56217 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56218 new_path="$unix_path" 56219 fi 56220 56221 if test "x$path" != "x$new_path"; then 56222 MSVC_DLL="$new_path" 56223 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56224 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56225 fi 56226 56227 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56228 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56229 56230 else 56231 # We're on a unix platform. Hooray! :) 56232 path="$MSVC_DLL" 56233 has_space=`$ECHO "$path" | $GREP " "` 56234 if test "x$has_space" != x; then 56235 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56236 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56237 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56238 fi 56239 56240 # Use eval to expand a potential ~ 56241 eval path="$path" 56242 if test ! -f "$path" && test ! -d "$path"; then 56243 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56244 fi 56245 56246 if test -d "$path"; then 56247 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56248 else 56249 dir="`$DIRNAME "$path"`" 56250 base="`$BASENAME "$path"`" 56251 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56252 fi 56253 fi 56254 fi 56255 56256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56257 $as_echo_n "checking for $DLL_NAME... " >&6; } 56258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56259 $as_echo "$MSVC_DLL" >&6; } 56260 else 56261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56262 $as_echo "incorrect, ignoring" >&6; } 56263 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56264 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56265 fi 56266 fi 56267 56268 fi 56269 fi 56270 56271 if test "x$MSVC_DLL" = x; then 56272 # Probe: Check in the Boot JDK directory. 56273 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 56274 56275 DLL_NAME="$DLL_NAME" 56276 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56277 METHOD="well-known location in Boot JDK" 56278 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56279 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56280 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56281 56282 # Need to check if the found msvcr is correct architecture 56283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56284 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56285 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56286 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56287 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56288 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56289 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56290 CORRECT_MSVCR_ARCH="PE32 executable" 56291 else 56292 CORRECT_MSVCR_ARCH="PE32+ executable" 56293 fi 56294 else 56295 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56296 CORRECT_MSVCR_ARCH=386 56297 else 56298 CORRECT_MSVCR_ARCH=x86-64 56299 fi 56300 fi 56301 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56303 $as_echo "ok" >&6; } 56304 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56305 56306 # Only process if variable expands to non-empty 56307 56308 if test "x$MSVC_DLL" != x; then 56309 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56310 56311 # Input might be given as Windows format, start by converting to 56312 # unix format. 56313 path="$MSVC_DLL" 56314 new_path=`$CYGPATH -u "$path"` 56315 56316 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56317 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56318 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56319 # "foo.exe" is OK but "foo" is an error. 56320 # 56321 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56322 # It is also a way to make sure we got the proper file name for the real test later on. 56323 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56324 if test "x$test_shortpath" = x; then 56325 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56326 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56327 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56328 fi 56329 56330 # Call helper function which possibly converts this using DOS-style short mode. 56331 # If so, the updated path is stored in $new_path. 56332 56333 input_path="$new_path" 56334 # Check if we need to convert this using DOS-style short mode. If the path 56335 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56336 # take no chances and rewrite it. 56337 # Note: m4 eats our [], so we need to use [ and ] instead. 56338 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56339 if test "x$has_forbidden_chars" != x; then 56340 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56341 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56342 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56343 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56344 # Going to short mode and back again did indeed matter. Since short mode is 56345 # case insensitive, let's make it lowercase to improve readability. 56346 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56347 # Now convert it back to Unix-style (cygpath) 56348 input_path=`$CYGPATH -u "$shortmode_path"` 56349 new_path="$input_path" 56350 fi 56351 fi 56352 56353 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56354 if test "x$test_cygdrive_prefix" = x; then 56355 # As a simple fix, exclude /usr/bin since it's not a real path. 56356 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56357 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56358 # a path prefixed by /cygdrive for fixpath to work. 56359 new_path="$CYGWIN_ROOT_PATH$input_path" 56360 fi 56361 fi 56362 56363 56364 if test "x$path" != "x$new_path"; then 56365 MSVC_DLL="$new_path" 56366 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56367 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56368 fi 56369 56370 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56371 56372 path="$MSVC_DLL" 56373 has_colon=`$ECHO $path | $GREP ^.:` 56374 new_path="$path" 56375 if test "x$has_colon" = x; then 56376 # Not in mixed or Windows style, start by that. 56377 new_path=`cmd //c echo $path` 56378 fi 56379 56380 56381 input_path="$new_path" 56382 # Check if we need to convert this using DOS-style short mode. If the path 56383 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56384 # take no chances and rewrite it. 56385 # Note: m4 eats our [], so we need to use [ and ] instead. 56386 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56387 if test "x$has_forbidden_chars" != x; then 56388 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56389 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56390 fi 56391 56392 56393 windows_path="$new_path" 56394 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56395 unix_path=`$CYGPATH -u "$windows_path"` 56396 new_path="$unix_path" 56397 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56398 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56399 new_path="$unix_path" 56400 fi 56401 56402 if test "x$path" != "x$new_path"; then 56403 MSVC_DLL="$new_path" 56404 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56405 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56406 fi 56407 56408 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56409 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56410 56411 else 56412 # We're on a unix platform. Hooray! :) 56413 path="$MSVC_DLL" 56414 has_space=`$ECHO "$path" | $GREP " "` 56415 if test "x$has_space" != x; then 56416 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56417 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56418 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56419 fi 56420 56421 # Use eval to expand a potential ~ 56422 eval path="$path" 56423 if test ! -f "$path" && test ! -d "$path"; then 56424 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56425 fi 56426 56427 if test -d "$path"; then 56428 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56429 else 56430 dir="`$DIRNAME "$path"`" 56431 base="`$BASENAME "$path"`" 56432 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56433 fi 56434 fi 56435 fi 56436 56437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56438 $as_echo_n "checking for $DLL_NAME... " >&6; } 56439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56440 $as_echo "$MSVC_DLL" >&6; } 56441 else 56442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56443 $as_echo "incorrect, ignoring" >&6; } 56444 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56445 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56446 fi 56447 fi 56448 56449 fi 56450 56451 if test "x$MSVC_DLL" = x; then 56452 # Probe: Look in the Windows system32 directory 56453 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 56454 56455 windows_path="$CYGWIN_SYSTEMROOT" 56456 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56457 unix_path=`$CYGPATH -u "$windows_path"` 56458 CYGWIN_SYSTEMROOT="$unix_path" 56459 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56460 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56461 CYGWIN_SYSTEMROOT="$unix_path" 56462 fi 56463 56464 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 56465 56466 DLL_NAME="$DLL_NAME" 56467 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56468 METHOD="well-known location in SYSTEMROOT" 56469 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56470 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56471 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56472 56473 # Need to check if the found msvcr is correct architecture 56474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56475 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56476 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56477 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56478 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56479 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56480 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56481 CORRECT_MSVCR_ARCH="PE32 executable" 56482 else 56483 CORRECT_MSVCR_ARCH="PE32+ executable" 56484 fi 56485 else 56486 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56487 CORRECT_MSVCR_ARCH=386 56488 else 56489 CORRECT_MSVCR_ARCH=x86-64 56490 fi 56491 fi 56492 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56494 $as_echo "ok" >&6; } 56495 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56496 56497 # Only process if variable expands to non-empty 56498 56499 if test "x$MSVC_DLL" != x; then 56500 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56501 56502 # Input might be given as Windows format, start by converting to 56503 # unix format. 56504 path="$MSVC_DLL" 56505 new_path=`$CYGPATH -u "$path"` 56506 56507 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56508 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56509 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56510 # "foo.exe" is OK but "foo" is an error. 56511 # 56512 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56513 # It is also a way to make sure we got the proper file name for the real test later on. 56514 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56515 if test "x$test_shortpath" = x; then 56516 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56517 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56518 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56519 fi 56520 56521 # Call helper function which possibly converts this using DOS-style short mode. 56522 # If so, the updated path is stored in $new_path. 56523 56524 input_path="$new_path" 56525 # Check if we need to convert this using DOS-style short mode. If the path 56526 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56527 # take no chances and rewrite it. 56528 # Note: m4 eats our [], so we need to use [ and ] instead. 56529 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56530 if test "x$has_forbidden_chars" != x; then 56531 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56532 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56533 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56534 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56535 # Going to short mode and back again did indeed matter. Since short mode is 56536 # case insensitive, let's make it lowercase to improve readability. 56537 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56538 # Now convert it back to Unix-style (cygpath) 56539 input_path=`$CYGPATH -u "$shortmode_path"` 56540 new_path="$input_path" 56541 fi 56542 fi 56543 56544 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56545 if test "x$test_cygdrive_prefix" = x; then 56546 # As a simple fix, exclude /usr/bin since it's not a real path. 56547 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56548 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56549 # a path prefixed by /cygdrive for fixpath to work. 56550 new_path="$CYGWIN_ROOT_PATH$input_path" 56551 fi 56552 fi 56553 56554 56555 if test "x$path" != "x$new_path"; then 56556 MSVC_DLL="$new_path" 56557 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56558 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56559 fi 56560 56561 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56562 56563 path="$MSVC_DLL" 56564 has_colon=`$ECHO $path | $GREP ^.:` 56565 new_path="$path" 56566 if test "x$has_colon" = x; then 56567 # Not in mixed or Windows style, start by that. 56568 new_path=`cmd //c echo $path` 56569 fi 56570 56571 56572 input_path="$new_path" 56573 # Check if we need to convert this using DOS-style short mode. If the path 56574 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56575 # take no chances and rewrite it. 56576 # Note: m4 eats our [], so we need to use [ and ] instead. 56577 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56578 if test "x$has_forbidden_chars" != x; then 56579 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56580 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56581 fi 56582 56583 56584 windows_path="$new_path" 56585 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56586 unix_path=`$CYGPATH -u "$windows_path"` 56587 new_path="$unix_path" 56588 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56589 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56590 new_path="$unix_path" 56591 fi 56592 56593 if test "x$path" != "x$new_path"; then 56594 MSVC_DLL="$new_path" 56595 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56596 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56597 fi 56598 56599 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56600 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56601 56602 else 56603 # We're on a unix platform. Hooray! :) 56604 path="$MSVC_DLL" 56605 has_space=`$ECHO "$path" | $GREP " "` 56606 if test "x$has_space" != x; then 56607 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56608 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56609 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56610 fi 56611 56612 # Use eval to expand a potential ~ 56613 eval path="$path" 56614 if test ! -f "$path" && test ! -d "$path"; then 56615 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56616 fi 56617 56618 if test -d "$path"; then 56619 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56620 else 56621 dir="`$DIRNAME "$path"`" 56622 base="`$BASENAME "$path"`" 56623 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56624 fi 56625 fi 56626 fi 56627 56628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56629 $as_echo_n "checking for $DLL_NAME... " >&6; } 56630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56631 $as_echo "$MSVC_DLL" >&6; } 56632 else 56633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56634 $as_echo "incorrect, ignoring" >&6; } 56635 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56636 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56637 fi 56638 fi 56639 56640 fi 56641 56642 if test "x$MSVC_DLL" = x; then 56643 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 56644 if test "x$VS100COMNTOOLS" != x; then 56645 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 56646 56647 windows_path="$CYGWIN_VS_TOOLS_DIR" 56648 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56649 unix_path=`$CYGPATH -u "$windows_path"` 56650 CYGWIN_VS_TOOLS_DIR="$unix_path" 56651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56652 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56653 CYGWIN_VS_TOOLS_DIR="$unix_path" 56654 fi 56655 56656 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56657 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 56658 | $GREP -i /x64/ | $HEAD --lines 1` 56659 else 56660 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 56661 | $GREP -i /x86/ | $HEAD --lines 1` 56662 fi 56663 56664 DLL_NAME="$DLL_NAME" 56665 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56666 METHOD="search of VS100COMNTOOLS" 56667 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56668 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56669 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56670 56671 # Need to check if the found msvcr is correct architecture 56672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56673 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56674 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56676 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56677 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56678 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56679 CORRECT_MSVCR_ARCH="PE32 executable" 56680 else 56681 CORRECT_MSVCR_ARCH="PE32+ executable" 56682 fi 56683 else 56684 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56685 CORRECT_MSVCR_ARCH=386 56686 else 56687 CORRECT_MSVCR_ARCH=x86-64 56688 fi 56689 fi 56690 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56692 $as_echo "ok" >&6; } 56693 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56694 56695 # Only process if variable expands to non-empty 56696 56697 if test "x$MSVC_DLL" != x; then 56698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56699 56700 # Input might be given as Windows format, start by converting to 56701 # unix format. 56702 path="$MSVC_DLL" 56703 new_path=`$CYGPATH -u "$path"` 56704 56705 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56706 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56707 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56708 # "foo.exe" is OK but "foo" is an error. 56709 # 56710 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56711 # It is also a way to make sure we got the proper file name for the real test later on. 56712 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56713 if test "x$test_shortpath" = x; then 56714 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56715 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56716 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56717 fi 56718 56719 # Call helper function which possibly converts this using DOS-style short mode. 56720 # If so, the updated path is stored in $new_path. 56721 56722 input_path="$new_path" 56723 # Check if we need to convert this using DOS-style short mode. If the path 56724 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56725 # take no chances and rewrite it. 56726 # Note: m4 eats our [], so we need to use [ and ] instead. 56727 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56728 if test "x$has_forbidden_chars" != x; then 56729 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56730 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56731 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56732 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56733 # Going to short mode and back again did indeed matter. Since short mode is 56734 # case insensitive, let's make it lowercase to improve readability. 56735 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56736 # Now convert it back to Unix-style (cygpath) 56737 input_path=`$CYGPATH -u "$shortmode_path"` 56738 new_path="$input_path" 56739 fi 56740 fi 56741 56742 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56743 if test "x$test_cygdrive_prefix" = x; then 56744 # As a simple fix, exclude /usr/bin since it's not a real path. 56745 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56746 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56747 # a path prefixed by /cygdrive for fixpath to work. 56748 new_path="$CYGWIN_ROOT_PATH$input_path" 56749 fi 56750 fi 56751 56752 56753 if test "x$path" != "x$new_path"; then 56754 MSVC_DLL="$new_path" 56755 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56756 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56757 fi 56758 56759 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56760 56761 path="$MSVC_DLL" 56762 has_colon=`$ECHO $path | $GREP ^.:` 56763 new_path="$path" 56764 if test "x$has_colon" = x; then 56765 # Not in mixed or Windows style, start by that. 56766 new_path=`cmd //c echo $path` 56767 fi 56768 56769 56770 input_path="$new_path" 56771 # Check if we need to convert this using DOS-style short mode. If the path 56772 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56773 # take no chances and rewrite it. 56774 # Note: m4 eats our [], so we need to use [ and ] instead. 56775 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56776 if test "x$has_forbidden_chars" != x; then 56777 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56778 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56779 fi 56780 56781 56782 windows_path="$new_path" 56783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56784 unix_path=`$CYGPATH -u "$windows_path"` 56785 new_path="$unix_path" 56786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56787 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56788 new_path="$unix_path" 56789 fi 56790 56791 if test "x$path" != "x$new_path"; then 56792 MSVC_DLL="$new_path" 56793 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56794 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56795 fi 56796 56797 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56798 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56799 56800 else 56801 # We're on a unix platform. Hooray! :) 56802 path="$MSVC_DLL" 56803 has_space=`$ECHO "$path" | $GREP " "` 56804 if test "x$has_space" != x; then 56805 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56806 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56807 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56808 fi 56809 56810 # Use eval to expand a potential ~ 56811 eval path="$path" 56812 if test ! -f "$path" && test ! -d "$path"; then 56813 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 56814 fi 56815 56816 if test -d "$path"; then 56817 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 56818 else 56819 dir="`$DIRNAME "$path"`" 56820 base="`$BASENAME "$path"`" 56821 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 56822 fi 56823 fi 56824 fi 56825 56826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56827 $as_echo_n "checking for $DLL_NAME... " >&6; } 56828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56829 $as_echo "$MSVC_DLL" >&6; } 56830 else 56831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56832 $as_echo "incorrect, ignoring" >&6; } 56833 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56834 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56835 fi 56836 fi 56837 56838 fi 56839 fi 56840 56841 if test "x$MSVC_DLL" = x; then 56842 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 56843 # (This was the original behaviour; kept since it might turn something up) 56844 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 56845 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56846 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 56847 | $GREP x64 | $HEAD --lines 1` 56848 else 56849 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 56850 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 56851 if test "x$POSSIBLE_MSVC_DLL" = x; then 56852 # We're grasping at straws now... 56853 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 56854 | $HEAD --lines 1` 56855 fi 56856 fi 56857 56858 56859 DLL_NAME="$DLL_NAME" 56860 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 56861 METHOD="search of VCINSTALLDIR" 56862 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 56863 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 56864 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 56865 56866 # Need to check if the found msvcr is correct architecture 56867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 56868 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 56869 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 56870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56871 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 56872 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 56873 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56874 CORRECT_MSVCR_ARCH="PE32 executable" 56875 else 56876 CORRECT_MSVCR_ARCH="PE32+ executable" 56877 fi 56878 else 56879 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 56880 CORRECT_MSVCR_ARCH=386 56881 else 56882 CORRECT_MSVCR_ARCH=x86-64 56883 fi 56884 fi 56885 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 56886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 56887 $as_echo "ok" >&6; } 56888 MSVC_DLL="$POSSIBLE_MSVC_DLL" 56889 56890 # Only process if variable expands to non-empty 56891 56892 if test "x$MSVC_DLL" != x; then 56893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56894 56895 # Input might be given as Windows format, start by converting to 56896 # unix format. 56897 path="$MSVC_DLL" 56898 new_path=`$CYGPATH -u "$path"` 56899 56900 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56901 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56902 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56903 # "foo.exe" is OK but "foo" is an error. 56904 # 56905 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56906 # It is also a way to make sure we got the proper file name for the real test later on. 56907 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56908 if test "x$test_shortpath" = x; then 56909 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 56910 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 56911 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 56912 fi 56913 56914 # Call helper function which possibly converts this using DOS-style short mode. 56915 # If so, the updated path is stored in $new_path. 56916 56917 input_path="$new_path" 56918 # Check if we need to convert this using DOS-style short mode. If the path 56919 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56920 # take no chances and rewrite it. 56921 # Note: m4 eats our [], so we need to use [ and ] instead. 56922 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56923 if test "x$has_forbidden_chars" != x; then 56924 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56925 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56926 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56927 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56928 # Going to short mode and back again did indeed matter. Since short mode is 56929 # case insensitive, let's make it lowercase to improve readability. 56930 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56931 # Now convert it back to Unix-style (cygpath) 56932 input_path=`$CYGPATH -u "$shortmode_path"` 56933 new_path="$input_path" 56934 fi 56935 fi 56936 56937 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56938 if test "x$test_cygdrive_prefix" = x; then 56939 # As a simple fix, exclude /usr/bin since it's not a real path. 56940 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56941 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56942 # a path prefixed by /cygdrive for fixpath to work. 56943 new_path="$CYGWIN_ROOT_PATH$input_path" 56944 fi 56945 fi 56946 56947 56948 if test "x$path" != "x$new_path"; then 56949 MSVC_DLL="$new_path" 56950 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56951 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56952 fi 56953 56954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56955 56956 path="$MSVC_DLL" 56957 has_colon=`$ECHO $path | $GREP ^.:` 56958 new_path="$path" 56959 if test "x$has_colon" = x; then 56960 # Not in mixed or Windows style, start by that. 56961 new_path=`cmd //c echo $path` 56962 fi 56963 56964 56965 input_path="$new_path" 56966 # Check if we need to convert this using DOS-style short mode. If the path 56967 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56968 # take no chances and rewrite it. 56969 # Note: m4 eats our [], so we need to use [ and ] instead. 56970 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56971 if test "x$has_forbidden_chars" != x; then 56972 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56973 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56974 fi 56975 56976 56977 windows_path="$new_path" 56978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56979 unix_path=`$CYGPATH -u "$windows_path"` 56980 new_path="$unix_path" 56981 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56982 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56983 new_path="$unix_path" 56984 fi 56985 56986 if test "x$path" != "x$new_path"; then 56987 MSVC_DLL="$new_path" 56988 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 56989 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 56990 fi 56991 56992 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56993 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56994 56995 else 56996 # We're on a unix platform. Hooray! :) 56997 path="$MSVC_DLL" 56998 has_space=`$ECHO "$path" | $GREP " "` 56999 if test "x$has_space" != x; then 57000 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 57001 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 57002 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57003 fi 57004 57005 # Use eval to expand a potential ~ 57006 eval path="$path" 57007 if test ! -f "$path" && test ! -d "$path"; then 57008 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 57009 fi 57010 57011 if test -d "$path"; then 57012 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 57013 else 57014 dir="`$DIRNAME "$path"`" 57015 base="`$BASENAME "$path"`" 57016 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 57017 fi 57018 fi 57019 fi 57020 57021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57022 $as_echo_n "checking for $DLL_NAME... " >&6; } 57023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 57024 $as_echo "$MSVC_DLL" >&6; } 57025 else 57026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 57027 $as_echo "incorrect, ignoring" >&6; } 57028 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 57029 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 57030 fi 57031 fi 57032 57033 fi 57034 fi 57035 57036 if test "x$MSVC_DLL" = x; then 57037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 57038 $as_echo_n "checking for $DLL_NAME... " >&6; } 57039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57040 $as_echo "no" >&6; } 57041 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 57042 fi 57043 57044 MSVCP_DLL="$MSVC_DLL" 57045 fi 57046 57047 fi 57048 57049 fi 57050 57051 57052 if test "x$NEEDS_LIB_X11" = xfalse; then 57053 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 57054 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 57055 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 57056 fi 57057 X_CFLAGS= 57058 X_LIBS= 57059 else 57060 57061 if test "x${with_x}" = xno; then 57062 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 57063 fi 57064 57065 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 57066 # The user has specified a X11 base directory. Use it for includes and 57067 # libraries, unless explicitly overridden. 57068 if test "x$x_includes" = xNONE; then 57069 x_includes="${with_x}/include" 57070 fi 57071 if test "x$x_libraries" = xNONE; then 57072 x_libraries="${with_x}/lib" 57073 fi 57074 else 57075 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 57076 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 57077 # --x-libraries for the sysroot, if that seems to be correct. 57078 if test "x$SYSROOT" != "x"; then 57079 if test "x$x_includes" = xNONE; then 57080 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 57081 x_includes="$SYSROOT/usr/X11R6/include" 57082 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 57083 x_includes="$SYSROOT/usr/include" 57084 fi 57085 fi 57086 if test "x$x_libraries" = xNONE; then 57087 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 57088 x_libraries="$SYSROOT/usr/X11R6/lib" 57089 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57090 x_libraries="$SYSROOT/usr/lib64" 57091 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 57092 x_libraries="$SYSROOT/usr/lib" 57093 fi 57094 fi 57095 fi 57096 fi 57097 57098 # Now let autoconf do it's magic 57099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 57100 $as_echo_n "checking for X... " >&6; } 57101 57102 57103 # Check whether --with-x was given. 57104 if test "${with_x+set}" = set; then : 57105 withval=$with_x; 57106 fi 57107 57108 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 57109 if test "x$with_x" = xno; then 57110 # The user explicitly disabled X. 57111 have_x=disabled 57112 else 57113 case $x_includes,$x_libraries in #( 57114 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 57115 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 57116 $as_echo_n "(cached) " >&6 57117 else 57118 # One or both of the vars are not set, and there is no cached value. 57119 ac_x_includes=no ac_x_libraries=no 57120 rm -f -r conftest.dir 57121 if mkdir conftest.dir; then 57122 cd conftest.dir 57123 cat >Imakefile <<'_ACEOF' 57124 incroot: 57125 @echo incroot='${INCROOT}' 57126 usrlibdir: 57127 @echo usrlibdir='${USRLIBDIR}' 57128 libdir: 57129 @echo libdir='${LIBDIR}' 57130 _ACEOF 57131 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 57132 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 57133 for ac_var in incroot usrlibdir libdir; do 57134 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 57135 done 57136 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 57137 for ac_extension in a so sl dylib la dll; do 57138 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 57139 test -f "$ac_im_libdir/libX11.$ac_extension"; then 57140 ac_im_usrlibdir=$ac_im_libdir; break 57141 fi 57142 done 57143 # Screen out bogus values from the imake configuration. They are 57144 # bogus both because they are the default anyway, and because 57145 # using them would break gcc on systems where it needs fixed includes. 57146 case $ac_im_incroot in 57147 /usr/include) ac_x_includes= ;; 57148 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 57149 esac 57150 case $ac_im_usrlibdir in 57151 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 57152 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 57153 esac 57154 fi 57155 cd .. 57156 rm -f -r conftest.dir 57157 fi 57158 57159 # Standard set of common directories for X headers. 57160 # Check X11 before X11Rn because it is often a symlink to the current release. 57161 ac_x_header_dirs=' 57162 /usr/X11/include 57163 /usr/X11R7/include 57164 /usr/X11R6/include 57165 /usr/X11R5/include 57166 /usr/X11R4/include 57167 57168 /usr/include/X11 57169 /usr/include/X11R7 57170 /usr/include/X11R6 57171 /usr/include/X11R5 57172 /usr/include/X11R4 57173 57174 /usr/local/X11/include 57175 /usr/local/X11R7/include 57176 /usr/local/X11R6/include 57177 /usr/local/X11R5/include 57178 /usr/local/X11R4/include 57179 57180 /usr/local/include/X11 57181 /usr/local/include/X11R7 57182 /usr/local/include/X11R6 57183 /usr/local/include/X11R5 57184 /usr/local/include/X11R4 57185 57186 /usr/X386/include 57187 /usr/x386/include 57188 /usr/XFree86/include/X11 57189 57190 /usr/include 57191 /usr/local/include 57192 /usr/unsupported/include 57193 /usr/athena/include 57194 /usr/local/x11r5/include 57195 /usr/lpp/Xamples/include 57196 57197 /usr/openwin/include 57198 /usr/openwin/share/include' 57199 57200 if test "$ac_x_includes" = no; then 57201 # Guess where to find include files, by looking for Xlib.h. 57202 # First, try using that file with no special directory specified. 57203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57204 /* end confdefs.h. */ 57205 #include <X11/Xlib.h> 57206 _ACEOF 57207 if ac_fn_cxx_try_cpp "$LINENO"; then : 57208 # We can compile using X headers with no special include directory. 57209 ac_x_includes= 57210 else 57211 for ac_dir in $ac_x_header_dirs; do 57212 if test -r "$ac_dir/X11/Xlib.h"; then 57213 ac_x_includes=$ac_dir 57214 break 57215 fi 57216 done 57217 fi 57218 rm -f conftest.err conftest.i conftest.$ac_ext 57219 fi # $ac_x_includes = no 57220 57221 if test "$ac_x_libraries" = no; then 57222 # Check for the libraries. 57223 # See if we find them without any special options. 57224 # Don't add to $LIBS permanently. 57225 ac_save_LIBS=$LIBS 57226 LIBS="-lX11 $LIBS" 57227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57228 /* end confdefs.h. */ 57229 #include <X11/Xlib.h> 57230 int 57231 main () 57232 { 57233 XrmInitialize () 57234 ; 57235 return 0; 57236 } 57237 _ACEOF 57238 if ac_fn_cxx_try_link "$LINENO"; then : 57239 LIBS=$ac_save_LIBS 57240 # We can link X programs with no special library path. 57241 ac_x_libraries= 57242 else 57243 LIBS=$ac_save_LIBS 57244 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 57245 do 57246 # Don't even attempt the hair of trying to link an X program! 57247 for ac_extension in a so sl dylib la dll; do 57248 if test -r "$ac_dir/libX11.$ac_extension"; then 57249 ac_x_libraries=$ac_dir 57250 break 2 57251 fi 57252 done 57253 done 57254 fi 57255 rm -f core conftest.err conftest.$ac_objext \ 57256 conftest$ac_exeext conftest.$ac_ext 57257 fi # $ac_x_libraries = no 57258 57259 case $ac_x_includes,$ac_x_libraries in #( 57260 no,* | *,no | *\'*) 57261 # Didn't find X, or a directory has "'" in its name. 57262 ac_cv_have_x="have_x=no";; #( 57263 *) 57264 # Record where we found X for the cache. 57265 ac_cv_have_x="have_x=yes\ 57266 ac_x_includes='$ac_x_includes'\ 57267 ac_x_libraries='$ac_x_libraries'" 57268 esac 57269 fi 57270 ;; #( 57271 *) have_x=yes;; 57272 esac 57273 eval "$ac_cv_have_x" 57274 fi # $with_x != no 57275 57276 if test "$have_x" != yes; then 57277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 57278 $as_echo "$have_x" >&6; } 57279 no_x=yes 57280 else 57281 # If each of the values was on the command line, it overrides each guess. 57282 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 57283 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 57284 # Update the cache value to reflect the command line values. 57285 ac_cv_have_x="have_x=yes\ 57286 ac_x_includes='$x_includes'\ 57287 ac_x_libraries='$x_libraries'" 57288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 57289 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 57290 fi 57291 57292 if test "$no_x" = yes; then 57293 # Not all programs may use this symbol, but it does not hurt to define it. 57294 57295 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 57296 57297 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 57298 else 57299 if test -n "$x_includes"; then 57300 X_CFLAGS="$X_CFLAGS -I$x_includes" 57301 fi 57302 57303 # It would also be nice to do this for all -L options, not just this one. 57304 if test -n "$x_libraries"; then 57305 X_LIBS="$X_LIBS -L$x_libraries" 57306 # For Solaris; some versions of Sun CC require a space after -R and 57307 # others require no space. Words are not sufficient . . . . 57308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 57309 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 57310 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 57311 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 57312 ac_cxx_werror_flag=yes 57313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57314 /* end confdefs.h. */ 57315 57316 int 57317 main () 57318 { 57319 57320 ; 57321 return 0; 57322 } 57323 _ACEOF 57324 if ac_fn_cxx_try_link "$LINENO"; then : 57325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57326 $as_echo "no" >&6; } 57327 X_LIBS="$X_LIBS -R$x_libraries" 57328 else 57329 LIBS="$ac_xsave_LIBS -R $x_libraries" 57330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57331 /* end confdefs.h. */ 57332 57333 int 57334 main () 57335 { 57336 57337 ; 57338 return 0; 57339 } 57340 _ACEOF 57341 if ac_fn_cxx_try_link "$LINENO"; then : 57342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57343 $as_echo "yes" >&6; } 57344 X_LIBS="$X_LIBS -R $x_libraries" 57345 else 57346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 57347 $as_echo "neither works" >&6; } 57348 fi 57349 rm -f core conftest.err conftest.$ac_objext \ 57350 conftest$ac_exeext conftest.$ac_ext 57351 fi 57352 rm -f core conftest.err conftest.$ac_objext \ 57353 conftest$ac_exeext conftest.$ac_ext 57354 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 57355 LIBS=$ac_xsave_LIBS 57356 fi 57357 57358 # Check for system-dependent libraries X programs must link with. 57359 # Do this before checking for the system-independent R6 libraries 57360 # (-lICE), since we may need -lsocket or whatever for X linking. 57361 57362 if test "$ISC" = yes; then 57363 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 57364 else 57365 # Martyn Johnson says this is needed for Ultrix, if the X 57366 # libraries were built with DECnet support. And Karl Berry says 57367 # the Alpha needs dnet_stub (dnet does not exist). 57368 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 57369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57370 /* end confdefs.h. */ 57371 57372 /* Override any GCC internal prototype to avoid an error. 57373 Use char because int might match the return type of a GCC 57374 builtin and then its argument prototype would still apply. */ 57375 #ifdef __cplusplus 57376 extern "C" 57377 #endif 57378 char XOpenDisplay (); 57379 int 57380 main () 57381 { 57382 return XOpenDisplay (); 57383 ; 57384 return 0; 57385 } 57386 _ACEOF 57387 if ac_fn_cxx_try_link "$LINENO"; then : 57388 57389 else 57390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 57391 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 57392 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 57393 $as_echo_n "(cached) " >&6 57394 else 57395 ac_check_lib_save_LIBS=$LIBS 57396 LIBS="-ldnet $LIBS" 57397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57398 /* end confdefs.h. */ 57399 57400 /* Override any GCC internal prototype to avoid an error. 57401 Use char because int might match the return type of a GCC 57402 builtin and then its argument prototype would still apply. */ 57403 #ifdef __cplusplus 57404 extern "C" 57405 #endif 57406 char dnet_ntoa (); 57407 int 57408 main () 57409 { 57410 return dnet_ntoa (); 57411 ; 57412 return 0; 57413 } 57414 _ACEOF 57415 if ac_fn_cxx_try_link "$LINENO"; then : 57416 ac_cv_lib_dnet_dnet_ntoa=yes 57417 else 57418 ac_cv_lib_dnet_dnet_ntoa=no 57419 fi 57420 rm -f core conftest.err conftest.$ac_objext \ 57421 conftest$ac_exeext conftest.$ac_ext 57422 LIBS=$ac_check_lib_save_LIBS 57423 fi 57424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 57425 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 57426 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 57427 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 57428 fi 57429 57430 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 57431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 57432 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 57433 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 57434 $as_echo_n "(cached) " >&6 57435 else 57436 ac_check_lib_save_LIBS=$LIBS 57437 LIBS="-ldnet_stub $LIBS" 57438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57439 /* end confdefs.h. */ 57440 57441 /* Override any GCC internal prototype to avoid an error. 57442 Use char because int might match the return type of a GCC 57443 builtin and then its argument prototype would still apply. */ 57444 #ifdef __cplusplus 57445 extern "C" 57446 #endif 57447 char dnet_ntoa (); 57448 int 57449 main () 57450 { 57451 return dnet_ntoa (); 57452 ; 57453 return 0; 57454 } 57455 _ACEOF 57456 if ac_fn_cxx_try_link "$LINENO"; then : 57457 ac_cv_lib_dnet_stub_dnet_ntoa=yes 57458 else 57459 ac_cv_lib_dnet_stub_dnet_ntoa=no 57460 fi 57461 rm -f core conftest.err conftest.$ac_objext \ 57462 conftest$ac_exeext conftest.$ac_ext 57463 LIBS=$ac_check_lib_save_LIBS 57464 fi 57465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 57466 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 57467 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 57468 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 57469 fi 57470 57471 fi 57472 fi 57473 rm -f core conftest.err conftest.$ac_objext \ 57474 conftest$ac_exeext conftest.$ac_ext 57475 LIBS="$ac_xsave_LIBS" 57476 57477 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 57478 # to get the SysV transport functions. 57479 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 57480 # needs -lnsl. 57481 # The nsl library prevents programs from opening the X display 57482 # on Irix 5.2, according to T.E. Dickey. 57483 # The functions gethostbyname, getservbyname, and inet_addr are 57484 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 57485 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 57486 if test "x$ac_cv_func_gethostbyname" = xyes; then : 57487 57488 fi 57489 57490 if test $ac_cv_func_gethostbyname = no; then 57491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 57492 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 57493 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 57494 $as_echo_n "(cached) " >&6 57495 else 57496 ac_check_lib_save_LIBS=$LIBS 57497 LIBS="-lnsl $LIBS" 57498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57499 /* end confdefs.h. */ 57500 57501 /* Override any GCC internal prototype to avoid an error. 57502 Use char because int might match the return type of a GCC 57503 builtin and then its argument prototype would still apply. */ 57504 #ifdef __cplusplus 57505 extern "C" 57506 #endif 57507 char gethostbyname (); 57508 int 57509 main () 57510 { 57511 return gethostbyname (); 57512 ; 57513 return 0; 57514 } 57515 _ACEOF 57516 if ac_fn_cxx_try_link "$LINENO"; then : 57517 ac_cv_lib_nsl_gethostbyname=yes 57518 else 57519 ac_cv_lib_nsl_gethostbyname=no 57520 fi 57521 rm -f core conftest.err conftest.$ac_objext \ 57522 conftest$ac_exeext conftest.$ac_ext 57523 LIBS=$ac_check_lib_save_LIBS 57524 fi 57525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 57526 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 57527 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 57528 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 57529 fi 57530 57531 if test $ac_cv_lib_nsl_gethostbyname = no; then 57532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 57533 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 57534 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 57535 $as_echo_n "(cached) " >&6 57536 else 57537 ac_check_lib_save_LIBS=$LIBS 57538 LIBS="-lbsd $LIBS" 57539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57540 /* end confdefs.h. */ 57541 57542 /* Override any GCC internal prototype to avoid an error. 57543 Use char because int might match the return type of a GCC 57544 builtin and then its argument prototype would still apply. */ 57545 #ifdef __cplusplus 57546 extern "C" 57547 #endif 57548 char gethostbyname (); 57549 int 57550 main () 57551 { 57552 return gethostbyname (); 57553 ; 57554 return 0; 57555 } 57556 _ACEOF 57557 if ac_fn_cxx_try_link "$LINENO"; then : 57558 ac_cv_lib_bsd_gethostbyname=yes 57559 else 57560 ac_cv_lib_bsd_gethostbyname=no 57561 fi 57562 rm -f core conftest.err conftest.$ac_objext \ 57563 conftest$ac_exeext conftest.$ac_ext 57564 LIBS=$ac_check_lib_save_LIBS 57565 fi 57566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 57567 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 57568 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 57569 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 57570 fi 57571 57572 fi 57573 fi 57574 57575 # lieder@skyler.mavd.honeywell.com says without -lsocket, 57576 # socket/setsockopt and other routines are undefined under SCO ODT 57577 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 57578 # on later versions), says Simon Leinen: it contains gethostby* 57579 # variants that don't use the name server (or something). -lsocket 57580 # must be given before -lnsl if both are needed. We assume that 57581 # if connect needs -lnsl, so does gethostbyname. 57582 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 57583 if test "x$ac_cv_func_connect" = xyes; then : 57584 57585 fi 57586 57587 if test $ac_cv_func_connect = no; then 57588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 57589 $as_echo_n "checking for connect in -lsocket... " >&6; } 57590 if ${ac_cv_lib_socket_connect+:} false; then : 57591 $as_echo_n "(cached) " >&6 57592 else 57593 ac_check_lib_save_LIBS=$LIBS 57594 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 57595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57596 /* end confdefs.h. */ 57597 57598 /* Override any GCC internal prototype to avoid an error. 57599 Use char because int might match the return type of a GCC 57600 builtin and then its argument prototype would still apply. */ 57601 #ifdef __cplusplus 57602 extern "C" 57603 #endif 57604 char connect (); 57605 int 57606 main () 57607 { 57608 return connect (); 57609 ; 57610 return 0; 57611 } 57612 _ACEOF 57613 if ac_fn_cxx_try_link "$LINENO"; then : 57614 ac_cv_lib_socket_connect=yes 57615 else 57616 ac_cv_lib_socket_connect=no 57617 fi 57618 rm -f core conftest.err conftest.$ac_objext \ 57619 conftest$ac_exeext conftest.$ac_ext 57620 LIBS=$ac_check_lib_save_LIBS 57621 fi 57622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 57623 $as_echo "$ac_cv_lib_socket_connect" >&6; } 57624 if test "x$ac_cv_lib_socket_connect" = xyes; then : 57625 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 57626 fi 57627 57628 fi 57629 57630 # Guillermo Gomez says -lposix is necessary on A/UX. 57631 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 57632 if test "x$ac_cv_func_remove" = xyes; then : 57633 57634 fi 57635 57636 if test $ac_cv_func_remove = no; then 57637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 57638 $as_echo_n "checking for remove in -lposix... " >&6; } 57639 if ${ac_cv_lib_posix_remove+:} false; then : 57640 $as_echo_n "(cached) " >&6 57641 else 57642 ac_check_lib_save_LIBS=$LIBS 57643 LIBS="-lposix $LIBS" 57644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57645 /* end confdefs.h. */ 57646 57647 /* Override any GCC internal prototype to avoid an error. 57648 Use char because int might match the return type of a GCC 57649 builtin and then its argument prototype would still apply. */ 57650 #ifdef __cplusplus 57651 extern "C" 57652 #endif 57653 char remove (); 57654 int 57655 main () 57656 { 57657 return remove (); 57658 ; 57659 return 0; 57660 } 57661 _ACEOF 57662 if ac_fn_cxx_try_link "$LINENO"; then : 57663 ac_cv_lib_posix_remove=yes 57664 else 57665 ac_cv_lib_posix_remove=no 57666 fi 57667 rm -f core conftest.err conftest.$ac_objext \ 57668 conftest$ac_exeext conftest.$ac_ext 57669 LIBS=$ac_check_lib_save_LIBS 57670 fi 57671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 57672 $as_echo "$ac_cv_lib_posix_remove" >&6; } 57673 if test "x$ac_cv_lib_posix_remove" = xyes; then : 57674 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 57675 fi 57676 57677 fi 57678 57679 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 57680 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 57681 if test "x$ac_cv_func_shmat" = xyes; then : 57682 57683 fi 57684 57685 if test $ac_cv_func_shmat = no; then 57686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 57687 $as_echo_n "checking for shmat in -lipc... " >&6; } 57688 if ${ac_cv_lib_ipc_shmat+:} false; then : 57689 $as_echo_n "(cached) " >&6 57690 else 57691 ac_check_lib_save_LIBS=$LIBS 57692 LIBS="-lipc $LIBS" 57693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57694 /* end confdefs.h. */ 57695 57696 /* Override any GCC internal prototype to avoid an error. 57697 Use char because int might match the return type of a GCC 57698 builtin and then its argument prototype would still apply. */ 57699 #ifdef __cplusplus 57700 extern "C" 57701 #endif 57702 char shmat (); 57703 int 57704 main () 57705 { 57706 return shmat (); 57707 ; 57708 return 0; 57709 } 57710 _ACEOF 57711 if ac_fn_cxx_try_link "$LINENO"; then : 57712 ac_cv_lib_ipc_shmat=yes 57713 else 57714 ac_cv_lib_ipc_shmat=no 57715 fi 57716 rm -f core conftest.err conftest.$ac_objext \ 57717 conftest$ac_exeext conftest.$ac_ext 57718 LIBS=$ac_check_lib_save_LIBS 57719 fi 57720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 57721 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 57722 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 57723 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 57724 fi 57725 57726 fi 57727 fi 57728 57729 # Check for libraries that X11R6 Xt/Xaw programs need. 57730 ac_save_LDFLAGS=$LDFLAGS 57731 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 57732 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 57733 # check for ICE first), but we must link in the order -lSM -lICE or 57734 # we get undefined symbols. So assume we have SM if we have ICE. 57735 # These have to be linked with before -lX11, unlike the other 57736 # libraries we check for below, so use a different variable. 57737 # John Interrante, Karl Berry 57738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 57739 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 57740 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 57741 $as_echo_n "(cached) " >&6 57742 else 57743 ac_check_lib_save_LIBS=$LIBS 57744 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 57745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57746 /* end confdefs.h. */ 57747 57748 /* Override any GCC internal prototype to avoid an error. 57749 Use char because int might match the return type of a GCC 57750 builtin and then its argument prototype would still apply. */ 57751 #ifdef __cplusplus 57752 extern "C" 57753 #endif 57754 char IceConnectionNumber (); 57755 int 57756 main () 57757 { 57758 return IceConnectionNumber (); 57759 ; 57760 return 0; 57761 } 57762 _ACEOF 57763 if ac_fn_cxx_try_link "$LINENO"; then : 57764 ac_cv_lib_ICE_IceConnectionNumber=yes 57765 else 57766 ac_cv_lib_ICE_IceConnectionNumber=no 57767 fi 57768 rm -f core conftest.err conftest.$ac_objext \ 57769 conftest$ac_exeext conftest.$ac_ext 57770 LIBS=$ac_check_lib_save_LIBS 57771 fi 57772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 57773 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 57774 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 57775 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 57776 fi 57777 57778 LDFLAGS=$ac_save_LDFLAGS 57779 57780 fi 57781 57782 57783 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 57784 # this doesn't make sense so we remove it. 57785 if test "x$COMPILE_TYPE" = xcross; then 57786 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 57787 fi 57788 57789 if test "x$no_x" = xyes; then 57790 57791 # Print a helpful message on how to acquire the necessary build dependency. 57792 # x11 is the help tag: freetype, cups, alsa etc 57793 MISSING_DEPENDENCY=x11 57794 57795 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57796 cygwin_help $MISSING_DEPENDENCY 57797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57798 msys_help $MISSING_DEPENDENCY 57799 else 57800 PKGHANDLER_COMMAND= 57801 57802 case $PKGHANDLER in 57803 apt-get) 57804 apt_help $MISSING_DEPENDENCY ;; 57805 yum) 57806 yum_help $MISSING_DEPENDENCY ;; 57807 brew) 57808 brew_help $MISSING_DEPENDENCY ;; 57809 port) 57810 port_help $MISSING_DEPENDENCY ;; 57811 pkgutil) 57812 pkgutil_help $MISSING_DEPENDENCY ;; 57813 pkgadd) 57814 pkgadd_help $MISSING_DEPENDENCY ;; 57815 esac 57816 57817 if test "x$PKGHANDLER_COMMAND" != x; then 57818 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57819 fi 57820 fi 57821 57822 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 57823 fi 57824 57825 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 57826 OPENWIN_HOME="/usr/openwin" 57827 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 57828 X_LIBS="-L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 57829 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 57830 fi 57831 57832 ac_ext=c 57833 ac_cpp='$CPP $CPPFLAGS' 57834 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 57835 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 57836 ac_compiler_gnu=$ac_cv_c_compiler_gnu 57837 57838 OLD_CFLAGS="$CFLAGS" 57839 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 57840 57841 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 57842 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 57843 do : 57844 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 57845 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 57846 # include <X11/Xlib.h> 57847 # include <X11/Xutil.h> 57848 57849 57850 " 57851 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 57852 cat >>confdefs.h <<_ACEOF 57853 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 57854 _ACEOF 57855 X11_HEADERS_OK=yes 57856 else 57857 X11_HEADERS_OK=no; break 57858 fi 57859 57860 done 57861 57862 57863 if test "x$X11_HEADERS_OK" = xno; then 57864 57865 # Print a helpful message on how to acquire the necessary build dependency. 57866 # x11 is the help tag: freetype, cups, alsa etc 57867 MISSING_DEPENDENCY=x11 57868 57869 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57870 cygwin_help $MISSING_DEPENDENCY 57871 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57872 msys_help $MISSING_DEPENDENCY 57873 else 57874 PKGHANDLER_COMMAND= 57875 57876 case $PKGHANDLER in 57877 apt-get) 57878 apt_help $MISSING_DEPENDENCY ;; 57879 yum) 57880 yum_help $MISSING_DEPENDENCY ;; 57881 brew) 57882 brew_help $MISSING_DEPENDENCY ;; 57883 port) 57884 port_help $MISSING_DEPENDENCY ;; 57885 pkgutil) 57886 pkgutil_help $MISSING_DEPENDENCY ;; 57887 pkgadd) 57888 pkgadd_help $MISSING_DEPENDENCY ;; 57889 esac 57890 57891 if test "x$PKGHANDLER_COMMAND" != x; then 57892 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57893 fi 57894 fi 57895 57896 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 57897 fi 57898 57899 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 57900 # defined in libawt_xawt. 57901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 57902 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 57903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57904 /* end confdefs.h. */ 57905 #include <X11/extensions/Xrender.h> 57906 int 57907 main () 57908 { 57909 XLinearGradient x; 57910 ; 57911 return 0; 57912 } 57913 _ACEOF 57914 if ac_fn_c_try_compile "$LINENO"; then : 57915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57916 $as_echo "yes" >&6; } 57917 else 57918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57919 $as_echo "no" >&6; } 57920 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 57921 fi 57922 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 57923 57924 CFLAGS="$OLD_CFLAGS" 57925 ac_ext=cpp 57926 ac_cpp='$CXXCPP $CPPFLAGS' 57927 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 57928 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 57929 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 57930 57931 fi # NEEDS_LIB_X11 57932 57933 57934 57935 57936 57937 57938 # Check whether --with-cups was given. 57939 if test "${with_cups+set}" = set; then : 57940 withval=$with_cups; 57941 fi 57942 57943 57944 # Check whether --with-cups-include was given. 57945 if test "${with_cups_include+set}" = set; then : 57946 withval=$with_cups_include; 57947 fi 57948 57949 57950 if test "x$NEEDS_LIB_CUPS" = xfalse; then 57951 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 57952 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 57953 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 57954 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 57955 fi 57956 CUPS_CFLAGS= 57957 else 57958 CUPS_FOUND=no 57959 57960 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 57961 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 57962 fi 57963 57964 if test "x${with_cups}" != x; then 57965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 57966 $as_echo_n "checking for cups headers... " >&6; } 57967 if test -s "${with_cups}/include/cups/cups.h"; then 57968 CUPS_CFLAGS="-I${with_cups}/include" 57969 CUPS_FOUND=yes 57970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 57971 $as_echo "$CUPS_FOUND" >&6; } 57972 else 57973 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 57974 fi 57975 fi 57976 if test "x${with_cups_include}" != x; then 57977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 57978 $as_echo_n "checking for cups headers... " >&6; } 57979 if test -s "${with_cups_include}/cups/cups.h"; then 57980 CUPS_CFLAGS="-I${with_cups_include}" 57981 CUPS_FOUND=yes 57982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 57983 $as_echo "$CUPS_FOUND" >&6; } 57984 else 57985 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 57986 fi 57987 fi 57988 if test "x$CUPS_FOUND" = xno; then 57989 # Are the cups headers installed in the default /usr/include location? 57990 for ac_header in cups/cups.h cups/ppd.h 57991 do : 57992 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 57993 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 57994 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 57995 cat >>confdefs.h <<_ACEOF 57996 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 57997 _ACEOF 57998 57999 CUPS_FOUND=yes 58000 CUPS_CFLAGS= 58001 DEFAULT_CUPS=yes 58002 58003 fi 58004 58005 done 58006 58007 fi 58008 if test "x$CUPS_FOUND" = xno; then 58009 58010 # Print a helpful message on how to acquire the necessary build dependency. 58011 # cups is the help tag: freetype, cups, alsa etc 58012 MISSING_DEPENDENCY=cups 58013 58014 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58015 cygwin_help $MISSING_DEPENDENCY 58016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58017 msys_help $MISSING_DEPENDENCY 58018 else 58019 PKGHANDLER_COMMAND= 58020 58021 case $PKGHANDLER in 58022 apt-get) 58023 apt_help $MISSING_DEPENDENCY ;; 58024 yum) 58025 yum_help $MISSING_DEPENDENCY ;; 58026 brew) 58027 brew_help $MISSING_DEPENDENCY ;; 58028 port) 58029 port_help $MISSING_DEPENDENCY ;; 58030 pkgutil) 58031 pkgutil_help $MISSING_DEPENDENCY ;; 58032 pkgadd) 58033 pkgadd_help $MISSING_DEPENDENCY ;; 58034 esac 58035 58036 if test "x$PKGHANDLER_COMMAND" != x; then 58037 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 58038 fi 58039 fi 58040 58041 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 58042 fi 58043 fi 58044 58045 58046 58047 58048 58049 # Check whether --with-freetype was given. 58050 if test "${with_freetype+set}" = set; then : 58051 withval=$with_freetype; 58052 fi 58053 58054 58055 # Check whether --with-freetype-include was given. 58056 if test "${with_freetype_include+set}" = set; then : 58057 withval=$with_freetype_include; 58058 fi 58059 58060 58061 # Check whether --with-freetype-lib was given. 58062 if test "${with_freetype_lib+set}" = set; then : 58063 withval=$with_freetype_lib; 58064 fi 58065 58066 58067 # Check whether --with-freetype-src was given. 58068 if test "${with_freetype_src+set}" = set; then : 58069 withval=$with_freetype_src; 58070 fi 58071 58072 # Check whether --enable-freetype-bundling was given. 58073 if test "${enable_freetype_bundling+set}" = set; then : 58074 enableval=$enable_freetype_bundling; 58075 fi 58076 58077 58078 # Check whether --with-freetype-license was given. 58079 if test "${with_freetype_license+set}" = set; then : 58080 withval=$with_freetype_license; 58081 fi 58082 58083 58084 # Need to specify explicitly since it needs to be overridden on some versions of macosx 58085 FREETYPE_BASE_NAME=freetype 58086 FREETYPE_CFLAGS= 58087 FREETYPE_LIBS= 58088 FREETYPE_BUNDLE_LIB_PATH= 58089 58090 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 58091 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 58092 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 58093 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 58094 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 58095 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 58096 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 58097 fi 58098 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 58099 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 58100 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 58101 fi 58102 else 58103 # freetype is needed to build; go get it! 58104 58105 BUNDLE_FREETYPE="$enable_freetype_bundling" 58106 58107 if test "x$with_freetype_src" != x; then 58108 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58109 # Try to build freetype if --with-freetype-src was given on Windows 58110 58111 FREETYPE_SRC_PATH="$with_freetype_src" 58112 BUILD_FREETYPE=yes 58113 58114 # Check if the freetype sources are acessible.. 58115 if ! test -d $FREETYPE_SRC_PATH; then 58116 { $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 58117 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 58118 BUILD_FREETYPE=no 58119 fi 58120 # ..and contain a vc2010 project file 58121 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 58122 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 58123 { $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 58124 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 58125 BUILD_FREETYPE=no 58126 fi 58127 # Now check if configure found a version of 'msbuild.exe' 58128 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 58129 { $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 58130 $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;} 58131 BUILD_FREETYPE=no 58132 fi 58133 58134 # Ready to go.. 58135 if test "x$BUILD_FREETYPE" = xyes; then 58136 # msbuild requires trailing slashes for output directories 58137 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 58138 freetype_lib_path_unix="$freetype_lib_path" 58139 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 58140 58141 unix_path="$vcxproj_path" 58142 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58143 windows_path=`$CYGPATH -m "$unix_path"` 58144 vcxproj_path="$windows_path" 58145 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58146 windows_path=`cmd //c echo $unix_path` 58147 vcxproj_path="$windows_path" 58148 fi 58149 58150 58151 unix_path="$freetype_lib_path" 58152 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58153 windows_path=`$CYGPATH -m "$unix_path"` 58154 freetype_lib_path="$windows_path" 58155 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58156 windows_path=`cmd //c echo $unix_path` 58157 freetype_lib_path="$windows_path" 58158 fi 58159 58160 58161 unix_path="$freetype_obj_path" 58162 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58163 windows_path=`$CYGPATH -m "$unix_path"` 58164 freetype_obj_path="$windows_path" 58165 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58166 windows_path=`cmd //c echo $unix_path` 58167 freetype_obj_path="$windows_path" 58168 fi 58169 58170 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58171 freetype_platform=x64 58172 else 58173 freetype_platform=win32 58174 fi 58175 58176 # The original freetype project file is for VS 2010 (i.e. 'v100'), 58177 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 58178 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 58179 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 58180 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 58181 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 58182 58183 # First we try to build the freetype.dll 58184 $ECHO -e "@echo off\n"\ 58185 "$MSBUILD $vcxproj_path "\ 58186 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 58187 "/p:Configuration=\"Release Multithreaded\" "\ 58188 "/p:Platform=$freetype_platform "\ 58189 "/p:ConfigurationType=DynamicLibrary "\ 58190 "/p:TargetName=freetype "\ 58191 "/p:OutDir=\"$freetype_lib_path\" "\ 58192 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 58193 cmd /c freetype.bat 58194 58195 if test -s "$freetype_lib_path_unix/freetype.dll"; then 58196 # If that succeeds we also build freetype.lib 58197 $ECHO -e "@echo off\n"\ 58198 "$MSBUILD $vcxproj_path "\ 58199 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 58200 "/p:Configuration=\"Release Multithreaded\" "\ 58201 "/p:Platform=$freetype_platform "\ 58202 "/p:ConfigurationType=StaticLibrary "\ 58203 "/p:TargetName=freetype "\ 58204 "/p:OutDir=\"$freetype_lib_path\" "\ 58205 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 58206 cmd /c freetype.bat 58207 58208 if test -s "$freetype_lib_path_unix/freetype.lib"; then 58209 # Once we build both, lib and dll, set freetype lib and include path appropriately 58210 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 58211 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 58212 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 58213 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 58214 else 58215 BUILD_FREETYPE=no 58216 fi 58217 else 58218 BUILD_FREETYPE=no 58219 fi 58220 fi 58221 58222 if test "x$BUILD_FREETYPE" = xyes; then 58223 # Okay, we built it. Check that it works. 58224 58225 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58226 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58227 METHOD="--with-freetype-src" 58228 58229 # Let's start with an optimistic view of the world :-) 58230 FOUND_FREETYPE=yes 58231 58232 # First look for the canonical freetype main include file ft2build.h. 58233 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58234 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58235 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58236 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58237 # Fail. 58238 FOUND_FREETYPE=no 58239 fi 58240 fi 58241 58242 if test "x$FOUND_FREETYPE" = xyes; then 58243 # Include file found, let's continue the sanity check. 58244 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58245 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58246 58247 # Reset to default value 58248 FREETYPE_BASE_NAME=freetype 58249 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58250 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58251 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58252 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58253 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58254 # for the .6 version explicitly. 58255 FREETYPE_BASE_NAME=freetype.6 58256 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58257 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58258 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58259 else 58260 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58261 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58262 FOUND_FREETYPE=no 58263 fi 58264 else 58265 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58266 # On Windows, we will need both .lib and .dll file. 58267 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58268 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58269 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58270 FOUND_FREETYPE=no 58271 fi 58272 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58273 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58274 # Found lib in isa dir, use that instead. 58275 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58276 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58277 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58278 fi 58279 fi 58280 fi 58281 58282 if test "x$FOUND_FREETYPE" = xyes; then 58283 58284 # Only process if variable expands to non-empty 58285 58286 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58287 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58288 58289 # Input might be given as Windows format, start by converting to 58290 # unix format. 58291 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58292 new_path=`$CYGPATH -u "$path"` 58293 58294 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58295 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58296 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58297 # "foo.exe" is OK but "foo" is an error. 58298 # 58299 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58300 # It is also a way to make sure we got the proper file name for the real test later on. 58301 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58302 if test "x$test_shortpath" = x; then 58303 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58304 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58305 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58306 fi 58307 58308 # Call helper function which possibly converts this using DOS-style short mode. 58309 # If so, the updated path is stored in $new_path. 58310 58311 input_path="$new_path" 58312 # Check if we need to convert this using DOS-style short mode. If the path 58313 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58314 # take no chances and rewrite it. 58315 # Note: m4 eats our [], so we need to use [ and ] instead. 58316 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58317 if test "x$has_forbidden_chars" != x; then 58318 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58319 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58320 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58321 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58322 # Going to short mode and back again did indeed matter. Since short mode is 58323 # case insensitive, let's make it lowercase to improve readability. 58324 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58325 # Now convert it back to Unix-style (cygpath) 58326 input_path=`$CYGPATH -u "$shortmode_path"` 58327 new_path="$input_path" 58328 fi 58329 fi 58330 58331 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58332 if test "x$test_cygdrive_prefix" = x; then 58333 # As a simple fix, exclude /usr/bin since it's not a real path. 58334 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58335 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58336 # a path prefixed by /cygdrive for fixpath to work. 58337 new_path="$CYGWIN_ROOT_PATH$input_path" 58338 fi 58339 fi 58340 58341 58342 if test "x$path" != "x$new_path"; then 58343 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58344 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58345 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58346 fi 58347 58348 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58349 58350 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58351 has_colon=`$ECHO $path | $GREP ^.:` 58352 new_path="$path" 58353 if test "x$has_colon" = x; then 58354 # Not in mixed or Windows style, start by that. 58355 new_path=`cmd //c echo $path` 58356 fi 58357 58358 58359 input_path="$new_path" 58360 # Check if we need to convert this using DOS-style short mode. If the path 58361 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58362 # take no chances and rewrite it. 58363 # Note: m4 eats our [], so we need to use [ and ] instead. 58364 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58365 if test "x$has_forbidden_chars" != x; then 58366 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58367 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58368 fi 58369 58370 58371 windows_path="$new_path" 58372 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58373 unix_path=`$CYGPATH -u "$windows_path"` 58374 new_path="$unix_path" 58375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58376 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58377 new_path="$unix_path" 58378 fi 58379 58380 if test "x$path" != "x$new_path"; then 58381 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58382 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58383 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58384 fi 58385 58386 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58387 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58388 58389 else 58390 # We're on a unix platform. Hooray! :) 58391 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58392 has_space=`$ECHO "$path" | $GREP " "` 58393 if test "x$has_space" != x; then 58394 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58395 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58396 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58397 fi 58398 58399 # Use eval to expand a potential ~ 58400 eval path="$path" 58401 if test ! -f "$path" && test ! -d "$path"; then 58402 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58403 fi 58404 58405 if test -d "$path"; then 58406 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58407 else 58408 dir="`$DIRNAME "$path"`" 58409 base="`$BASENAME "$path"`" 58410 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58411 fi 58412 fi 58413 fi 58414 58415 58416 # Only process if variable expands to non-empty 58417 58418 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58419 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58420 58421 # Input might be given as Windows format, start by converting to 58422 # unix format. 58423 path="$POTENTIAL_FREETYPE_LIB_PATH" 58424 new_path=`$CYGPATH -u "$path"` 58425 58426 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58427 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58428 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58429 # "foo.exe" is OK but "foo" is an error. 58430 # 58431 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58432 # It is also a way to make sure we got the proper file name for the real test later on. 58433 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58434 if test "x$test_shortpath" = x; then 58435 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58436 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58437 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58438 fi 58439 58440 # Call helper function which possibly converts this using DOS-style short mode. 58441 # If so, the updated path is stored in $new_path. 58442 58443 input_path="$new_path" 58444 # Check if we need to convert this using DOS-style short mode. If the path 58445 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58446 # take no chances and rewrite it. 58447 # Note: m4 eats our [], so we need to use [ and ] instead. 58448 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58449 if test "x$has_forbidden_chars" != x; then 58450 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58451 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58452 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58453 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58454 # Going to short mode and back again did indeed matter. Since short mode is 58455 # case insensitive, let's make it lowercase to improve readability. 58456 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58457 # Now convert it back to Unix-style (cygpath) 58458 input_path=`$CYGPATH -u "$shortmode_path"` 58459 new_path="$input_path" 58460 fi 58461 fi 58462 58463 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58464 if test "x$test_cygdrive_prefix" = x; then 58465 # As a simple fix, exclude /usr/bin since it's not a real path. 58466 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58467 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58468 # a path prefixed by /cygdrive for fixpath to work. 58469 new_path="$CYGWIN_ROOT_PATH$input_path" 58470 fi 58471 fi 58472 58473 58474 if test "x$path" != "x$new_path"; then 58475 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58476 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58477 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58478 fi 58479 58480 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58481 58482 path="$POTENTIAL_FREETYPE_LIB_PATH" 58483 has_colon=`$ECHO $path | $GREP ^.:` 58484 new_path="$path" 58485 if test "x$has_colon" = x; then 58486 # Not in mixed or Windows style, start by that. 58487 new_path=`cmd //c echo $path` 58488 fi 58489 58490 58491 input_path="$new_path" 58492 # Check if we need to convert this using DOS-style short mode. If the path 58493 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58494 # take no chances and rewrite it. 58495 # Note: m4 eats our [], so we need to use [ and ] instead. 58496 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58497 if test "x$has_forbidden_chars" != x; then 58498 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58499 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58500 fi 58501 58502 58503 windows_path="$new_path" 58504 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58505 unix_path=`$CYGPATH -u "$windows_path"` 58506 new_path="$unix_path" 58507 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58508 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58509 new_path="$unix_path" 58510 fi 58511 58512 if test "x$path" != "x$new_path"; then 58513 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58514 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58515 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58516 fi 58517 58518 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58519 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58520 58521 else 58522 # We're on a unix platform. Hooray! :) 58523 path="$POTENTIAL_FREETYPE_LIB_PATH" 58524 has_space=`$ECHO "$path" | $GREP " "` 58525 if test "x$has_space" != x; then 58526 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58527 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58528 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58529 fi 58530 58531 # Use eval to expand a potential ~ 58532 eval path="$path" 58533 if test ! -f "$path" && test ! -d "$path"; then 58534 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58535 fi 58536 58537 if test -d "$path"; then 58538 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58539 else 58540 dir="`$DIRNAME "$path"`" 58541 base="`$BASENAME "$path"`" 58542 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58543 fi 58544 fi 58545 fi 58546 58547 58548 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58550 $as_echo_n "checking for freetype includes... " >&6; } 58551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58552 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58553 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58555 $as_echo_n "checking for freetype libraries... " >&6; } 58556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58557 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58558 fi 58559 58560 if test "x$FOUND_FREETYPE" != xyes; then 58561 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 58562 fi 58563 else 58564 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 58565 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 58566 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 58567 fi 58568 else 58569 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 58570 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 58571 fi 58572 fi 58573 58574 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 58575 # User has specified settings 58576 58577 if test "x$BUNDLE_FREETYPE" = x; then 58578 # If not specified, default is to bundle freetype 58579 BUNDLE_FREETYPE=yes 58580 fi 58581 58582 if test "x$with_freetype" != x; then 58583 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 58584 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 58585 fi 58586 58587 # Allow --with-freetype-lib and --with-freetype-include to override 58588 if test "x$with_freetype_include" != x; then 58589 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 58590 fi 58591 if test "x$with_freetype_lib" != x; then 58592 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 58593 fi 58594 58595 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58596 # Okay, we got it. Check that it works. 58597 58598 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58599 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58600 METHOD="--with-freetype" 58601 58602 # Let's start with an optimistic view of the world :-) 58603 FOUND_FREETYPE=yes 58604 58605 # First look for the canonical freetype main include file ft2build.h. 58606 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58607 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58608 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58609 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58610 # Fail. 58611 FOUND_FREETYPE=no 58612 fi 58613 fi 58614 58615 if test "x$FOUND_FREETYPE" = xyes; then 58616 # Include file found, let's continue the sanity check. 58617 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58618 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58619 58620 # Reset to default value 58621 FREETYPE_BASE_NAME=freetype 58622 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58623 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58624 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58625 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58626 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58627 # for the .6 version explicitly. 58628 FREETYPE_BASE_NAME=freetype.6 58629 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58630 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58631 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58632 else 58633 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58634 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58635 FOUND_FREETYPE=no 58636 fi 58637 else 58638 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58639 # On Windows, we will need both .lib and .dll file. 58640 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58641 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58642 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58643 FOUND_FREETYPE=no 58644 fi 58645 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58646 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58647 # Found lib in isa dir, use that instead. 58648 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58649 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58650 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58651 fi 58652 fi 58653 fi 58654 58655 if test "x$FOUND_FREETYPE" = xyes; then 58656 58657 # Only process if variable expands to non-empty 58658 58659 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58661 58662 # Input might be given as Windows format, start by converting to 58663 # unix format. 58664 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58665 new_path=`$CYGPATH -u "$path"` 58666 58667 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58668 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58669 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58670 # "foo.exe" is OK but "foo" is an error. 58671 # 58672 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58673 # It is also a way to make sure we got the proper file name for the real test later on. 58674 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58675 if test "x$test_shortpath" = x; then 58676 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58677 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58678 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58679 fi 58680 58681 # Call helper function which possibly converts this using DOS-style short mode. 58682 # If so, the updated path is stored in $new_path. 58683 58684 input_path="$new_path" 58685 # Check if we need to convert this using DOS-style short mode. If the path 58686 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58687 # take no chances and rewrite it. 58688 # Note: m4 eats our [], so we need to use [ and ] instead. 58689 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58690 if test "x$has_forbidden_chars" != x; then 58691 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58692 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58693 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58694 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58695 # Going to short mode and back again did indeed matter. Since short mode is 58696 # case insensitive, let's make it lowercase to improve readability. 58697 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58698 # Now convert it back to Unix-style (cygpath) 58699 input_path=`$CYGPATH -u "$shortmode_path"` 58700 new_path="$input_path" 58701 fi 58702 fi 58703 58704 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58705 if test "x$test_cygdrive_prefix" = x; then 58706 # As a simple fix, exclude /usr/bin since it's not a real path. 58707 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58708 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58709 # a path prefixed by /cygdrive for fixpath to work. 58710 new_path="$CYGWIN_ROOT_PATH$input_path" 58711 fi 58712 fi 58713 58714 58715 if test "x$path" != "x$new_path"; then 58716 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58717 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58718 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58719 fi 58720 58721 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58722 58723 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58724 has_colon=`$ECHO $path | $GREP ^.:` 58725 new_path="$path" 58726 if test "x$has_colon" = x; then 58727 # Not in mixed or Windows style, start by that. 58728 new_path=`cmd //c echo $path` 58729 fi 58730 58731 58732 input_path="$new_path" 58733 # Check if we need to convert this using DOS-style short mode. If the path 58734 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58735 # take no chances and rewrite it. 58736 # Note: m4 eats our [], so we need to use [ and ] instead. 58737 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58738 if test "x$has_forbidden_chars" != x; then 58739 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58740 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58741 fi 58742 58743 58744 windows_path="$new_path" 58745 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58746 unix_path=`$CYGPATH -u "$windows_path"` 58747 new_path="$unix_path" 58748 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58749 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58750 new_path="$unix_path" 58751 fi 58752 58753 if test "x$path" != "x$new_path"; then 58754 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58755 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58756 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58757 fi 58758 58759 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58760 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58761 58762 else 58763 # We're on a unix platform. Hooray! :) 58764 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58765 has_space=`$ECHO "$path" | $GREP " "` 58766 if test "x$has_space" != x; then 58767 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58768 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58769 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58770 fi 58771 58772 # Use eval to expand a potential ~ 58773 eval path="$path" 58774 if test ! -f "$path" && test ! -d "$path"; then 58775 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58776 fi 58777 58778 if test -d "$path"; then 58779 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58780 else 58781 dir="`$DIRNAME "$path"`" 58782 base="`$BASENAME "$path"`" 58783 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58784 fi 58785 fi 58786 fi 58787 58788 58789 # Only process if variable expands to non-empty 58790 58791 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58793 58794 # Input might be given as Windows format, start by converting to 58795 # unix format. 58796 path="$POTENTIAL_FREETYPE_LIB_PATH" 58797 new_path=`$CYGPATH -u "$path"` 58798 58799 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58800 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58801 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58802 # "foo.exe" is OK but "foo" is an error. 58803 # 58804 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58805 # It is also a way to make sure we got the proper file name for the real test later on. 58806 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58807 if test "x$test_shortpath" = x; then 58808 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58809 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58810 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58811 fi 58812 58813 # Call helper function which possibly converts this using DOS-style short mode. 58814 # If so, the updated path is stored in $new_path. 58815 58816 input_path="$new_path" 58817 # Check if we need to convert this using DOS-style short mode. If the path 58818 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58819 # take no chances and rewrite it. 58820 # Note: m4 eats our [], so we need to use [ and ] instead. 58821 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58822 if test "x$has_forbidden_chars" != x; then 58823 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58824 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58825 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58826 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58827 # Going to short mode and back again did indeed matter. Since short mode is 58828 # case insensitive, let's make it lowercase to improve readability. 58829 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58830 # Now convert it back to Unix-style (cygpath) 58831 input_path=`$CYGPATH -u "$shortmode_path"` 58832 new_path="$input_path" 58833 fi 58834 fi 58835 58836 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58837 if test "x$test_cygdrive_prefix" = x; then 58838 # As a simple fix, exclude /usr/bin since it's not a real path. 58839 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58840 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58841 # a path prefixed by /cygdrive for fixpath to work. 58842 new_path="$CYGWIN_ROOT_PATH$input_path" 58843 fi 58844 fi 58845 58846 58847 if test "x$path" != "x$new_path"; then 58848 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58849 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58850 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58851 fi 58852 58853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58854 58855 path="$POTENTIAL_FREETYPE_LIB_PATH" 58856 has_colon=`$ECHO $path | $GREP ^.:` 58857 new_path="$path" 58858 if test "x$has_colon" = x; then 58859 # Not in mixed or Windows style, start by that. 58860 new_path=`cmd //c echo $path` 58861 fi 58862 58863 58864 input_path="$new_path" 58865 # Check if we need to convert this using DOS-style short mode. If the path 58866 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58867 # take no chances and rewrite it. 58868 # Note: m4 eats our [], so we need to use [ and ] instead. 58869 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58870 if test "x$has_forbidden_chars" != x; then 58871 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58872 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58873 fi 58874 58875 58876 windows_path="$new_path" 58877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58878 unix_path=`$CYGPATH -u "$windows_path"` 58879 new_path="$unix_path" 58880 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58881 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58882 new_path="$unix_path" 58883 fi 58884 58885 if test "x$path" != "x$new_path"; then 58886 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58887 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58888 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58889 fi 58890 58891 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58892 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58893 58894 else 58895 # We're on a unix platform. Hooray! :) 58896 path="$POTENTIAL_FREETYPE_LIB_PATH" 58897 has_space=`$ECHO "$path" | $GREP " "` 58898 if test "x$has_space" != x; then 58899 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58900 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58901 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58902 fi 58903 58904 # Use eval to expand a potential ~ 58905 eval path="$path" 58906 if test ! -f "$path" && test ! -d "$path"; then 58907 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58908 fi 58909 58910 if test -d "$path"; then 58911 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58912 else 58913 dir="`$DIRNAME "$path"`" 58914 base="`$BASENAME "$path"`" 58915 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58916 fi 58917 fi 58918 fi 58919 58920 58921 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58923 $as_echo_n "checking for freetype includes... " >&6; } 58924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58925 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58926 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58928 $as_echo_n "checking for freetype libraries... " >&6; } 58929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58930 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58931 fi 58932 58933 if test "x$FOUND_FREETYPE" != xyes; then 58934 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 58935 fi 58936 else 58937 # User specified only one of lib or include. This is an error. 58938 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 58939 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 58940 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 58941 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 58942 else 58943 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 58944 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 58945 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 58946 fi 58947 fi 58948 else 58949 # User did not specify settings, but we need freetype. Try to locate it. 58950 58951 if test "x$BUNDLE_FREETYPE" = x; then 58952 # If not specified, default is to bundle freetype only on windows 58953 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58954 BUNDLE_FREETYPE=yes 58955 else 58956 BUNDLE_FREETYPE=no 58957 fi 58958 fi 58959 58960 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 58961 if test "x$SYSROOT" = x; then 58962 if test "x$FOUND_FREETYPE" != xyes; then 58963 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 58964 if test "x$PKG_CONFIG" != x; then 58965 58966 pkg_failed=no 58967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 58968 $as_echo_n "checking for FREETYPE... " >&6; } 58969 58970 if test -n "$FREETYPE_CFLAGS"; then 58971 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 58972 elif test -n "$PKG_CONFIG"; then 58973 if test -n "$PKG_CONFIG" && \ 58974 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 58975 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 58976 ac_status=$? 58977 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 58978 test $ac_status = 0; }; then 58979 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 58980 else 58981 pkg_failed=yes 58982 fi 58983 else 58984 pkg_failed=untried 58985 fi 58986 if test -n "$FREETYPE_LIBS"; then 58987 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 58988 elif test -n "$PKG_CONFIG"; then 58989 if test -n "$PKG_CONFIG" && \ 58990 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 58991 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 58992 ac_status=$? 58993 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 58994 test $ac_status = 0; }; then 58995 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 58996 else 58997 pkg_failed=yes 58998 fi 58999 else 59000 pkg_failed=untried 59001 fi 59002 59003 59004 59005 if test $pkg_failed = yes; then 59006 59007 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 59008 _pkg_short_errors_supported=yes 59009 else 59010 _pkg_short_errors_supported=no 59011 fi 59012 if test $_pkg_short_errors_supported = yes; then 59013 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 59014 else 59015 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 59016 fi 59017 # Put the nasty error message in config.log where it belongs 59018 echo "$FREETYPE_PKG_ERRORS" >&5 59019 59020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59021 $as_echo "no" >&6; } 59022 FOUND_FREETYPE=no 59023 elif test $pkg_failed = untried; then 59024 FOUND_FREETYPE=no 59025 else 59026 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 59027 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 59028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 59029 $as_echo "yes" >&6; } 59030 FOUND_FREETYPE=yes 59031 fi 59032 if test "x$FOUND_FREETYPE" = xyes; then 59033 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 59034 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 59035 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 59036 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 59037 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 59038 fi 59039 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 59040 if test "x$BUNDLE_FREETYPE" = xyes; then 59041 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 59042 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 59043 FOUND_FREETYPE=no 59044 else 59045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 59046 $as_echo_n "checking for freetype... " >&6; } 59047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 59048 $as_echo "yes (using pkg-config)" >&6; } 59049 fi 59050 fi 59051 fi 59052 fi 59053 fi 59054 59055 if test "x$FOUND_FREETYPE" != xyes; then 59056 # Check in well-known locations 59057 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59058 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 59059 59060 windows_path="$FREETYPE_BASE_DIR" 59061 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59062 unix_path=`$CYGPATH -u "$windows_path"` 59063 FREETYPE_BASE_DIR="$unix_path" 59064 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59065 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59066 FREETYPE_BASE_DIR="$unix_path" 59067 fi 59068 59069 59070 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59071 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 59072 METHOD="well-known location" 59073 59074 # Let's start with an optimistic view of the world :-) 59075 FOUND_FREETYPE=yes 59076 59077 # First look for the canonical freetype main include file ft2build.h. 59078 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59079 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59080 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59081 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59082 # Fail. 59083 FOUND_FREETYPE=no 59084 fi 59085 fi 59086 59087 if test "x$FOUND_FREETYPE" = xyes; then 59088 # Include file found, let's continue the sanity check. 59089 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59090 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59091 59092 # Reset to default value 59093 FREETYPE_BASE_NAME=freetype 59094 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59095 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59096 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59097 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59098 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59099 # for the .6 version explicitly. 59100 FREETYPE_BASE_NAME=freetype.6 59101 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59102 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59103 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59104 else 59105 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59106 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59107 FOUND_FREETYPE=no 59108 fi 59109 else 59110 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59111 # On Windows, we will need both .lib and .dll file. 59112 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59113 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59114 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59115 FOUND_FREETYPE=no 59116 fi 59117 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59118 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59119 # Found lib in isa dir, use that instead. 59120 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59121 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59122 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59123 fi 59124 fi 59125 fi 59126 59127 if test "x$FOUND_FREETYPE" = xyes; then 59128 59129 # Only process if variable expands to non-empty 59130 59131 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59132 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59133 59134 # Input might be given as Windows format, start by converting to 59135 # unix format. 59136 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59137 new_path=`$CYGPATH -u "$path"` 59138 59139 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59140 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59141 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59142 # "foo.exe" is OK but "foo" is an error. 59143 # 59144 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59145 # It is also a way to make sure we got the proper file name for the real test later on. 59146 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59147 if test "x$test_shortpath" = x; then 59148 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59149 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59150 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59151 fi 59152 59153 # Call helper function which possibly converts this using DOS-style short mode. 59154 # If so, the updated path is stored in $new_path. 59155 59156 input_path="$new_path" 59157 # Check if we need to convert this using DOS-style short mode. If the path 59158 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59159 # take no chances and rewrite it. 59160 # Note: m4 eats our [], so we need to use [ and ] instead. 59161 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59162 if test "x$has_forbidden_chars" != x; then 59163 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59164 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59165 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59166 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59167 # Going to short mode and back again did indeed matter. Since short mode is 59168 # case insensitive, let's make it lowercase to improve readability. 59169 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59170 # Now convert it back to Unix-style (cygpath) 59171 input_path=`$CYGPATH -u "$shortmode_path"` 59172 new_path="$input_path" 59173 fi 59174 fi 59175 59176 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59177 if test "x$test_cygdrive_prefix" = x; then 59178 # As a simple fix, exclude /usr/bin since it's not a real path. 59179 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59180 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59181 # a path prefixed by /cygdrive for fixpath to work. 59182 new_path="$CYGWIN_ROOT_PATH$input_path" 59183 fi 59184 fi 59185 59186 59187 if test "x$path" != "x$new_path"; then 59188 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59189 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59190 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59191 fi 59192 59193 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59194 59195 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59196 has_colon=`$ECHO $path | $GREP ^.:` 59197 new_path="$path" 59198 if test "x$has_colon" = x; then 59199 # Not in mixed or Windows style, start by that. 59200 new_path=`cmd //c echo $path` 59201 fi 59202 59203 59204 input_path="$new_path" 59205 # Check if we need to convert this using DOS-style short mode. If the path 59206 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59207 # take no chances and rewrite it. 59208 # Note: m4 eats our [], so we need to use [ and ] instead. 59209 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59210 if test "x$has_forbidden_chars" != x; then 59211 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59212 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59213 fi 59214 59215 59216 windows_path="$new_path" 59217 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59218 unix_path=`$CYGPATH -u "$windows_path"` 59219 new_path="$unix_path" 59220 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59221 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59222 new_path="$unix_path" 59223 fi 59224 59225 if test "x$path" != "x$new_path"; then 59226 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59227 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59228 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59229 fi 59230 59231 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59232 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59233 59234 else 59235 # We're on a unix platform. Hooray! :) 59236 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59237 has_space=`$ECHO "$path" | $GREP " "` 59238 if test "x$has_space" != x; then 59239 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59240 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59241 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59242 fi 59243 59244 # Use eval to expand a potential ~ 59245 eval path="$path" 59246 if test ! -f "$path" && test ! -d "$path"; then 59247 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59248 fi 59249 59250 if test -d "$path"; then 59251 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59252 else 59253 dir="`$DIRNAME "$path"`" 59254 base="`$BASENAME "$path"`" 59255 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59256 fi 59257 fi 59258 fi 59259 59260 59261 # Only process if variable expands to non-empty 59262 59263 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59264 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59265 59266 # Input might be given as Windows format, start by converting to 59267 # unix format. 59268 path="$POTENTIAL_FREETYPE_LIB_PATH" 59269 new_path=`$CYGPATH -u "$path"` 59270 59271 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59272 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59273 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59274 # "foo.exe" is OK but "foo" is an error. 59275 # 59276 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59277 # It is also a way to make sure we got the proper file name for the real test later on. 59278 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59279 if test "x$test_shortpath" = x; then 59280 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59281 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59282 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59283 fi 59284 59285 # Call helper function which possibly converts this using DOS-style short mode. 59286 # If so, the updated path is stored in $new_path. 59287 59288 input_path="$new_path" 59289 # Check if we need to convert this using DOS-style short mode. If the path 59290 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59291 # take no chances and rewrite it. 59292 # Note: m4 eats our [], so we need to use [ and ] instead. 59293 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59294 if test "x$has_forbidden_chars" != x; then 59295 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59296 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59297 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59298 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59299 # Going to short mode and back again did indeed matter. Since short mode is 59300 # case insensitive, let's make it lowercase to improve readability. 59301 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59302 # Now convert it back to Unix-style (cygpath) 59303 input_path=`$CYGPATH -u "$shortmode_path"` 59304 new_path="$input_path" 59305 fi 59306 fi 59307 59308 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59309 if test "x$test_cygdrive_prefix" = x; then 59310 # As a simple fix, exclude /usr/bin since it's not a real path. 59311 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59312 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59313 # a path prefixed by /cygdrive for fixpath to work. 59314 new_path="$CYGWIN_ROOT_PATH$input_path" 59315 fi 59316 fi 59317 59318 59319 if test "x$path" != "x$new_path"; then 59320 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59321 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59322 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59323 fi 59324 59325 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59326 59327 path="$POTENTIAL_FREETYPE_LIB_PATH" 59328 has_colon=`$ECHO $path | $GREP ^.:` 59329 new_path="$path" 59330 if test "x$has_colon" = x; then 59331 # Not in mixed or Windows style, start by that. 59332 new_path=`cmd //c echo $path` 59333 fi 59334 59335 59336 input_path="$new_path" 59337 # Check if we need to convert this using DOS-style short mode. If the path 59338 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59339 # take no chances and rewrite it. 59340 # Note: m4 eats our [], so we need to use [ and ] instead. 59341 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59342 if test "x$has_forbidden_chars" != x; then 59343 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59344 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59345 fi 59346 59347 59348 windows_path="$new_path" 59349 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59350 unix_path=`$CYGPATH -u "$windows_path"` 59351 new_path="$unix_path" 59352 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59353 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59354 new_path="$unix_path" 59355 fi 59356 59357 if test "x$path" != "x$new_path"; then 59358 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59359 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59360 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59361 fi 59362 59363 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59364 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59365 59366 else 59367 # We're on a unix platform. Hooray! :) 59368 path="$POTENTIAL_FREETYPE_LIB_PATH" 59369 has_space=`$ECHO "$path" | $GREP " "` 59370 if test "x$has_space" != x; then 59371 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59372 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59373 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59374 fi 59375 59376 # Use eval to expand a potential ~ 59377 eval path="$path" 59378 if test ! -f "$path" && test ! -d "$path"; then 59379 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59380 fi 59381 59382 if test -d "$path"; then 59383 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59384 else 59385 dir="`$DIRNAME "$path"`" 59386 base="`$BASENAME "$path"`" 59387 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59388 fi 59389 fi 59390 fi 59391 59392 59393 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59395 $as_echo_n "checking for freetype includes... " >&6; } 59396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59397 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59398 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59400 $as_echo_n "checking for freetype libraries... " >&6; } 59401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59402 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59403 fi 59404 59405 if test "x$FOUND_FREETYPE" != xyes; then 59406 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 59407 59408 windows_path="$FREETYPE_BASE_DIR" 59409 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59410 unix_path=`$CYGPATH -u "$windows_path"` 59411 FREETYPE_BASE_DIR="$unix_path" 59412 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59413 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59414 FREETYPE_BASE_DIR="$unix_path" 59415 fi 59416 59417 59418 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59419 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 59420 METHOD="well-known location" 59421 59422 # Let's start with an optimistic view of the world :-) 59423 FOUND_FREETYPE=yes 59424 59425 # First look for the canonical freetype main include file ft2build.h. 59426 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59427 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59428 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59429 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59430 # Fail. 59431 FOUND_FREETYPE=no 59432 fi 59433 fi 59434 59435 if test "x$FOUND_FREETYPE" = xyes; then 59436 # Include file found, let's continue the sanity check. 59437 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59438 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59439 59440 # Reset to default value 59441 FREETYPE_BASE_NAME=freetype 59442 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59443 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59444 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59445 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59446 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59447 # for the .6 version explicitly. 59448 FREETYPE_BASE_NAME=freetype.6 59449 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59450 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59451 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59452 else 59453 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59454 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59455 FOUND_FREETYPE=no 59456 fi 59457 else 59458 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59459 # On Windows, we will need both .lib and .dll file. 59460 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59461 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59462 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59463 FOUND_FREETYPE=no 59464 fi 59465 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59466 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59467 # Found lib in isa dir, use that instead. 59468 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59469 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59470 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59471 fi 59472 fi 59473 fi 59474 59475 if test "x$FOUND_FREETYPE" = xyes; then 59476 59477 # Only process if variable expands to non-empty 59478 59479 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59481 59482 # Input might be given as Windows format, start by converting to 59483 # unix format. 59484 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59485 new_path=`$CYGPATH -u "$path"` 59486 59487 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59488 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59489 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59490 # "foo.exe" is OK but "foo" is an error. 59491 # 59492 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59493 # It is also a way to make sure we got the proper file name for the real test later on. 59494 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59495 if test "x$test_shortpath" = x; then 59496 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59497 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59498 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59499 fi 59500 59501 # Call helper function which possibly converts this using DOS-style short mode. 59502 # If so, the updated path is stored in $new_path. 59503 59504 input_path="$new_path" 59505 # Check if we need to convert this using DOS-style short mode. If the path 59506 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59507 # take no chances and rewrite it. 59508 # Note: m4 eats our [], so we need to use [ and ] instead. 59509 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59510 if test "x$has_forbidden_chars" != x; then 59511 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59512 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59513 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59514 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59515 # Going to short mode and back again did indeed matter. Since short mode is 59516 # case insensitive, let's make it lowercase to improve readability. 59517 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59518 # Now convert it back to Unix-style (cygpath) 59519 input_path=`$CYGPATH -u "$shortmode_path"` 59520 new_path="$input_path" 59521 fi 59522 fi 59523 59524 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59525 if test "x$test_cygdrive_prefix" = x; then 59526 # As a simple fix, exclude /usr/bin since it's not a real path. 59527 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59528 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59529 # a path prefixed by /cygdrive for fixpath to work. 59530 new_path="$CYGWIN_ROOT_PATH$input_path" 59531 fi 59532 fi 59533 59534 59535 if test "x$path" != "x$new_path"; then 59536 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59537 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59538 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59539 fi 59540 59541 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59542 59543 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59544 has_colon=`$ECHO $path | $GREP ^.:` 59545 new_path="$path" 59546 if test "x$has_colon" = x; then 59547 # Not in mixed or Windows style, start by that. 59548 new_path=`cmd //c echo $path` 59549 fi 59550 59551 59552 input_path="$new_path" 59553 # Check if we need to convert this using DOS-style short mode. If the path 59554 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59555 # take no chances and rewrite it. 59556 # Note: m4 eats our [], so we need to use [ and ] instead. 59557 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59558 if test "x$has_forbidden_chars" != x; then 59559 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59560 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59561 fi 59562 59563 59564 windows_path="$new_path" 59565 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59566 unix_path=`$CYGPATH -u "$windows_path"` 59567 new_path="$unix_path" 59568 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59569 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59570 new_path="$unix_path" 59571 fi 59572 59573 if test "x$path" != "x$new_path"; then 59574 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59575 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59576 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59577 fi 59578 59579 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59580 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59581 59582 else 59583 # We're on a unix platform. Hooray! :) 59584 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59585 has_space=`$ECHO "$path" | $GREP " "` 59586 if test "x$has_space" != x; then 59587 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59588 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59589 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59590 fi 59591 59592 # Use eval to expand a potential ~ 59593 eval path="$path" 59594 if test ! -f "$path" && test ! -d "$path"; then 59595 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59596 fi 59597 59598 if test -d "$path"; then 59599 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59600 else 59601 dir="`$DIRNAME "$path"`" 59602 base="`$BASENAME "$path"`" 59603 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59604 fi 59605 fi 59606 fi 59607 59608 59609 # Only process if variable expands to non-empty 59610 59611 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59612 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59613 59614 # Input might be given as Windows format, start by converting to 59615 # unix format. 59616 path="$POTENTIAL_FREETYPE_LIB_PATH" 59617 new_path=`$CYGPATH -u "$path"` 59618 59619 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59620 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59621 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59622 # "foo.exe" is OK but "foo" is an error. 59623 # 59624 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59625 # It is also a way to make sure we got the proper file name for the real test later on. 59626 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59627 if test "x$test_shortpath" = x; then 59628 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59629 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59630 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59631 fi 59632 59633 # Call helper function which possibly converts this using DOS-style short mode. 59634 # If so, the updated path is stored in $new_path. 59635 59636 input_path="$new_path" 59637 # Check if we need to convert this using DOS-style short mode. If the path 59638 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59639 # take no chances and rewrite it. 59640 # Note: m4 eats our [], so we need to use [ and ] instead. 59641 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59642 if test "x$has_forbidden_chars" != x; then 59643 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59644 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59645 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59646 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59647 # Going to short mode and back again did indeed matter. Since short mode is 59648 # case insensitive, let's make it lowercase to improve readability. 59649 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59650 # Now convert it back to Unix-style (cygpath) 59651 input_path=`$CYGPATH -u "$shortmode_path"` 59652 new_path="$input_path" 59653 fi 59654 fi 59655 59656 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59657 if test "x$test_cygdrive_prefix" = x; then 59658 # As a simple fix, exclude /usr/bin since it's not a real path. 59659 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59660 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59661 # a path prefixed by /cygdrive for fixpath to work. 59662 new_path="$CYGWIN_ROOT_PATH$input_path" 59663 fi 59664 fi 59665 59666 59667 if test "x$path" != "x$new_path"; then 59668 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59669 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59670 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59671 fi 59672 59673 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59674 59675 path="$POTENTIAL_FREETYPE_LIB_PATH" 59676 has_colon=`$ECHO $path | $GREP ^.:` 59677 new_path="$path" 59678 if test "x$has_colon" = x; then 59679 # Not in mixed or Windows style, start by that. 59680 new_path=`cmd //c echo $path` 59681 fi 59682 59683 59684 input_path="$new_path" 59685 # Check if we need to convert this using DOS-style short mode. If the path 59686 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59687 # take no chances and rewrite it. 59688 # Note: m4 eats our [], so we need to use [ and ] instead. 59689 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59690 if test "x$has_forbidden_chars" != x; then 59691 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59692 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59693 fi 59694 59695 59696 windows_path="$new_path" 59697 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59698 unix_path=`$CYGPATH -u "$windows_path"` 59699 new_path="$unix_path" 59700 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59701 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59702 new_path="$unix_path" 59703 fi 59704 59705 if test "x$path" != "x$new_path"; then 59706 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59707 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59708 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59709 fi 59710 59711 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59712 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59713 59714 else 59715 # We're on a unix platform. Hooray! :) 59716 path="$POTENTIAL_FREETYPE_LIB_PATH" 59717 has_space=`$ECHO "$path" | $GREP " "` 59718 if test "x$has_space" != x; then 59719 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59720 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59721 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59722 fi 59723 59724 # Use eval to expand a potential ~ 59725 eval path="$path" 59726 if test ! -f "$path" && test ! -d "$path"; then 59727 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59728 fi 59729 59730 if test -d "$path"; then 59731 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59732 else 59733 dir="`$DIRNAME "$path"`" 59734 base="`$BASENAME "$path"`" 59735 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59736 fi 59737 fi 59738 fi 59739 59740 59741 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59743 $as_echo_n "checking for freetype includes... " >&6; } 59744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59745 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59746 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59748 $as_echo_n "checking for freetype libraries... " >&6; } 59749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59750 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59751 fi 59752 59753 fi 59754 if test "x$FOUND_FREETYPE" != xyes; then 59755 FREETYPE_BASE_DIR="$HOME/freetype" 59756 59757 windows_path="$FREETYPE_BASE_DIR" 59758 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59759 unix_path=`$CYGPATH -u "$windows_path"` 59760 FREETYPE_BASE_DIR="$unix_path" 59761 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59762 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59763 FREETYPE_BASE_DIR="$unix_path" 59764 fi 59765 59766 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59767 59768 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59769 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59770 METHOD="well-known location" 59771 59772 # Let's start with an optimistic view of the world :-) 59773 FOUND_FREETYPE=yes 59774 59775 # First look for the canonical freetype main include file ft2build.h. 59776 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59777 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59778 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59779 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59780 # Fail. 59781 FOUND_FREETYPE=no 59782 fi 59783 fi 59784 59785 if test "x$FOUND_FREETYPE" = xyes; then 59786 # Include file found, let's continue the sanity check. 59787 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59788 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59789 59790 # Reset to default value 59791 FREETYPE_BASE_NAME=freetype 59792 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59793 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59794 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59795 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59796 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59797 # for the .6 version explicitly. 59798 FREETYPE_BASE_NAME=freetype.6 59799 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59800 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59801 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59802 else 59803 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59804 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59805 FOUND_FREETYPE=no 59806 fi 59807 else 59808 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59809 # On Windows, we will need both .lib and .dll file. 59810 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59811 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59812 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59813 FOUND_FREETYPE=no 59814 fi 59815 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59816 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59817 # Found lib in isa dir, use that instead. 59818 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59819 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59820 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59821 fi 59822 fi 59823 fi 59824 59825 if test "x$FOUND_FREETYPE" = xyes; then 59826 59827 # Only process if variable expands to non-empty 59828 59829 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59830 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59831 59832 # Input might be given as Windows format, start by converting to 59833 # unix format. 59834 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59835 new_path=`$CYGPATH -u "$path"` 59836 59837 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59838 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59839 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59840 # "foo.exe" is OK but "foo" is an error. 59841 # 59842 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59843 # It is also a way to make sure we got the proper file name for the real test later on. 59844 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59845 if test "x$test_shortpath" = x; then 59846 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59847 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59848 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59849 fi 59850 59851 # Call helper function which possibly converts this using DOS-style short mode. 59852 # If so, the updated path is stored in $new_path. 59853 59854 input_path="$new_path" 59855 # Check if we need to convert this using DOS-style short mode. If the path 59856 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59857 # take no chances and rewrite it. 59858 # Note: m4 eats our [], so we need to use [ and ] instead. 59859 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59860 if test "x$has_forbidden_chars" != x; then 59861 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59862 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59863 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59864 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59865 # Going to short mode and back again did indeed matter. Since short mode is 59866 # case insensitive, let's make it lowercase to improve readability. 59867 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59868 # Now convert it back to Unix-style (cygpath) 59869 input_path=`$CYGPATH -u "$shortmode_path"` 59870 new_path="$input_path" 59871 fi 59872 fi 59873 59874 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59875 if test "x$test_cygdrive_prefix" = x; then 59876 # As a simple fix, exclude /usr/bin since it's not a real path. 59877 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59878 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59879 # a path prefixed by /cygdrive for fixpath to work. 59880 new_path="$CYGWIN_ROOT_PATH$input_path" 59881 fi 59882 fi 59883 59884 59885 if test "x$path" != "x$new_path"; then 59886 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59887 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59888 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59889 fi 59890 59891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59892 59893 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59894 has_colon=`$ECHO $path | $GREP ^.:` 59895 new_path="$path" 59896 if test "x$has_colon" = x; then 59897 # Not in mixed or Windows style, start by that. 59898 new_path=`cmd //c echo $path` 59899 fi 59900 59901 59902 input_path="$new_path" 59903 # Check if we need to convert this using DOS-style short mode. If the path 59904 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59905 # take no chances and rewrite it. 59906 # Note: m4 eats our [], so we need to use [ and ] instead. 59907 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59908 if test "x$has_forbidden_chars" != x; then 59909 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59910 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59911 fi 59912 59913 59914 windows_path="$new_path" 59915 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59916 unix_path=`$CYGPATH -u "$windows_path"` 59917 new_path="$unix_path" 59918 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59919 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59920 new_path="$unix_path" 59921 fi 59922 59923 if test "x$path" != "x$new_path"; then 59924 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59925 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59926 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59927 fi 59928 59929 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59930 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59931 59932 else 59933 # We're on a unix platform. Hooray! :) 59934 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59935 has_space=`$ECHO "$path" | $GREP " "` 59936 if test "x$has_space" != x; then 59937 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59938 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59939 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59940 fi 59941 59942 # Use eval to expand a potential ~ 59943 eval path="$path" 59944 if test ! -f "$path" && test ! -d "$path"; then 59945 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59946 fi 59947 59948 if test -d "$path"; then 59949 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59950 else 59951 dir="`$DIRNAME "$path"`" 59952 base="`$BASENAME "$path"`" 59953 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59954 fi 59955 fi 59956 fi 59957 59958 59959 # Only process if variable expands to non-empty 59960 59961 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59962 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59963 59964 # Input might be given as Windows format, start by converting to 59965 # unix format. 59966 path="$POTENTIAL_FREETYPE_LIB_PATH" 59967 new_path=`$CYGPATH -u "$path"` 59968 59969 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59970 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59971 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59972 # "foo.exe" is OK but "foo" is an error. 59973 # 59974 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59975 # It is also a way to make sure we got the proper file name for the real test later on. 59976 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59977 if test "x$test_shortpath" = x; then 59978 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59979 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59980 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59981 fi 59982 59983 # Call helper function which possibly converts this using DOS-style short mode. 59984 # If so, the updated path is stored in $new_path. 59985 59986 input_path="$new_path" 59987 # Check if we need to convert this using DOS-style short mode. If the path 59988 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59989 # take no chances and rewrite it. 59990 # Note: m4 eats our [], so we need to use [ and ] instead. 59991 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59992 if test "x$has_forbidden_chars" != x; then 59993 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59994 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59995 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59996 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59997 # Going to short mode and back again did indeed matter. Since short mode is 59998 # case insensitive, let's make it lowercase to improve readability. 59999 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60000 # Now convert it back to Unix-style (cygpath) 60001 input_path=`$CYGPATH -u "$shortmode_path"` 60002 new_path="$input_path" 60003 fi 60004 fi 60005 60006 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60007 if test "x$test_cygdrive_prefix" = x; then 60008 # As a simple fix, exclude /usr/bin since it's not a real path. 60009 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60010 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60011 # a path prefixed by /cygdrive for fixpath to work. 60012 new_path="$CYGWIN_ROOT_PATH$input_path" 60013 fi 60014 fi 60015 60016 60017 if test "x$path" != "x$new_path"; then 60018 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60019 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60020 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60021 fi 60022 60023 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60024 60025 path="$POTENTIAL_FREETYPE_LIB_PATH" 60026 has_colon=`$ECHO $path | $GREP ^.:` 60027 new_path="$path" 60028 if test "x$has_colon" = x; then 60029 # Not in mixed or Windows style, start by that. 60030 new_path=`cmd //c echo $path` 60031 fi 60032 60033 60034 input_path="$new_path" 60035 # Check if we need to convert this using DOS-style short mode. If the path 60036 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60037 # take no chances and rewrite it. 60038 # Note: m4 eats our [], so we need to use [ and ] instead. 60039 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60040 if test "x$has_forbidden_chars" != x; then 60041 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60042 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60043 fi 60044 60045 60046 windows_path="$new_path" 60047 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60048 unix_path=`$CYGPATH -u "$windows_path"` 60049 new_path="$unix_path" 60050 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60051 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60052 new_path="$unix_path" 60053 fi 60054 60055 if test "x$path" != "x$new_path"; then 60056 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60057 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60058 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60059 fi 60060 60061 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60062 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60063 60064 else 60065 # We're on a unix platform. Hooray! :) 60066 path="$POTENTIAL_FREETYPE_LIB_PATH" 60067 has_space=`$ECHO "$path" | $GREP " "` 60068 if test "x$has_space" != x; then 60069 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60070 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60071 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60072 fi 60073 60074 # Use eval to expand a potential ~ 60075 eval path="$path" 60076 if test ! -f "$path" && test ! -d "$path"; then 60077 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60078 fi 60079 60080 if test -d "$path"; then 60081 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60082 else 60083 dir="`$DIRNAME "$path"`" 60084 base="`$BASENAME "$path"`" 60085 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60086 fi 60087 fi 60088 fi 60089 60090 60091 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60093 $as_echo_n "checking for freetype includes... " >&6; } 60094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60095 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60096 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60098 $as_echo_n "checking for freetype libraries... " >&6; } 60099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60100 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60101 fi 60102 60103 else 60104 60105 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60106 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 60107 METHOD="well-known location" 60108 60109 # Let's start with an optimistic view of the world :-) 60110 FOUND_FREETYPE=yes 60111 60112 # First look for the canonical freetype main include file ft2build.h. 60113 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60114 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60115 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60116 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60117 # Fail. 60118 FOUND_FREETYPE=no 60119 fi 60120 fi 60121 60122 if test "x$FOUND_FREETYPE" = xyes; then 60123 # Include file found, let's continue the sanity check. 60124 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60125 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60126 60127 # Reset to default value 60128 FREETYPE_BASE_NAME=freetype 60129 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60130 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60131 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60132 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60133 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60134 # for the .6 version explicitly. 60135 FREETYPE_BASE_NAME=freetype.6 60136 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60137 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60138 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60139 else 60140 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60141 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60142 FOUND_FREETYPE=no 60143 fi 60144 else 60145 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60146 # On Windows, we will need both .lib and .dll file. 60147 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60148 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60149 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60150 FOUND_FREETYPE=no 60151 fi 60152 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60153 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60154 # Found lib in isa dir, use that instead. 60155 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60156 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60157 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60158 fi 60159 fi 60160 fi 60161 60162 if test "x$FOUND_FREETYPE" = xyes; then 60163 60164 # Only process if variable expands to non-empty 60165 60166 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60167 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60168 60169 # Input might be given as Windows format, start by converting to 60170 # unix format. 60171 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60172 new_path=`$CYGPATH -u "$path"` 60173 60174 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60175 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60176 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60177 # "foo.exe" is OK but "foo" is an error. 60178 # 60179 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60180 # It is also a way to make sure we got the proper file name for the real test later on. 60181 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60182 if test "x$test_shortpath" = x; then 60183 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60184 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60185 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60186 fi 60187 60188 # Call helper function which possibly converts this using DOS-style short mode. 60189 # If so, the updated path is stored in $new_path. 60190 60191 input_path="$new_path" 60192 # Check if we need to convert this using DOS-style short mode. If the path 60193 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60194 # take no chances and rewrite it. 60195 # Note: m4 eats our [], so we need to use [ and ] instead. 60196 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60197 if test "x$has_forbidden_chars" != x; then 60198 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60199 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60200 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60201 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60202 # Going to short mode and back again did indeed matter. Since short mode is 60203 # case insensitive, let's make it lowercase to improve readability. 60204 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60205 # Now convert it back to Unix-style (cygpath) 60206 input_path=`$CYGPATH -u "$shortmode_path"` 60207 new_path="$input_path" 60208 fi 60209 fi 60210 60211 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60212 if test "x$test_cygdrive_prefix" = x; then 60213 # As a simple fix, exclude /usr/bin since it's not a real path. 60214 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60215 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60216 # a path prefixed by /cygdrive for fixpath to work. 60217 new_path="$CYGWIN_ROOT_PATH$input_path" 60218 fi 60219 fi 60220 60221 60222 if test "x$path" != "x$new_path"; then 60223 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60224 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60225 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60226 fi 60227 60228 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60229 60230 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60231 has_colon=`$ECHO $path | $GREP ^.:` 60232 new_path="$path" 60233 if test "x$has_colon" = x; then 60234 # Not in mixed or Windows style, start by that. 60235 new_path=`cmd //c echo $path` 60236 fi 60237 60238 60239 input_path="$new_path" 60240 # Check if we need to convert this using DOS-style short mode. If the path 60241 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60242 # take no chances and rewrite it. 60243 # Note: m4 eats our [], so we need to use [ and ] instead. 60244 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60245 if test "x$has_forbidden_chars" != x; then 60246 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60247 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60248 fi 60249 60250 60251 windows_path="$new_path" 60252 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60253 unix_path=`$CYGPATH -u "$windows_path"` 60254 new_path="$unix_path" 60255 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60256 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60257 new_path="$unix_path" 60258 fi 60259 60260 if test "x$path" != "x$new_path"; then 60261 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60262 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60263 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60264 fi 60265 60266 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60267 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60268 60269 else 60270 # We're on a unix platform. Hooray! :) 60271 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60272 has_space=`$ECHO "$path" | $GREP " "` 60273 if test "x$has_space" != x; then 60274 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60275 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60276 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60277 fi 60278 60279 # Use eval to expand a potential ~ 60280 eval path="$path" 60281 if test ! -f "$path" && test ! -d "$path"; then 60282 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60283 fi 60284 60285 if test -d "$path"; then 60286 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60287 else 60288 dir="`$DIRNAME "$path"`" 60289 base="`$BASENAME "$path"`" 60290 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60291 fi 60292 fi 60293 fi 60294 60295 60296 # Only process if variable expands to non-empty 60297 60298 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60300 60301 # Input might be given as Windows format, start by converting to 60302 # unix format. 60303 path="$POTENTIAL_FREETYPE_LIB_PATH" 60304 new_path=`$CYGPATH -u "$path"` 60305 60306 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60307 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60308 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60309 # "foo.exe" is OK but "foo" is an error. 60310 # 60311 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60312 # It is also a way to make sure we got the proper file name for the real test later on. 60313 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60314 if test "x$test_shortpath" = x; then 60315 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60316 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60317 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60318 fi 60319 60320 # Call helper function which possibly converts this using DOS-style short mode. 60321 # If so, the updated path is stored in $new_path. 60322 60323 input_path="$new_path" 60324 # Check if we need to convert this using DOS-style short mode. If the path 60325 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60326 # take no chances and rewrite it. 60327 # Note: m4 eats our [], so we need to use [ and ] instead. 60328 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60329 if test "x$has_forbidden_chars" != x; then 60330 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60331 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60332 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60333 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60334 # Going to short mode and back again did indeed matter. Since short mode is 60335 # case insensitive, let's make it lowercase to improve readability. 60336 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60337 # Now convert it back to Unix-style (cygpath) 60338 input_path=`$CYGPATH -u "$shortmode_path"` 60339 new_path="$input_path" 60340 fi 60341 fi 60342 60343 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60344 if test "x$test_cygdrive_prefix" = x; then 60345 # As a simple fix, exclude /usr/bin since it's not a real path. 60346 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60347 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60348 # a path prefixed by /cygdrive for fixpath to work. 60349 new_path="$CYGWIN_ROOT_PATH$input_path" 60350 fi 60351 fi 60352 60353 60354 if test "x$path" != "x$new_path"; then 60355 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60356 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60357 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60358 fi 60359 60360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60361 60362 path="$POTENTIAL_FREETYPE_LIB_PATH" 60363 has_colon=`$ECHO $path | $GREP ^.:` 60364 new_path="$path" 60365 if test "x$has_colon" = x; then 60366 # Not in mixed or Windows style, start by that. 60367 new_path=`cmd //c echo $path` 60368 fi 60369 60370 60371 input_path="$new_path" 60372 # Check if we need to convert this using DOS-style short mode. If the path 60373 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60374 # take no chances and rewrite it. 60375 # Note: m4 eats our [], so we need to use [ and ] instead. 60376 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60377 if test "x$has_forbidden_chars" != x; then 60378 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60379 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60380 fi 60381 60382 60383 windows_path="$new_path" 60384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60385 unix_path=`$CYGPATH -u "$windows_path"` 60386 new_path="$unix_path" 60387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60388 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60389 new_path="$unix_path" 60390 fi 60391 60392 if test "x$path" != "x$new_path"; then 60393 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60394 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60395 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60396 fi 60397 60398 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60399 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60400 60401 else 60402 # We're on a unix platform. Hooray! :) 60403 path="$POTENTIAL_FREETYPE_LIB_PATH" 60404 has_space=`$ECHO "$path" | $GREP " "` 60405 if test "x$has_space" != x; then 60406 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60407 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60408 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60409 fi 60410 60411 # Use eval to expand a potential ~ 60412 eval path="$path" 60413 if test ! -f "$path" && test ! -d "$path"; then 60414 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60415 fi 60416 60417 if test -d "$path"; then 60418 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60419 else 60420 dir="`$DIRNAME "$path"`" 60421 base="`$BASENAME "$path"`" 60422 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60423 fi 60424 fi 60425 fi 60426 60427 60428 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60430 $as_echo_n "checking for freetype includes... " >&6; } 60431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60432 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60433 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60435 $as_echo_n "checking for freetype libraries... " >&6; } 60436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60437 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60438 fi 60439 60440 fi 60441 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 60442 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 60443 # Source is available, as a last resort try to build freetype in default location 60444 60445 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 60446 BUILD_FREETYPE=yes 60447 60448 # Check if the freetype sources are acessible.. 60449 if ! test -d $FREETYPE_SRC_PATH; then 60450 { $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 60451 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 60452 BUILD_FREETYPE=no 60453 fi 60454 # ..and contain a vc2010 project file 60455 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 60456 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 60457 { $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 60458 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 60459 BUILD_FREETYPE=no 60460 fi 60461 # Now check if configure found a version of 'msbuild.exe' 60462 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 60463 { $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 60464 $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;} 60465 BUILD_FREETYPE=no 60466 fi 60467 60468 # Ready to go.. 60469 if test "x$BUILD_FREETYPE" = xyes; then 60470 # msbuild requires trailing slashes for output directories 60471 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 60472 freetype_lib_path_unix="$freetype_lib_path" 60473 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 60474 60475 unix_path="$vcxproj_path" 60476 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60477 windows_path=`$CYGPATH -m "$unix_path"` 60478 vcxproj_path="$windows_path" 60479 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60480 windows_path=`cmd //c echo $unix_path` 60481 vcxproj_path="$windows_path" 60482 fi 60483 60484 60485 unix_path="$freetype_lib_path" 60486 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60487 windows_path=`$CYGPATH -m "$unix_path"` 60488 freetype_lib_path="$windows_path" 60489 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60490 windows_path=`cmd //c echo $unix_path` 60491 freetype_lib_path="$windows_path" 60492 fi 60493 60494 60495 unix_path="$freetype_obj_path" 60496 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60497 windows_path=`$CYGPATH -m "$unix_path"` 60498 freetype_obj_path="$windows_path" 60499 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60500 windows_path=`cmd //c echo $unix_path` 60501 freetype_obj_path="$windows_path" 60502 fi 60503 60504 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 60505 freetype_platform=x64 60506 else 60507 freetype_platform=win32 60508 fi 60509 60510 # The original freetype project file is for VS 2010 (i.e. 'v100'), 60511 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 60512 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 60513 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 60514 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 60515 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 60516 60517 # First we try to build the freetype.dll 60518 $ECHO -e "@echo off\n"\ 60519 "$MSBUILD $vcxproj_path "\ 60520 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 60521 "/p:Configuration=\"Release Multithreaded\" "\ 60522 "/p:Platform=$freetype_platform "\ 60523 "/p:ConfigurationType=DynamicLibrary "\ 60524 "/p:TargetName=freetype "\ 60525 "/p:OutDir=\"$freetype_lib_path\" "\ 60526 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 60527 cmd /c freetype.bat 60528 60529 if test -s "$freetype_lib_path_unix/freetype.dll"; then 60530 # If that succeeds we also build freetype.lib 60531 $ECHO -e "@echo off\n"\ 60532 "$MSBUILD $vcxproj_path "\ 60533 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 60534 "/p:Configuration=\"Release Multithreaded\" "\ 60535 "/p:Platform=$freetype_platform "\ 60536 "/p:ConfigurationType=StaticLibrary "\ 60537 "/p:TargetName=freetype "\ 60538 "/p:OutDir=\"$freetype_lib_path\" "\ 60539 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 60540 cmd /c freetype.bat 60541 60542 if test -s "$freetype_lib_path_unix/freetype.lib"; then 60543 # Once we build both, lib and dll, set freetype lib and include path appropriately 60544 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 60545 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 60546 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 60547 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 60548 else 60549 BUILD_FREETYPE=no 60550 fi 60551 else 60552 BUILD_FREETYPE=no 60553 fi 60554 fi 60555 60556 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 60557 60558 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60559 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 60560 METHOD="well-known location" 60561 60562 # Let's start with an optimistic view of the world :-) 60563 FOUND_FREETYPE=yes 60564 60565 # First look for the canonical freetype main include file ft2build.h. 60566 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60567 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60568 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60569 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60570 # Fail. 60571 FOUND_FREETYPE=no 60572 fi 60573 fi 60574 60575 if test "x$FOUND_FREETYPE" = xyes; then 60576 # Include file found, let's continue the sanity check. 60577 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60578 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60579 60580 # Reset to default value 60581 FREETYPE_BASE_NAME=freetype 60582 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60583 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60584 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60585 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60586 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60587 # for the .6 version explicitly. 60588 FREETYPE_BASE_NAME=freetype.6 60589 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60590 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60591 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60592 else 60593 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60594 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60595 FOUND_FREETYPE=no 60596 fi 60597 else 60598 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60599 # On Windows, we will need both .lib and .dll file. 60600 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60601 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60602 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60603 FOUND_FREETYPE=no 60604 fi 60605 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60606 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60607 # Found lib in isa dir, use that instead. 60608 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60609 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60610 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60611 fi 60612 fi 60613 fi 60614 60615 if test "x$FOUND_FREETYPE" = xyes; then 60616 60617 # Only process if variable expands to non-empty 60618 60619 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60621 60622 # Input might be given as Windows format, start by converting to 60623 # unix format. 60624 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60625 new_path=`$CYGPATH -u "$path"` 60626 60627 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60628 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60629 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60630 # "foo.exe" is OK but "foo" is an error. 60631 # 60632 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60633 # It is also a way to make sure we got the proper file name for the real test later on. 60634 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60635 if test "x$test_shortpath" = x; then 60636 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60637 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60638 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60639 fi 60640 60641 # Call helper function which possibly converts this using DOS-style short mode. 60642 # If so, the updated path is stored in $new_path. 60643 60644 input_path="$new_path" 60645 # Check if we need to convert this using DOS-style short mode. If the path 60646 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60647 # take no chances and rewrite it. 60648 # Note: m4 eats our [], so we need to use [ and ] instead. 60649 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60650 if test "x$has_forbidden_chars" != x; then 60651 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60652 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60653 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60654 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60655 # Going to short mode and back again did indeed matter. Since short mode is 60656 # case insensitive, let's make it lowercase to improve readability. 60657 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60658 # Now convert it back to Unix-style (cygpath) 60659 input_path=`$CYGPATH -u "$shortmode_path"` 60660 new_path="$input_path" 60661 fi 60662 fi 60663 60664 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60665 if test "x$test_cygdrive_prefix" = x; then 60666 # As a simple fix, exclude /usr/bin since it's not a real path. 60667 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60668 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60669 # a path prefixed by /cygdrive for fixpath to work. 60670 new_path="$CYGWIN_ROOT_PATH$input_path" 60671 fi 60672 fi 60673 60674 60675 if test "x$path" != "x$new_path"; then 60676 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60677 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60678 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60679 fi 60680 60681 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60682 60683 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60684 has_colon=`$ECHO $path | $GREP ^.:` 60685 new_path="$path" 60686 if test "x$has_colon" = x; then 60687 # Not in mixed or Windows style, start by that. 60688 new_path=`cmd //c echo $path` 60689 fi 60690 60691 60692 input_path="$new_path" 60693 # Check if we need to convert this using DOS-style short mode. If the path 60694 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60695 # take no chances and rewrite it. 60696 # Note: m4 eats our [], so we need to use [ and ] instead. 60697 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60698 if test "x$has_forbidden_chars" != x; then 60699 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60700 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60701 fi 60702 60703 60704 windows_path="$new_path" 60705 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60706 unix_path=`$CYGPATH -u "$windows_path"` 60707 new_path="$unix_path" 60708 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60709 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60710 new_path="$unix_path" 60711 fi 60712 60713 if test "x$path" != "x$new_path"; then 60714 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60715 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60716 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60717 fi 60718 60719 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60720 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60721 60722 else 60723 # We're on a unix platform. Hooray! :) 60724 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60725 has_space=`$ECHO "$path" | $GREP " "` 60726 if test "x$has_space" != x; then 60727 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60728 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60729 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60730 fi 60731 60732 # Use eval to expand a potential ~ 60733 eval path="$path" 60734 if test ! -f "$path" && test ! -d "$path"; then 60735 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60736 fi 60737 60738 if test -d "$path"; then 60739 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60740 else 60741 dir="`$DIRNAME "$path"`" 60742 base="`$BASENAME "$path"`" 60743 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60744 fi 60745 fi 60746 fi 60747 60748 60749 # Only process if variable expands to non-empty 60750 60751 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60752 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60753 60754 # Input might be given as Windows format, start by converting to 60755 # unix format. 60756 path="$POTENTIAL_FREETYPE_LIB_PATH" 60757 new_path=`$CYGPATH -u "$path"` 60758 60759 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60760 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60761 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60762 # "foo.exe" is OK but "foo" is an error. 60763 # 60764 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60765 # It is also a way to make sure we got the proper file name for the real test later on. 60766 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60767 if test "x$test_shortpath" = x; then 60768 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60769 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60770 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60771 fi 60772 60773 # Call helper function which possibly converts this using DOS-style short mode. 60774 # If so, the updated path is stored in $new_path. 60775 60776 input_path="$new_path" 60777 # Check if we need to convert this using DOS-style short mode. If the path 60778 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60779 # take no chances and rewrite it. 60780 # Note: m4 eats our [], so we need to use [ and ] instead. 60781 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60782 if test "x$has_forbidden_chars" != x; then 60783 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60784 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60785 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60786 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60787 # Going to short mode and back again did indeed matter. Since short mode is 60788 # case insensitive, let's make it lowercase to improve readability. 60789 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60790 # Now convert it back to Unix-style (cygpath) 60791 input_path=`$CYGPATH -u "$shortmode_path"` 60792 new_path="$input_path" 60793 fi 60794 fi 60795 60796 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60797 if test "x$test_cygdrive_prefix" = x; then 60798 # As a simple fix, exclude /usr/bin since it's not a real path. 60799 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60800 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60801 # a path prefixed by /cygdrive for fixpath to work. 60802 new_path="$CYGWIN_ROOT_PATH$input_path" 60803 fi 60804 fi 60805 60806 60807 if test "x$path" != "x$new_path"; then 60808 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60809 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60810 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60811 fi 60812 60813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60814 60815 path="$POTENTIAL_FREETYPE_LIB_PATH" 60816 has_colon=`$ECHO $path | $GREP ^.:` 60817 new_path="$path" 60818 if test "x$has_colon" = x; then 60819 # Not in mixed or Windows style, start by that. 60820 new_path=`cmd //c echo $path` 60821 fi 60822 60823 60824 input_path="$new_path" 60825 # Check if we need to convert this using DOS-style short mode. If the path 60826 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60827 # take no chances and rewrite it. 60828 # Note: m4 eats our [], so we need to use [ and ] instead. 60829 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60830 if test "x$has_forbidden_chars" != x; then 60831 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60832 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60833 fi 60834 60835 60836 windows_path="$new_path" 60837 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60838 unix_path=`$CYGPATH -u "$windows_path"` 60839 new_path="$unix_path" 60840 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60841 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60842 new_path="$unix_path" 60843 fi 60844 60845 if test "x$path" != "x$new_path"; then 60846 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60847 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60848 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60849 fi 60850 60851 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60852 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60853 60854 else 60855 # We're on a unix platform. Hooray! :) 60856 path="$POTENTIAL_FREETYPE_LIB_PATH" 60857 has_space=`$ECHO "$path" | $GREP " "` 60858 if test "x$has_space" != x; then 60859 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60860 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60861 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60862 fi 60863 60864 # Use eval to expand a potential ~ 60865 eval path="$path" 60866 if test ! -f "$path" && test ! -d "$path"; then 60867 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60868 fi 60869 60870 if test -d "$path"; then 60871 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60872 else 60873 dir="`$DIRNAME "$path"`" 60874 base="`$BASENAME "$path"`" 60875 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60876 fi 60877 fi 60878 fi 60879 60880 60881 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60883 $as_echo_n "checking for freetype includes... " >&6; } 60884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60885 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60886 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60888 $as_echo_n "checking for freetype libraries... " >&6; } 60889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60890 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60891 fi 60892 60893 else 60894 60895 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60896 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 60897 METHOD="well-known location" 60898 60899 # Let's start with an optimistic view of the world :-) 60900 FOUND_FREETYPE=yes 60901 60902 # First look for the canonical freetype main include file ft2build.h. 60903 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60904 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60905 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60906 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60907 # Fail. 60908 FOUND_FREETYPE=no 60909 fi 60910 fi 60911 60912 if test "x$FOUND_FREETYPE" = xyes; then 60913 # Include file found, let's continue the sanity check. 60914 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60915 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60916 60917 # Reset to default value 60918 FREETYPE_BASE_NAME=freetype 60919 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60920 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60921 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60922 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60923 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60924 # for the .6 version explicitly. 60925 FREETYPE_BASE_NAME=freetype.6 60926 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60927 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60928 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60929 else 60930 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60931 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60932 FOUND_FREETYPE=no 60933 fi 60934 else 60935 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60936 # On Windows, we will need both .lib and .dll file. 60937 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60938 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60939 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60940 FOUND_FREETYPE=no 60941 fi 60942 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60943 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60944 # Found lib in isa dir, use that instead. 60945 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60946 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60947 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60948 fi 60949 fi 60950 fi 60951 60952 if test "x$FOUND_FREETYPE" = xyes; then 60953 60954 # Only process if variable expands to non-empty 60955 60956 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60957 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60958 60959 # Input might be given as Windows format, start by converting to 60960 # unix format. 60961 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60962 new_path=`$CYGPATH -u "$path"` 60963 60964 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60965 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60966 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60967 # "foo.exe" is OK but "foo" is an error. 60968 # 60969 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60970 # It is also a way to make sure we got the proper file name for the real test later on. 60971 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60972 if test "x$test_shortpath" = x; then 60973 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60974 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60975 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60976 fi 60977 60978 # Call helper function which possibly converts this using DOS-style short mode. 60979 # If so, the updated path is stored in $new_path. 60980 60981 input_path="$new_path" 60982 # Check if we need to convert this using DOS-style short mode. If the path 60983 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60984 # take no chances and rewrite it. 60985 # Note: m4 eats our [], so we need to use [ and ] instead. 60986 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60987 if test "x$has_forbidden_chars" != x; then 60988 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60989 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60990 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60991 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60992 # Going to short mode and back again did indeed matter. Since short mode is 60993 # case insensitive, let's make it lowercase to improve readability. 60994 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60995 # Now convert it back to Unix-style (cygpath) 60996 input_path=`$CYGPATH -u "$shortmode_path"` 60997 new_path="$input_path" 60998 fi 60999 fi 61000 61001 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61002 if test "x$test_cygdrive_prefix" = x; then 61003 # As a simple fix, exclude /usr/bin since it's not a real path. 61004 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61005 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61006 # a path prefixed by /cygdrive for fixpath to work. 61007 new_path="$CYGWIN_ROOT_PATH$input_path" 61008 fi 61009 fi 61010 61011 61012 if test "x$path" != "x$new_path"; then 61013 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61014 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61015 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61016 fi 61017 61018 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61019 61020 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61021 has_colon=`$ECHO $path | $GREP ^.:` 61022 new_path="$path" 61023 if test "x$has_colon" = x; then 61024 # Not in mixed or Windows style, start by that. 61025 new_path=`cmd //c echo $path` 61026 fi 61027 61028 61029 input_path="$new_path" 61030 # Check if we need to convert this using DOS-style short mode. If the path 61031 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61032 # take no chances and rewrite it. 61033 # Note: m4 eats our [], so we need to use [ and ] instead. 61034 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61035 if test "x$has_forbidden_chars" != x; then 61036 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61037 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61038 fi 61039 61040 61041 windows_path="$new_path" 61042 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61043 unix_path=`$CYGPATH -u "$windows_path"` 61044 new_path="$unix_path" 61045 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61046 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61047 new_path="$unix_path" 61048 fi 61049 61050 if test "x$path" != "x$new_path"; then 61051 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61052 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61053 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61054 fi 61055 61056 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61057 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61058 61059 else 61060 # We're on a unix platform. Hooray! :) 61061 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61062 has_space=`$ECHO "$path" | $GREP " "` 61063 if test "x$has_space" != x; then 61064 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61065 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61066 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61067 fi 61068 61069 # Use eval to expand a potential ~ 61070 eval path="$path" 61071 if test ! -f "$path" && test ! -d "$path"; then 61072 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61073 fi 61074 61075 if test -d "$path"; then 61076 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61077 else 61078 dir="`$DIRNAME "$path"`" 61079 base="`$BASENAME "$path"`" 61080 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61081 fi 61082 fi 61083 fi 61084 61085 61086 # Only process if variable expands to non-empty 61087 61088 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61089 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61090 61091 # Input might be given as Windows format, start by converting to 61092 # unix format. 61093 path="$POTENTIAL_FREETYPE_LIB_PATH" 61094 new_path=`$CYGPATH -u "$path"` 61095 61096 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61097 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61098 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61099 # "foo.exe" is OK but "foo" is an error. 61100 # 61101 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61102 # It is also a way to make sure we got the proper file name for the real test later on. 61103 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61104 if test "x$test_shortpath" = x; then 61105 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61106 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61107 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61108 fi 61109 61110 # Call helper function which possibly converts this using DOS-style short mode. 61111 # If so, the updated path is stored in $new_path. 61112 61113 input_path="$new_path" 61114 # Check if we need to convert this using DOS-style short mode. If the path 61115 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61116 # take no chances and rewrite it. 61117 # Note: m4 eats our [], so we need to use [ and ] instead. 61118 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61119 if test "x$has_forbidden_chars" != x; then 61120 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61121 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61122 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61123 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61124 # Going to short mode and back again did indeed matter. Since short mode is 61125 # case insensitive, let's make it lowercase to improve readability. 61126 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61127 # Now convert it back to Unix-style (cygpath) 61128 input_path=`$CYGPATH -u "$shortmode_path"` 61129 new_path="$input_path" 61130 fi 61131 fi 61132 61133 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61134 if test "x$test_cygdrive_prefix" = x; then 61135 # As a simple fix, exclude /usr/bin since it's not a real path. 61136 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61137 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61138 # a path prefixed by /cygdrive for fixpath to work. 61139 new_path="$CYGWIN_ROOT_PATH$input_path" 61140 fi 61141 fi 61142 61143 61144 if test "x$path" != "x$new_path"; then 61145 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61146 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61147 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61148 fi 61149 61150 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61151 61152 path="$POTENTIAL_FREETYPE_LIB_PATH" 61153 has_colon=`$ECHO $path | $GREP ^.:` 61154 new_path="$path" 61155 if test "x$has_colon" = x; then 61156 # Not in mixed or Windows style, start by that. 61157 new_path=`cmd //c echo $path` 61158 fi 61159 61160 61161 input_path="$new_path" 61162 # Check if we need to convert this using DOS-style short mode. If the path 61163 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61164 # take no chances and rewrite it. 61165 # Note: m4 eats our [], so we need to use [ and ] instead. 61166 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61167 if test "x$has_forbidden_chars" != x; then 61168 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61169 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61170 fi 61171 61172 61173 windows_path="$new_path" 61174 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61175 unix_path=`$CYGPATH -u "$windows_path"` 61176 new_path="$unix_path" 61177 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61178 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61179 new_path="$unix_path" 61180 fi 61181 61182 if test "x$path" != "x$new_path"; then 61183 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61184 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61185 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61186 fi 61187 61188 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61189 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61190 61191 else 61192 # We're on a unix platform. Hooray! :) 61193 path="$POTENTIAL_FREETYPE_LIB_PATH" 61194 has_space=`$ECHO "$path" | $GREP " "` 61195 if test "x$has_space" != x; then 61196 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61197 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61198 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61199 fi 61200 61201 # Use eval to expand a potential ~ 61202 eval path="$path" 61203 if test ! -f "$path" && test ! -d "$path"; then 61204 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61205 fi 61206 61207 if test -d "$path"; then 61208 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61209 else 61210 dir="`$DIRNAME "$path"`" 61211 base="`$BASENAME "$path"`" 61212 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61213 fi 61214 fi 61215 fi 61216 61217 61218 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61220 $as_echo_n "checking for freetype includes... " >&6; } 61221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61222 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61223 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61225 $as_echo_n "checking for freetype libraries... " >&6; } 61226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61227 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61228 fi 61229 61230 fi 61231 fi 61232 fi 61233 else 61234 FREETYPE_BASE_DIR="$SYSROOT/usr" 61235 61236 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61237 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61238 METHOD="well-known location" 61239 61240 # Let's start with an optimistic view of the world :-) 61241 FOUND_FREETYPE=yes 61242 61243 # First look for the canonical freetype main include file ft2build.h. 61244 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61245 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61246 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61247 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61248 # Fail. 61249 FOUND_FREETYPE=no 61250 fi 61251 fi 61252 61253 if test "x$FOUND_FREETYPE" = xyes; then 61254 # Include file found, let's continue the sanity check. 61255 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61256 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61257 61258 # Reset to default value 61259 FREETYPE_BASE_NAME=freetype 61260 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61261 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61262 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61263 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61264 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61265 # for the .6 version explicitly. 61266 FREETYPE_BASE_NAME=freetype.6 61267 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61268 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61269 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61270 else 61271 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61272 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61273 FOUND_FREETYPE=no 61274 fi 61275 else 61276 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61277 # On Windows, we will need both .lib and .dll file. 61278 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61279 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61280 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61281 FOUND_FREETYPE=no 61282 fi 61283 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61284 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61285 # Found lib in isa dir, use that instead. 61286 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61287 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61288 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61289 fi 61290 fi 61291 fi 61292 61293 if test "x$FOUND_FREETYPE" = xyes; then 61294 61295 # Only process if variable expands to non-empty 61296 61297 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61298 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61299 61300 # Input might be given as Windows format, start by converting to 61301 # unix format. 61302 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61303 new_path=`$CYGPATH -u "$path"` 61304 61305 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61306 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61307 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61308 # "foo.exe" is OK but "foo" is an error. 61309 # 61310 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61311 # It is also a way to make sure we got the proper file name for the real test later on. 61312 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61313 if test "x$test_shortpath" = x; then 61314 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61315 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61316 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61317 fi 61318 61319 # Call helper function which possibly converts this using DOS-style short mode. 61320 # If so, the updated path is stored in $new_path. 61321 61322 input_path="$new_path" 61323 # Check if we need to convert this using DOS-style short mode. If the path 61324 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61325 # take no chances and rewrite it. 61326 # Note: m4 eats our [], so we need to use [ and ] instead. 61327 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61328 if test "x$has_forbidden_chars" != x; then 61329 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61330 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61331 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61332 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61333 # Going to short mode and back again did indeed matter. Since short mode is 61334 # case insensitive, let's make it lowercase to improve readability. 61335 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61336 # Now convert it back to Unix-style (cygpath) 61337 input_path=`$CYGPATH -u "$shortmode_path"` 61338 new_path="$input_path" 61339 fi 61340 fi 61341 61342 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61343 if test "x$test_cygdrive_prefix" = x; then 61344 # As a simple fix, exclude /usr/bin since it's not a real path. 61345 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61346 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61347 # a path prefixed by /cygdrive for fixpath to work. 61348 new_path="$CYGWIN_ROOT_PATH$input_path" 61349 fi 61350 fi 61351 61352 61353 if test "x$path" != "x$new_path"; then 61354 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61355 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61356 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61357 fi 61358 61359 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61360 61361 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61362 has_colon=`$ECHO $path | $GREP ^.:` 61363 new_path="$path" 61364 if test "x$has_colon" = x; then 61365 # Not in mixed or Windows style, start by that. 61366 new_path=`cmd //c echo $path` 61367 fi 61368 61369 61370 input_path="$new_path" 61371 # Check if we need to convert this using DOS-style short mode. If the path 61372 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61373 # take no chances and rewrite it. 61374 # Note: m4 eats our [], so we need to use [ and ] instead. 61375 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61376 if test "x$has_forbidden_chars" != x; then 61377 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61378 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61379 fi 61380 61381 61382 windows_path="$new_path" 61383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61384 unix_path=`$CYGPATH -u "$windows_path"` 61385 new_path="$unix_path" 61386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61387 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61388 new_path="$unix_path" 61389 fi 61390 61391 if test "x$path" != "x$new_path"; then 61392 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61393 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61394 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61395 fi 61396 61397 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61398 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61399 61400 else 61401 # We're on a unix platform. Hooray! :) 61402 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61403 has_space=`$ECHO "$path" | $GREP " "` 61404 if test "x$has_space" != x; then 61405 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61406 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61407 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61408 fi 61409 61410 # Use eval to expand a potential ~ 61411 eval path="$path" 61412 if test ! -f "$path" && test ! -d "$path"; then 61413 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61414 fi 61415 61416 if test -d "$path"; then 61417 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61418 else 61419 dir="`$DIRNAME "$path"`" 61420 base="`$BASENAME "$path"`" 61421 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61422 fi 61423 fi 61424 fi 61425 61426 61427 # Only process if variable expands to non-empty 61428 61429 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61430 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61431 61432 # Input might be given as Windows format, start by converting to 61433 # unix format. 61434 path="$POTENTIAL_FREETYPE_LIB_PATH" 61435 new_path=`$CYGPATH -u "$path"` 61436 61437 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61438 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61439 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61440 # "foo.exe" is OK but "foo" is an error. 61441 # 61442 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61443 # It is also a way to make sure we got the proper file name for the real test later on. 61444 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61445 if test "x$test_shortpath" = x; then 61446 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61447 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61448 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61449 fi 61450 61451 # Call helper function which possibly converts this using DOS-style short mode. 61452 # If so, the updated path is stored in $new_path. 61453 61454 input_path="$new_path" 61455 # Check if we need to convert this using DOS-style short mode. If the path 61456 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61457 # take no chances and rewrite it. 61458 # Note: m4 eats our [], so we need to use [ and ] instead. 61459 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61460 if test "x$has_forbidden_chars" != x; then 61461 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61462 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61463 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61464 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61465 # Going to short mode and back again did indeed matter. Since short mode is 61466 # case insensitive, let's make it lowercase to improve readability. 61467 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61468 # Now convert it back to Unix-style (cygpath) 61469 input_path=`$CYGPATH -u "$shortmode_path"` 61470 new_path="$input_path" 61471 fi 61472 fi 61473 61474 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61475 if test "x$test_cygdrive_prefix" = x; then 61476 # As a simple fix, exclude /usr/bin since it's not a real path. 61477 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61478 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61479 # a path prefixed by /cygdrive for fixpath to work. 61480 new_path="$CYGWIN_ROOT_PATH$input_path" 61481 fi 61482 fi 61483 61484 61485 if test "x$path" != "x$new_path"; then 61486 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61487 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61488 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61489 fi 61490 61491 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61492 61493 path="$POTENTIAL_FREETYPE_LIB_PATH" 61494 has_colon=`$ECHO $path | $GREP ^.:` 61495 new_path="$path" 61496 if test "x$has_colon" = x; then 61497 # Not in mixed or Windows style, start by that. 61498 new_path=`cmd //c echo $path` 61499 fi 61500 61501 61502 input_path="$new_path" 61503 # Check if we need to convert this using DOS-style short mode. If the path 61504 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61505 # take no chances and rewrite it. 61506 # Note: m4 eats our [], so we need to use [ and ] instead. 61507 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61508 if test "x$has_forbidden_chars" != x; then 61509 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61510 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61511 fi 61512 61513 61514 windows_path="$new_path" 61515 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61516 unix_path=`$CYGPATH -u "$windows_path"` 61517 new_path="$unix_path" 61518 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61519 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61520 new_path="$unix_path" 61521 fi 61522 61523 if test "x$path" != "x$new_path"; then 61524 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61525 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61526 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61527 fi 61528 61529 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61530 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61531 61532 else 61533 # We're on a unix platform. Hooray! :) 61534 path="$POTENTIAL_FREETYPE_LIB_PATH" 61535 has_space=`$ECHO "$path" | $GREP " "` 61536 if test "x$has_space" != x; then 61537 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61538 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61539 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61540 fi 61541 61542 # Use eval to expand a potential ~ 61543 eval path="$path" 61544 if test ! -f "$path" && test ! -d "$path"; then 61545 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61546 fi 61547 61548 if test -d "$path"; then 61549 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61550 else 61551 dir="`$DIRNAME "$path"`" 61552 base="`$BASENAME "$path"`" 61553 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61554 fi 61555 fi 61556 fi 61557 61558 61559 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61561 $as_echo_n "checking for freetype includes... " >&6; } 61562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61563 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61564 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61566 $as_echo_n "checking for freetype libraries... " >&6; } 61567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61568 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61569 fi 61570 61571 61572 if test "x$FOUND_FREETYPE" != xyes; then 61573 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 61574 61575 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61576 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61577 METHOD="well-known location" 61578 61579 # Let's start with an optimistic view of the world :-) 61580 FOUND_FREETYPE=yes 61581 61582 # First look for the canonical freetype main include file ft2build.h. 61583 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61584 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61585 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61586 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61587 # Fail. 61588 FOUND_FREETYPE=no 61589 fi 61590 fi 61591 61592 if test "x$FOUND_FREETYPE" = xyes; then 61593 # Include file found, let's continue the sanity check. 61594 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61595 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61596 61597 # Reset to default value 61598 FREETYPE_BASE_NAME=freetype 61599 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61600 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61601 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61602 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61603 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61604 # for the .6 version explicitly. 61605 FREETYPE_BASE_NAME=freetype.6 61606 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61607 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61608 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61609 else 61610 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61611 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61612 FOUND_FREETYPE=no 61613 fi 61614 else 61615 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61616 # On Windows, we will need both .lib and .dll file. 61617 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61618 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61619 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61620 FOUND_FREETYPE=no 61621 fi 61622 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61623 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61624 # Found lib in isa dir, use that instead. 61625 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61626 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61627 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61628 fi 61629 fi 61630 fi 61631 61632 if test "x$FOUND_FREETYPE" = xyes; then 61633 61634 # Only process if variable expands to non-empty 61635 61636 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61637 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61638 61639 # Input might be given as Windows format, start by converting to 61640 # unix format. 61641 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61642 new_path=`$CYGPATH -u "$path"` 61643 61644 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61645 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61646 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61647 # "foo.exe" is OK but "foo" is an error. 61648 # 61649 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61650 # It is also a way to make sure we got the proper file name for the real test later on. 61651 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61652 if test "x$test_shortpath" = x; then 61653 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61654 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61655 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61656 fi 61657 61658 # Call helper function which possibly converts this using DOS-style short mode. 61659 # If so, the updated path is stored in $new_path. 61660 61661 input_path="$new_path" 61662 # Check if we need to convert this using DOS-style short mode. If the path 61663 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61664 # take no chances and rewrite it. 61665 # Note: m4 eats our [], so we need to use [ and ] instead. 61666 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61667 if test "x$has_forbidden_chars" != x; then 61668 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61669 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61670 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61671 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61672 # Going to short mode and back again did indeed matter. Since short mode is 61673 # case insensitive, let's make it lowercase to improve readability. 61674 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61675 # Now convert it back to Unix-style (cygpath) 61676 input_path=`$CYGPATH -u "$shortmode_path"` 61677 new_path="$input_path" 61678 fi 61679 fi 61680 61681 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61682 if test "x$test_cygdrive_prefix" = x; then 61683 # As a simple fix, exclude /usr/bin since it's not a real path. 61684 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61685 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61686 # a path prefixed by /cygdrive for fixpath to work. 61687 new_path="$CYGWIN_ROOT_PATH$input_path" 61688 fi 61689 fi 61690 61691 61692 if test "x$path" != "x$new_path"; then 61693 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61694 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61695 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61696 fi 61697 61698 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61699 61700 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61701 has_colon=`$ECHO $path | $GREP ^.:` 61702 new_path="$path" 61703 if test "x$has_colon" = x; then 61704 # Not in mixed or Windows style, start by that. 61705 new_path=`cmd //c echo $path` 61706 fi 61707 61708 61709 input_path="$new_path" 61710 # Check if we need to convert this using DOS-style short mode. If the path 61711 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61712 # take no chances and rewrite it. 61713 # Note: m4 eats our [], so we need to use [ and ] instead. 61714 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61715 if test "x$has_forbidden_chars" != x; then 61716 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61717 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61718 fi 61719 61720 61721 windows_path="$new_path" 61722 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61723 unix_path=`$CYGPATH -u "$windows_path"` 61724 new_path="$unix_path" 61725 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61726 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61727 new_path="$unix_path" 61728 fi 61729 61730 if test "x$path" != "x$new_path"; then 61731 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61732 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61733 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61734 fi 61735 61736 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61737 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61738 61739 else 61740 # We're on a unix platform. Hooray! :) 61741 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61742 has_space=`$ECHO "$path" | $GREP " "` 61743 if test "x$has_space" != x; then 61744 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61745 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61746 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61747 fi 61748 61749 # Use eval to expand a potential ~ 61750 eval path="$path" 61751 if test ! -f "$path" && test ! -d "$path"; then 61752 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61753 fi 61754 61755 if test -d "$path"; then 61756 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61757 else 61758 dir="`$DIRNAME "$path"`" 61759 base="`$BASENAME "$path"`" 61760 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61761 fi 61762 fi 61763 fi 61764 61765 61766 # Only process if variable expands to non-empty 61767 61768 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61769 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61770 61771 # Input might be given as Windows format, start by converting to 61772 # unix format. 61773 path="$POTENTIAL_FREETYPE_LIB_PATH" 61774 new_path=`$CYGPATH -u "$path"` 61775 61776 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61777 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61778 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61779 # "foo.exe" is OK but "foo" is an error. 61780 # 61781 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61782 # It is also a way to make sure we got the proper file name for the real test later on. 61783 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61784 if test "x$test_shortpath" = x; then 61785 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61786 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61787 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61788 fi 61789 61790 # Call helper function which possibly converts this using DOS-style short mode. 61791 # If so, the updated path is stored in $new_path. 61792 61793 input_path="$new_path" 61794 # Check if we need to convert this using DOS-style short mode. If the path 61795 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61796 # take no chances and rewrite it. 61797 # Note: m4 eats our [], so we need to use [ and ] instead. 61798 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61799 if test "x$has_forbidden_chars" != x; then 61800 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61801 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61802 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61803 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61804 # Going to short mode and back again did indeed matter. Since short mode is 61805 # case insensitive, let's make it lowercase to improve readability. 61806 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61807 # Now convert it back to Unix-style (cygpath) 61808 input_path=`$CYGPATH -u "$shortmode_path"` 61809 new_path="$input_path" 61810 fi 61811 fi 61812 61813 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61814 if test "x$test_cygdrive_prefix" = x; then 61815 # As a simple fix, exclude /usr/bin since it's not a real path. 61816 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61817 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61818 # a path prefixed by /cygdrive for fixpath to work. 61819 new_path="$CYGWIN_ROOT_PATH$input_path" 61820 fi 61821 fi 61822 61823 61824 if test "x$path" != "x$new_path"; then 61825 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61826 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61827 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61828 fi 61829 61830 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61831 61832 path="$POTENTIAL_FREETYPE_LIB_PATH" 61833 has_colon=`$ECHO $path | $GREP ^.:` 61834 new_path="$path" 61835 if test "x$has_colon" = x; then 61836 # Not in mixed or Windows style, start by that. 61837 new_path=`cmd //c echo $path` 61838 fi 61839 61840 61841 input_path="$new_path" 61842 # Check if we need to convert this using DOS-style short mode. If the path 61843 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61844 # take no chances and rewrite it. 61845 # Note: m4 eats our [], so we need to use [ and ] instead. 61846 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61847 if test "x$has_forbidden_chars" != x; then 61848 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61849 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61850 fi 61851 61852 61853 windows_path="$new_path" 61854 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61855 unix_path=`$CYGPATH -u "$windows_path"` 61856 new_path="$unix_path" 61857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61858 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61859 new_path="$unix_path" 61860 fi 61861 61862 if test "x$path" != "x$new_path"; then 61863 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61864 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61865 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61866 fi 61867 61868 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61869 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61870 61871 else 61872 # We're on a unix platform. Hooray! :) 61873 path="$POTENTIAL_FREETYPE_LIB_PATH" 61874 has_space=`$ECHO "$path" | $GREP " "` 61875 if test "x$has_space" != x; then 61876 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61877 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61878 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61879 fi 61880 61881 # Use eval to expand a potential ~ 61882 eval path="$path" 61883 if test ! -f "$path" && test ! -d "$path"; then 61884 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61885 fi 61886 61887 if test -d "$path"; then 61888 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61889 else 61890 dir="`$DIRNAME "$path"`" 61891 base="`$BASENAME "$path"`" 61892 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61893 fi 61894 fi 61895 fi 61896 61897 61898 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61900 $as_echo_n "checking for freetype includes... " >&6; } 61901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61902 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61903 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61905 $as_echo_n "checking for freetype libraries... " >&6; } 61906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61907 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61908 fi 61909 61910 fi 61911 if test "x$FOUND_FREETYPE" != xyes; then 61912 FREETYPE_BASE_DIR="$SYSROOT/usr/local" 61913 61914 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61915 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61916 METHOD="well-known location" 61917 61918 # Let's start with an optimistic view of the world :-) 61919 FOUND_FREETYPE=yes 61920 61921 # First look for the canonical freetype main include file ft2build.h. 61922 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61923 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61924 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61925 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61926 # Fail. 61927 FOUND_FREETYPE=no 61928 fi 61929 fi 61930 61931 if test "x$FOUND_FREETYPE" = xyes; then 61932 # Include file found, let's continue the sanity check. 61933 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61934 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61935 61936 # Reset to default value 61937 FREETYPE_BASE_NAME=freetype 61938 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61939 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61940 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61941 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61942 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61943 # for the .6 version explicitly. 61944 FREETYPE_BASE_NAME=freetype.6 61945 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61946 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61947 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61948 else 61949 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61950 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61951 FOUND_FREETYPE=no 61952 fi 61953 else 61954 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61955 # On Windows, we will need both .lib and .dll file. 61956 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61957 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61958 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61959 FOUND_FREETYPE=no 61960 fi 61961 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61962 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61963 # Found lib in isa dir, use that instead. 61964 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61965 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61966 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61967 fi 61968 fi 61969 fi 61970 61971 if test "x$FOUND_FREETYPE" = xyes; then 61972 61973 # Only process if variable expands to non-empty 61974 61975 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61976 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61977 61978 # Input might be given as Windows format, start by converting to 61979 # unix format. 61980 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61981 new_path=`$CYGPATH -u "$path"` 61982 61983 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61984 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61985 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61986 # "foo.exe" is OK but "foo" is an error. 61987 # 61988 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61989 # It is also a way to make sure we got the proper file name for the real test later on. 61990 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61991 if test "x$test_shortpath" = x; then 61992 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61993 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61994 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61995 fi 61996 61997 # Call helper function which possibly converts this using DOS-style short mode. 61998 # If so, the updated path is stored in $new_path. 61999 62000 input_path="$new_path" 62001 # Check if we need to convert this using DOS-style short mode. If the path 62002 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62003 # take no chances and rewrite it. 62004 # Note: m4 eats our [], so we need to use [ and ] instead. 62005 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62006 if test "x$has_forbidden_chars" != x; then 62007 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62008 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62009 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62010 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62011 # Going to short mode and back again did indeed matter. Since short mode is 62012 # case insensitive, let's make it lowercase to improve readability. 62013 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62014 # Now convert it back to Unix-style (cygpath) 62015 input_path=`$CYGPATH -u "$shortmode_path"` 62016 new_path="$input_path" 62017 fi 62018 fi 62019 62020 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62021 if test "x$test_cygdrive_prefix" = x; then 62022 # As a simple fix, exclude /usr/bin since it's not a real path. 62023 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62024 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62025 # a path prefixed by /cygdrive for fixpath to work. 62026 new_path="$CYGWIN_ROOT_PATH$input_path" 62027 fi 62028 fi 62029 62030 62031 if test "x$path" != "x$new_path"; then 62032 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62033 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62034 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62035 fi 62036 62037 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62038 62039 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62040 has_colon=`$ECHO $path | $GREP ^.:` 62041 new_path="$path" 62042 if test "x$has_colon" = x; then 62043 # Not in mixed or Windows style, start by that. 62044 new_path=`cmd //c echo $path` 62045 fi 62046 62047 62048 input_path="$new_path" 62049 # Check if we need to convert this using DOS-style short mode. If the path 62050 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62051 # take no chances and rewrite it. 62052 # Note: m4 eats our [], so we need to use [ and ] instead. 62053 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62054 if test "x$has_forbidden_chars" != x; then 62055 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62056 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62057 fi 62058 62059 62060 windows_path="$new_path" 62061 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62062 unix_path=`$CYGPATH -u "$windows_path"` 62063 new_path="$unix_path" 62064 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62065 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62066 new_path="$unix_path" 62067 fi 62068 62069 if test "x$path" != "x$new_path"; then 62070 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62071 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62072 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62073 fi 62074 62075 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62076 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62077 62078 else 62079 # We're on a unix platform. Hooray! :) 62080 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62081 has_space=`$ECHO "$path" | $GREP " "` 62082 if test "x$has_space" != x; then 62083 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62084 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62085 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62086 fi 62087 62088 # Use eval to expand a potential ~ 62089 eval path="$path" 62090 if test ! -f "$path" && test ! -d "$path"; then 62091 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62092 fi 62093 62094 if test -d "$path"; then 62095 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62096 else 62097 dir="`$DIRNAME "$path"`" 62098 base="`$BASENAME "$path"`" 62099 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62100 fi 62101 fi 62102 fi 62103 62104 62105 # Only process if variable expands to non-empty 62106 62107 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62109 62110 # Input might be given as Windows format, start by converting to 62111 # unix format. 62112 path="$POTENTIAL_FREETYPE_LIB_PATH" 62113 new_path=`$CYGPATH -u "$path"` 62114 62115 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62116 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62117 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62118 # "foo.exe" is OK but "foo" is an error. 62119 # 62120 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62121 # It is also a way to make sure we got the proper file name for the real test later on. 62122 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62123 if test "x$test_shortpath" = x; then 62124 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62125 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62126 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62127 fi 62128 62129 # Call helper function which possibly converts this using DOS-style short mode. 62130 # If so, the updated path is stored in $new_path. 62131 62132 input_path="$new_path" 62133 # Check if we need to convert this using DOS-style short mode. If the path 62134 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62135 # take no chances and rewrite it. 62136 # Note: m4 eats our [], so we need to use [ and ] instead. 62137 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62138 if test "x$has_forbidden_chars" != x; then 62139 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62140 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62141 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62142 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62143 # Going to short mode and back again did indeed matter. Since short mode is 62144 # case insensitive, let's make it lowercase to improve readability. 62145 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62146 # Now convert it back to Unix-style (cygpath) 62147 input_path=`$CYGPATH -u "$shortmode_path"` 62148 new_path="$input_path" 62149 fi 62150 fi 62151 62152 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62153 if test "x$test_cygdrive_prefix" = x; then 62154 # As a simple fix, exclude /usr/bin since it's not a real path. 62155 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62156 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62157 # a path prefixed by /cygdrive for fixpath to work. 62158 new_path="$CYGWIN_ROOT_PATH$input_path" 62159 fi 62160 fi 62161 62162 62163 if test "x$path" != "x$new_path"; then 62164 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62165 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62166 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62167 fi 62168 62169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62170 62171 path="$POTENTIAL_FREETYPE_LIB_PATH" 62172 has_colon=`$ECHO $path | $GREP ^.:` 62173 new_path="$path" 62174 if test "x$has_colon" = x; then 62175 # Not in mixed or Windows style, start by that. 62176 new_path=`cmd //c echo $path` 62177 fi 62178 62179 62180 input_path="$new_path" 62181 # Check if we need to convert this using DOS-style short mode. If the path 62182 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62183 # take no chances and rewrite it. 62184 # Note: m4 eats our [], so we need to use [ and ] instead. 62185 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62186 if test "x$has_forbidden_chars" != x; then 62187 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62188 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62189 fi 62190 62191 62192 windows_path="$new_path" 62193 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62194 unix_path=`$CYGPATH -u "$windows_path"` 62195 new_path="$unix_path" 62196 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62197 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62198 new_path="$unix_path" 62199 fi 62200 62201 if test "x$path" != "x$new_path"; then 62202 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62203 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62204 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62205 fi 62206 62207 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62208 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62209 62210 else 62211 # We're on a unix platform. Hooray! :) 62212 path="$POTENTIAL_FREETYPE_LIB_PATH" 62213 has_space=`$ECHO "$path" | $GREP " "` 62214 if test "x$has_space" != x; then 62215 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62216 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62217 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62218 fi 62219 62220 # Use eval to expand a potential ~ 62221 eval path="$path" 62222 if test ! -f "$path" && test ! -d "$path"; then 62223 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62224 fi 62225 62226 if test -d "$path"; then 62227 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62228 else 62229 dir="`$DIRNAME "$path"`" 62230 base="`$BASENAME "$path"`" 62231 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62232 fi 62233 fi 62234 fi 62235 62236 62237 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62239 $as_echo_n "checking for freetype includes... " >&6; } 62240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62241 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62242 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62244 $as_echo_n "checking for freetype libraries... " >&6; } 62245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62246 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62247 fi 62248 62249 fi 62250 62251 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 62252 if test "x$FOUND_FREETYPE" != xyes; then 62253 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 62254 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 62255 62256 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62257 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 62258 METHOD="well-known location" 62259 62260 # Let's start with an optimistic view of the world :-) 62261 FOUND_FREETYPE=yes 62262 62263 # First look for the canonical freetype main include file ft2build.h. 62264 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62265 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62266 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62267 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62268 # Fail. 62269 FOUND_FREETYPE=no 62270 fi 62271 fi 62272 62273 if test "x$FOUND_FREETYPE" = xyes; then 62274 # Include file found, let's continue the sanity check. 62275 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62276 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62277 62278 # Reset to default value 62279 FREETYPE_BASE_NAME=freetype 62280 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62281 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62282 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62283 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62284 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62285 # for the .6 version explicitly. 62286 FREETYPE_BASE_NAME=freetype.6 62287 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62288 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62289 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62290 else 62291 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62292 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62293 FOUND_FREETYPE=no 62294 fi 62295 else 62296 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62297 # On Windows, we will need both .lib and .dll file. 62298 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62299 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62300 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62301 FOUND_FREETYPE=no 62302 fi 62303 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62304 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62305 # Found lib in isa dir, use that instead. 62306 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62307 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62308 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62309 fi 62310 fi 62311 fi 62312 62313 if test "x$FOUND_FREETYPE" = xyes; then 62314 62315 # Only process if variable expands to non-empty 62316 62317 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62319 62320 # Input might be given as Windows format, start by converting to 62321 # unix format. 62322 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62323 new_path=`$CYGPATH -u "$path"` 62324 62325 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62326 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62327 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62328 # "foo.exe" is OK but "foo" is an error. 62329 # 62330 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62331 # It is also a way to make sure we got the proper file name for the real test later on. 62332 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62333 if test "x$test_shortpath" = x; then 62334 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62335 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62336 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62337 fi 62338 62339 # Call helper function which possibly converts this using DOS-style short mode. 62340 # If so, the updated path is stored in $new_path. 62341 62342 input_path="$new_path" 62343 # Check if we need to convert this using DOS-style short mode. If the path 62344 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62345 # take no chances and rewrite it. 62346 # Note: m4 eats our [], so we need to use [ and ] instead. 62347 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62348 if test "x$has_forbidden_chars" != x; then 62349 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62350 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62351 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62352 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62353 # Going to short mode and back again did indeed matter. Since short mode is 62354 # case insensitive, let's make it lowercase to improve readability. 62355 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62356 # Now convert it back to Unix-style (cygpath) 62357 input_path=`$CYGPATH -u "$shortmode_path"` 62358 new_path="$input_path" 62359 fi 62360 fi 62361 62362 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62363 if test "x$test_cygdrive_prefix" = x; then 62364 # As a simple fix, exclude /usr/bin since it's not a real path. 62365 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62366 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62367 # a path prefixed by /cygdrive for fixpath to work. 62368 new_path="$CYGWIN_ROOT_PATH$input_path" 62369 fi 62370 fi 62371 62372 62373 if test "x$path" != "x$new_path"; then 62374 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62375 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62376 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62377 fi 62378 62379 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62380 62381 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62382 has_colon=`$ECHO $path | $GREP ^.:` 62383 new_path="$path" 62384 if test "x$has_colon" = x; then 62385 # Not in mixed or Windows style, start by that. 62386 new_path=`cmd //c echo $path` 62387 fi 62388 62389 62390 input_path="$new_path" 62391 # Check if we need to convert this using DOS-style short mode. If the path 62392 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62393 # take no chances and rewrite it. 62394 # Note: m4 eats our [], so we need to use [ and ] instead. 62395 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62396 if test "x$has_forbidden_chars" != x; then 62397 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62398 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62399 fi 62400 62401 62402 windows_path="$new_path" 62403 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62404 unix_path=`$CYGPATH -u "$windows_path"` 62405 new_path="$unix_path" 62406 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62407 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62408 new_path="$unix_path" 62409 fi 62410 62411 if test "x$path" != "x$new_path"; then 62412 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62413 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62414 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62415 fi 62416 62417 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62418 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62419 62420 else 62421 # We're on a unix platform. Hooray! :) 62422 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62423 has_space=`$ECHO "$path" | $GREP " "` 62424 if test "x$has_space" != x; then 62425 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62426 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62427 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62428 fi 62429 62430 # Use eval to expand a potential ~ 62431 eval path="$path" 62432 if test ! -f "$path" && test ! -d "$path"; then 62433 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62434 fi 62435 62436 if test -d "$path"; then 62437 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62438 else 62439 dir="`$DIRNAME "$path"`" 62440 base="`$BASENAME "$path"`" 62441 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62442 fi 62443 fi 62444 fi 62445 62446 62447 # Only process if variable expands to non-empty 62448 62449 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62450 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62451 62452 # Input might be given as Windows format, start by converting to 62453 # unix format. 62454 path="$POTENTIAL_FREETYPE_LIB_PATH" 62455 new_path=`$CYGPATH -u "$path"` 62456 62457 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62458 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62459 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62460 # "foo.exe" is OK but "foo" is an error. 62461 # 62462 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62463 # It is also a way to make sure we got the proper file name for the real test later on. 62464 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62465 if test "x$test_shortpath" = x; then 62466 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62467 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62468 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62469 fi 62470 62471 # Call helper function which possibly converts this using DOS-style short mode. 62472 # If so, the updated path is stored in $new_path. 62473 62474 input_path="$new_path" 62475 # Check if we need to convert this using DOS-style short mode. If the path 62476 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62477 # take no chances and rewrite it. 62478 # Note: m4 eats our [], so we need to use [ and ] instead. 62479 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62480 if test "x$has_forbidden_chars" != x; then 62481 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62482 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62483 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62484 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62485 # Going to short mode and back again did indeed matter. Since short mode is 62486 # case insensitive, let's make it lowercase to improve readability. 62487 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62488 # Now convert it back to Unix-style (cygpath) 62489 input_path=`$CYGPATH -u "$shortmode_path"` 62490 new_path="$input_path" 62491 fi 62492 fi 62493 62494 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62495 if test "x$test_cygdrive_prefix" = x; then 62496 # As a simple fix, exclude /usr/bin since it's not a real path. 62497 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62498 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62499 # a path prefixed by /cygdrive for fixpath to work. 62500 new_path="$CYGWIN_ROOT_PATH$input_path" 62501 fi 62502 fi 62503 62504 62505 if test "x$path" != "x$new_path"; then 62506 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62507 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62508 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62509 fi 62510 62511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62512 62513 path="$POTENTIAL_FREETYPE_LIB_PATH" 62514 has_colon=`$ECHO $path | $GREP ^.:` 62515 new_path="$path" 62516 if test "x$has_colon" = x; then 62517 # Not in mixed or Windows style, start by that. 62518 new_path=`cmd //c echo $path` 62519 fi 62520 62521 62522 input_path="$new_path" 62523 # Check if we need to convert this using DOS-style short mode. If the path 62524 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62525 # take no chances and rewrite it. 62526 # Note: m4 eats our [], so we need to use [ and ] instead. 62527 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62528 if test "x$has_forbidden_chars" != x; then 62529 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62530 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62531 fi 62532 62533 62534 windows_path="$new_path" 62535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62536 unix_path=`$CYGPATH -u "$windows_path"` 62537 new_path="$unix_path" 62538 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62539 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62540 new_path="$unix_path" 62541 fi 62542 62543 if test "x$path" != "x$new_path"; then 62544 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62545 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62546 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62547 fi 62548 62549 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62550 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62551 62552 else 62553 # We're on a unix platform. Hooray! :) 62554 path="$POTENTIAL_FREETYPE_LIB_PATH" 62555 has_space=`$ECHO "$path" | $GREP " "` 62556 if test "x$has_space" != x; then 62557 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62558 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62559 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62560 fi 62561 62562 # Use eval to expand a potential ~ 62563 eval path="$path" 62564 if test ! -f "$path" && test ! -d "$path"; then 62565 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62566 fi 62567 62568 if test -d "$path"; then 62569 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62570 else 62571 dir="`$DIRNAME "$path"`" 62572 base="`$BASENAME "$path"`" 62573 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62574 fi 62575 fi 62576 fi 62577 62578 62579 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62581 $as_echo_n "checking for freetype includes... " >&6; } 62582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62583 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62584 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62586 $as_echo_n "checking for freetype libraries... " >&6; } 62587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62588 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62589 fi 62590 62591 fi 62592 fi 62593 62594 if test "x$FOUND_FREETYPE" != xyes; then 62595 FREETYPE_BASE_DIR="$SYSROOT/usr" 62596 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 62597 62598 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62599 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/$OPENJDK_TARGET_CPU-linux-gnu" 62600 METHOD="well-known location" 62601 62602 # Let's start with an optimistic view of the world :-) 62603 FOUND_FREETYPE=yes 62604 62605 # First look for the canonical freetype main include file ft2build.h. 62606 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62607 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62608 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62609 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62610 # Fail. 62611 FOUND_FREETYPE=no 62612 fi 62613 fi 62614 62615 if test "x$FOUND_FREETYPE" = xyes; then 62616 # Include file found, let's continue the sanity check. 62617 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62618 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62619 62620 # Reset to default value 62621 FREETYPE_BASE_NAME=freetype 62622 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62623 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62624 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62625 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62626 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62627 # for the .6 version explicitly. 62628 FREETYPE_BASE_NAME=freetype.6 62629 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62630 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62631 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62632 else 62633 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62634 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62635 FOUND_FREETYPE=no 62636 fi 62637 else 62638 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62639 # On Windows, we will need both .lib and .dll file. 62640 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62641 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62642 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62643 FOUND_FREETYPE=no 62644 fi 62645 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62646 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62647 # Found lib in isa dir, use that instead. 62648 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62649 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62650 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62651 fi 62652 fi 62653 fi 62654 62655 if test "x$FOUND_FREETYPE" = xyes; then 62656 62657 # Only process if variable expands to non-empty 62658 62659 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62661 62662 # Input might be given as Windows format, start by converting to 62663 # unix format. 62664 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62665 new_path=`$CYGPATH -u "$path"` 62666 62667 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62668 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62669 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62670 # "foo.exe" is OK but "foo" is an error. 62671 # 62672 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62673 # It is also a way to make sure we got the proper file name for the real test later on. 62674 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62675 if test "x$test_shortpath" = x; then 62676 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62677 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62678 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62679 fi 62680 62681 # Call helper function which possibly converts this using DOS-style short mode. 62682 # If so, the updated path is stored in $new_path. 62683 62684 input_path="$new_path" 62685 # Check if we need to convert this using DOS-style short mode. If the path 62686 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62687 # take no chances and rewrite it. 62688 # Note: m4 eats our [], so we need to use [ and ] instead. 62689 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62690 if test "x$has_forbidden_chars" != x; then 62691 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62692 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62693 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62694 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62695 # Going to short mode and back again did indeed matter. Since short mode is 62696 # case insensitive, let's make it lowercase to improve readability. 62697 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62698 # Now convert it back to Unix-style (cygpath) 62699 input_path=`$CYGPATH -u "$shortmode_path"` 62700 new_path="$input_path" 62701 fi 62702 fi 62703 62704 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62705 if test "x$test_cygdrive_prefix" = x; then 62706 # As a simple fix, exclude /usr/bin since it's not a real path. 62707 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62708 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62709 # a path prefixed by /cygdrive for fixpath to work. 62710 new_path="$CYGWIN_ROOT_PATH$input_path" 62711 fi 62712 fi 62713 62714 62715 if test "x$path" != "x$new_path"; then 62716 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62717 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62718 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62719 fi 62720 62721 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62722 62723 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62724 has_colon=`$ECHO $path | $GREP ^.:` 62725 new_path="$path" 62726 if test "x$has_colon" = x; then 62727 # Not in mixed or Windows style, start by that. 62728 new_path=`cmd //c echo $path` 62729 fi 62730 62731 62732 input_path="$new_path" 62733 # Check if we need to convert this using DOS-style short mode. If the path 62734 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62735 # take no chances and rewrite it. 62736 # Note: m4 eats our [], so we need to use [ and ] instead. 62737 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62738 if test "x$has_forbidden_chars" != x; then 62739 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62740 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62741 fi 62742 62743 62744 windows_path="$new_path" 62745 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62746 unix_path=`$CYGPATH -u "$windows_path"` 62747 new_path="$unix_path" 62748 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62749 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62750 new_path="$unix_path" 62751 fi 62752 62753 if test "x$path" != "x$new_path"; then 62754 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62755 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62756 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62757 fi 62758 62759 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62760 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62761 62762 else 62763 # We're on a unix platform. Hooray! :) 62764 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62765 has_space=`$ECHO "$path" | $GREP " "` 62766 if test "x$has_space" != x; then 62767 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62768 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62769 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62770 fi 62771 62772 # Use eval to expand a potential ~ 62773 eval path="$path" 62774 if test ! -f "$path" && test ! -d "$path"; then 62775 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62776 fi 62777 62778 if test -d "$path"; then 62779 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62780 else 62781 dir="`$DIRNAME "$path"`" 62782 base="`$BASENAME "$path"`" 62783 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62784 fi 62785 fi 62786 fi 62787 62788 62789 # Only process if variable expands to non-empty 62790 62791 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62793 62794 # Input might be given as Windows format, start by converting to 62795 # unix format. 62796 path="$POTENTIAL_FREETYPE_LIB_PATH" 62797 new_path=`$CYGPATH -u "$path"` 62798 62799 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62800 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62801 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62802 # "foo.exe" is OK but "foo" is an error. 62803 # 62804 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62805 # It is also a way to make sure we got the proper file name for the real test later on. 62806 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62807 if test "x$test_shortpath" = x; then 62808 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62809 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62810 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62811 fi 62812 62813 # Call helper function which possibly converts this using DOS-style short mode. 62814 # If so, the updated path is stored in $new_path. 62815 62816 input_path="$new_path" 62817 # Check if we need to convert this using DOS-style short mode. If the path 62818 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62819 # take no chances and rewrite it. 62820 # Note: m4 eats our [], so we need to use [ and ] instead. 62821 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62822 if test "x$has_forbidden_chars" != x; then 62823 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62824 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62825 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62826 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62827 # Going to short mode and back again did indeed matter. Since short mode is 62828 # case insensitive, let's make it lowercase to improve readability. 62829 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62830 # Now convert it back to Unix-style (cygpath) 62831 input_path=`$CYGPATH -u "$shortmode_path"` 62832 new_path="$input_path" 62833 fi 62834 fi 62835 62836 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62837 if test "x$test_cygdrive_prefix" = x; then 62838 # As a simple fix, exclude /usr/bin since it's not a real path. 62839 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62840 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62841 # a path prefixed by /cygdrive for fixpath to work. 62842 new_path="$CYGWIN_ROOT_PATH$input_path" 62843 fi 62844 fi 62845 62846 62847 if test "x$path" != "x$new_path"; then 62848 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62849 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62850 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62851 fi 62852 62853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62854 62855 path="$POTENTIAL_FREETYPE_LIB_PATH" 62856 has_colon=`$ECHO $path | $GREP ^.:` 62857 new_path="$path" 62858 if test "x$has_colon" = x; then 62859 # Not in mixed or Windows style, start by that. 62860 new_path=`cmd //c echo $path` 62861 fi 62862 62863 62864 input_path="$new_path" 62865 # Check if we need to convert this using DOS-style short mode. If the path 62866 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62867 # take no chances and rewrite it. 62868 # Note: m4 eats our [], so we need to use [ and ] instead. 62869 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62870 if test "x$has_forbidden_chars" != x; then 62871 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62872 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62873 fi 62874 62875 62876 windows_path="$new_path" 62877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62878 unix_path=`$CYGPATH -u "$windows_path"` 62879 new_path="$unix_path" 62880 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62881 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62882 new_path="$unix_path" 62883 fi 62884 62885 if test "x$path" != "x$new_path"; then 62886 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62887 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62888 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62889 fi 62890 62891 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62892 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62893 62894 else 62895 # We're on a unix platform. Hooray! :) 62896 path="$POTENTIAL_FREETYPE_LIB_PATH" 62897 has_space=`$ECHO "$path" | $GREP " "` 62898 if test "x$has_space" != x; then 62899 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62900 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62901 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62902 fi 62903 62904 # Use eval to expand a potential ~ 62905 eval path="$path" 62906 if test ! -f "$path" && test ! -d "$path"; then 62907 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62908 fi 62909 62910 if test -d "$path"; then 62911 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62912 else 62913 dir="`$DIRNAME "$path"`" 62914 base="`$BASENAME "$path"`" 62915 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62916 fi 62917 fi 62918 fi 62919 62920 62921 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62923 $as_echo_n "checking for freetype includes... " >&6; } 62924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62925 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62926 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62928 $as_echo_n "checking for freetype libraries... " >&6; } 62929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62930 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62931 fi 62932 62933 else 62934 62935 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62936 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 62937 METHOD="well-known location" 62938 62939 # Let's start with an optimistic view of the world :-) 62940 FOUND_FREETYPE=yes 62941 62942 # First look for the canonical freetype main include file ft2build.h. 62943 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62944 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62945 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62946 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62947 # Fail. 62948 FOUND_FREETYPE=no 62949 fi 62950 fi 62951 62952 if test "x$FOUND_FREETYPE" = xyes; then 62953 # Include file found, let's continue the sanity check. 62954 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62955 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62956 62957 # Reset to default value 62958 FREETYPE_BASE_NAME=freetype 62959 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62960 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62961 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62962 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62963 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62964 # for the .6 version explicitly. 62965 FREETYPE_BASE_NAME=freetype.6 62966 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62967 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62968 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62969 else 62970 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62971 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62972 FOUND_FREETYPE=no 62973 fi 62974 else 62975 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62976 # On Windows, we will need both .lib and .dll file. 62977 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62978 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62979 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62980 FOUND_FREETYPE=no 62981 fi 62982 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62983 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62984 # Found lib in isa dir, use that instead. 62985 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62986 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62987 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62988 fi 62989 fi 62990 fi 62991 62992 if test "x$FOUND_FREETYPE" = xyes; then 62993 62994 # Only process if variable expands to non-empty 62995 62996 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62997 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62998 62999 # Input might be given as Windows format, start by converting to 63000 # unix format. 63001 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63002 new_path=`$CYGPATH -u "$path"` 63003 63004 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63005 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63006 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63007 # "foo.exe" is OK but "foo" is an error. 63008 # 63009 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63010 # It is also a way to make sure we got the proper file name for the real test later on. 63011 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63012 if test "x$test_shortpath" = x; then 63013 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63014 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63015 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 63016 fi 63017 63018 # Call helper function which possibly converts this using DOS-style short mode. 63019 # If so, the updated path is stored in $new_path. 63020 63021 input_path="$new_path" 63022 # Check if we need to convert this using DOS-style short mode. If the path 63023 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63024 # take no chances and rewrite it. 63025 # Note: m4 eats our [], so we need to use [ and ] instead. 63026 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63027 if test "x$has_forbidden_chars" != x; then 63028 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63029 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63030 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63031 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63032 # Going to short mode and back again did indeed matter. Since short mode is 63033 # case insensitive, let's make it lowercase to improve readability. 63034 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63035 # Now convert it back to Unix-style (cygpath) 63036 input_path=`$CYGPATH -u "$shortmode_path"` 63037 new_path="$input_path" 63038 fi 63039 fi 63040 63041 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63042 if test "x$test_cygdrive_prefix" = x; then 63043 # As a simple fix, exclude /usr/bin since it's not a real path. 63044 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63045 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63046 # a path prefixed by /cygdrive for fixpath to work. 63047 new_path="$CYGWIN_ROOT_PATH$input_path" 63048 fi 63049 fi 63050 63051 63052 if test "x$path" != "x$new_path"; then 63053 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63054 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63055 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63056 fi 63057 63058 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63059 63060 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63061 has_colon=`$ECHO $path | $GREP ^.:` 63062 new_path="$path" 63063 if test "x$has_colon" = x; then 63064 # Not in mixed or Windows style, start by that. 63065 new_path=`cmd //c echo $path` 63066 fi 63067 63068 63069 input_path="$new_path" 63070 # Check if we need to convert this using DOS-style short mode. If the path 63071 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63072 # take no chances and rewrite it. 63073 # Note: m4 eats our [], so we need to use [ and ] instead. 63074 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63075 if test "x$has_forbidden_chars" != x; then 63076 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63077 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63078 fi 63079 63080 63081 windows_path="$new_path" 63082 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63083 unix_path=`$CYGPATH -u "$windows_path"` 63084 new_path="$unix_path" 63085 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63086 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63087 new_path="$unix_path" 63088 fi 63089 63090 if test "x$path" != "x$new_path"; then 63091 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63092 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63093 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63094 fi 63095 63096 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63097 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63098 63099 else 63100 # We're on a unix platform. Hooray! :) 63101 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63102 has_space=`$ECHO "$path" | $GREP " "` 63103 if test "x$has_space" != x; then 63104 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63105 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63106 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63107 fi 63108 63109 # Use eval to expand a potential ~ 63110 eval path="$path" 63111 if test ! -f "$path" && test ! -d "$path"; then 63112 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63113 fi 63114 63115 if test -d "$path"; then 63116 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63117 else 63118 dir="`$DIRNAME "$path"`" 63119 base="`$BASENAME "$path"`" 63120 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63121 fi 63122 fi 63123 fi 63124 63125 63126 # Only process if variable expands to non-empty 63127 63128 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63129 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63130 63131 # Input might be given as Windows format, start by converting to 63132 # unix format. 63133 path="$POTENTIAL_FREETYPE_LIB_PATH" 63134 new_path=`$CYGPATH -u "$path"` 63135 63136 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63137 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63138 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63139 # "foo.exe" is OK but "foo" is an error. 63140 # 63141 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63142 # It is also a way to make sure we got the proper file name for the real test later on. 63143 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63144 if test "x$test_shortpath" = x; then 63145 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63146 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63147 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63148 fi 63149 63150 # Call helper function which possibly converts this using DOS-style short mode. 63151 # If so, the updated path is stored in $new_path. 63152 63153 input_path="$new_path" 63154 # Check if we need to convert this using DOS-style short mode. If the path 63155 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63156 # take no chances and rewrite it. 63157 # Note: m4 eats our [], so we need to use [ and ] instead. 63158 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63159 if test "x$has_forbidden_chars" != x; then 63160 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63161 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63162 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63163 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63164 # Going to short mode and back again did indeed matter. Since short mode is 63165 # case insensitive, let's make it lowercase to improve readability. 63166 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63167 # Now convert it back to Unix-style (cygpath) 63168 input_path=`$CYGPATH -u "$shortmode_path"` 63169 new_path="$input_path" 63170 fi 63171 fi 63172 63173 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63174 if test "x$test_cygdrive_prefix" = x; then 63175 # As a simple fix, exclude /usr/bin since it's not a real path. 63176 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63177 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63178 # a path prefixed by /cygdrive for fixpath to work. 63179 new_path="$CYGWIN_ROOT_PATH$input_path" 63180 fi 63181 fi 63182 63183 63184 if test "x$path" != "x$new_path"; then 63185 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63186 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63187 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63188 fi 63189 63190 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63191 63192 path="$POTENTIAL_FREETYPE_LIB_PATH" 63193 has_colon=`$ECHO $path | $GREP ^.:` 63194 new_path="$path" 63195 if test "x$has_colon" = x; then 63196 # Not in mixed or Windows style, start by that. 63197 new_path=`cmd //c echo $path` 63198 fi 63199 63200 63201 input_path="$new_path" 63202 # Check if we need to convert this using DOS-style short mode. If the path 63203 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63204 # take no chances and rewrite it. 63205 # Note: m4 eats our [], so we need to use [ and ] instead. 63206 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63207 if test "x$has_forbidden_chars" != x; then 63208 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63209 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63210 fi 63211 63212 63213 windows_path="$new_path" 63214 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63215 unix_path=`$CYGPATH -u "$windows_path"` 63216 new_path="$unix_path" 63217 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63218 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63219 new_path="$unix_path" 63220 fi 63221 63222 if test "x$path" != "x$new_path"; then 63223 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63224 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63225 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63226 fi 63227 63228 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63229 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63230 63231 else 63232 # We're on a unix platform. Hooray! :) 63233 path="$POTENTIAL_FREETYPE_LIB_PATH" 63234 has_space=`$ECHO "$path" | $GREP " "` 63235 if test "x$has_space" != x; then 63236 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63237 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63238 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63239 fi 63240 63241 # Use eval to expand a potential ~ 63242 eval path="$path" 63243 if test ! -f "$path" && test ! -d "$path"; then 63244 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63245 fi 63246 63247 if test -d "$path"; then 63248 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63249 else 63250 dir="`$DIRNAME "$path"`" 63251 base="`$BASENAME "$path"`" 63252 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63253 fi 63254 fi 63255 fi 63256 63257 63258 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63260 $as_echo_n "checking for freetype includes... " >&6; } 63261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63262 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63263 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63265 $as_echo_n "checking for freetype libraries... " >&6; } 63266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63267 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63268 fi 63269 63270 if test "x$FOUND_FREETYPE" != xyes; then 63271 63272 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 63273 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 63274 METHOD="well-known location" 63275 63276 # Let's start with an optimistic view of the world :-) 63277 FOUND_FREETYPE=yes 63278 63279 # First look for the canonical freetype main include file ft2build.h. 63280 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63281 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 63282 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 63283 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 63284 # Fail. 63285 FOUND_FREETYPE=no 63286 fi 63287 fi 63288 63289 if test "x$FOUND_FREETYPE" = xyes; then 63290 # Include file found, let's continue the sanity check. 63291 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 63292 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 63293 63294 # Reset to default value 63295 FREETYPE_BASE_NAME=freetype 63296 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63297 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 63298 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 63299 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 63300 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 63301 # for the .6 version explicitly. 63302 FREETYPE_BASE_NAME=freetype.6 63303 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 63304 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 63305 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 63306 else 63307 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 63308 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 63309 FOUND_FREETYPE=no 63310 fi 63311 else 63312 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63313 # On Windows, we will need both .lib and .dll file. 63314 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 63315 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 63316 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 63317 FOUND_FREETYPE=no 63318 fi 63319 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 63320 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 63321 # Found lib in isa dir, use that instead. 63322 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 63323 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 63324 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 63325 fi 63326 fi 63327 fi 63328 63329 if test "x$FOUND_FREETYPE" = xyes; then 63330 63331 # Only process if variable expands to non-empty 63332 63333 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 63334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63335 63336 # Input might be given as Windows format, start by converting to 63337 # unix format. 63338 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63339 new_path=`$CYGPATH -u "$path"` 63340 63341 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63342 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63343 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63344 # "foo.exe" is OK but "foo" is an error. 63345 # 63346 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63347 # It is also a way to make sure we got the proper file name for the real test later on. 63348 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63349 if test "x$test_shortpath" = x; then 63350 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63351 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63352 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 63353 fi 63354 63355 # Call helper function which possibly converts this using DOS-style short mode. 63356 # If so, the updated path is stored in $new_path. 63357 63358 input_path="$new_path" 63359 # Check if we need to convert this using DOS-style short mode. If the path 63360 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63361 # take no chances and rewrite it. 63362 # Note: m4 eats our [], so we need to use [ and ] instead. 63363 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63364 if test "x$has_forbidden_chars" != x; then 63365 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63366 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63367 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63368 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63369 # Going to short mode and back again did indeed matter. Since short mode is 63370 # case insensitive, let's make it lowercase to improve readability. 63371 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63372 # Now convert it back to Unix-style (cygpath) 63373 input_path=`$CYGPATH -u "$shortmode_path"` 63374 new_path="$input_path" 63375 fi 63376 fi 63377 63378 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63379 if test "x$test_cygdrive_prefix" = x; then 63380 # As a simple fix, exclude /usr/bin since it's not a real path. 63381 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63382 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63383 # a path prefixed by /cygdrive for fixpath to work. 63384 new_path="$CYGWIN_ROOT_PATH$input_path" 63385 fi 63386 fi 63387 63388 63389 if test "x$path" != "x$new_path"; then 63390 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63391 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63392 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63393 fi 63394 63395 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63396 63397 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63398 has_colon=`$ECHO $path | $GREP ^.:` 63399 new_path="$path" 63400 if test "x$has_colon" = x; then 63401 # Not in mixed or Windows style, start by that. 63402 new_path=`cmd //c echo $path` 63403 fi 63404 63405 63406 input_path="$new_path" 63407 # Check if we need to convert this using DOS-style short mode. If the path 63408 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63409 # take no chances and rewrite it. 63410 # Note: m4 eats our [], so we need to use [ and ] instead. 63411 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63412 if test "x$has_forbidden_chars" != x; then 63413 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63414 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63415 fi 63416 63417 63418 windows_path="$new_path" 63419 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63420 unix_path=`$CYGPATH -u "$windows_path"` 63421 new_path="$unix_path" 63422 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63423 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63424 new_path="$unix_path" 63425 fi 63426 63427 if test "x$path" != "x$new_path"; then 63428 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 63429 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63430 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63431 fi 63432 63433 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63434 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63435 63436 else 63437 # We're on a unix platform. Hooray! :) 63438 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63439 has_space=`$ECHO "$path" | $GREP " "` 63440 if test "x$has_space" != x; then 63441 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63442 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63443 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63444 fi 63445 63446 # Use eval to expand a potential ~ 63447 eval path="$path" 63448 if test ! -f "$path" && test ! -d "$path"; then 63449 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63450 fi 63451 63452 if test -d "$path"; then 63453 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63454 else 63455 dir="`$DIRNAME "$path"`" 63456 base="`$BASENAME "$path"`" 63457 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63458 fi 63459 fi 63460 fi 63461 63462 63463 # Only process if variable expands to non-empty 63464 63465 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 63466 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63467 63468 # Input might be given as Windows format, start by converting to 63469 # unix format. 63470 path="$POTENTIAL_FREETYPE_LIB_PATH" 63471 new_path=`$CYGPATH -u "$path"` 63472 63473 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63474 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63475 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63476 # "foo.exe" is OK but "foo" is an error. 63477 # 63478 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63479 # It is also a way to make sure we got the proper file name for the real test later on. 63480 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63481 if test "x$test_shortpath" = x; then 63482 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63483 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63484 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 63485 fi 63486 63487 # Call helper function which possibly converts this using DOS-style short mode. 63488 # If so, the updated path is stored in $new_path. 63489 63490 input_path="$new_path" 63491 # Check if we need to convert this using DOS-style short mode. If the path 63492 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63493 # take no chances and rewrite it. 63494 # Note: m4 eats our [], so we need to use [ and ] instead. 63495 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63496 if test "x$has_forbidden_chars" != x; then 63497 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63498 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63499 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63500 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63501 # Going to short mode and back again did indeed matter. Since short mode is 63502 # case insensitive, let's make it lowercase to improve readability. 63503 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63504 # Now convert it back to Unix-style (cygpath) 63505 input_path=`$CYGPATH -u "$shortmode_path"` 63506 new_path="$input_path" 63507 fi 63508 fi 63509 63510 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63511 if test "x$test_cygdrive_prefix" = x; then 63512 # As a simple fix, exclude /usr/bin since it's not a real path. 63513 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63514 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63515 # a path prefixed by /cygdrive for fixpath to work. 63516 new_path="$CYGWIN_ROOT_PATH$input_path" 63517 fi 63518 fi 63519 63520 63521 if test "x$path" != "x$new_path"; then 63522 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63523 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63524 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63525 fi 63526 63527 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63528 63529 path="$POTENTIAL_FREETYPE_LIB_PATH" 63530 has_colon=`$ECHO $path | $GREP ^.:` 63531 new_path="$path" 63532 if test "x$has_colon" = x; then 63533 # Not in mixed or Windows style, start by that. 63534 new_path=`cmd //c echo $path` 63535 fi 63536 63537 63538 input_path="$new_path" 63539 # Check if we need to convert this using DOS-style short mode. If the path 63540 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63541 # take no chances and rewrite it. 63542 # Note: m4 eats our [], so we need to use [ and ] instead. 63543 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63544 if test "x$has_forbidden_chars" != x; then 63545 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63546 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63547 fi 63548 63549 63550 windows_path="$new_path" 63551 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63552 unix_path=`$CYGPATH -u "$windows_path"` 63553 new_path="$unix_path" 63554 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63555 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63556 new_path="$unix_path" 63557 fi 63558 63559 if test "x$path" != "x$new_path"; then 63560 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 63561 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 63562 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63563 fi 63564 63565 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63566 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63567 63568 else 63569 # We're on a unix platform. Hooray! :) 63570 path="$POTENTIAL_FREETYPE_LIB_PATH" 63571 has_space=`$ECHO "$path" | $GREP " "` 63572 if test "x$has_space" != x; then 63573 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63574 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63575 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63576 fi 63577 63578 # Use eval to expand a potential ~ 63579 eval path="$path" 63580 if test ! -f "$path" && test ! -d "$path"; then 63581 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63582 fi 63583 63584 if test -d "$path"; then 63585 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63586 else 63587 dir="`$DIRNAME "$path"`" 63588 base="`$BASENAME "$path"`" 63589 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63590 fi 63591 fi 63592 fi 63593 63594 63595 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 63596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 63597 $as_echo_n "checking for freetype includes... " >&6; } 63598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 63599 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 63600 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 63601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 63602 $as_echo_n "checking for freetype libraries... " >&6; } 63603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 63604 $as_echo "$FREETYPE_LIB_PATH" >&6; } 63605 fi 63606 63607 fi 63608 fi 63609 fi 63610 fi 63611 fi # end check in well-known locations 63612 63613 if test "x$FOUND_FREETYPE" != xyes; then 63614 63615 # Print a helpful message on how to acquire the necessary build dependency. 63616 # freetype is the help tag: freetype, cups, alsa etc 63617 MISSING_DEPENDENCY=freetype 63618 63619 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63620 cygwin_help $MISSING_DEPENDENCY 63621 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63622 msys_help $MISSING_DEPENDENCY 63623 else 63624 PKGHANDLER_COMMAND= 63625 63626 case $PKGHANDLER in 63627 apt-get) 63628 apt_help $MISSING_DEPENDENCY ;; 63629 yum) 63630 yum_help $MISSING_DEPENDENCY ;; 63631 brew) 63632 brew_help $MISSING_DEPENDENCY ;; 63633 port) 63634 port_help $MISSING_DEPENDENCY ;; 63635 pkgutil) 63636 pkgutil_help $MISSING_DEPENDENCY ;; 63637 pkgadd) 63638 pkgadd_help $MISSING_DEPENDENCY ;; 63639 esac 63640 63641 if test "x$PKGHANDLER_COMMAND" != x; then 63642 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63643 fi 63644 fi 63645 63646 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 63647 fi 63648 fi # end user specified settings 63649 63650 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 63651 if test "x$FREETYPE_CFLAGS" = x; then 63652 63653 # Only process if variable expands to non-empty 63654 63655 if test "x$FREETYPE_INCLUDE_PATH" != x; then 63656 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63657 63658 # Input might be given as Windows format, start by converting to 63659 # unix format. 63660 path="$FREETYPE_INCLUDE_PATH" 63661 new_path=`$CYGPATH -u "$path"` 63662 63663 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63664 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63665 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63666 # "foo.exe" is OK but "foo" is an error. 63667 # 63668 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63669 # It is also a way to make sure we got the proper file name for the real test later on. 63670 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63671 if test "x$test_shortpath" = x; then 63672 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63673 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63674 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 63675 fi 63676 63677 # Call helper function which possibly converts this using DOS-style short mode. 63678 # If so, the updated path is stored in $new_path. 63679 63680 input_path="$new_path" 63681 # Check if we need to convert this using DOS-style short mode. If the path 63682 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63683 # take no chances and rewrite it. 63684 # Note: m4 eats our [], so we need to use [ and ] instead. 63685 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63686 if test "x$has_forbidden_chars" != x; then 63687 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63688 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63689 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63690 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63691 # Going to short mode and back again did indeed matter. Since short mode is 63692 # case insensitive, let's make it lowercase to improve readability. 63693 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63694 # Now convert it back to Unix-style (cygpath) 63695 input_path=`$CYGPATH -u "$shortmode_path"` 63696 new_path="$input_path" 63697 fi 63698 fi 63699 63700 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63701 if test "x$test_cygdrive_prefix" = x; then 63702 # As a simple fix, exclude /usr/bin since it's not a real path. 63703 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63704 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63705 # a path prefixed by /cygdrive for fixpath to work. 63706 new_path="$CYGWIN_ROOT_PATH$input_path" 63707 fi 63708 fi 63709 63710 63711 if test "x$path" != "x$new_path"; then 63712 FREETYPE_INCLUDE_PATH="$new_path" 63713 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63714 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63715 fi 63716 63717 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63718 63719 path="$FREETYPE_INCLUDE_PATH" 63720 has_colon=`$ECHO $path | $GREP ^.:` 63721 new_path="$path" 63722 if test "x$has_colon" = x; then 63723 # Not in mixed or Windows style, start by that. 63724 new_path=`cmd //c echo $path` 63725 fi 63726 63727 63728 input_path="$new_path" 63729 # Check if we need to convert this using DOS-style short mode. If the path 63730 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63731 # take no chances and rewrite it. 63732 # Note: m4 eats our [], so we need to use [ and ] instead. 63733 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63734 if test "x$has_forbidden_chars" != x; then 63735 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63736 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63737 fi 63738 63739 63740 windows_path="$new_path" 63741 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63742 unix_path=`$CYGPATH -u "$windows_path"` 63743 new_path="$unix_path" 63744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63745 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63746 new_path="$unix_path" 63747 fi 63748 63749 if test "x$path" != "x$new_path"; then 63750 FREETYPE_INCLUDE_PATH="$new_path" 63751 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 63752 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 63753 fi 63754 63755 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63756 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63757 63758 else 63759 # We're on a unix platform. Hooray! :) 63760 path="$FREETYPE_INCLUDE_PATH" 63761 has_space=`$ECHO "$path" | $GREP " "` 63762 if test "x$has_space" != x; then 63763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 63764 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 63765 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63766 fi 63767 63768 # Use eval to expand a potential ~ 63769 eval path="$path" 63770 if test ! -f "$path" && test ! -d "$path"; then 63771 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63772 fi 63773 63774 if test -d "$path"; then 63775 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 63776 else 63777 dir="`$DIRNAME "$path"`" 63778 base="`$BASENAME "$path"`" 63779 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63780 fi 63781 fi 63782 fi 63783 63784 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 63785 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 63786 else 63787 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 63788 fi 63789 fi 63790 63791 if test "x$FREETYPE_LIBS" = x; then 63792 63793 # Only process if variable expands to non-empty 63794 63795 if test "x$FREETYPE_LIB_PATH" != x; then 63796 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63797 63798 # Input might be given as Windows format, start by converting to 63799 # unix format. 63800 path="$FREETYPE_LIB_PATH" 63801 new_path=`$CYGPATH -u "$path"` 63802 63803 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63804 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63805 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63806 # "foo.exe" is OK but "foo" is an error. 63807 # 63808 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63809 # It is also a way to make sure we got the proper file name for the real test later on. 63810 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63811 if test "x$test_shortpath" = x; then 63812 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63813 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63814 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 63815 fi 63816 63817 # Call helper function which possibly converts this using DOS-style short mode. 63818 # If so, the updated path is stored in $new_path. 63819 63820 input_path="$new_path" 63821 # Check if we need to convert this using DOS-style short mode. If the path 63822 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63823 # take no chances and rewrite it. 63824 # Note: m4 eats our [], so we need to use [ and ] instead. 63825 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63826 if test "x$has_forbidden_chars" != x; then 63827 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63828 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63829 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63830 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63831 # Going to short mode and back again did indeed matter. Since short mode is 63832 # case insensitive, let's make it lowercase to improve readability. 63833 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63834 # Now convert it back to Unix-style (cygpath) 63835 input_path=`$CYGPATH -u "$shortmode_path"` 63836 new_path="$input_path" 63837 fi 63838 fi 63839 63840 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63841 if test "x$test_cygdrive_prefix" = x; then 63842 # As a simple fix, exclude /usr/bin since it's not a real path. 63843 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63844 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63845 # a path prefixed by /cygdrive for fixpath to work. 63846 new_path="$CYGWIN_ROOT_PATH$input_path" 63847 fi 63848 fi 63849 63850 63851 if test "x$path" != "x$new_path"; then 63852 FREETYPE_LIB_PATH="$new_path" 63853 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 63854 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63855 fi 63856 63857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63858 63859 path="$FREETYPE_LIB_PATH" 63860 has_colon=`$ECHO $path | $GREP ^.:` 63861 new_path="$path" 63862 if test "x$has_colon" = x; then 63863 # Not in mixed or Windows style, start by that. 63864 new_path=`cmd //c echo $path` 63865 fi 63866 63867 63868 input_path="$new_path" 63869 # Check if we need to convert this using DOS-style short mode. If the path 63870 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63871 # take no chances and rewrite it. 63872 # Note: m4 eats our [], so we need to use [ and ] instead. 63873 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63874 if test "x$has_forbidden_chars" != x; then 63875 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63876 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63877 fi 63878 63879 63880 windows_path="$new_path" 63881 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63882 unix_path=`$CYGPATH -u "$windows_path"` 63883 new_path="$unix_path" 63884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63885 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63886 new_path="$unix_path" 63887 fi 63888 63889 if test "x$path" != "x$new_path"; then 63890 FREETYPE_LIB_PATH="$new_path" 63891 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 63892 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 63893 fi 63894 63895 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63896 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63897 63898 else 63899 # We're on a unix platform. Hooray! :) 63900 path="$FREETYPE_LIB_PATH" 63901 has_space=`$ECHO "$path" | $GREP " "` 63902 if test "x$has_space" != x; then 63903 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 63904 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 63905 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63906 fi 63907 63908 # Use eval to expand a potential ~ 63909 eval path="$path" 63910 if test ! -f "$path" && test ! -d "$path"; then 63911 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 63912 fi 63913 63914 if test -d "$path"; then 63915 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 63916 else 63917 dir="`$DIRNAME "$path"`" 63918 base="`$BASENAME "$path"`" 63919 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 63920 fi 63921 fi 63922 fi 63923 63924 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63925 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 63926 else 63927 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 63928 fi 63929 fi 63930 63931 # Try to compile it 63932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 63933 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 63934 ac_ext=cpp 63935 ac_cpp='$CXXCPP $CPPFLAGS' 63936 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63937 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63938 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 63939 63940 PREV_CXXCFLAGS="$CXXFLAGS" 63941 PREV_LIBS="$LIBS" 63942 PREV_CXX="$CXX" 63943 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 63944 LIBS="$LIBS $FREETYPE_LIBS" 63945 CXX="$FIXPATH $CXX" 63946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63947 /* end confdefs.h. */ 63948 63949 #include<ft2build.h> 63950 #include FT_FREETYPE_H 63951 int main () { 63952 FT_Init_FreeType(NULL); 63953 return 0; 63954 } 63955 63956 _ACEOF 63957 if ac_fn_cxx_try_link "$LINENO"; then : 63958 63959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63960 $as_echo "yes" >&6; } 63961 63962 else 63963 63964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63965 $as_echo "no" >&6; } 63966 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 63967 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 63968 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 63969 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 63970 63971 63972 # Print a helpful message on how to acquire the necessary build dependency. 63973 # freetype is the help tag: freetype, cups, alsa etc 63974 MISSING_DEPENDENCY=freetype 63975 63976 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63977 cygwin_help $MISSING_DEPENDENCY 63978 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63979 msys_help $MISSING_DEPENDENCY 63980 else 63981 PKGHANDLER_COMMAND= 63982 63983 case $PKGHANDLER in 63984 apt-get) 63985 apt_help $MISSING_DEPENDENCY ;; 63986 yum) 63987 yum_help $MISSING_DEPENDENCY ;; 63988 brew) 63989 brew_help $MISSING_DEPENDENCY ;; 63990 port) 63991 port_help $MISSING_DEPENDENCY ;; 63992 pkgutil) 63993 pkgutil_help $MISSING_DEPENDENCY ;; 63994 pkgadd) 63995 pkgadd_help $MISSING_DEPENDENCY ;; 63996 esac 63997 63998 if test "x$PKGHANDLER_COMMAND" != x; then 63999 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64000 fi 64001 fi 64002 64003 64004 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 64005 64006 64007 fi 64008 rm -f core conftest.err conftest.$ac_objext \ 64009 conftest$ac_exeext conftest.$ac_ext 64010 CXXCFLAGS="$PREV_CXXFLAGS" 64011 LIBS="$PREV_LIBS" 64012 CXX="$PREV_CXX" 64013 ac_ext=cpp 64014 ac_cpp='$CXXCPP $CPPFLAGS' 64015 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64016 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64017 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 64018 64019 64020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 64021 $as_echo_n "checking if we should bundle freetype... " >&6; } 64022 if test "x$BUNDLE_FREETYPE" = xyes; then 64023 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 64024 fi 64025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 64026 $as_echo "$BUNDLE_FREETYPE" >&6; } 64027 64028 fi # end freetype needed 64029 64030 FREETYPE_LICENSE="" 64031 if test "x$with_freetype_license" = "xyes"; then 64032 as_fn_error $? "--with-freetype-license must have a value" "$LINENO" 5 64033 elif test "x$with_freetype_license" != "x"; then 64034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype license" >&5 64035 $as_echo_n "checking for freetype license... " >&6; } 64036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_freetype_license" >&5 64037 $as_echo "$with_freetype_license" >&6; } 64038 FREETYPE_LICENSE="$with_freetype_license" 64039 64040 # Only process if variable expands to non-empty 64041 64042 if test "x$FREETYPE_LICENSE" != x; then 64043 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64044 64045 # Input might be given as Windows format, start by converting to 64046 # unix format. 64047 path="$FREETYPE_LICENSE" 64048 new_path=`$CYGPATH -u "$path"` 64049 64050 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64051 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64052 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64053 # "foo.exe" is OK but "foo" is an error. 64054 # 64055 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64056 # It is also a way to make sure we got the proper file name for the real test later on. 64057 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64058 if test "x$test_shortpath" = x; then 64059 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 64060 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 64061 as_fn_error $? "Cannot locate the the path of FREETYPE_LICENSE" "$LINENO" 5 64062 fi 64063 64064 # Call helper function which possibly converts this using DOS-style short mode. 64065 # If so, the updated path is stored in $new_path. 64066 64067 input_path="$new_path" 64068 # Check if we need to convert this using DOS-style short mode. If the path 64069 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64070 # take no chances and rewrite it. 64071 # Note: m4 eats our [], so we need to use [ and ] instead. 64072 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64073 if test "x$has_forbidden_chars" != x; then 64074 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64075 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64076 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64077 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64078 # Going to short mode and back again did indeed matter. Since short mode is 64079 # case insensitive, let's make it lowercase to improve readability. 64080 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64081 # Now convert it back to Unix-style (cygpath) 64082 input_path=`$CYGPATH -u "$shortmode_path"` 64083 new_path="$input_path" 64084 fi 64085 fi 64086 64087 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64088 if test "x$test_cygdrive_prefix" = x; then 64089 # As a simple fix, exclude /usr/bin since it's not a real path. 64090 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64091 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64092 # a path prefixed by /cygdrive for fixpath to work. 64093 new_path="$CYGWIN_ROOT_PATH$input_path" 64094 fi 64095 fi 64096 64097 64098 if test "x$path" != "x$new_path"; then 64099 FREETYPE_LICENSE="$new_path" 64100 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 64101 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 64102 fi 64103 64104 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64105 64106 path="$FREETYPE_LICENSE" 64107 has_colon=`$ECHO $path | $GREP ^.:` 64108 new_path="$path" 64109 if test "x$has_colon" = x; then 64110 # Not in mixed or Windows style, start by that. 64111 new_path=`cmd //c echo $path` 64112 fi 64113 64114 64115 input_path="$new_path" 64116 # Check if we need to convert this using DOS-style short mode. If the path 64117 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64118 # take no chances and rewrite it. 64119 # Note: m4 eats our [], so we need to use [ and ] instead. 64120 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64121 if test "x$has_forbidden_chars" != x; then 64122 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64123 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64124 fi 64125 64126 64127 windows_path="$new_path" 64128 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64129 unix_path=`$CYGPATH -u "$windows_path"` 64130 new_path="$unix_path" 64131 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64132 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64133 new_path="$unix_path" 64134 fi 64135 64136 if test "x$path" != "x$new_path"; then 64137 FREETYPE_LICENSE="$new_path" 64138 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&5 64139 $as_echo "$as_me: Rewriting FREETYPE_LICENSE to \"$new_path\"" >&6;} 64140 fi 64141 64142 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64143 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64144 64145 else 64146 # We're on a unix platform. Hooray! :) 64147 path="$FREETYPE_LICENSE" 64148 has_space=`$ECHO "$path" | $GREP " "` 64149 if test "x$has_space" != x; then 64150 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&5 64151 $as_echo "$as_me: The path of FREETYPE_LICENSE, which resolves as \"$path\", is invalid." >&6;} 64152 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64153 fi 64154 64155 # Use eval to expand a potential ~ 64156 eval path="$path" 64157 if test ! -f "$path" && test ! -d "$path"; then 64158 as_fn_error $? "The path of FREETYPE_LICENSE, which resolves as \"$path\", is not found." "$LINENO" 5 64159 fi 64160 64161 if test -d "$path"; then 64162 FREETYPE_LICENSE="`cd "$path"; $THEPWDCMD -L`" 64163 else 64164 dir="`$DIRNAME "$path"`" 64165 base="`$BASENAME "$path"`" 64166 FREETYPE_LICENSE="`cd "$dir"; $THEPWDCMD -L`/$base" 64167 fi 64168 fi 64169 fi 64170 64171 if test ! -f "$FREETYPE_LICENSE"; then 64172 as_fn_error $? "$FREETYPE_LICENSE cannot be found" "$LINENO" 5 64173 fi 64174 fi 64175 64176 64177 64178 64179 64180 64181 64182 64183 # Check whether --with-alsa was given. 64184 if test "${with_alsa+set}" = set; then : 64185 withval=$with_alsa; 64186 fi 64187 64188 64189 # Check whether --with-alsa-include was given. 64190 if test "${with_alsa_include+set}" = set; then : 64191 withval=$with_alsa_include; 64192 fi 64193 64194 64195 # Check whether --with-alsa-lib was given. 64196 if test "${with_alsa_lib+set}" = set; then : 64197 withval=$with_alsa_lib; 64198 fi 64199 64200 64201 if test "x$NEEDS_LIB_ALSA" = xfalse; then 64202 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 64203 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 64204 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 64205 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 64206 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 64207 fi 64208 ALSA_CFLAGS= 64209 ALSA_LIBS= 64210 else 64211 ALSA_FOUND=no 64212 64213 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 64214 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 64215 fi 64216 64217 if test "x${with_alsa}" != x; then 64218 ALSA_LIBS="-L${with_alsa}/lib -lasound" 64219 ALSA_CFLAGS="-I${with_alsa}/include" 64220 ALSA_FOUND=yes 64221 fi 64222 if test "x${with_alsa_include}" != x; then 64223 ALSA_CFLAGS="-I${with_alsa_include}" 64224 ALSA_FOUND=yes 64225 fi 64226 if test "x${with_alsa_lib}" != x; then 64227 ALSA_LIBS="-L${with_alsa_lib} -lasound" 64228 ALSA_FOUND=yes 64229 fi 64230 # Do not try pkg-config if we have a sysroot set. 64231 if test "x$SYSROOT" = x; then 64232 if test "x$ALSA_FOUND" = xno; then 64233 64234 pkg_failed=no 64235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 64236 $as_echo_n "checking for ALSA... " >&6; } 64237 64238 if test -n "$ALSA_CFLAGS"; then 64239 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 64240 elif test -n "$PKG_CONFIG"; then 64241 if test -n "$PKG_CONFIG" && \ 64242 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 64243 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 64244 ac_status=$? 64245 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64246 test $ac_status = 0; }; then 64247 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 64248 else 64249 pkg_failed=yes 64250 fi 64251 else 64252 pkg_failed=untried 64253 fi 64254 if test -n "$ALSA_LIBS"; then 64255 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 64256 elif test -n "$PKG_CONFIG"; then 64257 if test -n "$PKG_CONFIG" && \ 64258 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 64259 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 64260 ac_status=$? 64261 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64262 test $ac_status = 0; }; then 64263 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 64264 else 64265 pkg_failed=yes 64266 fi 64267 else 64268 pkg_failed=untried 64269 fi 64270 64271 64272 64273 if test $pkg_failed = yes; then 64274 64275 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 64276 _pkg_short_errors_supported=yes 64277 else 64278 _pkg_short_errors_supported=no 64279 fi 64280 if test $_pkg_short_errors_supported = yes; then 64281 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 64282 else 64283 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 64284 fi 64285 # Put the nasty error message in config.log where it belongs 64286 echo "$ALSA_PKG_ERRORS" >&5 64287 64288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64289 $as_echo "no" >&6; } 64290 ALSA_FOUND=no 64291 elif test $pkg_failed = untried; then 64292 ALSA_FOUND=no 64293 else 64294 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 64295 ALSA_LIBS=$pkg_cv_ALSA_LIBS 64296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64297 $as_echo "yes" >&6; } 64298 ALSA_FOUND=yes 64299 fi 64300 fi 64301 fi 64302 if test "x$ALSA_FOUND" = xno; then 64303 for ac_header in alsa/asoundlib.h 64304 do : 64305 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 64306 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 64307 cat >>confdefs.h <<_ACEOF 64308 #define HAVE_ALSA_ASOUNDLIB_H 1 64309 _ACEOF 64310 64311 ALSA_FOUND=yes 64312 ALSA_CFLAGS=-Iignoreme 64313 ALSA_LIBS=-lasound 64314 DEFAULT_ALSA=yes 64315 64316 else 64317 ALSA_FOUND=no 64318 64319 fi 64320 64321 done 64322 64323 fi 64324 if test "x$ALSA_FOUND" = xno; then 64325 64326 # Print a helpful message on how to acquire the necessary build dependency. 64327 # alsa is the help tag: freetype, cups, alsa etc 64328 MISSING_DEPENDENCY=alsa 64329 64330 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64331 cygwin_help $MISSING_DEPENDENCY 64332 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64333 msys_help $MISSING_DEPENDENCY 64334 else 64335 PKGHANDLER_COMMAND= 64336 64337 case $PKGHANDLER in 64338 apt-get) 64339 apt_help $MISSING_DEPENDENCY ;; 64340 yum) 64341 yum_help $MISSING_DEPENDENCY ;; 64342 brew) 64343 brew_help $MISSING_DEPENDENCY ;; 64344 port) 64345 port_help $MISSING_DEPENDENCY ;; 64346 pkgutil) 64347 pkgutil_help $MISSING_DEPENDENCY ;; 64348 pkgadd) 64349 pkgadd_help $MISSING_DEPENDENCY ;; 64350 esac 64351 64352 if test "x$PKGHANDLER_COMMAND" != x; then 64353 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64354 fi 64355 fi 64356 64357 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 64358 fi 64359 fi 64360 64361 64362 64363 64364 64365 64366 # Check whether --with-libffi was given. 64367 if test "${with_libffi+set}" = set; then : 64368 withval=$with_libffi; 64369 fi 64370 64371 64372 # Check whether --with-libffi-include was given. 64373 if test "${with_libffi_include+set}" = set; then : 64374 withval=$with_libffi_include; 64375 fi 64376 64377 64378 # Check whether --with-libffi-lib was given. 64379 if test "${with_libffi_lib+set}" = set; then : 64380 withval=$with_libffi_lib; 64381 fi 64382 64383 # Check whether --enable-libffi-bundling was given. 64384 if test "${enable_libffi_bundling+set}" = set; then : 64385 enableval=$enable_libffi_bundling; 64386 fi 64387 64388 64389 if test "x$NEEDS_LIB_FFI" = xfalse; then 64390 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 64391 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 64392 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 64393 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 64394 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 64395 fi 64396 LIBFFI_CFLAGS= 64397 LIBFFI_LIBS= 64398 else 64399 LIBFFI_FOUND=no 64400 64401 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 64402 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 64403 fi 64404 64405 if test "x${with_libffi}" != x; then 64406 LIBFFI_LIB_PATH="${with_libffi}/lib" 64407 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 64408 LIBFFI_CFLAGS="-I${with_libffi}/include" 64409 LIBFFI_FOUND=yes 64410 fi 64411 if test "x${with_libffi_include}" != x; then 64412 LIBFFI_CFLAGS="-I${with_libffi_include}" 64413 LIBFFI_FOUND=yes 64414 fi 64415 if test "x${with_libffi_lib}" != x; then 64416 LIBFFI_LIB_PATH="${with_libffi_lib}" 64417 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 64418 LIBFFI_FOUND=yes 64419 fi 64420 # Do not try pkg-config if we have a sysroot set. 64421 if test "x$SYSROOT" = x; then 64422 if test "x$LIBFFI_FOUND" = xno; then 64423 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 64424 64425 pkg_failed=no 64426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 64427 $as_echo_n "checking for LIBFFI... " >&6; } 64428 64429 if test -n "$LIBFFI_CFLAGS"; then 64430 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 64431 elif test -n "$PKG_CONFIG"; then 64432 if test -n "$PKG_CONFIG" && \ 64433 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 64434 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 64435 ac_status=$? 64436 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64437 test $ac_status = 0; }; then 64438 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 64439 else 64440 pkg_failed=yes 64441 fi 64442 else 64443 pkg_failed=untried 64444 fi 64445 if test -n "$LIBFFI_LIBS"; then 64446 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 64447 elif test -n "$PKG_CONFIG"; then 64448 if test -n "$PKG_CONFIG" && \ 64449 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 64450 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 64451 ac_status=$? 64452 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64453 test $ac_status = 0; }; then 64454 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 64455 else 64456 pkg_failed=yes 64457 fi 64458 else 64459 pkg_failed=untried 64460 fi 64461 64462 64463 64464 if test $pkg_failed = yes; then 64465 64466 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 64467 _pkg_short_errors_supported=yes 64468 else 64469 _pkg_short_errors_supported=no 64470 fi 64471 if test $_pkg_short_errors_supported = yes; then 64472 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 64473 else 64474 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 64475 fi 64476 # Put the nasty error message in config.log where it belongs 64477 echo "$LIBFFI_PKG_ERRORS" >&5 64478 64479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64480 $as_echo "no" >&6; } 64481 LIBFFI_FOUND=no 64482 elif test $pkg_failed = untried; then 64483 LIBFFI_FOUND=no 64484 else 64485 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 64486 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 64487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64488 $as_echo "yes" >&6; } 64489 LIBFFI_FOUND=yes 64490 fi 64491 fi 64492 fi 64493 if test "x$LIBFFI_FOUND" = xno; then 64494 for ac_header in ffi.h 64495 do : 64496 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 64497 if test "x$ac_cv_header_ffi_h" = xyes; then : 64498 cat >>confdefs.h <<_ACEOF 64499 #define HAVE_FFI_H 1 64500 _ACEOF 64501 64502 LIBFFI_FOUND=yes 64503 LIBFFI_CFLAGS= 64504 LIBFFI_LIBS=-lffi 64505 64506 else 64507 LIBFFI_FOUND=no 64508 64509 fi 64510 64511 done 64512 64513 fi 64514 if test "x$LIBFFI_FOUND" = xno; then 64515 64516 # Print a helpful message on how to acquire the necessary build dependency. 64517 # ffi is the help tag: freetype, cups, alsa etc 64518 MISSING_DEPENDENCY=ffi 64519 64520 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64521 cygwin_help $MISSING_DEPENDENCY 64522 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64523 msys_help $MISSING_DEPENDENCY 64524 else 64525 PKGHANDLER_COMMAND= 64526 64527 case $PKGHANDLER in 64528 apt-get) 64529 apt_help $MISSING_DEPENDENCY ;; 64530 yum) 64531 yum_help $MISSING_DEPENDENCY ;; 64532 brew) 64533 brew_help $MISSING_DEPENDENCY ;; 64534 port) 64535 port_help $MISSING_DEPENDENCY ;; 64536 pkgutil) 64537 pkgutil_help $MISSING_DEPENDENCY ;; 64538 pkgadd) 64539 pkgadd_help $MISSING_DEPENDENCY ;; 64540 esac 64541 64542 if test "x$PKGHANDLER_COMMAND" != x; then 64543 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64544 fi 64545 fi 64546 64547 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 64548 fi 64549 64550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 64551 $as_echo_n "checking if libffi works... " >&6; } 64552 ac_ext=c 64553 ac_cpp='$CPP $CPPFLAGS' 64554 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64555 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64556 ac_compiler_gnu=$ac_cv_c_compiler_gnu 64557 64558 OLD_CFLAGS="$CFLAGS" 64559 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 64560 OLD_LIBS="$LIBS" 64561 LIBS="$LIBS $LIBFFI_LIBS" 64562 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64563 /* end confdefs.h. */ 64564 #include <ffi.h> 64565 int 64566 main () 64567 { 64568 64569 ffi_call(NULL, NULL, NULL, NULL); 64570 return 0; 64571 64572 ; 64573 return 0; 64574 } 64575 _ACEOF 64576 if ac_fn_c_try_link "$LINENO"; then : 64577 LIBFFI_WORKS=yes 64578 else 64579 LIBFFI_WORKS=no 64580 64581 fi 64582 rm -f core conftest.err conftest.$ac_objext \ 64583 conftest$ac_exeext conftest.$ac_ext 64584 CFLAGS="$OLD_CFLAGS" 64585 LIBS="$OLD_LIBS" 64586 ac_ext=cpp 64587 ac_cpp='$CXXCPP $CPPFLAGS' 64588 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64589 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64590 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 64591 64592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 64593 $as_echo "$LIBFFI_WORKS" >&6; } 64594 64595 if test "x$LIBFFI_WORKS" = xno; then 64596 64597 # Print a helpful message on how to acquire the necessary build dependency. 64598 # ffi is the help tag: freetype, cups, alsa etc 64599 MISSING_DEPENDENCY=ffi 64600 64601 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64602 cygwin_help $MISSING_DEPENDENCY 64603 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64604 msys_help $MISSING_DEPENDENCY 64605 else 64606 PKGHANDLER_COMMAND= 64607 64608 case $PKGHANDLER in 64609 apt-get) 64610 apt_help $MISSING_DEPENDENCY ;; 64611 yum) 64612 yum_help $MISSING_DEPENDENCY ;; 64613 brew) 64614 brew_help $MISSING_DEPENDENCY ;; 64615 port) 64616 port_help $MISSING_DEPENDENCY ;; 64617 pkgutil) 64618 pkgutil_help $MISSING_DEPENDENCY ;; 64619 pkgadd) 64620 pkgadd_help $MISSING_DEPENDENCY ;; 64621 esac 64622 64623 if test "x$PKGHANDLER_COMMAND" != x; then 64624 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64625 fi 64626 fi 64627 64628 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 64629 fi 64630 64631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi should be bundled" >&5 64632 $as_echo_n "checking if libffi should be bundled... " >&6; } 64633 if test "x$enable_libffi_bundling" = "x"; then 64634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64635 $as_echo "no" >&6; } 64636 ENABLE_LIBFFI_BUNDLING=false 64637 elif test "x$enable_libffi_bundling" = "xno"; then 64638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64639 $as_echo "no, forced" >&6; } 64640 ENABLE_LIBFFI_BUNDLING=false 64641 elif test "x$enable_libffi_bundling" = "xyes"; then 64642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64643 $as_echo "yes, forced" >&6; } 64644 ENABLE_LIBFFI_BUNDLING=true 64645 else 64646 as_fn_error $? "Invalid value for --enable-libffi-bundling" "$LINENO" 5 64647 fi 64648 64649 # Find the libffi.so.X to bundle 64650 if test "x${ENABLE_LIBFFI_BUNDLING}" = "xtrue"; then 64651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libffi lib file location" >&5 64652 $as_echo_n "checking for libffi lib file location... " >&6; } 64653 if test "x${LIBFFI_LIB_PATH}" != x; then 64654 if test -e ${LIBFFI_LIB_PATH}/libffi.so.?; then 64655 LIBFFI_LIB_FILE="${LIBFFI_LIB_PATH}/libffi.so.?" 64656 else 64657 as_fn_error $? "Could not locate libffi.so.? for bundling in ${LIBFFI_LIB_PATH}" "$LINENO" 5 64658 fi 64659 else 64660 # If we don't have an explicit path, look in a few obvious places 64661 if test "x${OPENJDK_TARGET_CPU}" = "xx86"; then 64662 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 64663 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 64664 elif test -e ${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.? ; then 64665 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.?" 64666 else 64667 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 64668 fi 64669 elif test "x${OPENJDK_TARGET_CPU}" = "xx86_64"; then 64670 if test -e ${SYSROOT}/usr/lib64/libffi.so.? ; then 64671 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib64/libffi.so.?" 64672 elif test -e ${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.? ; then 64673 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.?" 64674 else 64675 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 64676 fi 64677 else 64678 # Fallback on the default /usr/lib dir 64679 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 64680 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 64681 else 64682 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 64683 fi 64684 fi 64685 fi 64686 # Make sure the wildcard is evaluated 64687 LIBFFI_LIB_FILE="$(ls ${LIBFFI_LIB_FILE})" 64688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${LIBFFI_LIB_FILE}" >&5 64689 $as_echo "${LIBFFI_LIB_FILE}" >&6; } 64690 fi 64691 fi 64692 64693 64694 64695 64696 64697 64698 64699 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 64700 # Extract the first word of "llvm-config", so it can be a program name with args. 64701 set dummy llvm-config; ac_word=$2 64702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64703 $as_echo_n "checking for $ac_word... " >&6; } 64704 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 64705 $as_echo_n "(cached) " >&6 64706 else 64707 if test -n "$LLVM_CONFIG"; then 64708 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 64709 else 64710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64711 for as_dir in $PATH 64712 do 64713 IFS=$as_save_IFS 64714 test -z "$as_dir" && as_dir=. 64715 for ac_exec_ext in '' $ac_executable_extensions; do 64716 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64717 ac_cv_prog_LLVM_CONFIG="llvm-config" 64718 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64719 break 2 64720 fi 64721 done 64722 done 64723 IFS=$as_save_IFS 64724 64725 fi 64726 fi 64727 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 64728 if test -n "$LLVM_CONFIG"; then 64729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 64730 $as_echo "$LLVM_CONFIG" >&6; } 64731 else 64732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64733 $as_echo "no" >&6; } 64734 fi 64735 64736 64737 64738 if test "x$LLVM_CONFIG" != xllvm-config; then 64739 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 64740 fi 64741 64742 llvm_components="jit mcjit engine nativecodegen native" 64743 unset LLVM_CFLAGS 64744 for flag in $("$LLVM_CONFIG" --cxxflags); do 64745 if echo "${flag}" | grep -q '^-[ID]'; then 64746 if test "${flag}" != "-D_DEBUG" ; then 64747 if test "${LLVM_CFLAGS}" != "" ; then 64748 LLVM_CFLAGS="${LLVM_CFLAGS} " 64749 fi 64750 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 64751 fi 64752 fi 64753 done 64754 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 64755 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 64756 64757 unset LLVM_LDFLAGS 64758 for flag in $("${LLVM_CONFIG}" --ldflags); do 64759 if echo "${flag}" | grep -q '^-L'; then 64760 if test "${LLVM_LDFLAGS}" != ""; then 64761 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 64762 fi 64763 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 64764 fi 64765 done 64766 64767 unset LLVM_LIBS 64768 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 64769 if echo "${flag}" | grep -q '^-l'; then 64770 if test "${LLVM_LIBS}" != ""; then 64771 LLVM_LIBS="${LLVM_LIBS} " 64772 fi 64773 LLVM_LIBS="${LLVM_LIBS}${flag}" 64774 fi 64775 done 64776 64777 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 64778 # always properly detect -ltinfo 64779 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 64780 64781 64782 64783 64784 fi 64785 64786 64787 64788 # Check whether --with-libjpeg was given. 64789 if test "${with_libjpeg+set}" = set; then : 64790 withval=$with_libjpeg; 64791 fi 64792 64793 64794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 64795 $as_echo_n "checking for which libjpeg to use... " >&6; } 64796 # default is bundled 64797 DEFAULT_LIBJPEG=bundled 64798 # if user didn't specify, use DEFAULT_LIBJPEG 64799 if test "x${with_libjpeg}" = "x"; then 64800 with_libjpeg=${DEFAULT_LIBJPEG} 64801 fi 64802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 64803 $as_echo "${with_libjpeg}" >&6; } 64804 64805 if test "x${with_libjpeg}" = "xbundled"; then 64806 USE_EXTERNAL_LIBJPEG=false 64807 elif test "x${with_libjpeg}" = "xsystem"; then 64808 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 64809 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 64810 64811 else 64812 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 64813 fi 64814 64815 64816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 64817 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 64818 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 64819 $as_echo_n "(cached) " >&6 64820 else 64821 ac_check_lib_save_LIBS=$LIBS 64822 LIBS="-ljpeg $LIBS" 64823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64824 /* end confdefs.h. */ 64825 64826 /* Override any GCC internal prototype to avoid an error. 64827 Use char because int might match the return type of a GCC 64828 builtin and then its argument prototype would still apply. */ 64829 #ifdef __cplusplus 64830 extern "C" 64831 #endif 64832 char jpeg_CreateDecompress (); 64833 int 64834 main () 64835 { 64836 return jpeg_CreateDecompress (); 64837 ; 64838 return 0; 64839 } 64840 _ACEOF 64841 if ac_fn_cxx_try_link "$LINENO"; then : 64842 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 64843 else 64844 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 64845 fi 64846 rm -f core conftest.err conftest.$ac_objext \ 64847 conftest$ac_exeext conftest.$ac_ext 64848 LIBS=$ac_check_lib_save_LIBS 64849 fi 64850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 64851 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 64852 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 64853 cat >>confdefs.h <<_ACEOF 64854 #define HAVE_LIBJPEG 1 64855 _ACEOF 64856 64857 LIBS="-ljpeg $LIBS" 64858 64859 else 64860 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 64861 fi 64862 64863 64864 USE_EXTERNAL_LIBJPEG=true 64865 else 64866 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 64867 fi 64868 64869 64870 64871 64872 64873 # Check whether --with-giflib was given. 64874 if test "${with_giflib+set}" = set; then : 64875 withval=$with_giflib; 64876 fi 64877 64878 64879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 64880 $as_echo_n "checking for which giflib to use... " >&6; } 64881 # default is bundled 64882 DEFAULT_GIFLIB=bundled 64883 # if user didn't specify, use DEFAULT_GIFLIB 64884 if test "x${with_giflib}" = "x"; then 64885 with_giflib=${DEFAULT_GIFLIB} 64886 fi 64887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 64888 $as_echo "${with_giflib}" >&6; } 64889 64890 if test "x${with_giflib}" = "xbundled"; then 64891 USE_EXTERNAL_LIBGIF=false 64892 elif test "x${with_giflib}" = "xsystem"; then 64893 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 64894 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 64895 64896 else 64897 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 64898 fi 64899 64900 64901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 64902 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 64903 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 64904 $as_echo_n "(cached) " >&6 64905 else 64906 ac_check_lib_save_LIBS=$LIBS 64907 LIBS="-lgif $LIBS" 64908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64909 /* end confdefs.h. */ 64910 64911 /* Override any GCC internal prototype to avoid an error. 64912 Use char because int might match the return type of a GCC 64913 builtin and then its argument prototype would still apply. */ 64914 #ifdef __cplusplus 64915 extern "C" 64916 #endif 64917 char DGifGetCode (); 64918 int 64919 main () 64920 { 64921 return DGifGetCode (); 64922 ; 64923 return 0; 64924 } 64925 _ACEOF 64926 if ac_fn_cxx_try_link "$LINENO"; then : 64927 ac_cv_lib_gif_DGifGetCode=yes 64928 else 64929 ac_cv_lib_gif_DGifGetCode=no 64930 fi 64931 rm -f core conftest.err conftest.$ac_objext \ 64932 conftest$ac_exeext conftest.$ac_ext 64933 LIBS=$ac_check_lib_save_LIBS 64934 fi 64935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 64936 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 64937 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 64938 cat >>confdefs.h <<_ACEOF 64939 #define HAVE_LIBGIF 1 64940 _ACEOF 64941 64942 LIBS="-lgif $LIBS" 64943 64944 else 64945 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 64946 fi 64947 64948 64949 USE_EXTERNAL_LIBGIF=true 64950 else 64951 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 64952 fi 64953 64954 64955 64956 64957 64958 # Check whether --with-libpng was given. 64959 if test "${with_libpng+set}" = set; then : 64960 withval=$with_libpng; 64961 fi 64962 64963 64964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 64965 $as_echo_n "checking for which libpng to use... " >&6; } 64966 64967 # default is bundled 64968 DEFAULT_LIBPNG=bundled 64969 # if user didn't specify, use DEFAULT_LIBPNG 64970 if test "x${with_libpng}" = "x"; then 64971 with_libpng=${DEFAULT_LIBPNG} 64972 fi 64973 64974 if test "x${with_libpng}" = "xbundled"; then 64975 USE_EXTERNAL_LIBPNG=false 64976 PNG_CFLAGS="" 64977 PNG_LIBS="" 64978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 64979 $as_echo "bundled" >&6; } 64980 elif test "x${with_libpng}" = "xsystem"; then 64981 64982 pkg_failed=no 64983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 64984 $as_echo_n "checking for PNG... " >&6; } 64985 64986 if test -n "$PNG_CFLAGS"; then 64987 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 64988 elif test -n "$PKG_CONFIG"; then 64989 if test -n "$PKG_CONFIG" && \ 64990 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 64991 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 64992 ac_status=$? 64993 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64994 test $ac_status = 0; }; then 64995 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 64996 else 64997 pkg_failed=yes 64998 fi 64999 else 65000 pkg_failed=untried 65001 fi 65002 if test -n "$PNG_LIBS"; then 65003 pkg_cv_PNG_LIBS="$PNG_LIBS" 65004 elif test -n "$PKG_CONFIG"; then 65005 if test -n "$PKG_CONFIG" && \ 65006 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 65007 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 65008 ac_status=$? 65009 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65010 test $ac_status = 0; }; then 65011 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 65012 else 65013 pkg_failed=yes 65014 fi 65015 else 65016 pkg_failed=untried 65017 fi 65018 65019 65020 65021 if test $pkg_failed = yes; then 65022 65023 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 65024 _pkg_short_errors_supported=yes 65025 else 65026 _pkg_short_errors_supported=no 65027 fi 65028 if test $_pkg_short_errors_supported = yes; then 65029 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 65030 else 65031 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 65032 fi 65033 # Put the nasty error message in config.log where it belongs 65034 echo "$PNG_PKG_ERRORS" >&5 65035 65036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65037 $as_echo "no" >&6; } 65038 LIBPNG_FOUND=no 65039 elif test $pkg_failed = untried; then 65040 LIBPNG_FOUND=no 65041 else 65042 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 65043 PNG_LIBS=$pkg_cv_PNG_LIBS 65044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65045 $as_echo "yes" >&6; } 65046 LIBPNG_FOUND=yes 65047 fi 65048 if test "x${LIBPNG_FOUND}" = "xyes"; then 65049 # PKG_CHECK_MODULES will set PNG_CFLAGS and PNG_LIBS 65050 USE_EXTERNAL_LIBPNG=true 65051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 65052 $as_echo "system" >&6; } 65053 else 65054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 65055 $as_echo "system not found" >&6; } 65056 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 65057 fi 65058 else 65059 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 65060 fi 65061 65062 65063 65064 65065 65066 65067 65068 # Check whether --with-zlib was given. 65069 if test "${with_zlib+set}" = set; then : 65070 withval=$with_zlib; 65071 fi 65072 65073 65074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 65075 $as_echo_n "checking for compress in -lz... " >&6; } 65076 if ${ac_cv_lib_z_compress+:} false; then : 65077 $as_echo_n "(cached) " >&6 65078 else 65079 ac_check_lib_save_LIBS=$LIBS 65080 LIBS="-lz $LIBS" 65081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65082 /* end confdefs.h. */ 65083 65084 /* Override any GCC internal prototype to avoid an error. 65085 Use char because int might match the return type of a GCC 65086 builtin and then its argument prototype would still apply. */ 65087 #ifdef __cplusplus 65088 extern "C" 65089 #endif 65090 char compress (); 65091 int 65092 main () 65093 { 65094 return compress (); 65095 ; 65096 return 0; 65097 } 65098 _ACEOF 65099 if ac_fn_cxx_try_link "$LINENO"; then : 65100 ac_cv_lib_z_compress=yes 65101 else 65102 ac_cv_lib_z_compress=no 65103 fi 65104 rm -f core conftest.err conftest.$ac_objext \ 65105 conftest$ac_exeext conftest.$ac_ext 65106 LIBS=$ac_check_lib_save_LIBS 65107 fi 65108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 65109 $as_echo "$ac_cv_lib_z_compress" >&6; } 65110 if test "x$ac_cv_lib_z_compress" = xyes; then : 65111 ZLIB_FOUND=yes 65112 else 65113 ZLIB_FOUND=no 65114 fi 65115 65116 65117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 65118 $as_echo_n "checking for which zlib to use... " >&6; } 65119 65120 DEFAULT_ZLIB=system 65121 if test "x$OPENJDK_TARGET_OS" = xwindows; then 65122 # On windows default is bundled...on others default is system 65123 DEFAULT_ZLIB=bundled 65124 fi 65125 65126 if test "x${ZLIB_FOUND}" != "xyes"; then 65127 # If we don't find any system...set default to bundled 65128 DEFAULT_ZLIB=bundled 65129 fi 65130 65131 # If user didn't specify, use DEFAULT_ZLIB 65132 if test "x${with_zlib}" = "x"; then 65133 with_zlib=${DEFAULT_ZLIB} 65134 fi 65135 65136 if test "x${with_zlib}" = "xbundled"; then 65137 USE_EXTERNAL_LIBZ=false 65138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 65139 $as_echo "bundled" >&6; } 65140 elif test "x${with_zlib}" = "xsystem"; then 65141 if test "x${ZLIB_FOUND}" = "xyes"; then 65142 USE_EXTERNAL_LIBZ=true 65143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 65144 $as_echo "system" >&6; } 65145 else 65146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 65147 $as_echo "system not found" >&6; } 65148 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 65149 fi 65150 else 65151 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 65152 fi 65153 65154 65155 65156 65157 65158 # Check whether --with-lcms was given. 65159 if test "${with_lcms+set}" = set; then : 65160 withval=$with_lcms; 65161 fi 65162 65163 65164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 65165 $as_echo_n "checking for which lcms to use... " >&6; } 65166 65167 DEFAULT_LCMS=bundled 65168 # If user didn't specify, use DEFAULT_LCMS 65169 if test "x${with_lcms}" = "x"; then 65170 with_lcms=${DEFAULT_LCMS} 65171 fi 65172 65173 if test "x${with_lcms}" = "xbundled"; then 65174 USE_EXTERNAL_LCMS=false 65175 LCMS_CFLAGS="" 65176 LCMS_LIBS="" 65177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 65178 $as_echo "bundled" >&6; } 65179 elif test "x${with_lcms}" = "xsystem"; then 65180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 65181 $as_echo "system" >&6; } 65182 65183 pkg_failed=no 65184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 65185 $as_echo_n "checking for LCMS... " >&6; } 65186 65187 if test -n "$LCMS_CFLAGS"; then 65188 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 65189 elif test -n "$PKG_CONFIG"; then 65190 if test -n "$PKG_CONFIG" && \ 65191 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 65192 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 65193 ac_status=$? 65194 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65195 test $ac_status = 0; }; then 65196 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 65197 else 65198 pkg_failed=yes 65199 fi 65200 else 65201 pkg_failed=untried 65202 fi 65203 if test -n "$LCMS_LIBS"; then 65204 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 65205 elif test -n "$PKG_CONFIG"; then 65206 if test -n "$PKG_CONFIG" && \ 65207 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 65208 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 65209 ac_status=$? 65210 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 65211 test $ac_status = 0; }; then 65212 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 65213 else 65214 pkg_failed=yes 65215 fi 65216 else 65217 pkg_failed=untried 65218 fi 65219 65220 65221 65222 if test $pkg_failed = yes; then 65223 65224 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 65225 _pkg_short_errors_supported=yes 65226 else 65227 _pkg_short_errors_supported=no 65228 fi 65229 if test $_pkg_short_errors_supported = yes; then 65230 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 65231 else 65232 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 65233 fi 65234 # Put the nasty error message in config.log where it belongs 65235 echo "$LCMS_PKG_ERRORS" >&5 65236 65237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65238 $as_echo "no" >&6; } 65239 LCMS_FOUND=no 65240 elif test $pkg_failed = untried; then 65241 LCMS_FOUND=no 65242 else 65243 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 65244 LCMS_LIBS=$pkg_cv_LCMS_LIBS 65245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65246 $as_echo "yes" >&6; } 65247 LCMS_FOUND=yes 65248 fi 65249 if test "x${LCMS_FOUND}" = "xyes"; then 65250 # PKG_CHECK_MODULES will set LCMS_CFLAGS and LCMS_LIBS 65251 USE_EXTERNAL_LCMS=true 65252 else 65253 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 65254 fi 65255 else 65256 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 65257 fi 65258 65259 65260 65261 65262 65263 65264 65265 65266 65267 65268 65269 65270 65271 # Setup libm (the maths library) 65272 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 65273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 65274 $as_echo_n "checking for cos in -lm... " >&6; } 65275 if ${ac_cv_lib_m_cos+:} false; then : 65276 $as_echo_n "(cached) " >&6 65277 else 65278 ac_check_lib_save_LIBS=$LIBS 65279 LIBS="-lm $LIBS" 65280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65281 /* end confdefs.h. */ 65282 65283 /* Override any GCC internal prototype to avoid an error. 65284 Use char because int might match the return type of a GCC 65285 builtin and then its argument prototype would still apply. */ 65286 #ifdef __cplusplus 65287 extern "C" 65288 #endif 65289 char cos (); 65290 int 65291 main () 65292 { 65293 return cos (); 65294 ; 65295 return 0; 65296 } 65297 _ACEOF 65298 if ac_fn_cxx_try_link "$LINENO"; then : 65299 ac_cv_lib_m_cos=yes 65300 else 65301 ac_cv_lib_m_cos=no 65302 fi 65303 rm -f core conftest.err conftest.$ac_objext \ 65304 conftest$ac_exeext conftest.$ac_ext 65305 LIBS=$ac_check_lib_save_LIBS 65306 fi 65307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 65308 $as_echo "$ac_cv_lib_m_cos" >&6; } 65309 if test "x$ac_cv_lib_m_cos" = xyes; then : 65310 cat >>confdefs.h <<_ACEOF 65311 #define HAVE_LIBM 1 65312 _ACEOF 65313 65314 LIBS="-lm $LIBS" 65315 65316 else 65317 65318 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 65319 $as_echo "$as_me: Maths library was not found" >&6;} 65320 65321 fi 65322 65323 LIBM="-lm" 65324 else 65325 LIBM="" 65326 fi 65327 65328 65329 # Setup libdl (for dynamic library loading) 65330 save_LIBS="$LIBS" 65331 LIBS="" 65332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 65333 $as_echo_n "checking for dlopen in -ldl... " >&6; } 65334 if ${ac_cv_lib_dl_dlopen+:} false; then : 65335 $as_echo_n "(cached) " >&6 65336 else 65337 ac_check_lib_save_LIBS=$LIBS 65338 LIBS="-ldl $LIBS" 65339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65340 /* end confdefs.h. */ 65341 65342 /* Override any GCC internal prototype to avoid an error. 65343 Use char because int might match the return type of a GCC 65344 builtin and then its argument prototype would still apply. */ 65345 #ifdef __cplusplus 65346 extern "C" 65347 #endif 65348 char dlopen (); 65349 int 65350 main () 65351 { 65352 return dlopen (); 65353 ; 65354 return 0; 65355 } 65356 _ACEOF 65357 if ac_fn_cxx_try_link "$LINENO"; then : 65358 ac_cv_lib_dl_dlopen=yes 65359 else 65360 ac_cv_lib_dl_dlopen=no 65361 fi 65362 rm -f core conftest.err conftest.$ac_objext \ 65363 conftest$ac_exeext conftest.$ac_ext 65364 LIBS=$ac_check_lib_save_LIBS 65365 fi 65366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 65367 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 65368 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 65369 cat >>confdefs.h <<_ACEOF 65370 #define HAVE_LIBDL 1 65371 _ACEOF 65372 65373 LIBS="-ldl $LIBS" 65374 65375 fi 65376 65377 LIBDL="$LIBS" 65378 65379 LIBS="$save_LIBS" 65380 65381 # Deprecated libraries, keep the flags for backwards compatibility 65382 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 65383 65384 65385 # Check whether --with-dxsdk was given. 65386 if test "${with_dxsdk+set}" = set; then : 65387 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 65388 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 65389 fi 65390 65391 65392 65393 65394 # Check whether --with-dxsdk-lib was given. 65395 if test "${with_dxsdk_lib+set}" = set; then : 65396 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 65397 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 65398 fi 65399 65400 65401 65402 65403 # Check whether --with-dxsdk-include was given. 65404 if test "${with_dxsdk_include+set}" = set; then : 65405 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 65406 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 65407 fi 65408 65409 65410 fi 65411 65412 # Control if libzip can use mmap. Available for purposes of overriding. 65413 LIBZIP_CAN_USE_MMAP=true 65414 65415 65416 65417 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 65418 # Find the root of the Solaris Studio installation from the compiler path 65419 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 65420 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 65421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 65422 $as_echo_n "checking for libstlport.so.1... " >&6; } 65423 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 65424 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 65425 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 65426 fi 65427 if test -f "$STLPORT_LIB"; then 65428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 65429 $as_echo "yes, $STLPORT_LIB" >&6; } 65430 65431 # Only process if variable expands to non-empty 65432 65433 if test "x$STLPORT_LIB" != x; then 65434 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65435 65436 # Input might be given as Windows format, start by converting to 65437 # unix format. 65438 path="$STLPORT_LIB" 65439 new_path=`$CYGPATH -u "$path"` 65440 65441 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 65442 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 65443 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 65444 # "foo.exe" is OK but "foo" is an error. 65445 # 65446 # This test is therefore slightly more accurate than "test -f" to check for file precense. 65447 # It is also a way to make sure we got the proper file name for the real test later on. 65448 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 65449 if test "x$test_shortpath" = x; then 65450 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 65451 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 65452 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 65453 fi 65454 65455 # Call helper function which possibly converts this using DOS-style short mode. 65456 # If so, the updated path is stored in $new_path. 65457 65458 input_path="$new_path" 65459 # Check if we need to convert this using DOS-style short mode. If the path 65460 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65461 # take no chances and rewrite it. 65462 # Note: m4 eats our [], so we need to use [ and ] instead. 65463 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 65464 if test "x$has_forbidden_chars" != x; then 65465 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65466 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 65467 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 65468 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 65469 # Going to short mode and back again did indeed matter. Since short mode is 65470 # case insensitive, let's make it lowercase to improve readability. 65471 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65472 # Now convert it back to Unix-style (cygpath) 65473 input_path=`$CYGPATH -u "$shortmode_path"` 65474 new_path="$input_path" 65475 fi 65476 fi 65477 65478 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 65479 if test "x$test_cygdrive_prefix" = x; then 65480 # As a simple fix, exclude /usr/bin since it's not a real path. 65481 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 65482 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 65483 # a path prefixed by /cygdrive for fixpath to work. 65484 new_path="$CYGWIN_ROOT_PATH$input_path" 65485 fi 65486 fi 65487 65488 65489 if test "x$path" != "x$new_path"; then 65490 STLPORT_LIB="$new_path" 65491 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 65492 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 65493 fi 65494 65495 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65496 65497 path="$STLPORT_LIB" 65498 has_colon=`$ECHO $path | $GREP ^.:` 65499 new_path="$path" 65500 if test "x$has_colon" = x; then 65501 # Not in mixed or Windows style, start by that. 65502 new_path=`cmd //c echo $path` 65503 fi 65504 65505 65506 input_path="$new_path" 65507 # Check if we need to convert this using DOS-style short mode. If the path 65508 # contains just simple characters, use it. Otherwise (spaces, weird characters), 65509 # take no chances and rewrite it. 65510 # Note: m4 eats our [], so we need to use [ and ] instead. 65511 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 65512 if test "x$has_forbidden_chars" != x; then 65513 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 65514 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 65515 fi 65516 65517 65518 windows_path="$new_path" 65519 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65520 unix_path=`$CYGPATH -u "$windows_path"` 65521 new_path="$unix_path" 65522 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65523 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 65524 new_path="$unix_path" 65525 fi 65526 65527 if test "x$path" != "x$new_path"; then 65528 STLPORT_LIB="$new_path" 65529 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 65530 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 65531 fi 65532 65533 # Save the first 10 bytes of this path to the storage, so fixpath can work. 65534 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 65535 65536 else 65537 # We're on a unix platform. Hooray! :) 65538 path="$STLPORT_LIB" 65539 has_space=`$ECHO "$path" | $GREP " "` 65540 if test "x$has_space" != x; then 65541 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 65542 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 65543 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 65544 fi 65545 65546 # Use eval to expand a potential ~ 65547 eval path="$path" 65548 if test ! -f "$path" && test ! -d "$path"; then 65549 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 65550 fi 65551 65552 if test -d "$path"; then 65553 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 65554 else 65555 dir="`$DIRNAME "$path"`" 65556 base="`$BASENAME "$path"`" 65557 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 65558 fi 65559 fi 65560 fi 65561 65562 else 65563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 65564 $as_echo "no, not found at $STLPORT_LIB" >&6; } 65565 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 65566 fi 65567 65568 fi 65569 65570 65571 65572 65573 65574 65575 65576 65577 65578 65579 65580 65581 65582 65583 # Hotspot setup depends on lib checks. 65584 65585 65586 # The user can in some cases supply additional jvm features. For the custom 65587 # variant, this defines the entire variant. 65588 65589 # Check whether --with-jvm-features was given. 65590 if test "${with_jvm_features+set}" = set; then : 65591 withval=$with_jvm_features; 65592 fi 65593 65594 if test "x$with_jvm_features" != x; then 65595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 65596 $as_echo_n "checking additional JVM features... " >&6; } 65597 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 65598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 65599 $as_echo "$JVM_FEATURES" >&6; } 65600 fi 65601 65602 # Override hotspot cpu definitions for ARM platforms 65603 if test "x$OPENJDK_TARGET_CPU" = xarm; then 65604 HOTSPOT_TARGET_CPU=arm_32 65605 HOTSPOT_TARGET_CPU_DEFINE="ARM32" 65606 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 65607 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 65608 elif test "x$OPENJDK_TARGET_CPU" = xaarch64 && test "x$HOTSPOT_TARGET_CPU_PORT" = xarm64; then 65609 HOTSPOT_TARGET_CPU=arm_64 65610 HOTSPOT_TARGET_CPU_ARCH=arm 65611 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 65612 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 65613 fi 65614 65615 # Verify that dependencies are met for explicitly set features. 65616 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 65617 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 65618 fi 65619 65620 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 65621 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 65622 fi 65623 65624 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 65625 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 65626 fi 65627 65628 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 65629 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 65630 fi 65631 65632 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 65633 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 65634 fi 65635 65636 # Turn on additional features based on other parts of configure 65637 if test "x$INCLUDE_DTRACE" = "xtrue"; then 65638 JVM_FEATURES="$JVM_FEATURES dtrace" 65639 else 65640 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 65641 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 65642 fi 65643 fi 65644 65645 if test "x$STATIC_BUILD" = "xtrue"; then 65646 JVM_FEATURES="$JVM_FEATURES static-build" 65647 else 65648 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 65649 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 65650 fi 65651 fi 65652 65653 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 65654 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 65655 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 65656 fi 65657 fi 65658 65659 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 65660 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 65661 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 65662 fi 65663 fi 65664 65665 # Only enable jvmci on x86_64, sparcv9 and aarch64. 65666 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 65667 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 65668 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 65669 JVM_FEATURES_jvmci="jvmci" 65670 else 65671 JVM_FEATURES_jvmci="" 65672 fi 65673 65674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jdk.internal.vm.compiler should be built" >&5 65675 $as_echo_n "checking if jdk.internal.vm.compiler should be built... " >&6; } 65676 if [[ " $JVM_FEATURES " =~ " graal " ]] ; then 65677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65678 $as_echo "yes, forced" >&6; } 65679 if test "x$JVM_FEATURES_jvmci" != "xjvmci" ; then 65680 as_fn_error $? "Specified JVM feature 'graal' requires feature 'jvmci'" "$LINENO" 5 65681 fi 65682 INCLUDE_GRAAL="true" 65683 else 65684 # By default enable graal build on linux-x64 or where AOT is available. 65685 # graal build requires jvmci. 65686 if test "x$JVM_FEATURES_jvmci" = "xjvmci" && \ 65687 (test "x$OPENJDK_TARGET_CPU" = "xx86_64" && \ 65688 test "x$OPENJDK_TARGET_OS" = "xlinux" || \ 65689 test "x$ENABLE_AOT" = "xtrue") ; then 65690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65691 $as_echo "yes" >&6; } 65692 JVM_FEATURES_graal="graal" 65693 INCLUDE_GRAAL="true" 65694 else 65695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65696 $as_echo "no" >&6; } 65697 JVM_FEATURES_graal="" 65698 INCLUDE_GRAAL="false" 65699 fi 65700 fi 65701 65702 65703 65704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 65705 $as_echo_n "checking if aot should be enabled... " >&6; } 65706 if test "x$ENABLE_AOT" = "xtrue"; then 65707 if test "x$enable_aot" = "xyes"; then 65708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65709 $as_echo "yes, forced" >&6; } 65710 else 65711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65712 $as_echo "yes" >&6; } 65713 fi 65714 JVM_FEATURES_aot="aot" 65715 else 65716 if test "x$enable_aot" = "xno"; then 65717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65718 $as_echo "no, forced" >&6; } 65719 else 65720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65721 $as_echo "no" >&6; } 65722 fi 65723 JVM_FEATURES_aot="" 65724 fi 65725 65726 if test "x$OPENJDK_TARGET_CPU" = xarm ; then 65727 # Default to use link time optimizations on minimal on arm 65728 JVM_FEATURES_link_time_opt="link-time-opt" 65729 else 65730 JVM_FEATURES_link_time_opt="" 65731 fi 65732 65733 # All variants but minimal (and custom) get these features 65734 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti vm-structs jni-check services management all-gcs nmt" 65735 if test "x$ENABLE_CDS" = "xtrue"; then 65736 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES cds" 65737 fi 65738 65739 # Enable features depending on variant. 65740 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci $JVM_FEATURES_aot $JVM_FEATURES_graal" 65741 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 65742 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 65743 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES $JVM_FEATURES_link_time_opt" 65744 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 65745 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 65746 JVM_FEATURES_custom="$JVM_FEATURES" 65747 65748 65749 65750 65751 65752 65753 65754 65755 65756 # Used for verification of Makefiles by check-jvm-feature 65757 65758 65759 # We don't support --with-jvm-interpreter anymore, use zero instead. 65760 65761 65762 # Check whether --with-jvm-interpreter was given. 65763 if test "${with_jvm_interpreter+set}" = set; then : 65764 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 65765 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 65766 fi 65767 65768 65769 65770 65771 ############################################################################### 65772 # 65773 # We need to do some final tweaking, when everything else is done. 65774 # 65775 ############################################################################### 65776 65777 65778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 65779 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 65780 65781 if test -d "${TOPDIR}/src/jdk.crypto.ec/share/native/libsunec/impl"; then 65782 ENABLE_INTREE_EC=true 65783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65784 $as_echo "yes" >&6; } 65785 else 65786 ENABLE_INTREE_EC=false 65787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65788 $as_echo "no" >&6; } 65789 fi 65790 65791 65792 65793 65794 # Check whether --enable-jtreg-failure-handler was given. 65795 if test "${enable_jtreg_failure_handler+set}" = set; then : 65796 enableval=$enable_jtreg_failure_handler; 65797 fi 65798 65799 65800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 65801 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 65802 65803 if test "x$enable_jtreg_failure_handler" = "xyes"; then 65804 if test "x$JT_HOME" = "x"; then 65805 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 65806 else 65807 BUILD_FAILURE_HANDLER=true 65808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65809 $as_echo "yes, forced" >&6; } 65810 fi 65811 elif test "x$enable_jtreg_failure_handler" = "xno"; then 65812 BUILD_FAILURE_HANDLER=false 65813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65814 $as_echo "no, forced" >&6; } 65815 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 65816 || test "x$enable_jtreg_failure_handler" = "x"; then 65817 if test "x$JT_HOME" = "x"; then 65818 BUILD_FAILURE_HANDLER=false 65819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 65820 $as_echo "no, missing jtreg" >&6; } 65821 else 65822 BUILD_FAILURE_HANDLER=true 65823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 65824 $as_echo "yes, jtreg present" >&6; } 65825 fi 65826 else 65827 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 65828 fi 65829 65830 65831 65832 65833 # Check whether --enable-generate-classlist was given. 65834 if test "${enable_generate_classlist+set}" = set; then : 65835 enableval=$enable_generate_classlist; 65836 fi 65837 65838 65839 # Check if it's likely that it's possible to generate the classlist. Depending 65840 # on exact jvm configuration it could be possible anyway. 65841 if test "x$ENABLE_CDS" = "xtrue" && ( [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ); then 65842 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 65843 else 65844 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 65845 fi 65846 65847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 65848 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 65849 if test "x$enable_generate_classlist" = "xyes"; then 65850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 65851 $as_echo "yes, forced" >&6; } 65852 ENABLE_GENERATE_CLASSLIST="true" 65853 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 65854 { $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 65855 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS and enable-cds=$ENABLE_CDS" >&2;} 65856 fi 65857 elif test "x$enable_generate_classlist" = "xno"; then 65858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65859 $as_echo "no, forced" >&6; } 65860 ENABLE_GENERATE_CLASSLIST="false" 65861 elif test "x$enable_generate_classlist" = "x"; then 65862 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 65863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65864 $as_echo "yes" >&6; } 65865 ENABLE_GENERATE_CLASSLIST="true" 65866 else 65867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65868 $as_echo "no" >&6; } 65869 ENABLE_GENERATE_CLASSLIST="false" 65870 fi 65871 else 65872 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 65873 fi 65874 65875 65876 65877 65878 ############################################################################### 65879 # 65880 # Configure parts of the build that only affect the build performance, 65881 # not the result. 65882 # 65883 ############################################################################### 65884 65885 65886 # How many cores do we have on this build system? 65887 65888 # Check whether --with-num-cores was given. 65889 if test "${with_num_cores+set}" = set; then : 65890 withval=$with_num_cores; 65891 fi 65892 65893 if test "x$with_num_cores" = x; then 65894 # The number of cores were not specified, try to probe them. 65895 65896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 65897 $as_echo_n "checking for number of cores... " >&6; } 65898 NUM_CORES=1 65899 FOUND_CORES=no 65900 65901 if test -f /proc/cpuinfo; then 65902 # Looks like a Linux (or cygwin) system 65903 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 65904 FOUND_CORES=yes 65905 elif test -x /usr/sbin/psrinfo; then 65906 # Looks like a Solaris system 65907 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 65908 FOUND_CORES=yes 65909 elif test -x /usr/sbin/sysctl; then 65910 # Looks like a MacOSX system 65911 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 65912 FOUND_CORES=yes 65913 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 65914 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 65915 FOUND_CORES=yes 65916 elif test -n "$NUMBER_OF_PROCESSORS"; then 65917 # On windows, look in the env 65918 NUM_CORES=$NUMBER_OF_PROCESSORS 65919 FOUND_CORES=yes 65920 fi 65921 65922 if test "x$FOUND_CORES" = xyes; then 65923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 65924 $as_echo "$NUM_CORES" >&6; } 65925 else 65926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 65927 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 65928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 65929 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 65930 fi 65931 65932 else 65933 NUM_CORES=$with_num_cores 65934 fi 65935 65936 65937 65938 # How much memory do we have on this build system? 65939 65940 # Check whether --with-memory-size was given. 65941 if test "${with_memory_size+set}" = set; then : 65942 withval=$with_memory_size; 65943 fi 65944 65945 if test "x$with_memory_size" = x; then 65946 # The memory size was not specified, try to probe it. 65947 65948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 65949 $as_echo_n "checking for memory size... " >&6; } 65950 # Default to 1024 MB 65951 MEMORY_SIZE=1024 65952 FOUND_MEM=no 65953 65954 if test -f /proc/meminfo; then 65955 # Looks like a Linux (or cygwin) system 65956 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 65957 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 65958 FOUND_MEM=yes 65959 elif test -x /usr/sbin/prtconf; then 65960 # Looks like a Solaris or AIX system 65961 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 65962 FOUND_MEM=yes 65963 elif test -x /usr/sbin/sysctl; then 65964 # Looks like a MacOSX system 65965 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 65966 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 65967 FOUND_MEM=yes 65968 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 65969 # Windows, but without cygwin 65970 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 65971 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 65972 FOUND_MEM=yes 65973 fi 65974 65975 if test "x$FOUND_MEM" = xyes; then 65976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 65977 $as_echo "$MEMORY_SIZE MB" >&6; } 65978 else 65979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 65980 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 65981 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 65982 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 65983 fi 65984 65985 else 65986 MEMORY_SIZE=$with_memory_size 65987 fi 65988 65989 65990 65991 # Provide a decent default number of parallel jobs for make depending on 65992 # number of cores, amount of memory and machine architecture. 65993 65994 # Check whether --with-jobs was given. 65995 if test "${with_jobs+set}" = set; then : 65996 withval=$with_jobs; 65997 fi 65998 65999 if test "x$with_jobs" = x; then 66000 # Number of jobs was not specified, calculate. 66001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 66002 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 66003 # Approximate memory in GB. 66004 memory_gb=`expr $MEMORY_SIZE / 1024` 66005 # Pick the lowest of memory in gb and number of cores. 66006 if test "$memory_gb" -lt "$NUM_CORES"; then 66007 JOBS="$memory_gb" 66008 else 66009 JOBS="$NUM_CORES" 66010 fi 66011 if test "$JOBS" -eq "0"; then 66012 JOBS=1 66013 fi 66014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 66015 $as_echo "$JOBS" >&6; } 66016 else 66017 JOBS=$with_jobs 66018 fi 66019 66020 66021 66022 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 66023 66024 # Check whether --with-test-jobs was given. 66025 if test "${with_test_jobs+set}" = set; then : 66026 withval=$with_test_jobs; 66027 fi 66028 66029 if test "x$with_test_jobs" = x; then 66030 TEST_JOBS=0 66031 else 66032 TEST_JOBS=$with_test_jobs 66033 fi 66034 66035 66036 66037 # Setup arguments for the boot jdk (after cores and memory have been setup) 66038 66039 ############################################################################## 66040 # 66041 # Specify jvm options for anything that is run with the Boot JDK. 66042 # Not all JVM:s accept the same arguments on the command line. 66043 # 66044 66045 # Check whether --with-boot-jdk-jvmargs was given. 66046 if test "${with_boot_jdk_jvmargs+set}" = set; then : 66047 withval=$with_boot_jdk_jvmargs; 66048 fi 66049 66050 66051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 66052 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 66053 66054 # Disable special log output when a debug build is used as Boot JDK... 66055 66056 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 66057 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 66058 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 66059 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66060 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66061 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66062 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 66063 JVM_ARG_OK=true 66064 else 66065 $ECHO "Arg failed:" >&5 66066 $ECHO "$OUTPUT" >&5 66067 JVM_ARG_OK=false 66068 fi 66069 66070 66071 # Force en-US environment 66072 66073 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 66074 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 66075 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 66076 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66077 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66078 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66079 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 66080 JVM_ARG_OK=true 66081 else 66082 $ECHO "Arg failed:" >&5 66083 $ECHO "$OUTPUT" >&5 66084 JVM_ARG_OK=false 66085 fi 66086 66087 66088 # Apply user provided options. 66089 66090 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 66091 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 66092 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 66093 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66094 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66095 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66096 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 66097 JVM_ARG_OK=true 66098 else 66099 $ECHO "Arg failed:" >&5 66100 $ECHO "$OUTPUT" >&5 66101 JVM_ARG_OK=false 66102 fi 66103 66104 66105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 66106 $as_echo "$boot_jdk_jvmargs" >&6; } 66107 66108 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 66109 JAVA_FLAGS=$boot_jdk_jvmargs 66110 66111 66112 66113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 66114 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 66115 66116 # Starting amount of heap memory. 66117 66118 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 66119 $ECHO "Command: $JAVA -Xms64M -version" >&5 66120 OUTPUT=`$JAVA -Xms64M -version 2>&1` 66121 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66122 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66123 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66124 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 66125 JVM_ARG_OK=true 66126 else 66127 $ECHO "Arg failed:" >&5 66128 $ECHO "$OUTPUT" >&5 66129 JVM_ARG_OK=false 66130 fi 66131 66132 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 66133 66134 # Maximum amount of heap memory and stack size. 66135 JVM_HEAP_LIMIT_32="1024" 66136 # Running a 64 bit JVM allows for and requires a bigger heap 66137 JVM_HEAP_LIMIT_64="1600" 66138 STACK_SIZE_32=768 66139 STACK_SIZE_64=1536 66140 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 66141 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 66142 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 66143 fi 66144 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 66145 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 66146 fi 66147 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 66148 JVM_HEAP_LIMIT_32=512 66149 JVM_HEAP_LIMIT_64=512 66150 fi 66151 66152 if test "x$BOOT_JDK_BITS" = "x32"; then 66153 STACK_SIZE=$STACK_SIZE_32 66154 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 66155 else 66156 STACK_SIZE=$STACK_SIZE_64 66157 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 66158 fi 66159 66160 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 66161 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 66162 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 66163 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66164 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66165 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66166 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 66167 JVM_ARG_OK=true 66168 else 66169 $ECHO "Arg failed:" >&5 66170 $ECHO "$OUTPUT" >&5 66171 JVM_ARG_OK=false 66172 fi 66173 66174 66175 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 66176 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 66177 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 66178 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66179 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66180 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66181 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 66182 JVM_ARG_OK=true 66183 else 66184 $ECHO "Arg failed:" >&5 66185 $ECHO "$OUTPUT" >&5 66186 JVM_ARG_OK=false 66187 fi 66188 66189 66190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 66191 $as_echo "$boot_jdk_jvmargs_big" >&6; } 66192 66193 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 66194 66195 66196 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 66197 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 66198 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 66199 else 66200 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 66201 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 66202 fi 66203 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 66204 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 66205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 66206 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 66207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 66208 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 66209 66210 66211 # By default, the main javac compilations use big 66212 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 66213 66214 66215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 66216 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 66217 66218 # Use serial gc for small short lived tools if possible 66219 66220 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 66221 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 66222 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 66223 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66224 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66225 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66226 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 66227 JVM_ARG_OK=true 66228 else 66229 $ECHO "Arg failed:" >&5 66230 $ECHO "$OUTPUT" >&5 66231 JVM_ARG_OK=false 66232 fi 66233 66234 66235 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 66236 $ECHO "Command: $JAVA -Xms32M -version" >&5 66237 OUTPUT=`$JAVA -Xms32M -version 2>&1` 66238 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66239 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66240 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66241 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 66242 JVM_ARG_OK=true 66243 else 66244 $ECHO "Arg failed:" >&5 66245 $ECHO "$OUTPUT" >&5 66246 JVM_ARG_OK=false 66247 fi 66248 66249 66250 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 66251 $ECHO "Command: $JAVA -Xmx512M -version" >&5 66252 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 66253 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66254 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66255 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66256 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 66257 JVM_ARG_OK=true 66258 else 66259 $ECHO "Arg failed:" >&5 66260 $ECHO "$OUTPUT" >&5 66261 JVM_ARG_OK=false 66262 fi 66263 66264 66265 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 66266 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 66267 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 66268 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66269 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66270 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66271 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 66272 JVM_ARG_OK=true 66273 else 66274 $ECHO "Arg failed:" >&5 66275 $ECHO "$OUTPUT" >&5 66276 JVM_ARG_OK=false 66277 fi 66278 66279 66280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 66281 $as_echo "$boot_jdk_jvmargs_small" >&6; } 66282 66283 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 66284 66285 66286 JAVA_TOOL_FLAGS_SMALL="" 66287 for f in $JAVA_FLAGS_SMALL; do 66288 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 66289 done 66290 66291 66292 66293 # Setup smart javac (after cores and memory have been setup) 66294 66295 66296 # Check whether --with-sjavac-server-java was given. 66297 if test "${with_sjavac_server_java+set}" = set; then : 66298 withval=$with_sjavac_server_java; 66299 fi 66300 66301 66302 if test "x$with_sjavac_server_java" != x; then 66303 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 66304 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 66305 if test "x$FOUND_VERSION" = x; then 66306 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 66307 fi 66308 else 66309 SJAVAC_SERVER_JAVA="$JAVA" 66310 fi 66311 66312 66313 if test "$MEMORY_SIZE" -gt "3000"; then 66314 if "$JAVA" -version 2>&1 | $GREP -q "64-Bit"; then 66315 JVM_64BIT=true 66316 fi 66317 fi 66318 66319 MX_VALUE=`expr $MEMORY_SIZE / 2` 66320 if test "$JVM_64BIT" = true; then 66321 # Set ms lower than mx since more than one instance of the server might 66322 # get launched at the same time before they figure out which instance won. 66323 MS_VALUE=512 66324 if test "$MX_VALUE" -gt "2048"; then 66325 MX_VALUE=2048 66326 fi 66327 else 66328 MS_VALUE=256 66329 if test "$MX_VALUE" -gt "1500"; then 66330 MX_VALUE=1500 66331 fi 66332 fi 66333 if test "$MX_VALUE" -lt "512"; then 66334 MX_VALUE=512 66335 fi 66336 66337 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 66338 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 66339 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 66340 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 66341 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 66342 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 66343 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 66344 JVM_ARG_OK=true 66345 else 66346 $ECHO "Arg failed:" >&5 66347 $ECHO "$OUTPUT" >&5 66348 JVM_ARG_OK=false 66349 fi 66350 66351 66352 66353 # Check whether --enable-sjavac was given. 66354 if test "${enable_sjavac+set}" = set; then : 66355 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 66356 else 66357 ENABLE_SJAVAC="no" 66358 fi 66359 66360 if test "x$JVM_ARG_OK" = "xfalse"; then 66361 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 66362 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 66363 ENABLE_SJAVAC="no" 66364 fi 66365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 66366 $as_echo_n "checking whether to use sjavac... " >&6; } 66367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 66368 $as_echo "$ENABLE_SJAVAC" >&6; } 66369 66370 66371 # Check whether --enable-javac-server was given. 66372 if test "${enable_javac_server+set}" = set; then : 66373 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 66374 else 66375 ENABLE_JAVAC_SERVER="yes" 66376 fi 66377 66378 if test "x$JVM_ARG_OK" = "xfalse"; then 66379 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 66380 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 66381 ENABLE_JAVAC_SERVER="no" 66382 fi 66383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 66384 $as_echo_n "checking whether to use javac server... " >&6; } 66385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 66386 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 66387 66388 66389 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 66390 # When using a server javac, the small client instances do not need much 66391 # resources. 66392 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 66393 fi 66394 66395 66396 # Setup use of icecc if requested 66397 66398 # Check whether --enable-icecc was given. 66399 if test "${enable_icecc+set}" = set; then : 66400 enableval=$enable_icecc; 66401 fi 66402 66403 66404 if test "x${enable_icecc}" = "xyes"; then 66405 66406 66407 66408 # Publish this variable in the help. 66409 66410 66411 if [ -z "${ICECC_CMD+x}" ]; then 66412 # The variable is not set by user, try to locate tool using the code snippet 66413 for ac_prog in icecc 66414 do 66415 # Extract the first word of "$ac_prog", so it can be a program name with args. 66416 set dummy $ac_prog; ac_word=$2 66417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66418 $as_echo_n "checking for $ac_word... " >&6; } 66419 if ${ac_cv_path_ICECC_CMD+:} false; then : 66420 $as_echo_n "(cached) " >&6 66421 else 66422 case $ICECC_CMD in 66423 [\\/]* | ?:[\\/]*) 66424 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 66425 ;; 66426 *) 66427 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66428 for as_dir in $PATH 66429 do 66430 IFS=$as_save_IFS 66431 test -z "$as_dir" && as_dir=. 66432 for ac_exec_ext in '' $ac_executable_extensions; do 66433 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66434 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 66435 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66436 break 2 66437 fi 66438 done 66439 done 66440 IFS=$as_save_IFS 66441 66442 ;; 66443 esac 66444 fi 66445 ICECC_CMD=$ac_cv_path_ICECC_CMD 66446 if test -n "$ICECC_CMD"; then 66447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 66448 $as_echo "$ICECC_CMD" >&6; } 66449 else 66450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66451 $as_echo "no" >&6; } 66452 fi 66453 66454 66455 test -n "$ICECC_CMD" && break 66456 done 66457 66458 else 66459 # The variable is set, but is it from the command line or the environment? 66460 66461 # Try to remove the string !ICECC_CMD! from our list. 66462 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 66463 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66464 # If it failed, the variable was not from the command line. Ignore it, 66465 # but warn the user (except for BASH, which is always set by the calling BASH). 66466 if test "xICECC_CMD" != xBASH; then 66467 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 66468 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 66469 fi 66470 # Try to locate tool using the code snippet 66471 for ac_prog in icecc 66472 do 66473 # Extract the first word of "$ac_prog", so it can be a program name with args. 66474 set dummy $ac_prog; ac_word=$2 66475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66476 $as_echo_n "checking for $ac_word... " >&6; } 66477 if ${ac_cv_path_ICECC_CMD+:} false; then : 66478 $as_echo_n "(cached) " >&6 66479 else 66480 case $ICECC_CMD in 66481 [\\/]* | ?:[\\/]*) 66482 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 66483 ;; 66484 *) 66485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66486 for as_dir in $PATH 66487 do 66488 IFS=$as_save_IFS 66489 test -z "$as_dir" && as_dir=. 66490 for ac_exec_ext in '' $ac_executable_extensions; do 66491 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66492 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 66493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66494 break 2 66495 fi 66496 done 66497 done 66498 IFS=$as_save_IFS 66499 66500 ;; 66501 esac 66502 fi 66503 ICECC_CMD=$ac_cv_path_ICECC_CMD 66504 if test -n "$ICECC_CMD"; then 66505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 66506 $as_echo "$ICECC_CMD" >&6; } 66507 else 66508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66509 $as_echo "no" >&6; } 66510 fi 66511 66512 66513 test -n "$ICECC_CMD" && break 66514 done 66515 66516 else 66517 # If it succeeded, then it was overridden by the user. We will use it 66518 # for the tool. 66519 66520 # First remove it from the list of overridden variables, so we can test 66521 # for unknown variables in the end. 66522 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66523 66524 # Check if we try to supply an empty value 66525 if test "x$ICECC_CMD" = x; then 66526 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 66527 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 66528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 66529 $as_echo_n "checking for ICECC_CMD... " >&6; } 66530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66531 $as_echo "disabled" >&6; } 66532 else 66533 # Check if the provided tool contains a complete path. 66534 tool_specified="$ICECC_CMD" 66535 tool_basename="${tool_specified##*/}" 66536 if test "x$tool_basename" = "x$tool_specified"; then 66537 # A command without a complete path is provided, search $PATH. 66538 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 66539 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 66540 # Extract the first word of "$tool_basename", so it can be a program name with args. 66541 set dummy $tool_basename; ac_word=$2 66542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66543 $as_echo_n "checking for $ac_word... " >&6; } 66544 if ${ac_cv_path_ICECC_CMD+:} false; then : 66545 $as_echo_n "(cached) " >&6 66546 else 66547 case $ICECC_CMD in 66548 [\\/]* | ?:[\\/]*) 66549 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 66550 ;; 66551 *) 66552 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66553 for as_dir in $PATH 66554 do 66555 IFS=$as_save_IFS 66556 test -z "$as_dir" && as_dir=. 66557 for ac_exec_ext in '' $ac_executable_extensions; do 66558 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66559 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 66560 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66561 break 2 66562 fi 66563 done 66564 done 66565 IFS=$as_save_IFS 66566 66567 ;; 66568 esac 66569 fi 66570 ICECC_CMD=$ac_cv_path_ICECC_CMD 66571 if test -n "$ICECC_CMD"; then 66572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 66573 $as_echo "$ICECC_CMD" >&6; } 66574 else 66575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66576 $as_echo "no" >&6; } 66577 fi 66578 66579 66580 if test "x$ICECC_CMD" = x; then 66581 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 66582 fi 66583 else 66584 # Otherwise we believe it is a complete path. Use it as it is. 66585 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 66586 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 66587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 66588 $as_echo_n "checking for ICECC_CMD... " >&6; } 66589 if test ! -x "$tool_specified"; then 66590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 66591 $as_echo "not found" >&6; } 66592 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 66593 fi 66594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 66595 $as_echo "$tool_specified" >&6; } 66596 fi 66597 fi 66598 fi 66599 66600 fi 66601 66602 66603 66604 if test "x$ICECC_CMD" = x; then 66605 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 66606 fi 66607 66608 66609 old_path="$PATH" 66610 66611 # Look for icecc-create-env in some known places 66612 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 66613 66614 66615 66616 # Publish this variable in the help. 66617 66618 66619 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 66620 # The variable is not set by user, try to locate tool using the code snippet 66621 for ac_prog in icecc-create-env 66622 do 66623 # Extract the first word of "$ac_prog", so it can be a program name with args. 66624 set dummy $ac_prog; ac_word=$2 66625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66626 $as_echo_n "checking for $ac_word... " >&6; } 66627 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 66628 $as_echo_n "(cached) " >&6 66629 else 66630 case $ICECC_CREATE_ENV in 66631 [\\/]* | ?:[\\/]*) 66632 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 66633 ;; 66634 *) 66635 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66636 for as_dir in $PATH 66637 do 66638 IFS=$as_save_IFS 66639 test -z "$as_dir" && as_dir=. 66640 for ac_exec_ext in '' $ac_executable_extensions; do 66641 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66642 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 66643 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66644 break 2 66645 fi 66646 done 66647 done 66648 IFS=$as_save_IFS 66649 66650 ;; 66651 esac 66652 fi 66653 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 66654 if test -n "$ICECC_CREATE_ENV"; then 66655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 66656 $as_echo "$ICECC_CREATE_ENV" >&6; } 66657 else 66658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66659 $as_echo "no" >&6; } 66660 fi 66661 66662 66663 test -n "$ICECC_CREATE_ENV" && break 66664 done 66665 66666 else 66667 # The variable is set, but is it from the command line or the environment? 66668 66669 # Try to remove the string !ICECC_CREATE_ENV! from our list. 66670 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 66671 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66672 # If it failed, the variable was not from the command line. Ignore it, 66673 # but warn the user (except for BASH, which is always set by the calling BASH). 66674 if test "xICECC_CREATE_ENV" != xBASH; then 66675 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 66676 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 66677 fi 66678 # Try to locate tool using the code snippet 66679 for ac_prog in icecc-create-env 66680 do 66681 # Extract the first word of "$ac_prog", so it can be a program name with args. 66682 set dummy $ac_prog; ac_word=$2 66683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66684 $as_echo_n "checking for $ac_word... " >&6; } 66685 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 66686 $as_echo_n "(cached) " >&6 66687 else 66688 case $ICECC_CREATE_ENV in 66689 [\\/]* | ?:[\\/]*) 66690 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 66691 ;; 66692 *) 66693 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66694 for as_dir in $PATH 66695 do 66696 IFS=$as_save_IFS 66697 test -z "$as_dir" && as_dir=. 66698 for ac_exec_ext in '' $ac_executable_extensions; do 66699 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66700 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 66701 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66702 break 2 66703 fi 66704 done 66705 done 66706 IFS=$as_save_IFS 66707 66708 ;; 66709 esac 66710 fi 66711 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 66712 if test -n "$ICECC_CREATE_ENV"; then 66713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 66714 $as_echo "$ICECC_CREATE_ENV" >&6; } 66715 else 66716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66717 $as_echo "no" >&6; } 66718 fi 66719 66720 66721 test -n "$ICECC_CREATE_ENV" && break 66722 done 66723 66724 else 66725 # If it succeeded, then it was overridden by the user. We will use it 66726 # for the tool. 66727 66728 # First remove it from the list of overridden variables, so we can test 66729 # for unknown variables in the end. 66730 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66731 66732 # Check if we try to supply an empty value 66733 if test "x$ICECC_CREATE_ENV" = x; then 66734 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 66735 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 66736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 66737 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 66738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66739 $as_echo "disabled" >&6; } 66740 else 66741 # Check if the provided tool contains a complete path. 66742 tool_specified="$ICECC_CREATE_ENV" 66743 tool_basename="${tool_specified##*/}" 66744 if test "x$tool_basename" = "x$tool_specified"; then 66745 # A command without a complete path is provided, search $PATH. 66746 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 66747 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 66748 # Extract the first word of "$tool_basename", so it can be a program name with args. 66749 set dummy $tool_basename; ac_word=$2 66750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66751 $as_echo_n "checking for $ac_word... " >&6; } 66752 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 66753 $as_echo_n "(cached) " >&6 66754 else 66755 case $ICECC_CREATE_ENV in 66756 [\\/]* | ?:[\\/]*) 66757 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 66758 ;; 66759 *) 66760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66761 for as_dir in $PATH 66762 do 66763 IFS=$as_save_IFS 66764 test -z "$as_dir" && as_dir=. 66765 for ac_exec_ext in '' $ac_executable_extensions; do 66766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66767 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 66768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66769 break 2 66770 fi 66771 done 66772 done 66773 IFS=$as_save_IFS 66774 66775 ;; 66776 esac 66777 fi 66778 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 66779 if test -n "$ICECC_CREATE_ENV"; then 66780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 66781 $as_echo "$ICECC_CREATE_ENV" >&6; } 66782 else 66783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66784 $as_echo "no" >&6; } 66785 fi 66786 66787 66788 if test "x$ICECC_CREATE_ENV" = x; then 66789 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 66790 fi 66791 else 66792 # Otherwise we believe it is a complete path. Use it as it is. 66793 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 66794 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 66795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 66796 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 66797 if test ! -x "$tool_specified"; then 66798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 66799 $as_echo "not found" >&6; } 66800 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 66801 fi 66802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 66803 $as_echo "$tool_specified" >&6; } 66804 fi 66805 fi 66806 fi 66807 66808 fi 66809 66810 66811 66812 if test "x$ICECC_CREATE_ENV" = x; then 66813 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 66814 fi 66815 66816 66817 # Use icecc-create-env to create a minimal compilation environment that can 66818 # be sent to the other hosts in the icecream cluster. 66819 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 66820 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 66821 # Older versions of icecc does not have the --gcc parameter 66822 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 66823 icecc_gcc_arg="--gcc" 66824 fi 66825 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 66826 66827 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 66828 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 66829 ${icecc_create_env_log} 2>&1 ) 66830 if test "$?" != "0"; then 66831 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 66832 $as_echo "$as_me: icecc-create-env output:" >&6;} 66833 cat \ 66834 ${icecc_create_env_log} 66835 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 66836 fi 66837 66838 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 66839 # For clang, the icecc compilerwrapper is needed. It usually resides next 66840 # to icecc-create-env. 66841 66842 66843 66844 # Publish this variable in the help. 66845 66846 66847 if [ -z "${ICECC_WRAPPER+x}" ]; then 66848 # The variable is not set by user, try to locate tool using the code snippet 66849 for ac_prog in compilerwrapper 66850 do 66851 # Extract the first word of "$ac_prog", so it can be a program name with args. 66852 set dummy $ac_prog; ac_word=$2 66853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66854 $as_echo_n "checking for $ac_word... " >&6; } 66855 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 66856 $as_echo_n "(cached) " >&6 66857 else 66858 case $ICECC_WRAPPER in 66859 [\\/]* | ?:[\\/]*) 66860 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 66861 ;; 66862 *) 66863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66864 for as_dir in $PATH 66865 do 66866 IFS=$as_save_IFS 66867 test -z "$as_dir" && as_dir=. 66868 for ac_exec_ext in '' $ac_executable_extensions; do 66869 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66870 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 66871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66872 break 2 66873 fi 66874 done 66875 done 66876 IFS=$as_save_IFS 66877 66878 ;; 66879 esac 66880 fi 66881 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 66882 if test -n "$ICECC_WRAPPER"; then 66883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 66884 $as_echo "$ICECC_WRAPPER" >&6; } 66885 else 66886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66887 $as_echo "no" >&6; } 66888 fi 66889 66890 66891 test -n "$ICECC_WRAPPER" && break 66892 done 66893 66894 else 66895 # The variable is set, but is it from the command line or the environment? 66896 66897 # Try to remove the string !ICECC_WRAPPER! from our list. 66898 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 66899 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66900 # If it failed, the variable was not from the command line. Ignore it, 66901 # but warn the user (except for BASH, which is always set by the calling BASH). 66902 if test "xICECC_WRAPPER" != xBASH; then 66903 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 66904 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 66905 fi 66906 # Try to locate tool using the code snippet 66907 for ac_prog in compilerwrapper 66908 do 66909 # Extract the first word of "$ac_prog", so it can be a program name with args. 66910 set dummy $ac_prog; ac_word=$2 66911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66912 $as_echo_n "checking for $ac_word... " >&6; } 66913 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 66914 $as_echo_n "(cached) " >&6 66915 else 66916 case $ICECC_WRAPPER in 66917 [\\/]* | ?:[\\/]*) 66918 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 66919 ;; 66920 *) 66921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66922 for as_dir in $PATH 66923 do 66924 IFS=$as_save_IFS 66925 test -z "$as_dir" && as_dir=. 66926 for ac_exec_ext in '' $ac_executable_extensions; do 66927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66928 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 66929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66930 break 2 66931 fi 66932 done 66933 done 66934 IFS=$as_save_IFS 66935 66936 ;; 66937 esac 66938 fi 66939 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 66940 if test -n "$ICECC_WRAPPER"; then 66941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 66942 $as_echo "$ICECC_WRAPPER" >&6; } 66943 else 66944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66945 $as_echo "no" >&6; } 66946 fi 66947 66948 66949 test -n "$ICECC_WRAPPER" && break 66950 done 66951 66952 else 66953 # If it succeeded, then it was overridden by the user. We will use it 66954 # for the tool. 66955 66956 # First remove it from the list of overridden variables, so we can test 66957 # for unknown variables in the end. 66958 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66959 66960 # Check if we try to supply an empty value 66961 if test "x$ICECC_WRAPPER" = x; then 66962 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 66963 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 66964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 66965 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 66966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66967 $as_echo "disabled" >&6; } 66968 else 66969 # Check if the provided tool contains a complete path. 66970 tool_specified="$ICECC_WRAPPER" 66971 tool_basename="${tool_specified##*/}" 66972 if test "x$tool_basename" = "x$tool_specified"; then 66973 # A command without a complete path is provided, search $PATH. 66974 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 66975 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 66976 # Extract the first word of "$tool_basename", so it can be a program name with args. 66977 set dummy $tool_basename; ac_word=$2 66978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66979 $as_echo_n "checking for $ac_word... " >&6; } 66980 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 66981 $as_echo_n "(cached) " >&6 66982 else 66983 case $ICECC_WRAPPER in 66984 [\\/]* | ?:[\\/]*) 66985 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 66986 ;; 66987 *) 66988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66989 for as_dir in $PATH 66990 do 66991 IFS=$as_save_IFS 66992 test -z "$as_dir" && as_dir=. 66993 for ac_exec_ext in '' $ac_executable_extensions; do 66994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66995 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 66996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66997 break 2 66998 fi 66999 done 67000 done 67001 IFS=$as_save_IFS 67002 67003 ;; 67004 esac 67005 fi 67006 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 67007 if test -n "$ICECC_WRAPPER"; then 67008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 67009 $as_echo "$ICECC_WRAPPER" >&6; } 67010 else 67011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67012 $as_echo "no" >&6; } 67013 fi 67014 67015 67016 if test "x$ICECC_WRAPPER" = x; then 67017 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 67018 fi 67019 else 67020 # Otherwise we believe it is a complete path. Use it as it is. 67021 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 67022 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 67023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 67024 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 67025 if test ! -x "$tool_specified"; then 67026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 67027 $as_echo "not found" >&6; } 67028 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 67029 fi 67030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 67031 $as_echo "$tool_specified" >&6; } 67032 fi 67033 fi 67034 fi 67035 67036 fi 67037 67038 67039 67040 if test "x$ICECC_WRAPPER" = x; then 67041 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 67042 fi 67043 67044 67045 67046 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67047 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 67048 if test "$?" != "0"; then 67049 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67050 $as_echo "$as_me: icecc-create-env output:" >&6;} 67051 cat ${icecc_create_env_log} 67052 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67053 fi 67054 67055 else 67056 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 67057 fi 67058 PATH="$old_path" 67059 # The bundle with the compiler gets a name based on checksums. Parse log file 67060 # to find it. 67061 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 67062 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 67063 if test ! -f ${ICECC_ENV_BUNDLE}; then 67064 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 67065 fi 67066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 67067 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 67068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 67069 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 67070 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 67071 67072 if test "x${COMPILE_TYPE}" = "xcross"; then 67073 # If cross compiling, create a separate env package for the build compiler 67074 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 67075 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 67076 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 67077 67078 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67079 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 67080 ${icecc_create_env_log_build} 2>&1 ) 67081 if test "$?" != "0"; then 67082 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67083 $as_echo "$as_me: icecc-create-env output:" >&6;} 67084 cat \ 67085 ${icecc_create_env_log_build} 67086 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67087 fi 67088 67089 elif test "x${BUILD_CC##*/}" = "xclang"; then 67090 67091 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 67092 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 67093 if test "$?" != "0"; then 67094 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 67095 $as_echo "$as_me: icecc-create-env output:" >&6;} 67096 cat ${icecc_create_env_log_build} 67097 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 67098 fi 67099 67100 else 67101 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 67102 fi 67103 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 67104 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 67105 if test ! -f ${ICECC_ENV_BUNDLE}; then 67106 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 67107 fi 67108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 67109 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 67110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 67111 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 67112 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 67113 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 67114 else 67115 BUILD_ICECC="${ICECC}" 67116 fi 67117 67118 67119 fi 67120 67121 67122 # Can the C/C++ compiler use precompiled headers? 67123 67124 67125 ############################################################################### 67126 # 67127 # Can the C/C++ compiler use precompiled headers? 67128 # 67129 # Check whether --enable-precompiled-headers was given. 67130 if test "${enable_precompiled_headers+set}" = set; then : 67131 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 67132 else 67133 ENABLE_PRECOMPH=yes 67134 fi 67135 67136 67137 USE_PRECOMPILED_HEADER=true 67138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 67139 $as_echo_n "checking If precompiled header is enabled... " >&6; } 67140 if test "x$ENABLE_PRECOMPH" = xno; then 67141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 67142 $as_echo "no, forced" >&6; } 67143 USE_PRECOMPILED_HEADER=false 67144 elif test "x$ICECC" != "x"; then 67145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 67146 $as_echo "no, does not work effectively with icecc" >&6; } 67147 USE_PRECOMPILED_HEADER=false 67148 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 67149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 67150 $as_echo "no, does not work with Solaris Studio" >&6; } 67151 USE_PRECOMPILED_HEADER=false 67152 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 67153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 67154 $as_echo "no, does not work with xlc" >&6; } 67155 USE_PRECOMPILED_HEADER=false 67156 else 67157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67158 $as_echo "yes" >&6; } 67159 fi 67160 67161 if test "x$ENABLE_PRECOMPH" = xyes; then 67162 # Check that the compiler actually supports precomp headers. 67163 if test "x$TOOLCHAIN_TYPE" = xgcc; then 67164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 67165 $as_echo_n "checking that precompiled headers work... " >&6; } 67166 echo "int alfa();" > conftest.h 67167 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 67168 if test ! -f conftest.hpp.gch; then 67169 USE_PRECOMPILED_HEADER=false 67170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67171 $as_echo "no" >&6; } 67172 else 67173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67174 $as_echo "yes" >&6; } 67175 fi 67176 $RM conftest.h conftest.hpp.gch 67177 fi 67178 fi 67179 67180 67181 67182 67183 # Setup use of ccache, if available 67184 67185 # Check whether --enable-ccache was given. 67186 if test "${enable_ccache+set}" = set; then : 67187 enableval=$enable_ccache; 67188 fi 67189 67190 67191 CCACHE_STATUS= 67192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 67193 $as_echo_n "checking is ccache enabled... " >&6; } 67194 if test "x$enable_ccache" = xyes; then 67195 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 67196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67197 $as_echo "yes" >&6; } 67198 OLD_PATH="$PATH" 67199 if test "x$TOOLCHAIN_PATH" != x; then 67200 PATH=$TOOLCHAIN_PATH:$PATH 67201 fi 67202 67203 67204 67205 # Publish this variable in the help. 67206 67207 67208 if [ -z "${CCACHE+x}" ]; then 67209 # The variable is not set by user, try to locate tool using the code snippet 67210 for ac_prog in ccache 67211 do 67212 # Extract the first word of "$ac_prog", so it can be a program name with args. 67213 set dummy $ac_prog; ac_word=$2 67214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67215 $as_echo_n "checking for $ac_word... " >&6; } 67216 if ${ac_cv_path_CCACHE+:} false; then : 67217 $as_echo_n "(cached) " >&6 67218 else 67219 case $CCACHE in 67220 [\\/]* | ?:[\\/]*) 67221 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 67222 ;; 67223 *) 67224 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67225 for as_dir in $PATH 67226 do 67227 IFS=$as_save_IFS 67228 test -z "$as_dir" && as_dir=. 67229 for ac_exec_ext in '' $ac_executable_extensions; do 67230 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67231 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 67232 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67233 break 2 67234 fi 67235 done 67236 done 67237 IFS=$as_save_IFS 67238 67239 ;; 67240 esac 67241 fi 67242 CCACHE=$ac_cv_path_CCACHE 67243 if test -n "$CCACHE"; then 67244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 67245 $as_echo "$CCACHE" >&6; } 67246 else 67247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67248 $as_echo "no" >&6; } 67249 fi 67250 67251 67252 test -n "$CCACHE" && break 67253 done 67254 67255 else 67256 # The variable is set, but is it from the command line or the environment? 67257 67258 # Try to remove the string !CCACHE! from our list. 67259 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 67260 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 67261 # If it failed, the variable was not from the command line. Ignore it, 67262 # but warn the user (except for BASH, which is always set by the calling BASH). 67263 if test "xCCACHE" != xBASH; then 67264 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 67265 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 67266 fi 67267 # Try to locate tool using the code snippet 67268 for ac_prog in ccache 67269 do 67270 # Extract the first word of "$ac_prog", so it can be a program name with args. 67271 set dummy $ac_prog; ac_word=$2 67272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67273 $as_echo_n "checking for $ac_word... " >&6; } 67274 if ${ac_cv_path_CCACHE+:} false; then : 67275 $as_echo_n "(cached) " >&6 67276 else 67277 case $CCACHE in 67278 [\\/]* | ?:[\\/]*) 67279 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 67280 ;; 67281 *) 67282 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67283 for as_dir in $PATH 67284 do 67285 IFS=$as_save_IFS 67286 test -z "$as_dir" && as_dir=. 67287 for ac_exec_ext in '' $ac_executable_extensions; do 67288 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67289 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 67290 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67291 break 2 67292 fi 67293 done 67294 done 67295 IFS=$as_save_IFS 67296 67297 ;; 67298 esac 67299 fi 67300 CCACHE=$ac_cv_path_CCACHE 67301 if test -n "$CCACHE"; then 67302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 67303 $as_echo "$CCACHE" >&6; } 67304 else 67305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67306 $as_echo "no" >&6; } 67307 fi 67308 67309 67310 test -n "$CCACHE" && break 67311 done 67312 67313 else 67314 # If it succeeded, then it was overridden by the user. We will use it 67315 # for the tool. 67316 67317 # First remove it from the list of overridden variables, so we can test 67318 # for unknown variables in the end. 67319 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 67320 67321 # Check if we try to supply an empty value 67322 if test "x$CCACHE" = x; then 67323 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 67324 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 67325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 67326 $as_echo_n "checking for CCACHE... " >&6; } 67327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 67328 $as_echo "disabled" >&6; } 67329 else 67330 # Check if the provided tool contains a complete path. 67331 tool_specified="$CCACHE" 67332 tool_basename="${tool_specified##*/}" 67333 if test "x$tool_basename" = "x$tool_specified"; then 67334 # A command without a complete path is provided, search $PATH. 67335 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 67336 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 67337 # Extract the first word of "$tool_basename", so it can be a program name with args. 67338 set dummy $tool_basename; ac_word=$2 67339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 67340 $as_echo_n "checking for $ac_word... " >&6; } 67341 if ${ac_cv_path_CCACHE+:} false; then : 67342 $as_echo_n "(cached) " >&6 67343 else 67344 case $CCACHE in 67345 [\\/]* | ?:[\\/]*) 67346 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 67347 ;; 67348 *) 67349 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67350 for as_dir in $PATH 67351 do 67352 IFS=$as_save_IFS 67353 test -z "$as_dir" && as_dir=. 67354 for ac_exec_ext in '' $ac_executable_extensions; do 67355 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 67356 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 67357 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 67358 break 2 67359 fi 67360 done 67361 done 67362 IFS=$as_save_IFS 67363 67364 ;; 67365 esac 67366 fi 67367 CCACHE=$ac_cv_path_CCACHE 67368 if test -n "$CCACHE"; then 67369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 67370 $as_echo "$CCACHE" >&6; } 67371 else 67372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67373 $as_echo "no" >&6; } 67374 fi 67375 67376 67377 if test "x$CCACHE" = x; then 67378 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 67379 fi 67380 else 67381 # Otherwise we believe it is a complete path. Use it as it is. 67382 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 67383 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 67384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 67385 $as_echo_n "checking for CCACHE... " >&6; } 67386 if test ! -x "$tool_specified"; then 67387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 67388 $as_echo "not found" >&6; } 67389 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 67390 fi 67391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 67392 $as_echo "$tool_specified" >&6; } 67393 fi 67394 fi 67395 fi 67396 67397 fi 67398 67399 67400 67401 if test "x$CCACHE" = x; then 67402 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 67403 fi 67404 67405 67406 PATH="$OLD_PATH" 67407 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 67408 CCACHE_STATUS="Active ($CCACHE_VERSION)" 67409 else 67410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67411 $as_echo "no" >&6; } 67412 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 67413 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 67414 fi 67415 elif test "x$enable_ccache" = xno; then 67416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 67417 $as_echo "no, explicitly disabled" >&6; } 67418 CCACHE_STATUS="Disabled" 67419 elif test "x$enable_ccache" = x; then 67420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67421 $as_echo "no" >&6; } 67422 else 67423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 67424 $as_echo "unknown" >&6; } 67425 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 67426 fi 67427 67428 67429 67430 # Check whether --with-ccache-dir was given. 67431 if test "${with_ccache_dir+set}" = set; then : 67432 withval=$with_ccache_dir; 67433 fi 67434 67435 67436 if test "x$with_ccache_dir" != x; then 67437 # When using a non home ccache directory, assume the use is to share ccache files 67438 # with other users. Thus change the umask. 67439 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 67440 if test "x$CCACHE" = x; then 67441 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 67442 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 67443 fi 67444 fi 67445 67446 if test "x$CCACHE" != x; then 67447 67448 if test "x$CCACHE" != x; then 67449 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 67450 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 67451 $GREP -e '^1\.' -e '^2\.' -e '^3\.0\.' -e '^3\.1\.'` 67452 if test "x$HAS_BAD_CCACHE" != "x"; then 67453 as_fn_error $? "On macosx, ccache 3.2 or later is required, found $CCACHE_VERSION" "$LINENO" 5 67454 fi 67455 fi 67456 if test "x$USE_PRECOMPILED_HEADER" = "xtrue"; then 67457 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 67458 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 67459 if test "x$HAS_BAD_CCACHE" != "x"; then 67460 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 67461 fi 67462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 67463 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 67464 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 67465 PUSHED_FLAGS="$CXXFLAGS" 67466 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 67467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 67468 /* end confdefs.h. */ 67469 67470 int 67471 main () 67472 { 67473 67474 ; 67475 return 0; 67476 } 67477 _ACEOF 67478 if ac_fn_cxx_try_compile "$LINENO"; then : 67479 CC_KNOWS_CCACHE_TRICK=yes 67480 else 67481 CC_KNOWS_CCACHE_TRICK=no 67482 fi 67483 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 67484 CXXFLAGS="$PUSHED_FLAGS" 67485 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 67486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 67487 $as_echo "yes" >&6; } 67488 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 67489 67490 CCACHE_SLOPPINESS=pch_defines,time_macros 67491 else 67492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 67493 $as_echo "no" >&6; } 67494 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 67495 fi 67496 fi 67497 67498 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 67499 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 67500 67501 if test "x$SET_CCACHE_DIR" != x; then 67502 mkdir -p $CCACHE_DIR > /dev/null 2>&1 67503 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 67504 fi 67505 fi 67506 67507 fi 67508 67509 67510 ############################################################################### 67511 # 67512 # And now the finish... 67513 # 67514 ############################################################################### 67515 67516 # Check for some common pitfalls 67517 67518 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 67519 file_to_test="$SRC_ROOT/LICENSE" 67520 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 67521 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 67522 fi 67523 fi 67524 67525 67526 # Did user specify any unknown variables? 67527 67528 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 67529 # Replace the separating ! with spaces before presenting for end user. 67530 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 67531 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 67532 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 67533 fi 67534 67535 67536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 67537 $as_echo_n "checking if build directory is on local disk... " >&6; } 67538 67539 # df -l lists only local disks; if the given directory is not found then 67540 # a non-zero exit code is given 67541 if test "x$DF" = x; then 67542 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 67543 # msys does not have df; use Windows "net use" instead. 67544 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 67545 if test "x$IS_NETWORK_DISK" = x; then 67546 OUTPUT_DIR_IS_LOCAL="yes" 67547 else 67548 OUTPUT_DIR_IS_LOCAL="no" 67549 fi 67550 else 67551 # No df here, say it's local 67552 OUTPUT_DIR_IS_LOCAL="yes" 67553 fi 67554 else 67555 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 67556 OUTPUT_DIR_IS_LOCAL="yes" 67557 else 67558 OUTPUT_DIR_IS_LOCAL="no" 67559 fi 67560 fi 67561 67562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 67563 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 67564 67565 67566 67567 # Check if the user has any old-style ALT_ variables set. 67568 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 67569 67570 # Before generating output files, test if they exist. If they do, this is a reconfigure. 67571 # Since we can't properly handle the dependencies for this, warn the user about the situation 67572 if test -e $OUTPUT_ROOT/spec.gmk; then 67573 IS_RECONFIGURE=yes 67574 else 67575 IS_RECONFIGURE=no 67576 fi 67577 67578 67579 # At the end, call the custom hook. (Dummy macro if no custom sources available) 67580 67581 67582 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 67583 67584 # Keep feature lists sorted and free of duplicates 67585 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 67586 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 67587 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 67588 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 67589 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 67590 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 67591 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 67592 67593 # Validate features 67594 for variant in $JVM_VARIANTS; do 67595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 67596 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 67597 features_var_name=JVM_FEATURES_$variant 67598 JVM_FEATURES_TO_TEST=${!features_var_name} 67599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 67600 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 67601 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 67602 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 67603 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 67604 if test "x$INVALID_FEATURES" != x; then 67605 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 67606 fi 67607 done 67608 67609 67610 # We're messing a bit with internal autoconf variables to put the config.status 67611 # in the output directory instead of the current directory. 67612 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 67613 67614 # Create the actual output files. Now the main work of configure is done. 67615 cat >confcache <<\_ACEOF 67616 # This file is a shell script that caches the results of configure 67617 # tests run on this system so they can be shared between configure 67618 # scripts and configure runs, see configure's option --config-cache. 67619 # It is not useful on other systems. If it contains results you don't 67620 # want to keep, you may remove or edit it. 67621 # 67622 # config.status only pays attention to the cache file if you give it 67623 # the --recheck option to rerun configure. 67624 # 67625 # `ac_cv_env_foo' variables (set or unset) will be overridden when 67626 # loading this file, other *unset* `ac_cv_foo' will be assigned the 67627 # following values. 67628 67629 _ACEOF 67630 67631 # The following way of writing the cache mishandles newlines in values, 67632 # but we know of no workaround that is simple, portable, and efficient. 67633 # So, we kill variables containing newlines. 67634 # Ultrix sh set writes to stderr and can't be redirected directly, 67635 # and sets the high bit in the cache file unless we assign to the vars. 67636 ( 67637 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 67638 eval ac_val=\$$ac_var 67639 case $ac_val in #( 67640 *${as_nl}*) 67641 case $ac_var in #( 67642 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 67643 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 67644 esac 67645 case $ac_var in #( 67646 _ | IFS | as_nl) ;; #( 67647 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 67648 *) { eval $ac_var=; unset $ac_var;} ;; 67649 esac ;; 67650 esac 67651 done 67652 67653 (set) 2>&1 | 67654 case $as_nl`(ac_space=' '; set) 2>&1` in #( 67655 *${as_nl}ac_space=\ *) 67656 # `set' does not quote correctly, so add quotes: double-quote 67657 # substitution turns \\\\ into \\, and sed turns \\ into \. 67658 sed -n \ 67659 "s/'/'\\\\''/g; 67660 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 67661 ;; #( 67662 *) 67663 # `set' quotes correctly as required by POSIX, so do not add quotes. 67664 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 67665 ;; 67666 esac | 67667 sort 67668 ) | 67669 sed ' 67670 /^ac_cv_env_/b end 67671 t clear 67672 :clear 67673 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 67674 t end 67675 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 67676 :end' >>confcache 67677 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 67678 if test -w "$cache_file"; then 67679 if test "x$cache_file" != "x/dev/null"; then 67680 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 67681 $as_echo "$as_me: updating cache $cache_file" >&6;} 67682 if test ! -f "$cache_file" || test -h "$cache_file"; then 67683 cat confcache >"$cache_file" 67684 else 67685 case $cache_file in #( 67686 */* | ?:*) 67687 mv -f confcache "$cache_file"$$ && 67688 mv -f "$cache_file"$$ "$cache_file" ;; #( 67689 *) 67690 mv -f confcache "$cache_file" ;; 67691 esac 67692 fi 67693 fi 67694 else 67695 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 67696 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 67697 fi 67698 fi 67699 rm -f confcache 67700 67701 test "x$prefix" = xNONE && prefix=$ac_default_prefix 67702 # Let make expand exec_prefix. 67703 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 67704 67705 # Transform confdefs.h into DEFS. 67706 # Protect against shell expansion while executing Makefile rules. 67707 # Protect against Makefile macro expansion. 67708 # 67709 # If the first sed substitution is executed (which looks for macros that 67710 # take arguments), then branch to the quote section. Otherwise, 67711 # look for a macro that doesn't take arguments. 67712 ac_script=' 67713 :mline 67714 /\\$/{ 67715 N 67716 s,\\\n,, 67717 b mline 67718 } 67719 t clear 67720 :clear 67721 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 67722 t quote 67723 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 67724 t quote 67725 b any 67726 :quote 67727 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 67728 s/\[/\\&/g 67729 s/\]/\\&/g 67730 s/\$/$$/g 67731 H 67732 :any 67733 ${ 67734 g 67735 s/^\n// 67736 s/\n/ /g 67737 p 67738 } 67739 ' 67740 DEFS=`sed -n "$ac_script" confdefs.h` 67741 67742 67743 ac_libobjs= 67744 ac_ltlibobjs= 67745 U= 67746 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 67747 # 1. Remove the extension, and $U if already installed. 67748 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 67749 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 67750 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 67751 # will be set to the directory where LIBOBJS objects are built. 67752 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 67753 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 67754 done 67755 LIBOBJS=$ac_libobjs 67756 67757 LTLIBOBJS=$ac_ltlibobjs 67758 67759 67760 67761 : "${CONFIG_STATUS=./config.status}" 67762 ac_write_fail=0 67763 ac_clean_files_save=$ac_clean_files 67764 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 67765 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 67766 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 67767 as_write_fail=0 67768 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 67769 #! $SHELL 67770 # Generated by $as_me. 67771 # Run this file to recreate the current configuration. 67772 # Compiler output produced by configure, useful for debugging 67773 # configure, is in config.log if it exists. 67774 67775 debug=false 67776 ac_cs_recheck=false 67777 ac_cs_silent=false 67778 67779 SHELL=\${CONFIG_SHELL-$SHELL} 67780 export SHELL 67781 _ASEOF 67782 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 67783 ## -------------------- ## 67784 ## M4sh Initialization. ## 67785 ## -------------------- ## 67786 67787 # Be more Bourne compatible 67788 DUALCASE=1; export DUALCASE # for MKS sh 67789 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 67790 emulate sh 67791 NULLCMD=: 67792 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 67793 # is contrary to our usage. Disable this feature. 67794 alias -g '${1+"$@"}'='"$@"' 67795 setopt NO_GLOB_SUBST 67796 else 67797 case `(set -o) 2>/dev/null` in #( 67798 *posix*) : 67799 set -o posix ;; #( 67800 *) : 67801 ;; 67802 esac 67803 fi 67804 67805 67806 as_nl=' 67807 ' 67808 export as_nl 67809 # Printing a long string crashes Solaris 7 /usr/bin/printf. 67810 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 67811 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 67812 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 67813 # Prefer a ksh shell builtin over an external printf program on Solaris, 67814 # but without wasting forks for bash or zsh. 67815 if test -z "$BASH_VERSION$ZSH_VERSION" \ 67816 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 67817 as_echo='print -r --' 67818 as_echo_n='print -rn --' 67819 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 67820 as_echo='printf %s\n' 67821 as_echo_n='printf %s' 67822 else 67823 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 67824 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 67825 as_echo_n='/usr/ucb/echo -n' 67826 else 67827 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 67828 as_echo_n_body='eval 67829 arg=$1; 67830 case $arg in #( 67831 *"$as_nl"*) 67832 expr "X$arg" : "X\\(.*\\)$as_nl"; 67833 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 67834 esac; 67835 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 67836 ' 67837 export as_echo_n_body 67838 as_echo_n='sh -c $as_echo_n_body as_echo' 67839 fi 67840 export as_echo_body 67841 as_echo='sh -c $as_echo_body as_echo' 67842 fi 67843 67844 # The user is always right. 67845 if test "${PATH_SEPARATOR+set}" != set; then 67846 PATH_SEPARATOR=: 67847 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 67848 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 67849 PATH_SEPARATOR=';' 67850 } 67851 fi 67852 67853 67854 # IFS 67855 # We need space, tab and new line, in precisely that order. Quoting is 67856 # there to prevent editors from complaining about space-tab. 67857 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 67858 # splitting by setting IFS to empty value.) 67859 IFS=" "" $as_nl" 67860 67861 # Find who we are. Look in the path if we contain no directory separator. 67862 as_myself= 67863 case $0 in #(( 67864 *[\\/]* ) as_myself=$0 ;; 67865 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 67866 for as_dir in $PATH 67867 do 67868 IFS=$as_save_IFS 67869 test -z "$as_dir" && as_dir=. 67870 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 67871 done 67872 IFS=$as_save_IFS 67873 67874 ;; 67875 esac 67876 # We did not find ourselves, most probably we were run as `sh COMMAND' 67877 # in which case we are not to be found in the path. 67878 if test "x$as_myself" = x; then 67879 as_myself=$0 67880 fi 67881 if test ! -f "$as_myself"; then 67882 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 67883 exit 1 67884 fi 67885 67886 # Unset variables that we do not need and which cause bugs (e.g. in 67887 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 67888 # suppresses any "Segmentation fault" message there. '((' could 67889 # trigger a bug in pdksh 5.2.14. 67890 for as_var in BASH_ENV ENV MAIL MAILPATH 67891 do eval test x\${$as_var+set} = xset \ 67892 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 67893 done 67894 PS1='$ ' 67895 PS2='> ' 67896 PS4='+ ' 67897 67898 # NLS nuisances. 67899 LC_ALL=C 67900 export LC_ALL 67901 LANGUAGE=C 67902 export LANGUAGE 67903 67904 # CDPATH. 67905 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 67906 67907 67908 # as_fn_error STATUS ERROR [LINENO LOG_FD] 67909 # ---------------------------------------- 67910 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 67911 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 67912 # script with STATUS, using 1 if that was 0. 67913 as_fn_error () 67914 { 67915 as_status=$1; test $as_status -eq 0 && as_status=1 67916 if test "$4"; then 67917 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 67918 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 67919 fi 67920 $as_echo "$as_me: error: $2" >&2 67921 as_fn_exit $as_status 67922 } # as_fn_error 67923 67924 67925 # as_fn_set_status STATUS 67926 # ----------------------- 67927 # Set $? to STATUS, without forking. 67928 as_fn_set_status () 67929 { 67930 return $1 67931 } # as_fn_set_status 67932 67933 # as_fn_exit STATUS 67934 # ----------------- 67935 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 67936 as_fn_exit () 67937 { 67938 set +e 67939 as_fn_set_status $1 67940 exit $1 67941 } # as_fn_exit 67942 67943 # as_fn_unset VAR 67944 # --------------- 67945 # Portably unset VAR. 67946 as_fn_unset () 67947 { 67948 { eval $1=; unset $1;} 67949 } 67950 as_unset=as_fn_unset 67951 # as_fn_append VAR VALUE 67952 # ---------------------- 67953 # Append the text in VALUE to the end of the definition contained in VAR. Take 67954 # advantage of any shell optimizations that allow amortized linear growth over 67955 # repeated appends, instead of the typical quadratic growth present in naive 67956 # implementations. 67957 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 67958 eval 'as_fn_append () 67959 { 67960 eval $1+=\$2 67961 }' 67962 else 67963 as_fn_append () 67964 { 67965 eval $1=\$$1\$2 67966 } 67967 fi # as_fn_append 67968 67969 # as_fn_arith ARG... 67970 # ------------------ 67971 # Perform arithmetic evaluation on the ARGs, and store the result in the 67972 # global $as_val. Take advantage of shells that can avoid forks. The arguments 67973 # must be portable across $(()) and expr. 67974 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 67975 eval 'as_fn_arith () 67976 { 67977 as_val=$(( $* )) 67978 }' 67979 else 67980 as_fn_arith () 67981 { 67982 as_val=`expr "$@" || test $? -eq 1` 67983 } 67984 fi # as_fn_arith 67985 67986 67987 if expr a : '\(a\)' >/dev/null 2>&1 && 67988 test "X`expr 00001 : '.*\(...\)'`" = X001; then 67989 as_expr=expr 67990 else 67991 as_expr=false 67992 fi 67993 67994 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 67995 as_basename=basename 67996 else 67997 as_basename=false 67998 fi 67999 68000 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 68001 as_dirname=dirname 68002 else 68003 as_dirname=false 68004 fi 68005 68006 as_me=`$as_basename -- "$0" || 68007 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 68008 X"$0" : 'X\(//\)$' \| \ 68009 X"$0" : 'X\(/\)' \| . 2>/dev/null || 68010 $as_echo X/"$0" | 68011 sed '/^.*\/\([^/][^/]*\)\/*$/{ 68012 s//\1/ 68013 q 68014 } 68015 /^X\/\(\/\/\)$/{ 68016 s//\1/ 68017 q 68018 } 68019 /^X\/\(\/\).*/{ 68020 s//\1/ 68021 q 68022 } 68023 s/.*/./; q'` 68024 68025 # Avoid depending upon Character Ranges. 68026 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 68027 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 68028 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 68029 as_cr_digits='0123456789' 68030 as_cr_alnum=$as_cr_Letters$as_cr_digits 68031 68032 ECHO_C= ECHO_N= ECHO_T= 68033 case `echo -n x` in #((((( 68034 -n*) 68035 case `echo 'xy\c'` in 68036 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 68037 xy) ECHO_C='\c';; 68038 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 68039 ECHO_T=' ';; 68040 esac;; 68041 *) 68042 ECHO_N='-n';; 68043 esac 68044 68045 rm -f conf$$ conf$$.exe conf$$.file 68046 if test -d conf$$.dir; then 68047 rm -f conf$$.dir/conf$$.file 68048 else 68049 rm -f conf$$.dir 68050 mkdir conf$$.dir 2>/dev/null 68051 fi 68052 if (echo >conf$$.file) 2>/dev/null; then 68053 if ln -s conf$$.file conf$$ 2>/dev/null; then 68054 as_ln_s='ln -s' 68055 # ... but there are two gotchas: 68056 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 68057 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 68058 # In both cases, we have to default to `cp -pR'. 68059 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 68060 as_ln_s='cp -pR' 68061 elif ln conf$$.file conf$$ 2>/dev/null; then 68062 as_ln_s=ln 68063 else 68064 as_ln_s='cp -pR' 68065 fi 68066 else 68067 as_ln_s='cp -pR' 68068 fi 68069 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 68070 rmdir conf$$.dir 2>/dev/null 68071 68072 68073 # as_fn_mkdir_p 68074 # ------------- 68075 # Create "$as_dir" as a directory, including parents if necessary. 68076 as_fn_mkdir_p () 68077 { 68078 68079 case $as_dir in #( 68080 -*) as_dir=./$as_dir;; 68081 esac 68082 test -d "$as_dir" || eval $as_mkdir_p || { 68083 as_dirs= 68084 while :; do 68085 case $as_dir in #( 68086 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 68087 *) as_qdir=$as_dir;; 68088 esac 68089 as_dirs="'$as_qdir' $as_dirs" 68090 as_dir=`$as_dirname -- "$as_dir" || 68091 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 68092 X"$as_dir" : 'X\(//\)[^/]' \| \ 68093 X"$as_dir" : 'X\(//\)$' \| \ 68094 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 68095 $as_echo X"$as_dir" | 68096 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 68097 s//\1/ 68098 q 68099 } 68100 /^X\(\/\/\)[^/].*/{ 68101 s//\1/ 68102 q 68103 } 68104 /^X\(\/\/\)$/{ 68105 s//\1/ 68106 q 68107 } 68108 /^X\(\/\).*/{ 68109 s//\1/ 68110 q 68111 } 68112 s/.*/./; q'` 68113 test -d "$as_dir" && break 68114 done 68115 test -z "$as_dirs" || eval "mkdir $as_dirs" 68116 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 68117 68118 68119 } # as_fn_mkdir_p 68120 if mkdir -p . 2>/dev/null; then 68121 as_mkdir_p='mkdir -p "$as_dir"' 68122 else 68123 test -d ./-p && rmdir ./-p 68124 as_mkdir_p=false 68125 fi 68126 68127 68128 # as_fn_executable_p FILE 68129 # ----------------------- 68130 # Test if FILE is an executable regular file. 68131 as_fn_executable_p () 68132 { 68133 test -f "$1" && test -x "$1" 68134 } # as_fn_executable_p 68135 as_test_x='test -x' 68136 as_executable_p=as_fn_executable_p 68137 68138 # Sed expression to map a string onto a valid CPP name. 68139 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 68140 68141 # Sed expression to map a string onto a valid variable name. 68142 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 68143 68144 68145 exec 6>&1 68146 ## ----------------------------------- ## 68147 ## Main body of $CONFIG_STATUS script. ## 68148 ## ----------------------------------- ## 68149 _ASEOF 68150 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 68151 68152 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68153 # Save the log message, to keep $0 and so on meaningful, and to 68154 # report actual input values of CONFIG_FILES etc. instead of their 68155 # values after options handling. 68156 ac_log=" 68157 This file was extended by OpenJDK $as_me jdk9, which was 68158 generated by GNU Autoconf 2.69. Invocation command line was 68159 68160 CONFIG_FILES = $CONFIG_FILES 68161 CONFIG_HEADERS = $CONFIG_HEADERS 68162 CONFIG_LINKS = $CONFIG_LINKS 68163 CONFIG_COMMANDS = $CONFIG_COMMANDS 68164 $ $0 $@ 68165 68166 on `(hostname || uname -n) 2>/dev/null | sed 1q` 68167 " 68168 68169 _ACEOF 68170 68171 case $ac_config_files in *" 68172 "*) set x $ac_config_files; shift; ac_config_files=$*;; 68173 esac 68174 68175 68176 68177 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68178 # Files that config.status was made for. 68179 config_files="$ac_config_files" 68180 68181 _ACEOF 68182 68183 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68184 ac_cs_usage="\ 68185 \`$as_me' instantiates files and other configuration actions 68186 from templates according to the current configuration. Unless the files 68187 and actions are specified as TAGs, all are instantiated by default. 68188 68189 Usage: $0 [OPTION]... [TAG]... 68190 68191 -h, --help print this help, then exit 68192 -V, --version print version number and configuration settings, then exit 68193 --config print configuration, then exit 68194 -q, --quiet, --silent 68195 do not print progress messages 68196 -d, --debug don't remove temporary files 68197 --recheck update $as_me by reconfiguring in the same conditions 68198 --file=FILE[:TEMPLATE] 68199 instantiate the configuration file FILE 68200 68201 Configuration files: 68202 $config_files 68203 68204 Report bugs to <build-dev@openjdk.java.net>. 68205 OpenJDK home page: <http://openjdk.java.net>." 68206 68207 _ACEOF 68208 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68209 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 68210 ac_cs_version="\\ 68211 OpenJDK config.status jdk9 68212 configured by $0, generated by GNU Autoconf 2.69, 68213 with options \\"\$ac_cs_config\\" 68214 68215 Copyright (C) 2012 Free Software Foundation, Inc. 68216 This config.status script is free software; the Free Software Foundation 68217 gives unlimited permission to copy, distribute and modify it." 68218 68219 ac_pwd='$ac_pwd' 68220 srcdir='$srcdir' 68221 AWK='$AWK' 68222 test -n "\$AWK" || AWK=awk 68223 _ACEOF 68224 68225 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68226 # The default lists apply if the user does not specify any file. 68227 ac_need_defaults=: 68228 while test $# != 0 68229 do 68230 case $1 in 68231 --*=?*) 68232 ac_option=`expr "X$1" : 'X\([^=]*\)='` 68233 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 68234 ac_shift=: 68235 ;; 68236 --*=) 68237 ac_option=`expr "X$1" : 'X\([^=]*\)='` 68238 ac_optarg= 68239 ac_shift=: 68240 ;; 68241 *) 68242 ac_option=$1 68243 ac_optarg=$2 68244 ac_shift=shift 68245 ;; 68246 esac 68247 68248 case $ac_option in 68249 # Handling of the options. 68250 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 68251 ac_cs_recheck=: ;; 68252 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 68253 $as_echo "$ac_cs_version"; exit ;; 68254 --config | --confi | --conf | --con | --co | --c ) 68255 $as_echo "$ac_cs_config"; exit ;; 68256 --debug | --debu | --deb | --de | --d | -d ) 68257 debug=: ;; 68258 --file | --fil | --fi | --f ) 68259 $ac_shift 68260 case $ac_optarg in 68261 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 68262 '') as_fn_error $? "missing file argument" ;; 68263 esac 68264 as_fn_append CONFIG_FILES " '$ac_optarg'" 68265 ac_need_defaults=false;; 68266 --he | --h | --help | --hel | -h ) 68267 $as_echo "$ac_cs_usage"; exit ;; 68268 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 68269 | -silent | --silent | --silen | --sile | --sil | --si | --s) 68270 ac_cs_silent=: ;; 68271 68272 # This is an error. 68273 -*) as_fn_error $? "unrecognized option: \`$1' 68274 Try \`$0 --help' for more information." ;; 68275 68276 *) as_fn_append ac_config_targets " $1" 68277 ac_need_defaults=false ;; 68278 68279 esac 68280 shift 68281 done 68282 68283 ac_configure_extra_args= 68284 68285 if $ac_cs_silent; then 68286 exec 6>/dev/null 68287 ac_configure_extra_args="$ac_configure_extra_args --silent" 68288 fi 68289 68290 _ACEOF 68291 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68292 if \$ac_cs_recheck; then 68293 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 68294 shift 68295 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 68296 CONFIG_SHELL='$SHELL' 68297 export CONFIG_SHELL 68298 exec "\$@" 68299 fi 68300 68301 _ACEOF 68302 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68303 exec 5>>config.log 68304 { 68305 echo 68306 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 68307 ## Running $as_me. ## 68308 _ASBOX 68309 $as_echo "$ac_log" 68310 } >&5 68311 68312 _ACEOF 68313 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68314 _ACEOF 68315 68316 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68317 68318 # Handling of arguments. 68319 for ac_config_target in $ac_config_targets 68320 do 68321 case $ac_config_target in 68322 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 68323 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 68324 "$OUTPUT_ROOT/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 68325 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 68326 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 68327 68328 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 68329 esac 68330 done 68331 68332 68333 # If the user did not use the arguments to specify the items to instantiate, 68334 # then the envvar interface is used. Set only those that are not. 68335 # We use the long form for the default assignment because of an extremely 68336 # bizarre bug on SunOS 4.1.3. 68337 if $ac_need_defaults; then 68338 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 68339 fi 68340 68341 # Have a temporary directory for convenience. Make it in the build tree 68342 # simply because there is no reason against having it here, and in addition, 68343 # creating and moving files from /tmp can sometimes cause problems. 68344 # Hook for its removal unless debugging. 68345 # Note that there is a small window in which the directory will not be cleaned: 68346 # after its creation but before its name has been assigned to `$tmp'. 68347 $debug || 68348 { 68349 tmp= ac_tmp= 68350 trap 'exit_status=$? 68351 : "${ac_tmp:=$tmp}" 68352 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 68353 ' 0 68354 trap 'as_fn_exit 1' 1 2 13 15 68355 } 68356 # Create a (secure) tmp directory for tmp files. 68357 68358 { 68359 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 68360 test -d "$tmp" 68361 } || 68362 { 68363 tmp=./conf$$-$RANDOM 68364 (umask 077 && mkdir "$tmp") 68365 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 68366 ac_tmp=$tmp 68367 68368 # Set up the scripts for CONFIG_FILES section. 68369 # No need to generate them if there are no CONFIG_FILES. 68370 # This happens for instance with `./config.status config.h'. 68371 if test -n "$CONFIG_FILES"; then 68372 68373 68374 ac_cr=`echo X | tr X '\015'` 68375 # On cygwin, bash can eat \r inside `` if the user requested igncr. 68376 # But we know of no other shell where ac_cr would be empty at this 68377 # point, so we can use a bashism as a fallback. 68378 if test "x$ac_cr" = x; then 68379 eval ac_cr=\$\'\\r\' 68380 fi 68381 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 68382 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 68383 ac_cs_awk_cr='\\r' 68384 else 68385 ac_cs_awk_cr=$ac_cr 68386 fi 68387 68388 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 68389 _ACEOF 68390 68391 68392 { 68393 echo "cat >conf$$subs.awk <<_ACEOF" && 68394 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 68395 echo "_ACEOF" 68396 } >conf$$subs.sh || 68397 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 68398 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 68399 ac_delim='%!_!# ' 68400 for ac_last_try in false false false false false :; do 68401 . ./conf$$subs.sh || 68402 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 68403 68404 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 68405 if test $ac_delim_n = $ac_delim_num; then 68406 break 68407 elif $ac_last_try; then 68408 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 68409 else 68410 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 68411 fi 68412 done 68413 rm -f conf$$subs.sh 68414 68415 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68416 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 68417 _ACEOF 68418 sed -n ' 68419 h 68420 s/^/S["/; s/!.*/"]=/ 68421 p 68422 g 68423 s/^[^!]*!// 68424 :repl 68425 t repl 68426 s/'"$ac_delim"'$// 68427 t delim 68428 :nl 68429 h 68430 s/\(.\{148\}\)..*/\1/ 68431 t more1 68432 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 68433 p 68434 n 68435 b repl 68436 :more1 68437 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 68438 p 68439 g 68440 s/.\{148\}// 68441 t nl 68442 :delim 68443 h 68444 s/\(.\{148\}\)..*/\1/ 68445 t more2 68446 s/["\\]/\\&/g; s/^/"/; s/$/"/ 68447 p 68448 b 68449 :more2 68450 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 68451 p 68452 g 68453 s/.\{148\}// 68454 t delim 68455 ' <conf$$subs.awk | sed ' 68456 /^[^""]/{ 68457 N 68458 s/\n// 68459 } 68460 ' >>$CONFIG_STATUS || ac_write_fail=1 68461 rm -f conf$$subs.awk 68462 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68463 _ACAWK 68464 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 68465 for (key in S) S_is_set[key] = 1 68466 FS = "" 68467 68468 } 68469 { 68470 line = $ 0 68471 nfields = split(line, field, "@") 68472 substed = 0 68473 len = length(field[1]) 68474 for (i = 2; i < nfields; i++) { 68475 key = field[i] 68476 keylen = length(key) 68477 if (S_is_set[key]) { 68478 value = S[key] 68479 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 68480 len += length(value) + length(field[++i]) 68481 substed = 1 68482 } else 68483 len += 1 + keylen 68484 } 68485 68486 print line 68487 } 68488 68489 _ACAWK 68490 _ACEOF 68491 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68492 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 68493 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 68494 else 68495 cat 68496 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 68497 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 68498 _ACEOF 68499 68500 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 68501 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 68502 # trailing colons and then remove the whole line if VPATH becomes empty 68503 # (actually we leave an empty line to preserve line numbers). 68504 if test "x$srcdir" = x.; then 68505 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 68506 h 68507 s/// 68508 s/^/:/ 68509 s/[ ]*$/:/ 68510 s/:\$(srcdir):/:/g 68511 s/:\${srcdir}:/:/g 68512 s/:@srcdir@:/:/g 68513 s/^:*// 68514 s/:*$// 68515 x 68516 s/\(=[ ]*\).*/\1/ 68517 G 68518 s/\n// 68519 s/^[^=]*=[ ]*$// 68520 }' 68521 fi 68522 68523 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68524 fi # test -n "$CONFIG_FILES" 68525 68526 68527 eval set X " :F $CONFIG_FILES " 68528 shift 68529 for ac_tag 68530 do 68531 case $ac_tag in 68532 :[FHLC]) ac_mode=$ac_tag; continue;; 68533 esac 68534 case $ac_mode$ac_tag in 68535 :[FHL]*:*);; 68536 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 68537 :[FH]-) ac_tag=-:-;; 68538 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 68539 esac 68540 ac_save_IFS=$IFS 68541 IFS=: 68542 set x $ac_tag 68543 IFS=$ac_save_IFS 68544 shift 68545 ac_file=$1 68546 shift 68547 68548 case $ac_mode in 68549 :L) ac_source=$1;; 68550 :[FH]) 68551 ac_file_inputs= 68552 for ac_f 68553 do 68554 case $ac_f in 68555 -) ac_f="$ac_tmp/stdin";; 68556 *) # Look for the file first in the build tree, then in the source tree 68557 # (if the path is not absolute). The absolute path cannot be DOS-style, 68558 # because $ac_f cannot contain `:'. 68559 test -f "$ac_f" || 68560 case $ac_f in 68561 [\\/$]*) false;; 68562 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 68563 esac || 68564 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 68565 esac 68566 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 68567 as_fn_append ac_file_inputs " '$ac_f'" 68568 done 68569 68570 # Let's still pretend it is `configure' which instantiates (i.e., don't 68571 # use $as_me), people would be surprised to read: 68572 # /* config.h. Generated by config.status. */ 68573 configure_input='Generated from '` 68574 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 68575 `' by configure.' 68576 if test x"$ac_file" != x-; then 68577 configure_input="$ac_file. $configure_input" 68578 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 68579 $as_echo "$as_me: creating $ac_file" >&6;} 68580 fi 68581 # Neutralize special characters interpreted by sed in replacement strings. 68582 case $configure_input in #( 68583 *\&* | *\|* | *\\* ) 68584 ac_sed_conf_input=`$as_echo "$configure_input" | 68585 sed 's/[\\\\&|]/\\\\&/g'`;; #( 68586 *) ac_sed_conf_input=$configure_input;; 68587 esac 68588 68589 case $ac_tag in 68590 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 68591 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 68592 esac 68593 ;; 68594 esac 68595 68596 ac_dir=`$as_dirname -- "$ac_file" || 68597 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 68598 X"$ac_file" : 'X\(//\)[^/]' \| \ 68599 X"$ac_file" : 'X\(//\)$' \| \ 68600 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 68601 $as_echo X"$ac_file" | 68602 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 68603 s//\1/ 68604 q 68605 } 68606 /^X\(\/\/\)[^/].*/{ 68607 s//\1/ 68608 q 68609 } 68610 /^X\(\/\/\)$/{ 68611 s//\1/ 68612 q 68613 } 68614 /^X\(\/\).*/{ 68615 s//\1/ 68616 q 68617 } 68618 s/.*/./; q'` 68619 as_dir="$ac_dir"; as_fn_mkdir_p 68620 ac_builddir=. 68621 68622 case "$ac_dir" in 68623 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 68624 *) 68625 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 68626 # A ".." for each directory in $ac_dir_suffix. 68627 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 68628 case $ac_top_builddir_sub in 68629 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 68630 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 68631 esac ;; 68632 esac 68633 ac_abs_top_builddir=$ac_pwd 68634 ac_abs_builddir=$ac_pwd$ac_dir_suffix 68635 # for backward compatibility: 68636 ac_top_builddir=$ac_top_build_prefix 68637 68638 case $srcdir in 68639 .) # We are building in place. 68640 ac_srcdir=. 68641 ac_top_srcdir=$ac_top_builddir_sub 68642 ac_abs_top_srcdir=$ac_pwd ;; 68643 [\\/]* | ?:[\\/]* ) # Absolute name. 68644 ac_srcdir=$srcdir$ac_dir_suffix; 68645 ac_top_srcdir=$srcdir 68646 ac_abs_top_srcdir=$srcdir ;; 68647 *) # Relative name. 68648 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 68649 ac_top_srcdir=$ac_top_build_prefix$srcdir 68650 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 68651 esac 68652 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 68653 68654 68655 case $ac_mode in 68656 :F) 68657 # 68658 # CONFIG_FILE 68659 # 68660 68661 _ACEOF 68662 68663 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68664 # If the template does not know about datarootdir, expand it. 68665 # FIXME: This hack should be removed a few years after 2.60. 68666 ac_datarootdir_hack=; ac_datarootdir_seen= 68667 ac_sed_dataroot=' 68668 /datarootdir/ { 68669 p 68670 q 68671 } 68672 /@datadir@/p 68673 /@docdir@/p 68674 /@infodir@/p 68675 /@localedir@/p 68676 /@mandir@/p' 68677 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 68678 *datarootdir*) ac_datarootdir_seen=yes;; 68679 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 68680 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 68681 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 68682 _ACEOF 68683 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68684 ac_datarootdir_hack=' 68685 s&@datadir@&$datadir&g 68686 s&@docdir@&$docdir&g 68687 s&@infodir@&$infodir&g 68688 s&@localedir@&$localedir&g 68689 s&@mandir@&$mandir&g 68690 s&\\\${datarootdir}&$datarootdir&g' ;; 68691 esac 68692 _ACEOF 68693 68694 # Neutralize VPATH when `$srcdir' = `.'. 68695 # Shell code in configure.ac might set extrasub. 68696 # FIXME: do we really want to maintain this feature? 68697 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 68698 ac_sed_extra="$ac_vpsub 68699 $extrasub 68700 _ACEOF 68701 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 68702 :t 68703 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 68704 s|@configure_input@|$ac_sed_conf_input|;t t 68705 s&@top_builddir@&$ac_top_builddir_sub&;t t 68706 s&@top_build_prefix@&$ac_top_build_prefix&;t t 68707 s&@srcdir@&$ac_srcdir&;t t 68708 s&@abs_srcdir@&$ac_abs_srcdir&;t t 68709 s&@top_srcdir@&$ac_top_srcdir&;t t 68710 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 68711 s&@builddir@&$ac_builddir&;t t 68712 s&@abs_builddir@&$ac_abs_builddir&;t t 68713 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 68714 $ac_datarootdir_hack 68715 " 68716 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 68717 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 68718 68719 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 68720 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 68721 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 68722 "$ac_tmp/out"`; test -z "$ac_out"; } && 68723 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 68724 which seems to be undefined. Please make sure it is defined" >&5 68725 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 68726 which seems to be undefined. Please make sure it is defined" >&2;} 68727 68728 rm -f "$ac_tmp/stdin" 68729 case $ac_file in 68730 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 68731 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 68732 esac \ 68733 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 68734 ;; 68735 68736 68737 68738 esac 68739 68740 done # for ac_tag 68741 68742 68743 as_fn_exit 0 68744 _ACEOF 68745 ac_clean_files=$ac_clean_files_save 68746 68747 test $ac_write_fail = 0 || 68748 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 68749 68750 68751 # configure is writing to config.log, and then calls config.status. 68752 # config.status does its own redirection, appending to config.log. 68753 # Unfortunately, on DOS this fails, as config.log is still kept open 68754 # by configure, so config.status won't be able to write to it; its 68755 # output is simply discarded. So we exec the FD to /dev/null, 68756 # effectively closing config.log, so it can be properly (re)opened and 68757 # appended to by config.status. When coming back to configure, we 68758 # need to make the FD available again. 68759 if test "$no_create" != yes; then 68760 ac_cs_success=: 68761 ac_config_status_args= 68762 test "$silent" = yes && 68763 ac_config_status_args="$ac_config_status_args --quiet" 68764 exec 5>/dev/null 68765 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 68766 exec 5>>config.log 68767 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 68768 # would make configure fail if this is the last instruction. 68769 $ac_cs_success || as_fn_exit 1 68770 fi 68771 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 68772 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 68773 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 68774 fi 68775 68776 68777 # After AC_OUTPUT, we need to do final work 68778 68779 68780 # Try to move config.log (generated by autoconf) to the configure-support directory. 68781 if test -e ./config.log; then 68782 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 68783 fi 68784 68785 # Rotate our log file (configure.log) 68786 if test -e "$OUTPUT_ROOT/configure.log.old"; then 68787 $RM -f "$OUTPUT_ROOT/configure.log.old" 68788 fi 68789 if test -e "$OUTPUT_ROOT/configure.log"; then 68790 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 68791 fi 68792 68793 # Move configure.log from current directory to the build output root 68794 if test -e ./configure.log; then 68795 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 68796 fi 68797 68798 # Make the compare script executable 68799 $CHMOD +x $OUTPUT_ROOT/compare.sh 68800 68801 68802 # Finally output some useful information to the user 68803 68804 # Finally output some useful information to the user 68805 68806 printf "\n" 68807 printf "====================================================\n" 68808 if test "x$no_create" != "xyes"; then 68809 if test "x$IS_RECONFIGURE" != "xyes"; then 68810 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 68811 else 68812 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 68813 fi 68814 else 68815 if test "x$IS_RECONFIGURE" != "xyes"; then 68816 printf "A configuration has been successfully checked but not created\n" 68817 else 68818 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 68819 fi 68820 fi 68821 if test "x$CONFIGURE_COMMAND_LINE" != x; then 68822 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 68823 else 68824 printf "using default settings.\n" 68825 fi 68826 68827 printf "\n" 68828 printf "Configuration summary:\n" 68829 printf "* Debug level: $DEBUG_LEVEL\n" 68830 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 68831 printf "* JDK variant: $JDK_VARIANT\n" 68832 printf "* JVM variants: $JVM_VARIANTS\n" 68833 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 68834 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 68835 68836 printf "\n" 68837 printf "Tools summary:\n" 68838 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 68839 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 68840 fi 68841 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 68842 if test "x$TOOLCHAIN_VERSION" != "x"; then 68843 print_version=" $TOOLCHAIN_VERSION" 68844 fi 68845 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 68846 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 68847 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 68848 68849 printf "\n" 68850 printf "Build performance summary:\n" 68851 printf "* Cores to use: $JOBS\n" 68852 printf "* Memory limit: $MEMORY_SIZE MB\n" 68853 if test "x$CCACHE_STATUS" != "x"; then 68854 printf "* ccache status: $CCACHE_STATUS\n" 68855 fi 68856 printf "\n" 68857 68858 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 68859 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 68860 printf "will result in longer build times.\n" 68861 printf "\n" 68862 fi 68863 68864 if test "x$FOUND_ALT_VARIABLES" != "x"; then 68865 printf "WARNING: You have old-style ALT_ environment variables set.\n" 68866 printf "These are not respected, and will be ignored. It is recommended\n" 68867 printf "that you clean your environment. The following variables are set:\n" 68868 printf "$FOUND_ALT_VARIABLES\n" 68869 printf "\n" 68870 fi 68871 68872 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 68873 printf "WARNING: Your build output directory is not on a local disk.\n" 68874 printf "This will severely degrade build performance!\n" 68875 printf "It is recommended that you create an output directory on a local disk,\n" 68876 printf "and run the configure script again from that directory.\n" 68877 printf "\n" 68878 fi 68879 68880 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 68881 printf "WARNING: The result of this configuration has overridden an older\n" 68882 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 68883 printf "proper build. Failure to do so might result in strange build problems.\n" 68884 printf "\n" 68885 fi 68886 68887 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 68888 printf "WARNING: The result of this configuration was not saved.\n" 68889 printf "You should run without '--no-create | -n' to create the configuration.\n" 68890 printf "\n" 68891 fi 68892 68893 68894 68895 # Locate config.log. 68896 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 68897 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 68898 elif test -e "./config.log"; then 68899 CONFIG_LOG_PATH="." 68900 fi 68901 68902 if test -e "$CONFIG_LOG_PATH/config.log"; then 68903 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 68904 if test $? -eq 0; then 68905 printf "The following warnings were produced. Repeated here for convenience:\n" 68906 # We must quote sed expression (using []) to stop m4 from eating the []. 68907 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 68908 printf "\n" 68909 fi 68910 fi 68911