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 STLPORT_LIB 658 LIBZIP_CAN_USE_MMAP 659 LIBDL 660 LIBM 661 USE_EXTERNAL_LCMS 662 LCMS_LIBS 663 LCMS_CFLAGS 664 USE_EXTERNAL_LIBZ 665 USE_EXTERNAL_LIBPNG 666 PNG_LIBS 667 PNG_CFLAGS 668 USE_EXTERNAL_LIBGIF 669 USE_EXTERNAL_LIBJPEG 670 LLVM_LIBS 671 LLVM_LDFLAGS 672 LLVM_CFLAGS 673 LLVM_CONFIG 674 LIBFFI_LIBS 675 LIBFFI_CFLAGS 676 ALSA_LIBS 677 ALSA_CFLAGS 678 FREETYPE_BUNDLE_LIB_PATH 679 FREETYPE_LIBS 680 FREETYPE_CFLAGS 681 CUPS_CFLAGS 682 X_EXTRA_LIBS 683 X_LIBS 684 X_PRE_LIBS 685 X_CFLAGS 686 XMKMF 687 MSVCP_DLL 688 MSVCR_DLL 689 LIBCXX 690 STATIC_CXX_SETTING 691 FIXPATH_DETACH_FLAG 692 FIXPATH 693 BUILD_GTEST 694 VALID_JVM_FEATURES 695 JVM_FEATURES_custom 696 JVM_FEATURES_zeroshark 697 JVM_FEATURES_zero 698 JVM_FEATURES_minimal 699 JVM_FEATURES_core 700 JVM_FEATURES_client 701 JVM_FEATURES_server 702 INCLUDE_DTRACE 703 GCOV_ENABLED 704 STRIP_POLICY 705 DEBUG_BINARIES 706 ZIP_EXTERNAL_DEBUG_SYMBOLS 707 COPY_DEBUG_SYMBOLS 708 COMPILE_WITH_DEBUG_SYMBOLS 709 CFLAGS_WARNINGS_ARE_ERRORS 710 BUILD_CC_DISABLE_WARNING_PREFIX 711 DISABLE_WARNING_PREFIX 712 HOTSPOT_SET_WARNINGS_AS_ERRORS 713 WARNINGS_AS_ERRORS 714 COMPILER_SUPPORTS_TARGET_BITS_FLAG 715 ZERO_ARCHFLAG 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_MIN 752 CXXSTD_CXXFLAG 753 CXX_O_FLAG_SIZE 754 CXX_O_FLAG_NONE 755 CXX_O_FLAG_DEBUG 756 CXX_O_FLAG_NORM 757 CXX_O_FLAG_HI 758 CXX_O_FLAG_HIGHEST 759 CXX_O_FLAG_HIGHEST_JVM 760 C_O_FLAG_SIZE 761 C_O_FLAG_NONE 762 C_O_FLAG_DEBUG 763 C_O_FLAG_NORM 764 C_O_FLAG_HI 765 C_O_FLAG_HIGHEST 766 C_O_FLAG_HIGHEST_JVM 767 JVM_CFLAGS_SYMBOLS 768 CXXFLAGS_DEBUG_SYMBOLS 769 CFLAGS_DEBUG_SYMBOLS 770 CXX_FLAG_DEPS 771 C_FLAG_DEPS 772 SHARED_LIBRARY_FLAGS 773 SET_SHARED_LIBRARY_MAPFILE 774 SET_SHARED_LIBRARY_NAME 775 SET_SHARED_LIBRARY_ORIGIN 776 SET_EXECUTABLE_ORIGIN 777 CXX_FLAG_REORDER 778 C_FLAG_REORDER 779 JVM_RCFLAGS 780 RC_FLAGS 781 AR_OUT_OPTION 782 LD_OUT_OPTION 783 EXE_OUT_OPTION 784 CC_OUT_OPTION 785 STRIPFLAGS 786 ARFLAGS 787 COMPILER_BINDCMD_FILE_FLAG 788 COMPILER_COMMAND_FILE_FLAG 789 COMPILER_TARGET_BITS_FLAG 790 JT_HOME 791 JTREGEXE 792 HOTSPOT_TOOLCHAIN_TYPE 793 USING_BROKEN_SUSE_LD 794 PACKAGE_PATH 795 USE_CLANG 796 HOTSPOT_LD 797 HOTSPOT_CXX 798 HOTSPOT_RC 799 HOTSPOT_MT 800 BUILD_AS 801 BUILD_LDCXX 802 BUILD_LD 803 BUILD_STRIP 804 BUILD_OBJCOPY 805 BUILD_AR 806 BUILD_NM 807 BUILD_CXX 808 BUILD_CC 809 BUILD_SYSROOT_LDFLAGS 810 BUILD_SYSROOT_CFLAGS 811 ac_ct_OBJDUMP 812 OBJDUMP 813 ac_ct_OBJCOPY 814 OBJCOPY 815 ac_ct_NM 816 ac_ct_STRIP 817 GNM 818 NM 819 STRIP 820 MSBUILD 821 DUMPBIN 822 RC 823 MT 824 LIPO 825 ac_ct_AR 826 AR 827 AS 828 LDCXX 829 LD 830 CXXCPP 831 CPP 832 CXX_VERSION_NUMBER 833 CC_VERSION_NUMBER 834 ac_ct_CXX 835 CXXFLAGS 836 CXX 837 TOOLCHAIN_PATH_CXX 838 POTENTIAL_CXX 839 OBJEXT 840 EXEEXT 841 ac_ct_CC 842 CPPFLAGS 843 LDFLAGS 844 CFLAGS 845 CC 846 TOOLCHAIN_PATH_CC 847 POTENTIAL_CC 848 TOOLCHAIN_VERSION 849 VS_LIB 850 VS_INCLUDE 851 VS_PATH 852 CYGWIN_LINK 853 SYSROOT_LDFLAGS 854 SYSROOT_CFLAGS 855 EXTRA_LDFLAGS 856 EXTRA_CXXFLAGS 857 EXTRA_CFLAGS 858 LEGACY_EXTRA_LDFLAGS 859 LEGACY_EXTRA_CXXFLAGS 860 LEGACY_EXTRA_CFLAGS 861 EXE_SUFFIX 862 OBJ_SUFFIX 863 STATIC_LIBRARY 864 SHARED_LIBRARY 865 STATIC_LIBRARY_SUFFIX 866 SHARED_LIBRARY_SUFFIX 867 LIBRARY_PREFIX 868 TOOLCHAIN_TYPE 869 STATIC_BUILD 870 IMPORT_MODULES_MAKE 871 IMPORT_MODULES_SRC 872 IMPORT_MODULES_CONF 873 IMPORT_MODULES_LIBS 874 IMPORT_MODULES_CMDS 875 IMPORT_MODULES_CLASSES 876 BUILD_HOTSPOT 877 HOTSPOT_DIST 878 BUILD_OUTPUT 879 JDK_TOPDIR 880 NASHORN_TOPDIR 881 HOTSPOT_TOPDIR 882 JAXWS_TOPDIR 883 JAXP_TOPDIR 884 CORBA_TOPDIR 885 LANGTOOLS_TOPDIR 886 EXTERNAL_BUILDJDK 887 BUILD_JDK 888 CREATE_BUILDJDK 889 JLINK 890 JMOD 891 BOOT_JDK_BITS 892 JAVAC_FLAGS 893 BOOT_JDK_MODULAR 894 BOOT_JDK_SOURCETARGET 895 JARSIGNER 896 JAR 897 JAVAH 898 JAVAC 899 JAVA 900 BOOT_JDK 901 JAVA_CHECK 902 JAVAC_CHECK 903 VERSION_IS_GA 904 VERSION_SHORT 905 VERSION_STRING 906 VERSION_NUMBER_FOUR_POSITIONS 907 VERSION_NUMBER 908 VERSION_OPT 909 VERSION_BUILD 910 VERSION_PRE 911 VERSION_PATCH 912 VERSION_SECURITY 913 VERSION_MINOR 914 VERSION_MAJOR 915 MACOSX_BUNDLE_ID_BASE 916 MACOSX_BUNDLE_NAME_BASE 917 HOTSPOT_VM_DISTRO 918 COMPANY_NAME 919 JDK_RC_PLATFORM_NAME 920 PRODUCT_SUFFIX 921 PRODUCT_NAME 922 LAUNCHER_NAME 923 JLINK_KEEP_PACKAGED_MODULES 924 COPYRIGHT_YEAR 925 COMPRESS_JARS 926 INCLUDE_SA 927 UNLIMITED_CRYPTO 928 CACERTS_FILE 929 BUILD_HEADLESS 930 SUPPORT_HEADFUL 931 SUPPORT_HEADLESS 932 DEFAULT_MAKE_TARGET 933 OS_VERSION_MICRO 934 OS_VERSION_MINOR 935 OS_VERSION_MAJOR 936 PKG_CONFIG 937 BASH_ARGS 938 SETFILE 939 CODESIGN 940 XATTR 941 DSYMUTIL 942 IS_GNU_TIME 943 PATCH 944 DTRACE 945 TIME 946 STAT 947 HG 948 READELF 949 OTOOL 950 LDD 951 ZIP 952 UNZIP 953 TAR_SUPPORTS_TRANSFORM 954 TAR_INCLUDE_PARAM 955 TAR_CREATE_EXTRA_PARAM 956 TAR_TYPE 957 FIND_DELETE 958 OUTPUT_SYNC 959 OUTPUT_SYNC_SUPPORTED 960 CHECK_TOOLSDIR_MAKE 961 CHECK_TOOLSDIR_GMAKE 962 CHECK_MAKE 963 CHECK_GMAKE 964 MAKE 965 PKGHANDLER 966 CONFIGURESUPPORT_OUTPUTDIR 967 OUTPUT_ROOT 968 CONF_NAME 969 SPEC 970 SDKROOT 971 XCODEBUILD 972 VALID_JVM_VARIANTS 973 JVM_VARIANTS 974 DEBUG_LEVEL 975 HOTSPOT_DEBUG_LEVEL 976 JDK_VARIANT 977 USERNAME 978 CANONICAL_TOPDIR 979 ORIGINAL_TOPDIR 980 TOPDIR 981 PATH_SEP 982 ZERO_ARCHDEF 983 HOTSPOT_BUILD_CPU_DEFINE 984 HOTSPOT_BUILD_CPU_ARCH 985 HOTSPOT_BUILD_CPU 986 HOTSPOT_BUILD_OS_TYPE 987 HOTSPOT_BUILD_OS 988 OPENJDK_BUILD_BUNDLE_PLATFORM 989 OPENJDK_BUILD_CPU_BUNDLE 990 OPENJDK_BUILD_OS_BUNDLE 991 OPENJDK_BUILD_OS_EXPORT_DIR 992 OPENJDK_BUILD_CPU_JLI_CFLAGS 993 OPENJDK_BUILD_CPU_OSARCH 994 OPENJDK_BUILD_CPU_ISADIR 995 OPENJDK_BUILD_CPU_LIBDIR 996 OPENJDK_BUILD_CPU_LEGACY_LIB 997 OPENJDK_BUILD_CPU_LEGACY 998 HOTSPOT_TARGET_CPU_DEFINE 999 HOTSPOT_TARGET_CPU_ARCH 1000 HOTSPOT_TARGET_CPU 1001 HOTSPOT_TARGET_OS_TYPE 1002 HOTSPOT_TARGET_OS 1003 DEFINE_CROSS_COMPILE_ARCH 1004 LP64 1005 OPENJDK_TARGET_BUNDLE_PLATFORM 1006 OPENJDK_TARGET_CPU_BUNDLE 1007 OPENJDK_TARGET_OS_BUNDLE 1008 OPENJDK_TARGET_OS_EXPORT_DIR 1009 OPENJDK_TARGET_CPU_JLI_CFLAGS 1010 OPENJDK_TARGET_CPU_OSARCH 1011 OPENJDK_TARGET_CPU_ISADIR 1012 OPENJDK_TARGET_CPU_LIBDIR 1013 OPENJDK_TARGET_CPU_LEGACY_LIB 1014 OPENJDK_TARGET_CPU_LEGACY 1015 REQUIRED_OS_VERSION 1016 REQUIRED_OS_NAME 1017 COMPILE_TYPE 1018 OPENJDK_TARGET_CPU_ENDIAN 1019 OPENJDK_TARGET_CPU_BITS 1020 OPENJDK_TARGET_CPU_ARCH 1021 OPENJDK_TARGET_CPU 1022 OPENJDK_TARGET_OS_ENV 1023 OPENJDK_TARGET_OS_TYPE 1024 OPENJDK_TARGET_OS 1025 OPENJDK_BUILD_CPU_ENDIAN 1026 OPENJDK_BUILD_CPU_BITS 1027 OPENJDK_BUILD_CPU_ARCH 1028 OPENJDK_BUILD_CPU 1029 OPENJDK_BUILD_OS_ENV 1030 OPENJDK_BUILD_OS_TYPE 1031 OPENJDK_BUILD_OS 1032 OPENJDK_BUILD_AUTOCONF_NAME 1033 OPENJDK_TARGET_AUTOCONF_NAME 1034 target_os 1035 target_vendor 1036 target_cpu 1037 target 1038 host_os 1039 host_vendor 1040 host_cpu 1041 host 1042 build_os 1043 build_vendor 1044 build_cpu 1045 build 1046 NICE 1047 CPIO 1048 DF 1049 READLINK 1050 CYGPATH 1051 SED 1052 FGREP 1053 EGREP 1054 GREP 1055 AWK 1056 XARGS 1057 WHICH 1058 WC 1059 UNIQ 1060 UNAME 1061 TR 1062 TOUCH 1063 TEE 1064 TAR 1065 TAIL 1066 SORT 1067 SH 1068 RMDIR 1069 RM 1070 PRINTF 1071 NAWK 1072 MV 1073 MKTEMP 1074 MKDIR 1075 LS 1076 LN 1077 GZIP 1078 GUNZIP 1079 HEAD 1080 FIND 1081 FILE 1082 EXPR 1083 ECHO 1084 DIRNAME 1085 DIFF 1086 DATE 1087 CUT 1088 CP 1089 COMM 1090 CMP 1091 CHMOD 1092 CAT 1093 BASH 1094 BASENAME 1095 DATE_WHEN_CONFIGURED 1096 ORIGINAL_PATH 1097 CONFIGURE_COMMAND_LINE 1098 target_alias 1099 host_alias 1100 build_alias 1101 LIBS 1102 ECHO_T 1103 ECHO_N 1104 ECHO_C 1105 DEFS 1106 mandir 1107 localedir 1108 libdir 1109 psdir 1110 pdfdir 1111 dvidir 1112 htmldir 1113 infodir 1114 docdir 1115 oldincludedir 1116 includedir 1117 localstatedir 1118 sharedstatedir 1119 sysconfdir 1120 datadir 1121 datarootdir 1122 libexecdir 1123 sbindir 1124 bindir 1125 program_transform_name 1126 prefix 1127 exec_prefix 1128 PACKAGE_URL 1129 PACKAGE_BUGREPORT 1130 PACKAGE_STRING 1131 PACKAGE_VERSION 1132 PACKAGE_TARNAME 1133 PACKAGE_NAME 1134 PATH_SEPARATOR 1135 SHELL' 1136 ac_subst_files='' 1137 ac_user_opts=' 1138 enable_option_checking 1139 with_target_bits 1140 enable_openjdk_only 1141 with_custom_make_dir 1142 with_jdk_variant 1143 enable_debug 1144 with_debug_level 1145 with_jvm_variants 1146 with_devkit 1147 with_sys_root 1148 with_sysroot 1149 with_tools_dir 1150 with_toolchain_path 1151 with_extra_path 1152 with_sdk_name 1153 with_conf_name 1154 with_output_sync 1155 with_default_make_target 1156 enable_headful 1157 with_cacerts_file 1158 enable_unlimited_crypto 1159 with_copyright_year 1160 enable_keep_packaged_modules 1161 with_milestone 1162 with_update_version 1163 with_user_release_suffix 1164 with_build_number 1165 with_version_string 1166 with_version_pre 1167 with_version_opt 1168 with_version_build 1169 with_version_major 1170 with_version_minor 1171 with_version_security 1172 with_version_patch 1173 with_boot_jdk 1174 with_build_jdk 1175 with_add_source_root 1176 with_override_source_root 1177 with_adds_and_overrides 1178 with_override_langtools 1179 with_override_corba 1180 with_override_jaxp 1181 with_override_jaxws 1182 with_override_hotspot 1183 with_override_nashorn 1184 with_override_jdk 1185 with_import_hotspot 1186 with_import_modules 1187 enable_static_build 1188 with_toolchain_type 1189 with_extra_cflags 1190 with_extra_cxxflags 1191 with_extra_ldflags 1192 with_toolchain_version 1193 with_build_devkit 1194 with_jtreg 1195 enable_warnings_as_errors 1196 with_native_debug_symbols 1197 enable_debug_symbols 1198 enable_zip_debug_info 1199 enable_native_coverage 1200 enable_dtrace 1201 with_jvm_features 1202 with_jvm_interpreter 1203 enable_hotspot_gtest 1204 with_stdc__lib 1205 with_msvcr_dll 1206 with_msvcp_dll 1207 with_x 1208 with_cups 1209 with_cups_include 1210 with_freetype 1211 with_freetype_include 1212 with_freetype_lib 1213 with_freetype_src 1214 enable_freetype_bundling 1215 with_alsa 1216 with_alsa_include 1217 with_alsa_lib 1218 with_libffi 1219 with_libffi_include 1220 with_libffi_lib 1221 with_libjpeg 1222 with_giflib 1223 with_libpng 1224 with_zlib 1225 with_lcms 1226 with_dxsdk 1227 with_dxsdk_lib 1228 with_dxsdk_include 1229 enable_jtreg_failure_handler 1230 enable_generate_classlist 1231 with_num_cores 1232 with_memory_size 1233 with_jobs 1234 with_test_jobs 1235 with_boot_jdk_jvmargs 1236 with_sjavac_server_java 1237 enable_sjavac 1238 enable_javac_server 1239 enable_icecc 1240 enable_precompiled_headers 1241 enable_ccache 1242 with_ccache_dir 1243 ' 1244 ac_precious_vars='build_alias 1245 host_alias 1246 target_alias 1247 BASENAME 1248 BASH 1249 CAT 1250 CHMOD 1251 CMP 1252 COMM 1253 CP 1254 CUT 1255 DATE 1256 DIFF 1257 DIRNAME 1258 ECHO 1259 EXPR 1260 FILE 1261 FIND 1262 HEAD 1263 GUNZIP 1264 GZIP 1265 LN 1266 LS 1267 MKDIR 1268 MKTEMP 1269 MV 1270 NAWK 1271 PRINTF 1272 RM 1273 RMDIR 1274 SH 1275 SORT 1276 TAIL 1277 TAR 1278 TEE 1279 TOUCH 1280 TR 1281 UNAME 1282 UNIQ 1283 WC 1284 WHICH 1285 XARGS 1286 AWK 1287 GREP 1288 EGREP 1289 FGREP 1290 SED 1291 CYGPATH 1292 READLINK 1293 DF 1294 CPIO 1295 NICE 1296 MAKE 1297 UNZIP 1298 ZIP 1299 LDD 1300 OTOOL 1301 READELF 1302 HG 1303 STAT 1304 TIME 1305 DTRACE 1306 PATCH 1307 DSYMUTIL 1308 XATTR 1309 CODESIGN 1310 SETFILE 1311 PKG_CONFIG 1312 JAVA 1313 JAVAC 1314 JAVAH 1315 JAR 1316 JARSIGNER 1317 CC 1318 CFLAGS 1319 LDFLAGS 1320 LIBS 1321 CPPFLAGS 1322 CXX 1323 CXXFLAGS 1324 CCC 1325 CPP 1326 CXXCPP 1327 AS 1328 AR 1329 LIPO 1330 STRIP 1331 NM 1332 GNM 1333 OBJCOPY 1334 OBJDUMP 1335 BUILD_CC 1336 BUILD_CXX 1337 BUILD_NM 1338 BUILD_AR 1339 BUILD_OBJCOPY 1340 BUILD_STRIP 1341 JTREGEXE 1342 XMKMF 1343 FREETYPE_CFLAGS 1344 FREETYPE_LIBS 1345 ALSA_CFLAGS 1346 ALSA_LIBS 1347 LIBFFI_CFLAGS 1348 LIBFFI_LIBS 1349 PNG_CFLAGS 1350 PNG_LIBS 1351 LCMS_CFLAGS 1352 LCMS_LIBS 1353 ICECC_CMD 1354 ICECC_CREATE_ENV 1355 ICECC_WRAPPER 1356 CCACHE' 1357 1358 1359 # Initialize some variables set by options. 1360 ac_init_help= 1361 ac_init_version=false 1362 ac_unrecognized_opts= 1363 ac_unrecognized_sep= 1364 # The variables have the same names as the options, with 1365 # dashes changed to underlines. 1366 cache_file=/dev/null 1367 exec_prefix=NONE 1368 no_create= 1369 no_recursion= 1370 prefix=NONE 1371 program_prefix=NONE 1372 program_suffix=NONE 1373 program_transform_name=s,x,x, 1374 silent= 1375 site= 1376 srcdir= 1377 verbose= 1378 x_includes=NONE 1379 x_libraries=NONE 1380 1381 # Installation directory options. 1382 # These are left unexpanded so users can "make install exec_prefix=/foo" 1383 # and all the variables that are supposed to be based on exec_prefix 1384 # by default will actually change. 1385 # Use braces instead of parens because sh, perl, etc. also accept them. 1386 # (The list follows the same order as the GNU Coding Standards.) 1387 bindir='${exec_prefix}/bin' 1388 sbindir='${exec_prefix}/sbin' 1389 libexecdir='${exec_prefix}/libexec' 1390 datarootdir='${prefix}/share' 1391 datadir='${datarootdir}' 1392 sysconfdir='${prefix}/etc' 1393 sharedstatedir='${prefix}/com' 1394 localstatedir='${prefix}/var' 1395 includedir='${prefix}/include' 1396 oldincludedir='/usr/include' 1397 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1398 infodir='${datarootdir}/info' 1399 htmldir='${docdir}' 1400 dvidir='${docdir}' 1401 pdfdir='${docdir}' 1402 psdir='${docdir}' 1403 libdir='${exec_prefix}/lib' 1404 localedir='${datarootdir}/locale' 1405 mandir='${datarootdir}/man' 1406 1407 ac_prev= 1408 ac_dashdash= 1409 for ac_option 1410 do 1411 # If the previous option needs an argument, assign it. 1412 if test -n "$ac_prev"; then 1413 eval $ac_prev=\$ac_option 1414 ac_prev= 1415 continue 1416 fi 1417 1418 case $ac_option in 1419 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1420 *=) ac_optarg= ;; 1421 *) ac_optarg=yes ;; 1422 esac 1423 1424 # Accept the important Cygnus configure options, so we can diagnose typos. 1425 1426 case $ac_dashdash$ac_option in 1427 --) 1428 ac_dashdash=yes ;; 1429 1430 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1431 ac_prev=bindir ;; 1432 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1433 bindir=$ac_optarg ;; 1434 1435 -build | --build | --buil | --bui | --bu) 1436 ac_prev=build_alias ;; 1437 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1438 build_alias=$ac_optarg ;; 1439 1440 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1441 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1442 ac_prev=cache_file ;; 1443 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1444 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1445 cache_file=$ac_optarg ;; 1446 1447 --config-cache | -C) 1448 cache_file=config.cache ;; 1449 1450 -datadir | --datadir | --datadi | --datad) 1451 ac_prev=datadir ;; 1452 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1453 datadir=$ac_optarg ;; 1454 1455 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1456 | --dataroo | --dataro | --datar) 1457 ac_prev=datarootdir ;; 1458 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1459 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1460 datarootdir=$ac_optarg ;; 1461 1462 -disable-* | --disable-*) 1463 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1464 # Reject names that are not valid shell variable names. 1465 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1466 as_fn_error $? "invalid feature name: $ac_useropt" 1467 ac_useropt_orig=$ac_useropt 1468 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1469 case $ac_user_opts in 1470 *" 1471 "enable_$ac_useropt" 1472 "*) ;; 1473 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1474 ac_unrecognized_sep=', ';; 1475 esac 1476 eval enable_$ac_useropt=no ;; 1477 1478 -docdir | --docdir | --docdi | --doc | --do) 1479 ac_prev=docdir ;; 1480 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1481 docdir=$ac_optarg ;; 1482 1483 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1484 ac_prev=dvidir ;; 1485 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1486 dvidir=$ac_optarg ;; 1487 1488 -enable-* | --enable-*) 1489 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1490 # Reject names that are not valid shell variable names. 1491 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1492 as_fn_error $? "invalid feature name: $ac_useropt" 1493 ac_useropt_orig=$ac_useropt 1494 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1495 case $ac_user_opts in 1496 *" 1497 "enable_$ac_useropt" 1498 "*) ;; 1499 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1500 ac_unrecognized_sep=', ';; 1501 esac 1502 eval enable_$ac_useropt=\$ac_optarg ;; 1503 1504 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1505 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1506 | --exec | --exe | --ex) 1507 ac_prev=exec_prefix ;; 1508 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1509 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1510 | --exec=* | --exe=* | --ex=*) 1511 exec_prefix=$ac_optarg ;; 1512 1513 -gas | --gas | --ga | --g) 1514 # Obsolete; use --with-gas. 1515 with_gas=yes ;; 1516 1517 -help | --help | --hel | --he | -h) 1518 ac_init_help=long ;; 1519 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1520 ac_init_help=recursive ;; 1521 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1522 ac_init_help=short ;; 1523 1524 -host | --host | --hos | --ho) 1525 ac_prev=host_alias ;; 1526 -host=* | --host=* | --hos=* | --ho=*) 1527 host_alias=$ac_optarg ;; 1528 1529 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1530 ac_prev=htmldir ;; 1531 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1532 | --ht=*) 1533 htmldir=$ac_optarg ;; 1534 1535 -includedir | --includedir | --includedi | --included | --include \ 1536 | --includ | --inclu | --incl | --inc) 1537 ac_prev=includedir ;; 1538 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1539 | --includ=* | --inclu=* | --incl=* | --inc=*) 1540 includedir=$ac_optarg ;; 1541 1542 -infodir | --infodir | --infodi | --infod | --info | --inf) 1543 ac_prev=infodir ;; 1544 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1545 infodir=$ac_optarg ;; 1546 1547 -libdir | --libdir | --libdi | --libd) 1548 ac_prev=libdir ;; 1549 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1550 libdir=$ac_optarg ;; 1551 1552 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1553 | --libexe | --libex | --libe) 1554 ac_prev=libexecdir ;; 1555 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1556 | --libexe=* | --libex=* | --libe=*) 1557 libexecdir=$ac_optarg ;; 1558 1559 -localedir | --localedir | --localedi | --localed | --locale) 1560 ac_prev=localedir ;; 1561 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1562 localedir=$ac_optarg ;; 1563 1564 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1565 | --localstate | --localstat | --localsta | --localst | --locals) 1566 ac_prev=localstatedir ;; 1567 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1568 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1569 localstatedir=$ac_optarg ;; 1570 1571 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1572 ac_prev=mandir ;; 1573 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1574 mandir=$ac_optarg ;; 1575 1576 -nfp | --nfp | --nf) 1577 # Obsolete; use --without-fp. 1578 with_fp=no ;; 1579 1580 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1581 | --no-cr | --no-c | -n) 1582 no_create=yes ;; 1583 1584 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1585 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1586 no_recursion=yes ;; 1587 1588 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1589 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1590 | --oldin | --oldi | --old | --ol | --o) 1591 ac_prev=oldincludedir ;; 1592 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1593 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1594 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1595 oldincludedir=$ac_optarg ;; 1596 1597 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1598 ac_prev=prefix ;; 1599 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1600 prefix=$ac_optarg ;; 1601 1602 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1603 | --program-pre | --program-pr | --program-p) 1604 ac_prev=program_prefix ;; 1605 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1606 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1607 program_prefix=$ac_optarg ;; 1608 1609 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1610 | --program-suf | --program-su | --program-s) 1611 ac_prev=program_suffix ;; 1612 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1613 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1614 program_suffix=$ac_optarg ;; 1615 1616 -program-transform-name | --program-transform-name \ 1617 | --program-transform-nam | --program-transform-na \ 1618 | --program-transform-n | --program-transform- \ 1619 | --program-transform | --program-transfor \ 1620 | --program-transfo | --program-transf \ 1621 | --program-trans | --program-tran \ 1622 | --progr-tra | --program-tr | --program-t) 1623 ac_prev=program_transform_name ;; 1624 -program-transform-name=* | --program-transform-name=* \ 1625 | --program-transform-nam=* | --program-transform-na=* \ 1626 | --program-transform-n=* | --program-transform-=* \ 1627 | --program-transform=* | --program-transfor=* \ 1628 | --program-transfo=* | --program-transf=* \ 1629 | --program-trans=* | --program-tran=* \ 1630 | --progr-tra=* | --program-tr=* | --program-t=*) 1631 program_transform_name=$ac_optarg ;; 1632 1633 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1634 ac_prev=pdfdir ;; 1635 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1636 pdfdir=$ac_optarg ;; 1637 1638 -psdir | --psdir | --psdi | --psd | --ps) 1639 ac_prev=psdir ;; 1640 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1641 psdir=$ac_optarg ;; 1642 1643 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1644 | -silent | --silent | --silen | --sile | --sil) 1645 silent=yes ;; 1646 1647 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1648 ac_prev=sbindir ;; 1649 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1650 | --sbi=* | --sb=*) 1651 sbindir=$ac_optarg ;; 1652 1653 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1654 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1655 | --sharedst | --shareds | --shared | --share | --shar \ 1656 | --sha | --sh) 1657 ac_prev=sharedstatedir ;; 1658 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1659 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1660 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1661 | --sha=* | --sh=*) 1662 sharedstatedir=$ac_optarg ;; 1663 1664 -site | --site | --sit) 1665 ac_prev=site ;; 1666 -site=* | --site=* | --sit=*) 1667 site=$ac_optarg ;; 1668 1669 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1670 ac_prev=srcdir ;; 1671 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1672 srcdir=$ac_optarg ;; 1673 1674 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1675 | --syscon | --sysco | --sysc | --sys | --sy) 1676 ac_prev=sysconfdir ;; 1677 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1678 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1679 sysconfdir=$ac_optarg ;; 1680 1681 -target | --target | --targe | --targ | --tar | --ta | --t) 1682 ac_prev=target_alias ;; 1683 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1684 target_alias=$ac_optarg ;; 1685 1686 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1687 verbose=yes ;; 1688 1689 -version | --version | --versio | --versi | --vers | -V) 1690 ac_init_version=: ;; 1691 1692 -with-* | --with-*) 1693 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1694 # Reject names that are not valid shell variable names. 1695 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1696 as_fn_error $? "invalid package name: $ac_useropt" 1697 ac_useropt_orig=$ac_useropt 1698 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1699 case $ac_user_opts in 1700 *" 1701 "with_$ac_useropt" 1702 "*) ;; 1703 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1704 ac_unrecognized_sep=', ';; 1705 esac 1706 eval with_$ac_useropt=\$ac_optarg ;; 1707 1708 -without-* | --without-*) 1709 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1710 # Reject names that are not valid shell variable names. 1711 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1712 as_fn_error $? "invalid package name: $ac_useropt" 1713 ac_useropt_orig=$ac_useropt 1714 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1715 case $ac_user_opts in 1716 *" 1717 "with_$ac_useropt" 1718 "*) ;; 1719 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1720 ac_unrecognized_sep=', ';; 1721 esac 1722 eval with_$ac_useropt=no ;; 1723 1724 --x) 1725 # Obsolete; use --with-x. 1726 with_x=yes ;; 1727 1728 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1729 | --x-incl | --x-inc | --x-in | --x-i) 1730 ac_prev=x_includes ;; 1731 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1732 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1733 x_includes=$ac_optarg ;; 1734 1735 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1736 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1737 ac_prev=x_libraries ;; 1738 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1739 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1740 x_libraries=$ac_optarg ;; 1741 1742 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1743 Try \`$0 --help' for more information" 1744 ;; 1745 1746 *=*) 1747 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1748 # Reject names that are not valid shell variable names. 1749 case $ac_envvar in #( 1750 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1751 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1752 esac 1753 eval $ac_envvar=\$ac_optarg 1754 export $ac_envvar ;; 1755 1756 *) 1757 # FIXME: should be removed in autoconf 3.0. 1758 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1759 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1760 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1761 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1762 ;; 1763 1764 esac 1765 done 1766 1767 if test -n "$ac_prev"; then 1768 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1769 as_fn_error $? "missing argument to $ac_option" 1770 fi 1771 1772 if test -n "$ac_unrecognized_opts"; then 1773 case $enable_option_checking in 1774 no) ;; 1775 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1776 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1777 esac 1778 fi 1779 1780 # Check all directory arguments for consistency. 1781 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1782 datadir sysconfdir sharedstatedir localstatedir includedir \ 1783 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1784 libdir localedir mandir 1785 do 1786 eval ac_val=\$$ac_var 1787 # Remove trailing slashes. 1788 case $ac_val in 1789 */ ) 1790 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1791 eval $ac_var=\$ac_val;; 1792 esac 1793 # Be sure to have absolute directory names. 1794 case $ac_val in 1795 [\\/$]* | ?:[\\/]* ) continue;; 1796 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1797 esac 1798 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1799 done 1800 1801 # There might be people who depend on the old broken behavior: `$host' 1802 # used to hold the argument of --host etc. 1803 # FIXME: To remove some day. 1804 build=$build_alias 1805 host=$host_alias 1806 target=$target_alias 1807 1808 # FIXME: To remove some day. 1809 if test "x$host_alias" != x; then 1810 if test "x$build_alias" = x; then 1811 cross_compiling=maybe 1812 elif test "x$build_alias" != "x$host_alias"; then 1813 cross_compiling=yes 1814 fi 1815 fi 1816 1817 ac_tool_prefix= 1818 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1819 1820 test "$silent" = yes && exec 6>/dev/null 1821 1822 1823 ac_pwd=`pwd` && test -n "$ac_pwd" && 1824 ac_ls_di=`ls -di .` && 1825 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1826 as_fn_error $? "working directory cannot be determined" 1827 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1828 as_fn_error $? "pwd does not report name of working directory" 1829 1830 1831 # Find the source files, if location was not specified. 1832 if test -z "$srcdir"; then 1833 ac_srcdir_defaulted=yes 1834 # Try the directory containing this script, then the parent directory. 1835 ac_confdir=`$as_dirname -- "$as_myself" || 1836 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1837 X"$as_myself" : 'X\(//\)[^/]' \| \ 1838 X"$as_myself" : 'X\(//\)$' \| \ 1839 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1840 $as_echo X"$as_myself" | 1841 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1842 s//\1/ 1843 q 1844 } 1845 /^X\(\/\/\)[^/].*/{ 1846 s//\1/ 1847 q 1848 } 1849 /^X\(\/\/\)$/{ 1850 s//\1/ 1851 q 1852 } 1853 /^X\(\/\).*/{ 1854 s//\1/ 1855 q 1856 } 1857 s/.*/./; q'` 1858 srcdir=$ac_confdir 1859 if test ! -r "$srcdir/$ac_unique_file"; then 1860 srcdir=.. 1861 fi 1862 else 1863 ac_srcdir_defaulted=no 1864 fi 1865 if test ! -r "$srcdir/$ac_unique_file"; then 1866 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1867 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1868 fi 1869 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1870 ac_abs_confdir=`( 1871 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1872 pwd)` 1873 # When building in place, set srcdir=. 1874 if test "$ac_abs_confdir" = "$ac_pwd"; then 1875 srcdir=. 1876 fi 1877 # Remove unnecessary trailing slashes from srcdir. 1878 # Double slashes in file names in object file debugging info 1879 # mess up M-x gdb in Emacs. 1880 case $srcdir in 1881 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1882 esac 1883 for ac_var in $ac_precious_vars; do 1884 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1885 eval ac_env_${ac_var}_value=\$${ac_var} 1886 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1887 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1888 done 1889 1890 # 1891 # Report the --help message. 1892 # 1893 if test "$ac_init_help" = "long"; then 1894 # Omit some internal or obsolete options to make the list less imposing. 1895 # This message is too long to be a string in the A/UX 3.1 sh. 1896 cat <<_ACEOF 1897 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1898 1899 Usage: $0 [OPTION]... [VAR=VALUE]... 1900 1901 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1902 VAR=VALUE. See below for descriptions of some of the useful variables. 1903 1904 Defaults for the options are specified in brackets. 1905 1906 Configuration: 1907 -h, --help display this help and exit 1908 --help=short display options specific to this package 1909 --help=recursive display the short help of all the included packages 1910 -V, --version display version information and exit 1911 -q, --quiet, --silent do not print \`checking ...' messages 1912 --cache-file=FILE cache test results in FILE [disabled] 1913 -C, --config-cache alias for \`--cache-file=config.cache' 1914 -n, --no-create do not create output files 1915 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1916 1917 Installation directories: 1918 --prefix=PREFIX install architecture-independent files in PREFIX 1919 [$ac_default_prefix] 1920 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1921 [PREFIX] 1922 1923 By default, \`make install' will install all the files in 1924 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1925 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1926 for instance \`--prefix=\$HOME'. 1927 1928 For better control, use the options below. 1929 1930 Fine tuning of the installation directories: 1931 --bindir=DIR user executables [EPREFIX/bin] 1932 --sbindir=DIR system admin executables [EPREFIX/sbin] 1933 --libexecdir=DIR program executables [EPREFIX/libexec] 1934 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1935 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1936 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1937 --libdir=DIR object code libraries [EPREFIX/lib] 1938 --includedir=DIR C header files [PREFIX/include] 1939 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1940 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1941 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1942 --infodir=DIR info documentation [DATAROOTDIR/info] 1943 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1944 --mandir=DIR man documentation [DATAROOTDIR/man] 1945 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1946 --htmldir=DIR html documentation [DOCDIR] 1947 --dvidir=DIR dvi documentation [DOCDIR] 1948 --pdfdir=DIR pdf documentation [DOCDIR] 1949 --psdir=DIR ps documentation [DOCDIR] 1950 _ACEOF 1951 1952 cat <<\_ACEOF 1953 1954 X features: 1955 --x-includes=DIR X include files are in DIR 1956 --x-libraries=DIR X library files are in DIR 1957 1958 System types: 1959 --build=BUILD configure for building on BUILD [guessed] 1960 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1961 --target=TARGET configure for building compilers for TARGET [HOST] 1962 _ACEOF 1963 fi 1964 1965 if test -n "$ac_init_help"; then 1966 case $ac_init_help in 1967 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1968 esac 1969 cat <<\_ACEOF 1970 1971 Optional Features: 1972 --disable-option-checking ignore unrecognized --enable/--with options 1973 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1974 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1975 --enable-openjdk-only suppress building custom source even if present 1976 [disabled] 1977 --enable-debug set the debug level to fastdebug (shorthand for 1978 --with-debug-level=fastdebug) [disabled] 1979 --disable-headful disable building headful support (graphical UI 1980 support) [enabled] 1981 --enable-unlimited-crypto 1982 Enable unlimited crypto policy [disabled] 1983 --disable-keep-packaged-modules 1984 Do not keep packaged modules in jdk image [enable] 1985 --enable-static-build enable static library build [disabled] 1986 --disable-warnings-as-errors 1987 do not consider native warnings to be an error 1988 [enabled] 1989 --enable-debug-symbols Deprecated. Option is kept for backwards 1990 compatibility and is ignored 1991 --enable-zip-debug-info Deprecated. Option is kept for backwards 1992 compatibility and is ignored 1993 --enable-native-coverage 1994 enable native compilation with code coverage 1995 data[disabled] 1996 --enable-dtrace[=yes/no/auto] 1997 enable dtrace. Default is auto, where dtrace is 1998 enabled if all dependencies are present. 1999 --disable-hotspot-gtest Disables building of the Hotspot unit tests 2000 --disable-freetype-bundling 2001 disable bundling of the freetype library with the 2002 build result [enabled on Windows or when using 2003 --with-freetype, disabled otherwise] 2004 --enable-jtreg-failure-handler 2005 forces build of the jtreg failure handler to be 2006 enabled, missing dependencies become fatal errors. 2007 Default is auto, where the failure handler is built 2008 if all dependencies are present and otherwise just 2009 disabled. 2010 --disable-generate-classlist 2011 forces enabling or disabling of the generation of a 2012 CDS classlist at build time. Default is to generate 2013 it when either the server or client JVMs are built. 2014 --enable-sjavac use sjavac to do fast incremental compiles 2015 [disabled] 2016 --disable-javac-server disable javac server [enabled] 2017 --enable-icecc enable distribted compilation of native code using 2018 icecc/icecream [disabled] 2019 --disable-precompiled-headers 2020 disable using precompiled headers when compiling C++ 2021 [enabled] 2022 --enable-ccache enable using ccache to speed up recompilations 2023 [disabled] 2024 2025 Optional Packages: 2026 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2027 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2028 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2029 support it), e.g. --with-target-bits=32 [guessed] 2030 --with-custom-make-dir Deprecated. Option is kept for backwards 2031 compatibility and is ignored 2032 --with-jdk-variant JDK variant to build (normal) [normal] 2033 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2034 optimized) [release] 2035 --with-jvm-variants JVM variants (separated by commas) to build 2036 (server,client,minimal,core,zero,zeroshark,custom) 2037 [server] 2038 --with-devkit use this devkit for compilers, tools and resources 2039 --with-sys-root alias for --with-sysroot for backwards compatability 2040 --with-sysroot use this directory as sysroot 2041 --with-tools-dir alias for --with-toolchain-path for backwards 2042 compatibility 2043 --with-toolchain-path prepend these directories when searching for 2044 toolchain binaries (compilers etc) 2045 --with-extra-path prepend these directories to the default path 2046 --with-sdk-name use the platform SDK of the given name. [macosx] 2047 --with-conf-name use this as the name of the configuration [generated 2048 from important configuration options] 2049 --with-output-sync set make output sync type if supported by make. 2050 [recurse] 2051 --with-default-make-target 2052 set the default make target [exploded-image] 2053 --with-cacerts-file specify alternative cacerts file 2054 --with-copyright-year Set copyright year value for build [current year] 2055 --with-milestone Deprecated. Option is kept for backwards 2056 compatibility and is ignored 2057 --with-update-version Deprecated. Option is kept for backwards 2058 compatibility and is ignored 2059 --with-user-release-suffix 2060 Deprecated. Option is kept for backwards 2061 compatibility and is ignored 2062 --with-build-number Deprecated. Option is kept for backwards 2063 compatibility and is ignored 2064 --with-version-string Set version string [calculated] 2065 --with-version-pre Set the base part of the version 'PRE' field 2066 (pre-release identifier) ['internal'] 2067 --with-version-opt Set version 'OPT' field (build metadata) 2068 [<timestamp>.<user>.<dirname>] 2069 --with-version-build Set version 'BUILD' field (build number) [not 2070 specified] 2071 --with-version-major Set version 'MAJOR' field (first number) [current 2072 source value] 2073 --with-version-minor Set version 'MINOR' field (second number) [current 2074 source value] 2075 --with-version-security Set version 'SECURITY' field (third number) [current 2076 source value] 2077 --with-version-patch Set version 'PATCH' field (fourth number) [not 2078 specified] 2079 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2080 --with-build-jdk path to JDK of same version as is being built[the 2081 newly built JDK] 2082 --with-add-source-root Deprecated. Option is kept for backwards 2083 compatibility and is ignored 2084 --with-override-source-root 2085 Deprecated. Option is kept for backwards 2086 compatibility and is ignored 2087 --with-adds-and-overrides 2088 Deprecated. Option is kept for backwards 2089 compatibility and is ignored 2090 --with-override-langtools 2091 Deprecated. Option is kept for backwards 2092 compatibility and is ignored 2093 --with-override-corba Deprecated. Option is kept for backwards 2094 compatibility and is ignored 2095 --with-override-jaxp Deprecated. Option is kept for backwards 2096 compatibility and is ignored 2097 --with-override-jaxws Deprecated. Option is kept for backwards 2098 compatibility and is ignored 2099 --with-override-hotspot Deprecated. Option is kept for backwards 2100 compatibility and is ignored 2101 --with-override-nashorn Deprecated. Option is kept for backwards 2102 compatibility and is ignored 2103 --with-override-jdk Deprecated. Option is kept for backwards 2104 compatibility and is ignored 2105 --with-import-hotspot import hotspot binaries from this jdk image or 2106 hotspot build dist dir instead of building from 2107 source 2108 --with-import-modules import a set of prebuilt modules either as a zip 2109 file or an exploded directory 2110 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2111 to show possible values [platform dependent] 2112 --with-extra-cflags extra flags to be used when compiling jdk c-files 2113 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2114 --with-extra-ldflags extra flags to be used when linking jdk 2115 --with-toolchain-version 2116 the version of the toolchain to look for, use 2117 '--help' to show possible values [platform 2118 dependent] 2119 --with-build-devkit Devkit to use for the build platform toolchain 2120 --with-jtreg Regression Test Harness [probed] 2121 --with-native-debug-symbols 2122 set the native debug symbol configuration (none, 2123 internal, external, zipped) [varying] 2124 --with-jvm-features additional JVM features to enable (separated by 2125 comma), use '--help' to show possible values [none] 2126 --with-jvm-interpreter Deprecated. Option is kept for backwards 2127 compatibility and is ignored 2128 --with-stdc++lib=<static>,<dynamic>,<default> 2129 force linking of the C++ runtime on Linux to either 2130 static or dynamic, default is static with dynamic as 2131 fallback 2132 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2133 (Windows only) [probed] 2134 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2135 (Windows only) [probed] 2136 --with-x use the X Window System 2137 --with-cups specify prefix directory for the cups package 2138 (expecting the headers under PATH/include) 2139 --with-cups-include specify directory for the cups include files 2140 --with-freetype specify prefix directory for the freetype package 2141 (expecting the libraries under PATH/lib and the 2142 headers under PATH/include) 2143 --with-freetype-include specify directory for the freetype include files 2144 --with-freetype-lib specify directory for the freetype library 2145 --with-freetype-src specify directory with freetype sources to 2146 automatically build the library (experimental, 2147 Windows-only) 2148 --with-alsa specify prefix directory for the alsa package 2149 (expecting the libraries under PATH/lib and the 2150 headers under PATH/include) 2151 --with-alsa-include specify directory for the alsa include files 2152 --with-alsa-lib specify directory for the alsa library 2153 --with-libffi specify prefix directory for the libffi package 2154 (expecting the libraries under PATH/lib and the 2155 headers under PATH/include) 2156 --with-libffi-include specify directory for the libffi include files 2157 --with-libffi-lib specify directory for the libffi library 2158 --with-libjpeg use libjpeg from build system or OpenJDK source 2159 (system, bundled) [bundled] 2160 --with-giflib use giflib from build system or OpenJDK source 2161 (system, bundled) [bundled] 2162 --with-libpng use libpng from build system or OpenJDK source 2163 (system, bundled) [bundled] 2164 --with-zlib use zlib from build system or OpenJDK source 2165 (system, bundled) [bundled] 2166 --with-lcms use lcms2 from build system or OpenJDK source 2167 (system, bundled) [bundled] 2168 --with-dxsdk Deprecated. Option is kept for backwards 2169 compatibility and is ignored 2170 --with-dxsdk-lib Deprecated. Option is kept for backwards 2171 compatibility and is ignored 2172 --with-dxsdk-include Deprecated. Option is kept for backwards 2173 compatibility and is ignored 2174 --with-num-cores number of cores in the build system, e.g. 2175 --with-num-cores=8 [probed] 2176 --with-memory-size memory (in MB) available in the build system, e.g. 2177 --with-memory-size=1024 [probed] 2178 --with-jobs number of parallel jobs to let make run [calculated 2179 based on cores and memory] 2180 --with-test-jobs number of parallel tests jobs to run [based on build 2181 jobs] 2182 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2183 invocations of boot JDK, overriding the default 2184 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2185 -enableassertions" 2186 --with-sjavac-server-java 2187 use this java binary for running the sjavac 2188 background server [Boot JDK java] 2189 --with-ccache-dir where to store ccache files [~/.ccache] 2190 2191 Some influential environment variables: 2192 BASENAME Override default value for BASENAME 2193 BASH Override default value for BASH 2194 CAT Override default value for CAT 2195 CHMOD Override default value for CHMOD 2196 CMP Override default value for CMP 2197 COMM Override default value for COMM 2198 CP Override default value for CP 2199 CUT Override default value for CUT 2200 DATE Override default value for DATE 2201 DIFF Override default value for DIFF 2202 DIRNAME Override default value for DIRNAME 2203 ECHO Override default value for ECHO 2204 EXPR Override default value for EXPR 2205 FILE Override default value for FILE 2206 FIND Override default value for FIND 2207 HEAD Override default value for HEAD 2208 GUNZIP Override default value for GUNZIP 2209 GZIP Override default value for GZIP 2210 LN Override default value for LN 2211 LS Override default value for LS 2212 MKDIR Override default value for MKDIR 2213 MKTEMP Override default value for MKTEMP 2214 MV Override default value for MV 2215 NAWK Override default value for NAWK 2216 PRINTF Override default value for PRINTF 2217 RM Override default value for RM 2218 RMDIR Override default value for RMDIR 2219 SH Override default value for SH 2220 SORT Override default value for SORT 2221 TAIL Override default value for TAIL 2222 TAR Override default value for TAR 2223 TEE Override default value for TEE 2224 TOUCH Override default value for TOUCH 2225 TR Override default value for TR 2226 UNAME Override default value for UNAME 2227 UNIQ Override default value for UNIQ 2228 WC Override default value for WC 2229 WHICH Override default value for WHICH 2230 XARGS Override default value for XARGS 2231 AWK Override default value for AWK 2232 GREP Override default value for GREP 2233 EGREP Override default value for EGREP 2234 FGREP Override default value for FGREP 2235 SED Override default value for SED 2236 CYGPATH Override default value for CYGPATH 2237 READLINK Override default value for READLINK 2238 DF Override default value for DF 2239 CPIO Override default value for CPIO 2240 NICE Override default value for NICE 2241 MAKE Override default value for MAKE 2242 UNZIP Override default value for UNZIP 2243 ZIP Override default value for ZIP 2244 LDD Override default value for LDD 2245 OTOOL Override default value for OTOOL 2246 READELF Override default value for READELF 2247 HG Override default value for HG 2248 STAT Override default value for STAT 2249 TIME Override default value for TIME 2250 DTRACE Override default value for DTRACE 2251 PATCH Override default value for PATCH 2252 DSYMUTIL Override default value for DSYMUTIL 2253 XATTR Override default value for XATTR 2254 CODESIGN Override default value for CODESIGN 2255 SETFILE Override default value for SETFILE 2256 PKG_CONFIG path to pkg-config utility 2257 JAVA Override default value for JAVA 2258 JAVAC Override default value for JAVAC 2259 JAVAH Override default value for JAVAH 2260 JAR Override default value for JAR 2261 JARSIGNER Override default value for JARSIGNER 2262 CC C compiler command 2263 CFLAGS C compiler flags 2264 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2265 nonstandard directory <lib dir> 2266 LIBS libraries to pass to the linker, e.g. -l<library> 2267 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2268 you have headers in a nonstandard directory <include dir> 2269 CXX C++ compiler command 2270 CXXFLAGS C++ compiler flags 2271 CPP C preprocessor 2272 CXXCPP C++ preprocessor 2273 AS Override default value for AS 2274 AR Override default value for AR 2275 LIPO Override default value for LIPO 2276 STRIP Override default value for STRIP 2277 NM Override default value for NM 2278 GNM Override default value for GNM 2279 OBJCOPY Override default value for OBJCOPY 2280 OBJDUMP Override default value for OBJDUMP 2281 BUILD_CC Override default value for BUILD_CC 2282 BUILD_CXX Override default value for BUILD_CXX 2283 BUILD_NM Override default value for BUILD_NM 2284 BUILD_AR Override default value for BUILD_AR 2285 BUILD_OBJCOPY 2286 Override default value for BUILD_OBJCOPY 2287 BUILD_STRIP Override default value for BUILD_STRIP 2288 JTREGEXE Override default value for JTREGEXE 2289 XMKMF Path to xmkmf, Makefile generator for X Window System 2290 FREETYPE_CFLAGS 2291 C compiler flags for FREETYPE, overriding pkg-config 2292 FREETYPE_LIBS 2293 linker flags for FREETYPE, overriding pkg-config 2294 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2295 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2296 LIBFFI_CFLAGS 2297 C compiler flags for LIBFFI, overriding pkg-config 2298 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2299 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2300 PNG_LIBS linker flags for PNG, overriding pkg-config 2301 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2302 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2303 ICECC_CMD Override default value for ICECC_CMD 2304 ICECC_CREATE_ENV 2305 Override default value for ICECC_CREATE_ENV 2306 ICECC_WRAPPER 2307 Override default value for ICECC_WRAPPER 2308 CCACHE Override default value for CCACHE 2309 2310 Use these variables to override the choices made by `configure' or to help 2311 it to find libraries and programs with nonstandard names/locations. 2312 2313 Report bugs to <build-dev@openjdk.java.net>. 2314 OpenJDK home page: <http://openjdk.java.net>. 2315 _ACEOF 2316 ac_status=$? 2317 fi 2318 2319 if test "$ac_init_help" = "recursive"; then 2320 # If there are subdirs, report their specific --help. 2321 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2322 test -d "$ac_dir" || 2323 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2324 continue 2325 ac_builddir=. 2326 2327 case "$ac_dir" in 2328 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2329 *) 2330 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2331 # A ".." for each directory in $ac_dir_suffix. 2332 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2333 case $ac_top_builddir_sub in 2334 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2335 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2336 esac ;; 2337 esac 2338 ac_abs_top_builddir=$ac_pwd 2339 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2340 # for backward compatibility: 2341 ac_top_builddir=$ac_top_build_prefix 2342 2343 case $srcdir in 2344 .) # We are building in place. 2345 ac_srcdir=. 2346 ac_top_srcdir=$ac_top_builddir_sub 2347 ac_abs_top_srcdir=$ac_pwd ;; 2348 [\\/]* | ?:[\\/]* ) # Absolute name. 2349 ac_srcdir=$srcdir$ac_dir_suffix; 2350 ac_top_srcdir=$srcdir 2351 ac_abs_top_srcdir=$srcdir ;; 2352 *) # Relative name. 2353 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2354 ac_top_srcdir=$ac_top_build_prefix$srcdir 2355 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2356 esac 2357 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2358 2359 cd "$ac_dir" || { ac_status=$?; continue; } 2360 # Check for guested configure. 2361 if test -f "$ac_srcdir/configure.gnu"; then 2362 echo && 2363 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2364 elif test -f "$ac_srcdir/configure"; then 2365 echo && 2366 $SHELL "$ac_srcdir/configure" --help=recursive 2367 else 2368 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2369 fi || ac_status=$? 2370 cd "$ac_pwd" || { ac_status=$?; break; } 2371 done 2372 fi 2373 2374 test -n "$ac_init_help" && exit $ac_status 2375 if $ac_init_version; then 2376 cat <<\_ACEOF 2377 OpenJDK configure jdk9 2378 generated by GNU Autoconf 2.69 2379 2380 Copyright (C) 2012 Free Software Foundation, Inc. 2381 This configure script is free software; the Free Software Foundation 2382 gives unlimited permission to copy, distribute and modify it. 2383 _ACEOF 2384 exit 2385 fi 2386 2387 ## ------------------------ ## 2388 ## Autoconf initialization. ## 2389 ## ------------------------ ## 2390 2391 # ac_fn_c_try_compile LINENO 2392 # -------------------------- 2393 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2394 ac_fn_c_try_compile () 2395 { 2396 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2397 rm -f conftest.$ac_objext 2398 if { { ac_try="$ac_compile" 2399 case "(($ac_try" in 2400 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2401 *) ac_try_echo=$ac_try;; 2402 esac 2403 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2404 $as_echo "$ac_try_echo"; } >&5 2405 (eval "$ac_compile") 2>conftest.err 2406 ac_status=$? 2407 if test -s conftest.err; then 2408 grep -v '^ *+' conftest.err >conftest.er1 2409 cat conftest.er1 >&5 2410 mv -f conftest.er1 conftest.err 2411 fi 2412 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2413 test $ac_status = 0; } && { 2414 test -z "$ac_c_werror_flag" || 2415 test ! -s conftest.err 2416 } && test -s conftest.$ac_objext; then : 2417 ac_retval=0 2418 else 2419 $as_echo "$as_me: failed program was:" >&5 2420 sed 's/^/| /' conftest.$ac_ext >&5 2421 2422 ac_retval=1 2423 fi 2424 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2425 as_fn_set_status $ac_retval 2426 2427 } # ac_fn_c_try_compile 2428 2429 # ac_fn_cxx_try_compile LINENO 2430 # ---------------------------- 2431 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2432 ac_fn_cxx_try_compile () 2433 { 2434 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2435 rm -f conftest.$ac_objext 2436 if { { ac_try="$ac_compile" 2437 case "(($ac_try" in 2438 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2439 *) ac_try_echo=$ac_try;; 2440 esac 2441 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2442 $as_echo "$ac_try_echo"; } >&5 2443 (eval "$ac_compile") 2>conftest.err 2444 ac_status=$? 2445 if test -s conftest.err; then 2446 grep -v '^ *+' conftest.err >conftest.er1 2447 cat conftest.er1 >&5 2448 mv -f conftest.er1 conftest.err 2449 fi 2450 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2451 test $ac_status = 0; } && { 2452 test -z "$ac_cxx_werror_flag" || 2453 test ! -s conftest.err 2454 } && test -s conftest.$ac_objext; then : 2455 ac_retval=0 2456 else 2457 $as_echo "$as_me: failed program was:" >&5 2458 sed 's/^/| /' conftest.$ac_ext >&5 2459 2460 ac_retval=1 2461 fi 2462 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2463 as_fn_set_status $ac_retval 2464 2465 } # ac_fn_cxx_try_compile 2466 2467 # ac_fn_c_try_cpp LINENO 2468 # ---------------------- 2469 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2470 ac_fn_c_try_cpp () 2471 { 2472 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2473 if { { ac_try="$ac_cpp conftest.$ac_ext" 2474 case "(($ac_try" in 2475 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2476 *) ac_try_echo=$ac_try;; 2477 esac 2478 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2479 $as_echo "$ac_try_echo"; } >&5 2480 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2481 ac_status=$? 2482 if test -s conftest.err; then 2483 grep -v '^ *+' conftest.err >conftest.er1 2484 cat conftest.er1 >&5 2485 mv -f conftest.er1 conftest.err 2486 fi 2487 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2488 test $ac_status = 0; } > conftest.i && { 2489 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2490 test ! -s conftest.err 2491 }; then : 2492 ac_retval=0 2493 else 2494 $as_echo "$as_me: failed program was:" >&5 2495 sed 's/^/| /' conftest.$ac_ext >&5 2496 2497 ac_retval=1 2498 fi 2499 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2500 as_fn_set_status $ac_retval 2501 2502 } # ac_fn_c_try_cpp 2503 2504 # ac_fn_cxx_try_cpp LINENO 2505 # ------------------------ 2506 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2507 ac_fn_cxx_try_cpp () 2508 { 2509 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2510 if { { ac_try="$ac_cpp conftest.$ac_ext" 2511 case "(($ac_try" in 2512 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2513 *) ac_try_echo=$ac_try;; 2514 esac 2515 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2516 $as_echo "$ac_try_echo"; } >&5 2517 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2518 ac_status=$? 2519 if test -s conftest.err; then 2520 grep -v '^ *+' conftest.err >conftest.er1 2521 cat conftest.er1 >&5 2522 mv -f conftest.er1 conftest.err 2523 fi 2524 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2525 test $ac_status = 0; } > conftest.i && { 2526 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2527 test ! -s conftest.err 2528 }; then : 2529 ac_retval=0 2530 else 2531 $as_echo "$as_me: failed program was:" >&5 2532 sed 's/^/| /' conftest.$ac_ext >&5 2533 2534 ac_retval=1 2535 fi 2536 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2537 as_fn_set_status $ac_retval 2538 2539 } # ac_fn_cxx_try_cpp 2540 2541 # ac_fn_c_try_link LINENO 2542 # ----------------------- 2543 # Try to link conftest.$ac_ext, and return whether this succeeded. 2544 ac_fn_c_try_link () 2545 { 2546 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2547 rm -f conftest.$ac_objext conftest$ac_exeext 2548 if { { ac_try="$ac_link" 2549 case "(($ac_try" in 2550 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2551 *) ac_try_echo=$ac_try;; 2552 esac 2553 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2554 $as_echo "$ac_try_echo"; } >&5 2555 (eval "$ac_link") 2>conftest.err 2556 ac_status=$? 2557 if test -s conftest.err; then 2558 grep -v '^ *+' conftest.err >conftest.er1 2559 cat conftest.er1 >&5 2560 mv -f conftest.er1 conftest.err 2561 fi 2562 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2563 test $ac_status = 0; } && { 2564 test -z "$ac_c_werror_flag" || 2565 test ! -s conftest.err 2566 } && test -s conftest$ac_exeext && { 2567 test "$cross_compiling" = yes || 2568 test -x conftest$ac_exeext 2569 }; then : 2570 ac_retval=0 2571 else 2572 $as_echo "$as_me: failed program was:" >&5 2573 sed 's/^/| /' conftest.$ac_ext >&5 2574 2575 ac_retval=1 2576 fi 2577 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2578 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2579 # interfere with the next link command; also delete a directory that is 2580 # left behind by Apple's compiler. We do this before executing the actions. 2581 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2582 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2583 as_fn_set_status $ac_retval 2584 2585 } # ac_fn_c_try_link 2586 2587 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2588 # --------------------------------------------------------- 2589 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2590 # the include files in INCLUDES and setting the cache variable VAR 2591 # accordingly. 2592 ac_fn_cxx_check_header_mongrel () 2593 { 2594 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2595 if eval \${$3+:} false; then : 2596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2597 $as_echo_n "checking for $2... " >&6; } 2598 if eval \${$3+:} false; then : 2599 $as_echo_n "(cached) " >&6 2600 fi 2601 eval ac_res=\$$3 2602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2603 $as_echo "$ac_res" >&6; } 2604 else 2605 # Is the header compilable? 2606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2607 $as_echo_n "checking $2 usability... " >&6; } 2608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2609 /* end confdefs.h. */ 2610 $4 2611 #include <$2> 2612 _ACEOF 2613 if ac_fn_cxx_try_compile "$LINENO"; then : 2614 ac_header_compiler=yes 2615 else 2616 ac_header_compiler=no 2617 fi 2618 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2620 $as_echo "$ac_header_compiler" >&6; } 2621 2622 # Is the header present? 2623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2624 $as_echo_n "checking $2 presence... " >&6; } 2625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2626 /* end confdefs.h. */ 2627 #include <$2> 2628 _ACEOF 2629 if ac_fn_cxx_try_cpp "$LINENO"; then : 2630 ac_header_preproc=yes 2631 else 2632 ac_header_preproc=no 2633 fi 2634 rm -f conftest.err conftest.i conftest.$ac_ext 2635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2636 $as_echo "$ac_header_preproc" >&6; } 2637 2638 # So? What about this header? 2639 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2640 yes:no: ) 2641 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2642 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2644 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2645 ;; 2646 no:yes:* ) 2647 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2648 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2649 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2650 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2651 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2652 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2653 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2654 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2655 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2656 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2657 ( $as_echo "## ----------------------------------------- ## 2658 ## Report this to build-dev@openjdk.java.net ## 2659 ## ----------------------------------------- ##" 2660 ) | sed "s/^/$as_me: WARNING: /" >&2 2661 ;; 2662 esac 2663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2664 $as_echo_n "checking for $2... " >&6; } 2665 if eval \${$3+:} false; then : 2666 $as_echo_n "(cached) " >&6 2667 else 2668 eval "$3=\$ac_header_compiler" 2669 fi 2670 eval ac_res=\$$3 2671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2672 $as_echo "$ac_res" >&6; } 2673 fi 2674 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2675 2676 } # ac_fn_cxx_check_header_mongrel 2677 2678 # ac_fn_cxx_try_run LINENO 2679 # ------------------------ 2680 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2681 # that executables *can* be run. 2682 ac_fn_cxx_try_run () 2683 { 2684 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2685 if { { ac_try="$ac_link" 2686 case "(($ac_try" in 2687 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2688 *) ac_try_echo=$ac_try;; 2689 esac 2690 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2691 $as_echo "$ac_try_echo"; } >&5 2692 (eval "$ac_link") 2>&5 2693 ac_status=$? 2694 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2695 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2696 { { case "(($ac_try" in 2697 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2698 *) ac_try_echo=$ac_try;; 2699 esac 2700 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2701 $as_echo "$ac_try_echo"; } >&5 2702 (eval "$ac_try") 2>&5 2703 ac_status=$? 2704 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2705 test $ac_status = 0; }; }; then : 2706 ac_retval=0 2707 else 2708 $as_echo "$as_me: program exited with status $ac_status" >&5 2709 $as_echo "$as_me: failed program was:" >&5 2710 sed 's/^/| /' conftest.$ac_ext >&5 2711 2712 ac_retval=$ac_status 2713 fi 2714 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2715 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2716 as_fn_set_status $ac_retval 2717 2718 } # ac_fn_cxx_try_run 2719 2720 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2721 # --------------------------------------------------------- 2722 # Tests whether HEADER exists and can be compiled using the include files in 2723 # INCLUDES, setting the cache variable VAR accordingly. 2724 ac_fn_cxx_check_header_compile () 2725 { 2726 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2728 $as_echo_n "checking for $2... " >&6; } 2729 if eval \${$3+:} false; then : 2730 $as_echo_n "(cached) " >&6 2731 else 2732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2733 /* end confdefs.h. */ 2734 $4 2735 #include <$2> 2736 _ACEOF 2737 if ac_fn_cxx_try_compile "$LINENO"; then : 2738 eval "$3=yes" 2739 else 2740 eval "$3=no" 2741 fi 2742 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2743 fi 2744 eval ac_res=\$$3 2745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2746 $as_echo "$ac_res" >&6; } 2747 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2748 2749 } # ac_fn_cxx_check_header_compile 2750 2751 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2752 # ---------------------------------------------- 2753 # Tries to find the compile-time value of EXPR in a program that includes 2754 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2755 # computed 2756 ac_fn_cxx_compute_int () 2757 { 2758 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2759 if test "$cross_compiling" = yes; then 2760 # Depending upon the size, compute the lo and hi bounds. 2761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2762 /* end confdefs.h. */ 2763 $4 2764 int 2765 main () 2766 { 2767 static int test_array [1 - 2 * !(($2) >= 0)]; 2768 test_array [0] = 0; 2769 return test_array [0]; 2770 2771 ; 2772 return 0; 2773 } 2774 _ACEOF 2775 if ac_fn_cxx_try_compile "$LINENO"; then : 2776 ac_lo=0 ac_mid=0 2777 while :; do 2778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2779 /* end confdefs.h. */ 2780 $4 2781 int 2782 main () 2783 { 2784 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2785 test_array [0] = 0; 2786 return test_array [0]; 2787 2788 ; 2789 return 0; 2790 } 2791 _ACEOF 2792 if ac_fn_cxx_try_compile "$LINENO"; then : 2793 ac_hi=$ac_mid; break 2794 else 2795 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2796 if test $ac_lo -le $ac_mid; then 2797 ac_lo= ac_hi= 2798 break 2799 fi 2800 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2801 fi 2802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2803 done 2804 else 2805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2806 /* end confdefs.h. */ 2807 $4 2808 int 2809 main () 2810 { 2811 static int test_array [1 - 2 * !(($2) < 0)]; 2812 test_array [0] = 0; 2813 return test_array [0]; 2814 2815 ; 2816 return 0; 2817 } 2818 _ACEOF 2819 if ac_fn_cxx_try_compile "$LINENO"; then : 2820 ac_hi=-1 ac_mid=-1 2821 while :; do 2822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2823 /* end confdefs.h. */ 2824 $4 2825 int 2826 main () 2827 { 2828 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2829 test_array [0] = 0; 2830 return test_array [0]; 2831 2832 ; 2833 return 0; 2834 } 2835 _ACEOF 2836 if ac_fn_cxx_try_compile "$LINENO"; then : 2837 ac_lo=$ac_mid; break 2838 else 2839 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2840 if test $ac_mid -le $ac_hi; then 2841 ac_lo= ac_hi= 2842 break 2843 fi 2844 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2845 fi 2846 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2847 done 2848 else 2849 ac_lo= ac_hi= 2850 fi 2851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2852 fi 2853 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2854 # Binary search between lo and hi bounds. 2855 while test "x$ac_lo" != "x$ac_hi"; do 2856 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2858 /* end confdefs.h. */ 2859 $4 2860 int 2861 main () 2862 { 2863 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2864 test_array [0] = 0; 2865 return test_array [0]; 2866 2867 ; 2868 return 0; 2869 } 2870 _ACEOF 2871 if ac_fn_cxx_try_compile "$LINENO"; then : 2872 ac_hi=$ac_mid 2873 else 2874 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2875 fi 2876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2877 done 2878 case $ac_lo in #(( 2879 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2880 '') ac_retval=1 ;; 2881 esac 2882 else 2883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2884 /* end confdefs.h. */ 2885 $4 2886 static long int longval () { return $2; } 2887 static unsigned long int ulongval () { return $2; } 2888 #include <stdio.h> 2889 #include <stdlib.h> 2890 int 2891 main () 2892 { 2893 2894 FILE *f = fopen ("conftest.val", "w"); 2895 if (! f) 2896 return 1; 2897 if (($2) < 0) 2898 { 2899 long int i = longval (); 2900 if (i != ($2)) 2901 return 1; 2902 fprintf (f, "%ld", i); 2903 } 2904 else 2905 { 2906 unsigned long int i = ulongval (); 2907 if (i != ($2)) 2908 return 1; 2909 fprintf (f, "%lu", i); 2910 } 2911 /* Do not output a trailing newline, as this causes \r\n confusion 2912 on some platforms. */ 2913 return ferror (f) || fclose (f) != 0; 2914 2915 ; 2916 return 0; 2917 } 2918 _ACEOF 2919 if ac_fn_cxx_try_run "$LINENO"; then : 2920 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2921 else 2922 ac_retval=1 2923 fi 2924 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2925 conftest.$ac_objext conftest.beam conftest.$ac_ext 2926 rm -f conftest.val 2927 2928 fi 2929 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2930 as_fn_set_status $ac_retval 2931 2932 } # ac_fn_cxx_compute_int 2933 2934 # ac_fn_cxx_try_link LINENO 2935 # ------------------------- 2936 # Try to link conftest.$ac_ext, and return whether this succeeded. 2937 ac_fn_cxx_try_link () 2938 { 2939 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2940 rm -f conftest.$ac_objext conftest$ac_exeext 2941 if { { ac_try="$ac_link" 2942 case "(($ac_try" in 2943 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2944 *) ac_try_echo=$ac_try;; 2945 esac 2946 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2947 $as_echo "$ac_try_echo"; } >&5 2948 (eval "$ac_link") 2>conftest.err 2949 ac_status=$? 2950 if test -s conftest.err; then 2951 grep -v '^ *+' conftest.err >conftest.er1 2952 cat conftest.er1 >&5 2953 mv -f conftest.er1 conftest.err 2954 fi 2955 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2956 test $ac_status = 0; } && { 2957 test -z "$ac_cxx_werror_flag" || 2958 test ! -s conftest.err 2959 } && test -s conftest$ac_exeext && { 2960 test "$cross_compiling" = yes || 2961 test -x conftest$ac_exeext 2962 }; then : 2963 ac_retval=0 2964 else 2965 $as_echo "$as_me: failed program was:" >&5 2966 sed 's/^/| /' conftest.$ac_ext >&5 2967 2968 ac_retval=1 2969 fi 2970 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2971 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2972 # interfere with the next link command; also delete a directory that is 2973 # left behind by Apple's compiler. We do this before executing the actions. 2974 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2975 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2976 as_fn_set_status $ac_retval 2977 2978 } # ac_fn_cxx_try_link 2979 2980 # ac_fn_cxx_check_func LINENO FUNC VAR 2981 # ------------------------------------ 2982 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2983 ac_fn_cxx_check_func () 2984 { 2985 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2987 $as_echo_n "checking for $2... " >&6; } 2988 if eval \${$3+:} false; then : 2989 $as_echo_n "(cached) " >&6 2990 else 2991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2992 /* end confdefs.h. */ 2993 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2994 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2995 #define $2 innocuous_$2 2996 2997 /* System header to define __stub macros and hopefully few prototypes, 2998 which can conflict with char $2 (); below. 2999 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 3000 <limits.h> exists even on freestanding compilers. */ 3001 3002 #ifdef __STDC__ 3003 # include <limits.h> 3004 #else 3005 # include <assert.h> 3006 #endif 3007 3008 #undef $2 3009 3010 /* Override any GCC internal prototype to avoid an error. 3011 Use char because int might match the return type of a GCC 3012 builtin and then its argument prototype would still apply. */ 3013 #ifdef __cplusplus 3014 extern "C" 3015 #endif 3016 char $2 (); 3017 /* The GNU C library defines this for functions which it implements 3018 to always fail with ENOSYS. Some functions are actually named 3019 something starting with __ and the normal name is an alias. */ 3020 #if defined __stub_$2 || defined __stub___$2 3021 choke me 3022 #endif 3023 3024 int 3025 main () 3026 { 3027 return $2 (); 3028 ; 3029 return 0; 3030 } 3031 _ACEOF 3032 if ac_fn_cxx_try_link "$LINENO"; then : 3033 eval "$3=yes" 3034 else 3035 eval "$3=no" 3036 fi 3037 rm -f core conftest.err conftest.$ac_objext \ 3038 conftest$ac_exeext conftest.$ac_ext 3039 fi 3040 eval ac_res=\$$3 3041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3042 $as_echo "$ac_res" >&6; } 3043 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3044 3045 } # ac_fn_cxx_check_func 3046 3047 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3048 # ------------------------------------------------------- 3049 # Tests whether HEADER exists and can be compiled using the include files in 3050 # INCLUDES, setting the cache variable VAR accordingly. 3051 ac_fn_c_check_header_compile () 3052 { 3053 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3055 $as_echo_n "checking for $2... " >&6; } 3056 if eval \${$3+:} false; then : 3057 $as_echo_n "(cached) " >&6 3058 else 3059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3060 /* end confdefs.h. */ 3061 $4 3062 #include <$2> 3063 _ACEOF 3064 if ac_fn_c_try_compile "$LINENO"; then : 3065 eval "$3=yes" 3066 else 3067 eval "$3=no" 3068 fi 3069 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3070 fi 3071 eval ac_res=\$$3 3072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3073 $as_echo "$ac_res" >&6; } 3074 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3075 3076 } # ac_fn_c_check_header_compile 3077 cat >config.log <<_ACEOF 3078 This file contains any messages produced by compilers while 3079 running configure, to aid debugging if configure makes a mistake. 3080 3081 It was created by OpenJDK $as_me jdk9, which was 3082 generated by GNU Autoconf 2.69. Invocation command line was 3083 3084 $ $0 $@ 3085 3086 _ACEOF 3087 exec 5>>config.log 3088 { 3089 cat <<_ASUNAME 3090 ## --------- ## 3091 ## Platform. ## 3092 ## --------- ## 3093 3094 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3095 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3096 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3097 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3098 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3099 3100 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3101 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3102 3103 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3104 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3105 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3106 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3107 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3108 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3109 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3110 3111 _ASUNAME 3112 3113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3114 for as_dir in $PATH 3115 do 3116 IFS=$as_save_IFS 3117 test -z "$as_dir" && as_dir=. 3118 $as_echo "PATH: $as_dir" 3119 done 3120 IFS=$as_save_IFS 3121 3122 } >&5 3123 3124 cat >&5 <<_ACEOF 3125 3126 3127 ## ----------- ## 3128 ## Core tests. ## 3129 ## ----------- ## 3130 3131 _ACEOF 3132 3133 3134 # Keep a trace of the command line. 3135 # Strip out --no-create and --no-recursion so they do not pile up. 3136 # Strip out --silent because we don't want to record it for future runs. 3137 # Also quote any args containing shell meta-characters. 3138 # Make two passes to allow for proper duplicate-argument suppression. 3139 ac_configure_args= 3140 ac_configure_args0= 3141 ac_configure_args1= 3142 ac_must_keep_next=false 3143 for ac_pass in 1 2 3144 do 3145 for ac_arg 3146 do 3147 case $ac_arg in 3148 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3149 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3150 | -silent | --silent | --silen | --sile | --sil) 3151 continue ;; 3152 *\'*) 3153 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3154 esac 3155 case $ac_pass in 3156 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3157 2) 3158 as_fn_append ac_configure_args1 " '$ac_arg'" 3159 if test $ac_must_keep_next = true; then 3160 ac_must_keep_next=false # Got value, back to normal. 3161 else 3162 case $ac_arg in 3163 *=* | --config-cache | -C | -disable-* | --disable-* \ 3164 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3165 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3166 | -with-* | --with-* | -without-* | --without-* | --x) 3167 case "$ac_configure_args0 " in 3168 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3169 esac 3170 ;; 3171 -* ) ac_must_keep_next=true ;; 3172 esac 3173 fi 3174 as_fn_append ac_configure_args " '$ac_arg'" 3175 ;; 3176 esac 3177 done 3178 done 3179 { ac_configure_args0=; unset ac_configure_args0;} 3180 { ac_configure_args1=; unset ac_configure_args1;} 3181 3182 # When interrupted or exit'd, cleanup temporary files, and complete 3183 # config.log. We remove comments because anyway the quotes in there 3184 # would cause problems or look ugly. 3185 # WARNING: Use '\'' to represent an apostrophe within the trap. 3186 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3187 trap 'exit_status=$? 3188 # Save into config.log some information that might help in debugging. 3189 { 3190 echo 3191 3192 $as_echo "## ---------------- ## 3193 ## Cache variables. ## 3194 ## ---------------- ##" 3195 echo 3196 # The following way of writing the cache mishandles newlines in values, 3197 ( 3198 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3199 eval ac_val=\$$ac_var 3200 case $ac_val in #( 3201 *${as_nl}*) 3202 case $ac_var in #( 3203 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3204 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3205 esac 3206 case $ac_var in #( 3207 _ | IFS | as_nl) ;; #( 3208 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3209 *) { eval $ac_var=; unset $ac_var;} ;; 3210 esac ;; 3211 esac 3212 done 3213 (set) 2>&1 | 3214 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3215 *${as_nl}ac_space=\ *) 3216 sed -n \ 3217 "s/'\''/'\''\\\\'\'''\''/g; 3218 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3219 ;; #( 3220 *) 3221 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3222 ;; 3223 esac | 3224 sort 3225 ) 3226 echo 3227 3228 $as_echo "## ----------------- ## 3229 ## Output variables. ## 3230 ## ----------------- ##" 3231 echo 3232 for ac_var in $ac_subst_vars 3233 do 3234 eval ac_val=\$$ac_var 3235 case $ac_val in 3236 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3237 esac 3238 $as_echo "$ac_var='\''$ac_val'\''" 3239 done | sort 3240 echo 3241 3242 if test -n "$ac_subst_files"; then 3243 $as_echo "## ------------------- ## 3244 ## File substitutions. ## 3245 ## ------------------- ##" 3246 echo 3247 for ac_var in $ac_subst_files 3248 do 3249 eval ac_val=\$$ac_var 3250 case $ac_val in 3251 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3252 esac 3253 $as_echo "$ac_var='\''$ac_val'\''" 3254 done | sort 3255 echo 3256 fi 3257 3258 if test -s confdefs.h; then 3259 $as_echo "## ----------- ## 3260 ## confdefs.h. ## 3261 ## ----------- ##" 3262 echo 3263 cat confdefs.h 3264 echo 3265 fi 3266 test "$ac_signal" != 0 && 3267 $as_echo "$as_me: caught signal $ac_signal" 3268 $as_echo "$as_me: exit $exit_status" 3269 } >&5 3270 rm -f core *.core core.conftest.* && 3271 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3272 exit $exit_status 3273 ' 0 3274 for ac_signal in 1 2 13 15; do 3275 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3276 done 3277 ac_signal=0 3278 3279 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3280 rm -f -r conftest* confdefs.h 3281 3282 $as_echo "/* confdefs.h */" > confdefs.h 3283 3284 # Predefined preprocessor variables. 3285 3286 cat >>confdefs.h <<_ACEOF 3287 #define PACKAGE_NAME "$PACKAGE_NAME" 3288 _ACEOF 3289 3290 cat >>confdefs.h <<_ACEOF 3291 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3292 _ACEOF 3293 3294 cat >>confdefs.h <<_ACEOF 3295 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3296 _ACEOF 3297 3298 cat >>confdefs.h <<_ACEOF 3299 #define PACKAGE_STRING "$PACKAGE_STRING" 3300 _ACEOF 3301 3302 cat >>confdefs.h <<_ACEOF 3303 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3304 _ACEOF 3305 3306 cat >>confdefs.h <<_ACEOF 3307 #define PACKAGE_URL "$PACKAGE_URL" 3308 _ACEOF 3309 3310 3311 # Let the site file select an alternate cache file if it wants to. 3312 # Prefer an explicitly selected file to automatically selected ones. 3313 ac_site_file1=NONE 3314 ac_site_file2=NONE 3315 if test -n "$CONFIG_SITE"; then 3316 # We do not want a PATH search for config.site. 3317 case $CONFIG_SITE in #(( 3318 -*) ac_site_file1=./$CONFIG_SITE;; 3319 */*) ac_site_file1=$CONFIG_SITE;; 3320 *) ac_site_file1=./$CONFIG_SITE;; 3321 esac 3322 elif test "x$prefix" != xNONE; then 3323 ac_site_file1=$prefix/share/config.site 3324 ac_site_file2=$prefix/etc/config.site 3325 else 3326 ac_site_file1=$ac_default_prefix/share/config.site 3327 ac_site_file2=$ac_default_prefix/etc/config.site 3328 fi 3329 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3330 do 3331 test "x$ac_site_file" = xNONE && continue 3332 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3333 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3334 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3335 sed 's/^/| /' "$ac_site_file" >&5 3336 . "$ac_site_file" \ 3337 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3338 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3339 as_fn_error $? "failed to load site script $ac_site_file 3340 See \`config.log' for more details" "$LINENO" 5; } 3341 fi 3342 done 3343 3344 if test -r "$cache_file"; then 3345 # Some versions of bash will fail to source /dev/null (special files 3346 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3347 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3348 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3349 $as_echo "$as_me: loading cache $cache_file" >&6;} 3350 case $cache_file in 3351 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3352 *) . "./$cache_file";; 3353 esac 3354 fi 3355 else 3356 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3357 $as_echo "$as_me: creating cache $cache_file" >&6;} 3358 >$cache_file 3359 fi 3360 3361 # Check that the precious variables saved in the cache have kept the same 3362 # value. 3363 ac_cache_corrupted=false 3364 for ac_var in $ac_precious_vars; do 3365 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3366 eval ac_new_set=\$ac_env_${ac_var}_set 3367 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3368 eval ac_new_val=\$ac_env_${ac_var}_value 3369 case $ac_old_set,$ac_new_set in 3370 set,) 3371 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3372 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3373 ac_cache_corrupted=: ;; 3374 ,set) 3375 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3376 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3377 ac_cache_corrupted=: ;; 3378 ,);; 3379 *) 3380 if test "x$ac_old_val" != "x$ac_new_val"; then 3381 # differences in whitespace do not lead to failure. 3382 ac_old_val_w=`echo x $ac_old_val` 3383 ac_new_val_w=`echo x $ac_new_val` 3384 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3385 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3386 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3387 ac_cache_corrupted=: 3388 else 3389 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3390 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3391 eval $ac_var=\$ac_old_val 3392 fi 3393 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3394 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3395 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3396 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3397 fi;; 3398 esac 3399 # Pass precious variables to config.status. 3400 if test "$ac_new_set" = set; then 3401 case $ac_new_val in 3402 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3403 *) ac_arg=$ac_var=$ac_new_val ;; 3404 esac 3405 case " $ac_configure_args " in 3406 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3407 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3408 esac 3409 fi 3410 done 3411 if $ac_cache_corrupted; then 3412 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3413 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3414 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3415 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3416 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3417 fi 3418 ## -------------------- ## 3419 ## Main body of script. ## 3420 ## -------------------- ## 3421 3422 ac_ext=c 3423 ac_cpp='$CPP $CPPFLAGS' 3424 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3425 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3426 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3427 3428 3429 3430 ac_aux_dir= 3431 for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do 3432 if test -f "$ac_dir/install-sh"; then 3433 ac_aux_dir=$ac_dir 3434 ac_install_sh="$ac_aux_dir/install-sh -c" 3435 break 3436 elif test -f "$ac_dir/install.sh"; then 3437 ac_aux_dir=$ac_dir 3438 ac_install_sh="$ac_aux_dir/install.sh -c" 3439 break 3440 elif test -f "$ac_dir/shtool"; then 3441 ac_aux_dir=$ac_dir 3442 ac_install_sh="$ac_aux_dir/shtool install -c" 3443 break 3444 fi 3445 done 3446 if test -z "$ac_aux_dir"; then 3447 as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/common/autoconf/build-aux \"$srcdir\"/$TOPDIR/common/autoconf/build-aux" "$LINENO" 5 3448 fi 3449 3450 # These three variables are undocumented and unsupported, 3451 # and are intended to be withdrawn in a future Autoconf release. 3452 # They can cause serious problems if a builder's source tree is in a directory 3453 # whose full name contains unusual characters. 3454 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3455 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3456 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3457 3458 3459 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3460 3461 # 3462 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3463 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3464 # 3465 # This code is free software; you can redistribute it and/or modify it 3466 # under the terms of the GNU General Public License version 2 only, as 3467 # published by the Free Software Foundation. Oracle designates this 3468 # particular file as subject to the "Classpath" exception as provided 3469 # by Oracle in the LICENSE file that accompanied this code. 3470 # 3471 # This code is distributed in the hope that it will be useful, but WITHOUT 3472 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3473 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3474 # version 2 for more details (a copy is included in the LICENSE file that 3475 # accompanied this code). 3476 # 3477 # You should have received a copy of the GNU General Public License version 3478 # 2 along with this work; if not, write to the Free Software Foundation, 3479 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3480 # 3481 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3482 # or visit www.oracle.com if you need additional information or have any 3483 # questions. 3484 # 3485 3486 # 3487 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3488 # 3489 # This program is free software; you can redistribute it and/or modify 3490 # it under the terms of the GNU General Public License as published by 3491 # the Free Software Foundation; either version 2 of the License, or 3492 # (at your option) any later version. 3493 # 3494 # This program is distributed in the hope that it will be useful, but 3495 # WITHOUT ANY WARRANTY; without even the implied warranty of 3496 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3497 # General Public License for more details. 3498 # 3499 # You should have received a copy of the GNU General Public License 3500 # along with this program; if not, write to the Free Software 3501 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3502 # 3503 # As a special exception to the GNU General Public License, if you 3504 # distribute this file as part of a program that contains a 3505 # configuration script generated by Autoconf, you may include it under 3506 # the same distribution terms that you use for the rest of that program. 3507 3508 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3509 # ---------------------------------- 3510 # PKG_PROG_PKG_CONFIG 3511 3512 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3513 # 3514 # Check to see whether a particular set of modules exists. Similar 3515 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3516 # 3517 # 3518 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3519 # this or PKG_CHECK_MODULES is called, or make sure to call 3520 # PKG_CHECK_EXISTS manually 3521 # -------------------------------------------------------------- 3522 3523 3524 3525 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3526 # --------------------------------------------- 3527 # _PKG_CONFIG 3528 3529 # _PKG_SHORT_ERRORS_SUPPORTED 3530 # ----------------------------- 3531 # _PKG_SHORT_ERRORS_SUPPORTED 3532 3533 3534 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3535 # [ACTION-IF-NOT-FOUND]) 3536 # 3537 # 3538 # Note that if there is a possibility the first call to 3539 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3540 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3541 # 3542 # 3543 # -------------------------------------------------------------- 3544 # PKG_CHECK_MODULES 3545 3546 3547 # Include these first... 3548 # 3549 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3550 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3551 # 3552 # This code is free software; you can redistribute it and/or modify it 3553 # under the terms of the GNU General Public License version 2 only, as 3554 # published by the Free Software Foundation. Oracle designates this 3555 # particular file as subject to the "Classpath" exception as provided 3556 # by Oracle in the LICENSE file that accompanied this code. 3557 # 3558 # This code is distributed in the hope that it will be useful, but WITHOUT 3559 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3560 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3561 # version 2 for more details (a copy is included in the LICENSE file that 3562 # accompanied this code). 3563 # 3564 # You should have received a copy of the GNU General Public License version 3565 # 2 along with this work; if not, write to the Free Software Foundation, 3566 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3567 # 3568 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3569 # or visit www.oracle.com if you need additional information or have any 3570 # questions. 3571 # 3572 3573 # Create a function/macro that takes a series of named arguments. The call is 3574 # similar to AC_DEFUN, but the setup of the function looks like this: 3575 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3576 # ... do something 3577 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3578 # ]) 3579 # A star (*) in front of a named argument means that it is required and it's 3580 # presence will be verified. To pass e.g. the first value as a normal indexed 3581 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3582 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3583 # "ARG_FOO". 3584 # 3585 # The generated function can be called like this: 3586 # MYFUNC(FOO: [foo-val], 3587 # BAR: [ 3588 # $ECHO hello world 3589 # ]) 3590 # Note that the argument value must start on the same line as the argument name. 3591 # 3592 # Argument 1: Name of the function to define 3593 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3594 # Argument 3: Argument array to treat as named, typically $@ 3595 # Argument 4: The main function body 3596 3597 3598 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3599 # If so, then append $1 to $2 \ 3600 # Also set JVM_ARG_OK to true/false depending on outcome. 3601 3602 3603 # Appends a string to a path variable, only adding the : when needed. 3604 3605 3606 # Prepends a string to a path variable, only adding the : when needed. 3607 3608 3609 # This will make sure the given variable points to a full and proper 3610 # path. This means: 3611 # 1) There will be no spaces in the path. On unix platforms, 3612 # spaces in the path will result in an error. On Windows, 3613 # the path will be rewritten using short-style to be space-free. 3614 # 2) The path will be absolute, and it will be in unix-style (on 3615 # cygwin). 3616 # $1: The name of the variable to fix 3617 3618 3619 # This will make sure the given variable points to a executable 3620 # with a full and proper path. This means: 3621 # 1) There will be no spaces in the path. On unix platforms, 3622 # spaces in the path will result in an error. On Windows, 3623 # the path will be rewritten using short-style to be space-free. 3624 # 2) The path will be absolute, and it will be in unix-style (on 3625 # cygwin). 3626 # Any arguments given to the executable is preserved. 3627 # If the input variable does not have a directory specification, then 3628 # it need to be in the PATH. 3629 # $1: The name of the variable to fix 3630 3631 3632 3633 3634 # Register a --with argument but mark it as deprecated 3635 # $1: The name of the with argument to deprecate, not including --with- 3636 3637 3638 # Register a --enable argument but mark it as deprecated 3639 # $1: The name of the with argument to deprecate, not including --enable- 3640 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3641 # $3: Messages to user. 3642 3643 3644 3645 3646 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3647 # $1: variable to check 3648 3649 3650 # Check that there are no unprocessed overridden variables left. 3651 # If so, they are an incorrect argument and we will exit with an error. 3652 3653 3654 # Setup a tool for the given variable. If correctly specified by the user, 3655 # use that value, otherwise search for the tool using the supplied code snippet. 3656 # $1: variable to set 3657 # $2: code snippet to call to look for the tool 3658 # $3: code snippet to call if variable was used to find tool 3659 3660 3661 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3662 # $1: variable to set 3663 # $2: executable name (or list of names) to look for 3664 3665 3666 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3667 # $1: variable to set 3668 # $2: executable name (or list of names) to look for 3669 3670 3671 # Like BASIC_PATH_PROGS but fails if no tool was found. 3672 # $1: variable to set 3673 # $2: executable name (or list of names) to look for 3674 3675 3676 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3677 # $1: variable to set 3678 # $2: autoconf macro to call to look for the special tool 3679 3680 3681 # Setup the most fundamental tools that relies on not much else to set up, 3682 # but is used by much of the early bootstrap code. 3683 3684 3685 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3686 3687 3688 # Evaluates platform specific overrides for devkit variables. 3689 # $1: Name of variable 3690 3691 3692 3693 3694 3695 3696 #%%% Simple tools %%% 3697 3698 # Check if we have found a usable version of make 3699 # $1: the path to a potential make binary (or empty) 3700 # $2: the description on how we found this 3701 3702 3703 3704 3705 # Goes looking for a usable version of GNU make. 3706 3707 3708 3709 3710 3711 3712 3713 3714 # Check if build directory is on local disk. If not possible to determine, 3715 # we prefer to claim it's local. 3716 # Argument 1: directory to test 3717 # Argument 2: what to do if it is on local disk 3718 # Argument 3: what to do otherwise (remote disk or failure) 3719 3720 3721 # Check that source files have basic read permissions set. This might 3722 # not be the case in cygwin in certain conditions. 3723 3724 3725 3726 3727 # Check for support for specific options in bash 3728 3729 3730 ################################################################################ 3731 # 3732 # Default make target 3733 # 3734 3735 3736 # Code to run after AC_OUTPUT 3737 3738 3739 # 3740 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3741 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3742 # 3743 # This code is free software; you can redistribute it and/or modify it 3744 # under the terms of the GNU General Public License version 2 only, as 3745 # published by the Free Software Foundation. Oracle designates this 3746 # particular file as subject to the "Classpath" exception as provided 3747 # by Oracle in the LICENSE file that accompanied this code. 3748 # 3749 # This code is distributed in the hope that it will be useful, but WITHOUT 3750 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3751 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3752 # version 2 for more details (a copy is included in the LICENSE file that 3753 # accompanied this code). 3754 # 3755 # You should have received a copy of the GNU General Public License version 3756 # 2 along with this work; if not, write to the Free Software Foundation, 3757 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3758 # 3759 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3760 # or visit www.oracle.com if you need additional information or have any 3761 # questions. 3762 # 3763 3764 3765 3766 3767 3768 # Helper function which possibly converts a path using DOS-style short mode. 3769 # If so, the updated path is stored in $new_path. 3770 # $1: The path to check 3771 3772 3773 # Helper function which possibly converts a path using DOS-style short mode. 3774 # If so, the updated path is stored in $new_path. 3775 # $1: The path to check 3776 3777 3778 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3779 # and could probably be heavily simplified. However, all changes in this 3780 # area tend to need lot of testing in different scenarios, and in lack of 3781 # proper unit testing, cleaning this up has not been deemed worth the effort 3782 # at the moment. 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3793 3794 3795 3796 3797 # ... then the rest 3798 # 3799 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3800 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3801 # 3802 # This code is free software; you can redistribute it and/or modify it 3803 # under the terms of the GNU General Public License version 2 only, as 3804 # published by the Free Software Foundation. Oracle designates this 3805 # particular file as subject to the "Classpath" exception as provided 3806 # by Oracle in the LICENSE file that accompanied this code. 3807 # 3808 # This code is distributed in the hope that it will be useful, but WITHOUT 3809 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3810 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3811 # version 2 for more details (a copy is included in the LICENSE file that 3812 # accompanied this code). 3813 # 3814 # You should have received a copy of the GNU General Public License version 3815 # 2 along with this work; if not, write to the Free Software Foundation, 3816 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3817 # 3818 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3819 # or visit www.oracle.com if you need additional information or have any 3820 # questions. 3821 # 3822 3823 ######################################################################## 3824 # This file handles detection of the Boot JDK. The Boot JDK detection 3825 # process has been developed as a response to solve a complex real-world 3826 # problem. Initially, it was simple, but it has grown as platform after 3827 # platform, idiosyncracy after idiosyncracy has been supported. 3828 # 3829 # The basic idea is this: 3830 # 1) You need an acceptable *) JDK to use as a Boot JDK 3831 # 2) There are several ways to locate a JDK, that are mostly platform 3832 # dependent **) 3833 # 3) You can have multiple JDKs installed 3834 # 4) If possible, configure should try to dig out an acceptable JDK 3835 # automatically, without having to resort to command-line options 3836 # 3837 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3838 # javac) and not a JRE, etc. 3839 # 3840 # **) On Windows we typically use a well-known path. 3841 # On MacOSX we typically use the tool java_home. 3842 # On Linux we typically find javac in the $PATH, and then follow a 3843 # chain of symlinks that often ends up in a real JDK. 3844 # 3845 # This leads to the code where we check in different ways to locate a 3846 # JDK, and if one is found, check if it is acceptable. If not, we print 3847 # our reasons for rejecting it (useful when debugging non-working 3848 # configure situations) and continue checking the next one. 3849 ######################################################################## 3850 3851 # Execute the check given as argument, and verify the result 3852 # If the Boot JDK was previously found, do nothing 3853 # $1 A command line (typically autoconf macro) to execute 3854 3855 3856 # Test: Is bootjdk explicitely set by command line arguments? 3857 3858 3859 # Test: Is $JAVA_HOME set? 3860 3861 3862 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3863 3864 3865 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3866 # $1: Argument to the java_home binary (optional) 3867 3868 3869 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3870 3871 3872 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3873 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3874 # $1 = Path to directory containing jdk installations. 3875 # $2 = String to append to the found JDK directory to get the proper JDK home 3876 3877 3878 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3879 # environmental variable as base for where to look. 3880 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3881 3882 3883 # Test: Is there a JDK installed in default, well-known locations? 3884 3885 3886 # Check that a command-line tool in the Boot JDK is correct 3887 # $1 = name of variable to assign 3888 # $2 = name of binary 3889 3890 3891 ############################################################################### 3892 # 3893 # We need a Boot JDK to bootstrap the build. 3894 # 3895 3896 3897 3898 3899 3900 # BUILD_JDK: the location of the latest JDK that can run 3901 # on the host system and supports the target class file version 3902 # generated in this JDK build. This variable should only be 3903 # used after the launchers are built. 3904 # 3905 3906 # Execute the check given as argument, and verify the result. 3907 # If the JDK was previously found, do nothing. 3908 # $1 A command line (typically autoconf macro) to execute 3909 3910 3911 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3912 # is different than the host system doing the build (e.g. cross-compilation), 3913 # a special BUILD_JDK is built as part of the build process. An external 3914 # prebuilt BUILD_JDK can also be supplied. 3915 3916 3917 # 3918 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3919 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3920 # 3921 # This code is free software; you can redistribute it and/or modify it 3922 # under the terms of the GNU General Public License version 2 only, as 3923 # published by the Free Software Foundation. Oracle designates this 3924 # particular file as subject to the "Classpath" exception as provided 3925 # by Oracle in the LICENSE file that accompanied this code. 3926 # 3927 # This code is distributed in the hope that it will be useful, but WITHOUT 3928 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3929 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3930 # version 2 for more details (a copy is included in the LICENSE file that 3931 # accompanied this code). 3932 # 3933 # You should have received a copy of the GNU General Public License version 3934 # 2 along with this work; if not, write to the Free Software Foundation, 3935 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3936 # 3937 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3938 # or visit www.oracle.com if you need additional information or have any 3939 # questions. 3940 # 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 ################################################################################ 3959 # 3960 # Runs icecc-create-env once and prints the error if it fails 3961 # 3962 # $1: arguments to icecc-create-env 3963 # $2: log file 3964 # 3965 3966 3967 ################################################################################ 3968 # 3969 # Optionally enable distributed compilation of native code using icecc/icecream 3970 # 3971 3972 3973 3974 3975 3976 3977 3978 # 3979 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3980 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3981 # 3982 # This code is free software; you can redistribute it and/or modify it 3983 # under the terms of the GNU General Public License version 2 only, as 3984 # published by the Free Software Foundation. Oracle designates this 3985 # particular file as subject to the "Classpath" exception as provided 3986 # by Oracle in the LICENSE file that accompanied this code. 3987 # 3988 # This code is distributed in the hope that it will be useful, but WITHOUT 3989 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3990 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3991 # version 2 for more details (a copy is included in the LICENSE file that 3992 # accompanied this code). 3993 # 3994 # You should have received a copy of the GNU General Public License version 3995 # 2 along with this work; if not, write to the Free Software Foundation, 3996 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3997 # 3998 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3999 # or visit www.oracle.com if you need additional information or have any 4000 # questions. 4001 # 4002 4003 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 4004 # corresponding configure arguments instead 4005 4006 4007 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4008 # that configure can use them while detecting compilers. 4009 # TOOLCHAIN_TYPE is available here. 4010 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4011 4012 4013 4014 4015 4016 4017 # Documentation on common flags used for solstudio in HIGHEST. 4018 # 4019 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4020 # done with care, there are some assumptions below that need to 4021 # be understood about the use of pointers, and IEEE behavior. 4022 # 4023 # -fns: Use non-standard floating point mode (not IEEE 754) 4024 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4025 # -fsingle: Use single precision floating point with 'float' 4026 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4027 # (Source with excessing pointer casting and data access with mixed 4028 # pointer types are not recommended) 4029 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4030 # (If you expect perfect errno behavior, do not use this) 4031 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4032 # -xrestrict: Pointer parameters to functions do not overlap 4033 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4034 # If you pass in multiple pointers to the same data, do not use this) 4035 # -xlibmil: Inline some library routines 4036 # (If you expect perfect errno behavior, do not use this) 4037 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4038 # (If you expect perfect errno behavior, do not use this) 4039 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4040 4041 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4042 # Bug? 4043 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4044 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4045 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4046 #fi 4047 4048 4049 4050 4051 4052 4053 ################################################################################ 4054 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4055 # conditionals against. 4056 # $2 - Optional prefix for each variable defined. 4057 4058 4059 # FLAGS_C_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_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4068 # IF_FALSE: [RUN-IF-FALSE]) 4069 # ------------------------------------------------------------ 4070 # Check that the C++ compiler supports an argument 4071 4072 4073 4074 4075 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4076 # IF_FALSE: [RUN-IF-FALSE]) 4077 # ------------------------------------------------------------ 4078 # Check that the C and C++ compilers support an argument 4079 4080 4081 4082 4083 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4084 # IF_FALSE: [RUN-IF-FALSE]) 4085 # ------------------------------------------------------------ 4086 # Check that the linker support an argument 4087 4088 4089 4090 4091 4092 4093 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4094 # Arguments: 4095 # $1 - Optional prefix for each variable defined. 4096 4097 4098 # 4099 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4100 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4101 # 4102 # This code is free software; you can redistribute it and/or modify it 4103 # under the terms of the GNU General Public License version 2 only, as 4104 # published by the Free Software Foundation. Oracle designates this 4105 # particular file as subject to the "Classpath" exception as provided 4106 # by Oracle in the LICENSE file that accompanied this code. 4107 # 4108 # This code is distributed in the hope that it will be useful, but WITHOUT 4109 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4110 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4111 # version 2 for more details (a copy is included in the LICENSE file that 4112 # accompanied this code). 4113 # 4114 # You should have received a copy of the GNU General Public License version 4115 # 2 along with this work; if not, write to the Free Software Foundation, 4116 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4117 # 4118 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4119 # or visit www.oracle.com if you need additional information or have any 4120 # questions. 4121 # 4122 4123 4124 4125 4126 4127 cygwin_help() { 4128 case $1 in 4129 unzip) 4130 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4131 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4132 ;; 4133 zip) 4134 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4135 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4136 ;; 4137 make) 4138 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4139 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4140 ;; 4141 freetype) 4142 HELP_MSG=" 4143 The freetype library can now be build during the configure process. 4144 Download the freetype sources and unpack them into an arbitrary directory: 4145 4146 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4147 tar -xzf freetype-2.5.3.tar.gz 4148 4149 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4150 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4151 builds or into '<freetype_src>/lib32' for 32-bit builds. 4152 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4153 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4154 4155 Alternatively you can unpack the sources like this to use the default directory: 4156 4157 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4158 ;; 4159 esac 4160 } 4161 4162 msys_help() { 4163 PKGHANDLER_COMMAND="" 4164 } 4165 4166 apt_help() { 4167 case $1 in 4168 reduced) 4169 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4170 devkit) 4171 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4172 openjdk) 4173 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4174 alsa) 4175 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4176 cups) 4177 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 4178 freetype) 4179 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 4180 ffi) 4181 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 4182 x11) 4183 PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 4184 ccache) 4185 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 4186 dtrace) 4187 PKGHANDLER_COMMAND="sudo apt-get install systemtap-sdt-dev" ;; 4188 esac 4189 } 4190 4191 yum_help() { 4192 case $1 in 4193 devkit) 4194 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4195 openjdk) 4196 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4197 alsa) 4198 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4199 cups) 4200 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4201 freetype) 4202 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4203 x11) 4204 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4205 ccache) 4206 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4207 esac 4208 } 4209 4210 port_help() { 4211 PKGHANDLER_COMMAND="" 4212 } 4213 4214 pkgutil_help() { 4215 PKGHANDLER_COMMAND="" 4216 } 4217 4218 pkgadd_help() { 4219 PKGHANDLER_COMMAND="" 4220 } 4221 4222 # This function will check if we're called from the "configure" wrapper while 4223 # printing --help. If so, we will print out additional information that can 4224 # only be extracted within the autoconf script, and then exit. This must be 4225 # called at the very beginning in configure.ac. 4226 4227 4228 4229 4230 4231 4232 # 4233 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4234 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4235 # 4236 # This code is free software; you can redistribute it and/or modify it 4237 # under the terms of the GNU General Public License version 2 only, as 4238 # published by the Free Software Foundation. Oracle designates this 4239 # particular file as subject to the "Classpath" exception as provided 4240 # by Oracle in the LICENSE file that accompanied this code. 4241 # 4242 # This code is distributed in the hope that it will be useful, but WITHOUT 4243 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4244 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4245 # version 2 for more details (a copy is included in the LICENSE file that 4246 # accompanied this code). 4247 # 4248 # You should have received a copy of the GNU General Public License version 4249 # 2 along with this work; if not, write to the Free Software Foundation, 4250 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4251 # 4252 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4253 # or visit www.oracle.com if you need additional information or have any 4254 # questions. 4255 # 4256 4257 # All valid JVM features, regardless of platform 4258 VALID_JVM_FEATURES="compiler1 compiler2 zero shark minimal dtrace jvmti jvmci \ 4259 fprof vm-structs jni-check services management all-gcs nmt cds static-build" 4260 4261 # All valid JVM variants 4262 VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" 4263 4264 ############################################################################### 4265 # Check if the specified JVM variant should be built. To be used in shell if 4266 # constructs, like this: 4267 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4268 # 4269 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4270 4271 # Definition kept in one line to allow inlining in if statements. 4272 # Additional [] needed to keep m4 from mangling shell constructs. 4273 4274 4275 ############################################################################### 4276 # Check if the specified JVM features are explicitly enabled. To be used in 4277 # shell if constructs, like this: 4278 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4279 # 4280 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4281 4282 # Definition kept in one line to allow inlining in if statements. 4283 # Additional [] needed to keep m4 from mangling shell constructs. 4284 4285 4286 ############################################################################### 4287 # Check which variants of the JVM that we want to build. Available variants are: 4288 # server: normal interpreter, and a tiered C1/C2 compiler 4289 # client: normal interpreter, and C1 (no C2 compiler) 4290 # minimal: reduced form of client with optional features stripped out 4291 # core: normal interpreter only, no compiler 4292 # zero: C++ based interpreter only, no compiler 4293 # zeroshark: C++ based interpreter, and a llvm-based compiler 4294 # custom: baseline JVM with no default features 4295 # 4296 4297 4298 ############################################################################### 4299 # Check if dtrace should be enabled and has all prerequisites present. 4300 # 4301 4302 4303 ############################################################################### 4304 # Set up all JVM features for each JVM variant. 4305 # 4306 4307 4308 ############################################################################### 4309 # Validate JVM features once all setup is complete, including custom setup. 4310 # 4311 4312 4313 ################################################################################ 4314 # Check if gtest should be built 4315 # 4316 4317 4318 # 4319 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4320 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4321 # 4322 # This code is free software; you can redistribute it and/or modify it 4323 # under the terms of the GNU General Public License version 2 only, as 4324 # published by the Free Software Foundation. Oracle designates this 4325 # particular file as subject to the "Classpath" exception as provided 4326 # by Oracle in the LICENSE file that accompanied this code. 4327 # 4328 # This code is distributed in the hope that it will be useful, but WITHOUT 4329 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4330 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4331 # version 2 for more details (a copy is included in the LICENSE file that 4332 # accompanied this code). 4333 # 4334 # You should have received a copy of the GNU General Public License version 4335 # 2 along with this work; if not, write to the Free Software Foundation, 4336 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4337 # 4338 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4339 # or visit www.oracle.com if you need additional information or have any 4340 # questions. 4341 # 4342 4343 ############################################################################### 4344 # Check which variant of the JDK that we want to build. 4345 # Currently we have: 4346 # normal: standard edition 4347 # but the custom make system may add other variants 4348 # 4349 # Effectively the JDK variant gives a name to a specific set of 4350 # modules to compile into the JDK. 4351 4352 4353 ############################################################################### 4354 # Set the debug level 4355 # release: no debug information, all optimizations, no asserts. 4356 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4357 # fastdebug: debug information (-g), all optimizations, all asserts 4358 # slowdebug: debug information (-g), no optimizations, all asserts 4359 4360 4361 ############################################################################### 4362 # 4363 # Should we build only OpenJDK even if closed sources are present? 4364 # 4365 4366 4367 4368 4369 ############################################################################### 4370 # 4371 # Enable or disable the elliptic curve crypto implementation 4372 # 4373 4374 4375 4376 4377 ################################################################################ 4378 # 4379 # Gcov coverage data for hotspot 4380 # 4381 4382 4383 ################################################################################ 4384 # 4385 # Static build support. When enabled will generate static 4386 # libraries instead of shared libraries for all JDK libs. 4387 # 4388 4389 4390 ################################################################################ 4391 # 4392 # jlink options. 4393 # We always keep packaged modules in JDK image. 4394 # 4395 4396 4397 ################################################################################ 4398 # 4399 # Check if building of the jtreg failure handler should be enabled. 4400 # 4401 4402 4403 ################################################################################ 4404 # 4405 # Enable or disable generation of the classlist at build time 4406 # 4407 4408 4409 # 4410 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4411 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4412 # 4413 # This code is free software; you can redistribute it and/or modify it 4414 # under the terms of the GNU General Public License version 2 only, as 4415 # published by the Free Software Foundation. Oracle designates this 4416 # particular file as subject to the "Classpath" exception as provided 4417 # by Oracle in the LICENSE file that accompanied this code. 4418 # 4419 # This code is distributed in the hope that it will be useful, but WITHOUT 4420 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4421 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4422 # version 2 for more details (a copy is included in the LICENSE file that 4423 # accompanied this code). 4424 # 4425 # You should have received a copy of the GNU General Public License version 4426 # 2 along with this work; if not, write to the Free Software Foundation, 4427 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4428 # 4429 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4430 # or visit www.oracle.com if you need additional information or have any 4431 # questions. 4432 # 4433 4434 ############################################################################### 4435 # 4436 # Setup version numbers 4437 # 4438 4439 # Verify that a given string represents a valid version number, and assign it 4440 # to a variable. 4441 4442 # Argument 1: the variable to assign to 4443 # Argument 2: the value given by the user 4444 4445 4446 4447 4448 # 4449 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4450 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4451 # 4452 # This code is free software; you can redistribute it and/or modify it 4453 # under the terms of the GNU General Public License version 2 only, as 4454 # published by the Free Software Foundation. Oracle designates this 4455 # particular file as subject to the "Classpath" exception as provided 4456 # by Oracle in the LICENSE file that accompanied this code. 4457 # 4458 # This code is distributed in the hope that it will be useful, but WITHOUT 4459 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4460 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4461 # version 2 for more details (a copy is included in the LICENSE file that 4462 # accompanied this code). 4463 # 4464 # You should have received a copy of the GNU General Public License version 4465 # 2 along with this work; if not, write to the Free Software Foundation, 4466 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4467 # 4468 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4469 # or visit www.oracle.com if you need additional information or have any 4470 # questions. 4471 # 4472 4473 # Major library component reside in separate files. 4474 # 4475 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4476 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4477 # 4478 # This code is free software; you can redistribute it and/or modify it 4479 # under the terms of the GNU General Public License version 2 only, as 4480 # published by the Free Software Foundation. Oracle designates this 4481 # particular file as subject to the "Classpath" exception as provided 4482 # by Oracle in the LICENSE file that accompanied this code. 4483 # 4484 # This code is distributed in the hope that it will be useful, but WITHOUT 4485 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4486 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4487 # version 2 for more details (a copy is included in the LICENSE file that 4488 # accompanied this code). 4489 # 4490 # You should have received a copy of the GNU General Public License version 4491 # 2 along with this work; if not, write to the Free Software Foundation, 4492 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4493 # 4494 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4495 # or visit www.oracle.com if you need additional information or have any 4496 # questions. 4497 # 4498 4499 ################################################################################ 4500 # Setup alsa (Advanced Linux Sound Architecture) 4501 ################################################################################ 4502 4503 4504 # 4505 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4506 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4507 # 4508 # This code is free software; you can redistribute it and/or modify it 4509 # under the terms of the GNU General Public License version 2 only, as 4510 # published by the Free Software Foundation. Oracle designates this 4511 # particular file as subject to the "Classpath" exception as provided 4512 # by Oracle in the LICENSE file that accompanied this code. 4513 # 4514 # This code is distributed in the hope that it will be useful, but WITHOUT 4515 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4516 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4517 # version 2 for more details (a copy is included in the LICENSE file that 4518 # accompanied this code). 4519 # 4520 # You should have received a copy of the GNU General Public License version 4521 # 2 along with this work; if not, write to the Free Software Foundation, 4522 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4523 # 4524 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4525 # or visit www.oracle.com if you need additional information or have any 4526 # questions. 4527 # 4528 4529 ################################################################################ 4530 # Setup bundled libraries. 4531 # 4532 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4533 # OpenJDK repository. Default is to use these libraries as bundled, but they 4534 # might be replaced by en external version by the user. 4535 ################################################################################ 4536 4537 4538 ################################################################################ 4539 # Setup libjpeg 4540 ################################################################################ 4541 4542 4543 ################################################################################ 4544 # Setup giflib 4545 ################################################################################ 4546 4547 4548 ################################################################################ 4549 # Setup libpng 4550 ################################################################################ 4551 4552 4553 ################################################################################ 4554 # Setup zlib 4555 ################################################################################ 4556 4557 4558 ################################################################################ 4559 # Setup lcms (Little CMS) 4560 ################################################################################ 4561 4562 4563 # 4564 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4565 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4566 # 4567 # This code is free software; you can redistribute it and/or modify it 4568 # under the terms of the GNU General Public License version 2 only, as 4569 # published by the Free Software Foundation. Oracle designates this 4570 # particular file as subject to the "Classpath" exception as provided 4571 # by Oracle in the LICENSE file that accompanied this code. 4572 # 4573 # This code is distributed in the hope that it will be useful, but WITHOUT 4574 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4575 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4576 # version 2 for more details (a copy is included in the LICENSE file that 4577 # accompanied this code). 4578 # 4579 # You should have received a copy of the GNU General Public License version 4580 # 2 along with this work; if not, write to the Free Software Foundation, 4581 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4582 # 4583 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4584 # or visit www.oracle.com if you need additional information or have any 4585 # questions. 4586 # 4587 4588 ################################################################################ 4589 # Setup cups (Common Unix Printing System) 4590 ################################################################################ 4591 4592 4593 # 4594 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4595 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4596 # 4597 # This code is free software; you can redistribute it and/or modify it 4598 # under the terms of the GNU General Public License version 2 only, as 4599 # published by the Free Software Foundation. Oracle designates this 4600 # particular file as subject to the "Classpath" exception as provided 4601 # by Oracle in the LICENSE file that accompanied this code. 4602 # 4603 # This code is distributed in the hope that it will be useful, but WITHOUT 4604 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4605 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4606 # version 2 for more details (a copy is included in the LICENSE file that 4607 # accompanied this code). 4608 # 4609 # You should have received a copy of the GNU General Public License version 4610 # 2 along with this work; if not, write to the Free Software Foundation, 4611 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4612 # 4613 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4614 # or visit www.oracle.com if you need additional information or have any 4615 # questions. 4616 # 4617 4618 ################################################################################ 4619 # Setup libffi (Foreign Function Interface) 4620 ################################################################################ 4621 4622 4623 # 4624 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4625 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4626 # 4627 # This code is free software; you can redistribute it and/or modify it 4628 # under the terms of the GNU General Public License version 2 only, as 4629 # published by the Free Software Foundation. Oracle designates this 4630 # particular file as subject to the "Classpath" exception as provided 4631 # by Oracle in the LICENSE file that accompanied this code. 4632 # 4633 # This code is distributed in the hope that it will be useful, but WITHOUT 4634 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4635 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4636 # version 2 for more details (a copy is included in the LICENSE file that 4637 # accompanied this code). 4638 # 4639 # You should have received a copy of the GNU General Public License version 4640 # 2 along with this work; if not, write to the Free Software Foundation, 4641 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4642 # 4643 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4644 # or visit www.oracle.com if you need additional information or have any 4645 # questions. 4646 # 4647 4648 ################################################################################ 4649 # Build the freetype lib from source 4650 ################################################################################ 4651 4652 4653 ################################################################################ 4654 # Check if a potential freeype library match is correct and usable 4655 ################################################################################ 4656 4657 4658 ################################################################################ 4659 # Setup freetype (The FreeType2 font rendering library) 4660 ################################################################################ 4661 4662 4663 # 4664 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4665 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4666 # 4667 # This code is free software; you can redistribute it and/or modify it 4668 # under the terms of the GNU General Public License version 2 only, as 4669 # published by the Free Software Foundation. Oracle designates this 4670 # particular file as subject to the "Classpath" exception as provided 4671 # by Oracle in the LICENSE file that accompanied this code. 4672 # 4673 # This code is distributed in the hope that it will be useful, but WITHOUT 4674 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4675 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4676 # version 2 for more details (a copy is included in the LICENSE file that 4677 # accompanied this code). 4678 # 4679 # You should have received a copy of the GNU General Public License version 4680 # 2 along with this work; if not, write to the Free Software Foundation, 4681 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4682 # 4683 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4684 # or visit www.oracle.com if you need additional information or have any 4685 # questions. 4686 # 4687 4688 ################################################################################ 4689 # Setup the standard C/C++ runtime libraries. 4690 # 4691 # Most importantly, determine if stdc++ should be linked statically or 4692 # dynamically. 4693 ################################################################################ 4694 4695 4696 # 4697 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4698 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4699 # 4700 # This code is free software; you can redistribute it and/or modify it 4701 # under the terms of the GNU General Public License version 2 only, as 4702 # published by the Free Software Foundation. Oracle designates this 4703 # particular file as subject to the "Classpath" exception as provided 4704 # by Oracle in the LICENSE file that accompanied this code. 4705 # 4706 # This code is distributed in the hope that it will be useful, but WITHOUT 4707 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4708 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4709 # version 2 for more details (a copy is included in the LICENSE file that 4710 # accompanied this code). 4711 # 4712 # You should have received a copy of the GNU General Public License version 4713 # 2 along with this work; if not, write to the Free Software Foundation, 4714 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4715 # 4716 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4717 # or visit www.oracle.com if you need additional information or have any 4718 # questions. 4719 # 4720 4721 ################################################################################ 4722 # Setup X11 Windows system 4723 ################################################################################ 4724 4725 4726 4727 ################################################################################ 4728 # Determine which libraries are needed for this configuration 4729 ################################################################################ 4730 4731 4732 ################################################################################ 4733 # Parse library options, and setup needed libraries 4734 ################################################################################ 4735 4736 4737 ################################################################################ 4738 # Setup llvm (Low-Level VM) 4739 ################################################################################ 4740 4741 4742 ################################################################################ 4743 # Setup various libraries, typically small system libraries 4744 ################################################################################ 4745 4746 4747 ################################################################################ 4748 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4749 # redistribute it in the test image. 4750 ################################################################################ 4751 4752 4753 4754 # 4755 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4756 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4757 # 4758 # This code is free software; you can redistribute it and/or modify it 4759 # under the terms of the GNU General Public License version 2 only, as 4760 # published by the Free Software Foundation. Oracle designates this 4761 # particular file as subject to the "Classpath" exception as provided 4762 # by Oracle in the LICENSE file that accompanied this code. 4763 # 4764 # This code is distributed in the hope that it will be useful, but WITHOUT 4765 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4766 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4767 # version 2 for more details (a copy is included in the LICENSE file that 4768 # accompanied this code). 4769 # 4770 # You should have received a copy of the GNU General Public License version 4771 # 2 along with this work; if not, write to the Free Software Foundation, 4772 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4773 # 4774 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4775 # or visit www.oracle.com if you need additional information or have any 4776 # questions. 4777 # 4778 4779 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4780 # Converts autoconf style CPU name to OpenJDK style, into 4781 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4782 4783 4784 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4785 # Converts autoconf style OS name to OpenJDK style, into 4786 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4787 4788 4789 # Expects $host_os $host_cpu $build_os and $build_cpu 4790 # and $with_target_bits to have been setup! 4791 # 4792 # Translate the standard triplet(quadruplet) definition 4793 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4794 # OPENJDK_BUILD_OS, etc. 4795 4796 4797 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4798 # accordingly. Must be done after setting up build and target system, but before 4799 # doing anything else with these values. 4800 4801 4802 # Setup the legacy variables, for controlling the old makefiles. 4803 # 4804 4805 4806 # $1 - Either TARGET or BUILD to setup the variables for. 4807 4808 4809 4810 4811 #%%% Build and target systems %%% 4812 4813 4814 4815 4816 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4817 # Add -mX to various FLAGS variables. 4818 4819 4820 4821 4822 4823 4824 # 4825 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4826 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4827 # 4828 # This code is free software; you can redistribute it and/or modify it 4829 # under the terms of the GNU General Public License version 2 only, as 4830 # published by the Free Software Foundation. Oracle designates this 4831 # particular file as subject to the "Classpath" exception as provided 4832 # by Oracle in the LICENSE file that accompanied this code. 4833 # 4834 # This code is distributed in the hope that it will be useful, but WITHOUT 4835 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4836 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4837 # version 2 for more details (a copy is included in the LICENSE file that 4838 # accompanied this code). 4839 # 4840 # You should have received a copy of the GNU General Public License version 4841 # 2 along with this work; if not, write to the Free Software Foundation, 4842 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4843 # 4844 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4845 # or visit www.oracle.com if you need additional information or have any 4846 # questions. 4847 # 4848 4849 4850 4851 4852 4853 4854 4855 ################################################################################ 4856 # Define a mechanism for importing extra prebuilt modules 4857 # 4858 4859 4860 4861 # 4862 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4863 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4864 # 4865 # This code is free software; you can redistribute it and/or modify it 4866 # under the terms of the GNU General Public License version 2 only, as 4867 # published by the Free Software Foundation. Oracle designates this 4868 # particular file as subject to the "Classpath" exception as provided 4869 # by Oracle in the LICENSE file that accompanied this code. 4870 # 4871 # This code is distributed in the hope that it will be useful, but WITHOUT 4872 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4873 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4874 # version 2 for more details (a copy is included in the LICENSE file that 4875 # accompanied this code). 4876 # 4877 # You should have received a copy of the GNU General Public License version 4878 # 2 along with this work; if not, write to the Free Software Foundation, 4879 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4880 # 4881 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4882 # or visit www.oracle.com if you need additional information or have any 4883 # questions. 4884 # 4885 4886 ######################################################################## 4887 # This file is responsible for detecting, verifying and setting up the 4888 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4889 # proper paths to the binaries, but it will not setup any flags. 4890 # 4891 # The binaries used is determined by the toolchain type, which is the family of 4892 # compilers and related tools that are used. 4893 ######################################################################## 4894 4895 4896 # All valid toolchains, regardless of platform (used by help.m4) 4897 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4898 4899 # These toolchains are valid on different platforms 4900 VALID_TOOLCHAINS_linux="gcc clang" 4901 VALID_TOOLCHAINS_solaris="solstudio" 4902 VALID_TOOLCHAINS_macosx="gcc clang" 4903 VALID_TOOLCHAINS_aix="xlc" 4904 VALID_TOOLCHAINS_windows="microsoft" 4905 4906 # Toolchain descriptions 4907 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4908 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4909 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4910 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4911 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4912 4913 # Minimum supported versions, empty means unspecified 4914 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4915 TOOLCHAIN_MINIMUM_VERSION_gcc="4.3" 4916 TOOLCHAIN_MINIMUM_VERSION_microsoft="" 4917 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 4918 TOOLCHAIN_MINIMUM_VERSION_xlc="" 4919 4920 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 4921 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 4922 # $1 - optional variable prefix for compiler and version variables (BUILD_) 4923 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 4924 4925 4926 # Check if the configured compiler (C and C++) is of a specific version or 4927 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 4928 # 4929 # Arguments: 4930 # VERSION: The version string to check against the found version 4931 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 4932 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 4933 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 4934 4935 4936 4937 4938 # Setup a number of variables describing how native output files are 4939 # named on this platform/toolchain. 4940 4941 4942 # Determine which toolchain type to use, and make sure it is valid for this 4943 # platform. Setup various information about the selected toolchain. 4944 4945 4946 # Before we start detecting the toolchain executables, we might need some 4947 # special setup, e.g. additional paths etc. 4948 4949 4950 # Restore path, etc 4951 4952 4953 # Check if a compiler is of the toolchain type we expect, and save the version 4954 # information from it. If the compiler does not match the expected type, 4955 # this function will abort using AC_MSG_ERROR. If it matches, the version will 4956 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 4957 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 4958 # 4959 # $1 = compiler to test (CC or CXX) 4960 # $2 = human readable name of compiler (C or C++) 4961 4962 4963 # Try to locate the given C or C++ compiler in the path, or otherwise. 4964 # 4965 # $1 = compiler to test (CC or CXX) 4966 # $2 = human readable name of compiler (C or C++) 4967 # $3 = list of compiler names to search for 4968 4969 4970 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 4971 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 4972 # archiver (AR). Verify that the compilers are correct according to the 4973 # toolchain type. 4974 4975 4976 # Setup additional tools that is considered a part of the toolchain, but not the 4977 # core part. Many of these are highly platform-specific and do not exist, 4978 # and/or are not needed on all platforms. 4979 4980 4981 # Setup the build tools (i.e, the compiler and linker used to build programs 4982 # that should be run on the build platform, not the target platform, as a build 4983 # helper). Since the non-cross-compile case uses the normal, target compilers 4984 # for this, we can only do this after these have been setup. 4985 4986 4987 # Setup legacy variables that are still needed as alternative ways to refer to 4988 # parts of the toolchain. 4989 4990 4991 # Do some additional checks on the detected tools. 4992 4993 4994 # Setup the JTReg Regression Test Harness. 4995 4996 4997 # 4998 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 4999 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5000 # 5001 # This code is free software; you can redistribute it and/or modify it 5002 # under the terms of the GNU General Public License version 2 only, as 5003 # published by the Free Software Foundation. Oracle designates this 5004 # particular file as subject to the "Classpath" exception as provided 5005 # by Oracle in the LICENSE file that accompanied this code. 5006 # 5007 # This code is distributed in the hope that it will be useful, but WITHOUT 5008 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5009 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5010 # version 2 for more details (a copy is included in the LICENSE file that 5011 # accompanied this code). 5012 # 5013 # You should have received a copy of the GNU General Public License version 5014 # 2 along with this work; if not, write to the Free Software Foundation, 5015 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5016 # 5017 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5018 # or visit www.oracle.com if you need additional information or have any 5019 # questions. 5020 # 5021 5022 ################################################################################ 5023 # The order of these defines the priority by which we try to find them. 5024 VALID_VS_VERSIONS="2013 2012 2010" 5025 5026 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5027 VS_VERSION_INTERNAL_2010=100 5028 VS_MSVCR_2010=msvcr100.dll 5029 # We don't use msvcp on Visual Studio 2010 5030 #VS_MSVCP_2010=msvcp100.dll 5031 VS_ENVVAR_2010="VS100COMNTOOLS" 5032 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5033 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5034 VS_VS_PLATFORM_NAME_2010="v100" 5035 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5036 5037 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5038 VS_VERSION_INTERNAL_2012=110 5039 VS_MSVCR_2012=msvcr110.dll 5040 VS_MSVCP_2012=msvcp110.dll 5041 VS_ENVVAR_2012="VS110COMNTOOLS" 5042 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5043 VS_SDK_INSTALLDIR_2012= 5044 VS_VS_PLATFORM_NAME_2012="v110" 5045 VS_SDK_PLATFORM_NAME_2012= 5046 5047 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5048 VS_VERSION_INTERNAL_2013=120 5049 VS_MSVCR_2013=msvcr120.dll 5050 VS_MSVCP_2013=msvcp120.dll 5051 VS_ENVVAR_2013="VS120COMNTOOLS" 5052 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5053 VS_SDK_INSTALLDIR_2013= 5054 VS_VS_PLATFORM_NAME_2013="v120" 5055 VS_SDK_PLATFORM_NAME_2013= 5056 5057 ################################################################################ 5058 5059 5060 5061 ################################################################################ 5062 5063 5064 5065 ################################################################################ 5066 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5067 # build environment and assigns it to VS_ENV_CMD 5068 5069 5070 ################################################################################ 5071 5072 5073 5074 ################################################################################ 5075 # Check if the VS env variables were setup prior to running configure. 5076 # If not, then find vcvarsall.bat and run it automatically, and integrate 5077 # the set env variables into the spec file. 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 # This line needs to be here, verbatim, after all includes and the dummy hook 5093 # definitions. It is replaced with custom functionality when building 5094 # custom sources. 5095 #CUSTOM_AUTOCONF_INCLUDE 5096 5097 # Do not change or remove the following line, it is needed for consistency checks: 5098 DATE_WHEN_GENERATED=1474991180 5099 5100 ############################################################################### 5101 # 5102 # Initialization / Boot-strapping 5103 # 5104 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5105 # thus it jumps back and forth, each time gaining something needed later on. 5106 # 5107 ############################################################################### 5108 5109 # If we are requested to print additional help, do that and then exit. 5110 # This must be the very first call. 5111 5112 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5113 5114 # Print available toolchains 5115 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5116 $PRINTF "Which are valid to use depends on the build platform.\n" 5117 for toolchain in $VALID_TOOLCHAINS_all; do 5118 # Use indirect variable referencing 5119 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5120 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5121 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5122 done 5123 $PRINTF "\n" 5124 5125 # Print available jvm features 5126 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5127 $PRINTF "Which are valid to use depends on the target platform.\n " 5128 $PRINTF "%s " $VALID_JVM_FEATURES 5129 $PRINTF "\n" 5130 5131 # And now exit directly 5132 exit 0 5133 fi 5134 5135 5136 # Basic initialization that must happen first of all in the normal process. 5137 5138 # Save the original command line. This is passed to us by the wrapper configure script. 5139 5140 # Save the path variable before it gets changed 5141 ORIGINAL_PATH="$PATH" 5142 5143 DATE_WHEN_CONFIGURED=`LANG=C date` 5144 5145 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5146 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5147 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5148 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5149 5150 5151 # Start with tools that do not need have cross compilation support 5152 # and can be expected to be found in the default PATH. These tools are 5153 # used by configure. 5154 5155 # First are all the simple required tools. 5156 5157 5158 5159 # Publish this variable in the help. 5160 5161 5162 if [ -z "${BASENAME+x}" ]; then 5163 # The variable is not set by user, try to locate tool using the code snippet 5164 for ac_prog in basename 5165 do 5166 # Extract the first word of "$ac_prog", so it can be a program name with args. 5167 set dummy $ac_prog; ac_word=$2 5168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5169 $as_echo_n "checking for $ac_word... " >&6; } 5170 if ${ac_cv_path_BASENAME+:} false; then : 5171 $as_echo_n "(cached) " >&6 5172 else 5173 case $BASENAME in 5174 [\\/]* | ?:[\\/]*) 5175 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5176 ;; 5177 *) 5178 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5179 for as_dir in $PATH 5180 do 5181 IFS=$as_save_IFS 5182 test -z "$as_dir" && as_dir=. 5183 for ac_exec_ext in '' $ac_executable_extensions; do 5184 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5185 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5186 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5187 break 2 5188 fi 5189 done 5190 done 5191 IFS=$as_save_IFS 5192 5193 ;; 5194 esac 5195 fi 5196 BASENAME=$ac_cv_path_BASENAME 5197 if test -n "$BASENAME"; then 5198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5199 $as_echo "$BASENAME" >&6; } 5200 else 5201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5202 $as_echo "no" >&6; } 5203 fi 5204 5205 5206 test -n "$BASENAME" && break 5207 done 5208 5209 else 5210 # The variable is set, but is it from the command line or the environment? 5211 5212 # Try to remove the string !BASENAME! from our list. 5213 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5214 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5215 # If it failed, the variable was not from the command line. Ignore it, 5216 # but warn the user (except for BASH, which is always set by the calling BASH). 5217 if test "xBASENAME" != xBASH; then 5218 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5219 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5220 fi 5221 # Try to locate tool using the code snippet 5222 for ac_prog in basename 5223 do 5224 # Extract the first word of "$ac_prog", so it can be a program name with args. 5225 set dummy $ac_prog; ac_word=$2 5226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5227 $as_echo_n "checking for $ac_word... " >&6; } 5228 if ${ac_cv_path_BASENAME+:} false; then : 5229 $as_echo_n "(cached) " >&6 5230 else 5231 case $BASENAME in 5232 [\\/]* | ?:[\\/]*) 5233 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5234 ;; 5235 *) 5236 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5237 for as_dir in $PATH 5238 do 5239 IFS=$as_save_IFS 5240 test -z "$as_dir" && as_dir=. 5241 for ac_exec_ext in '' $ac_executable_extensions; do 5242 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5243 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5244 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5245 break 2 5246 fi 5247 done 5248 done 5249 IFS=$as_save_IFS 5250 5251 ;; 5252 esac 5253 fi 5254 BASENAME=$ac_cv_path_BASENAME 5255 if test -n "$BASENAME"; then 5256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5257 $as_echo "$BASENAME" >&6; } 5258 else 5259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5260 $as_echo "no" >&6; } 5261 fi 5262 5263 5264 test -n "$BASENAME" && break 5265 done 5266 5267 else 5268 # If it succeeded, then it was overridden by the user. We will use it 5269 # for the tool. 5270 5271 # First remove it from the list of overridden variables, so we can test 5272 # for unknown variables in the end. 5273 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5274 5275 # Check if we try to supply an empty value 5276 if test "x$BASENAME" = x; then 5277 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5278 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5280 $as_echo_n "checking for BASENAME... " >&6; } 5281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5282 $as_echo "disabled" >&6; } 5283 else 5284 # Check if the provided tool contains a complete path. 5285 tool_specified="$BASENAME" 5286 tool_basename="${tool_specified##*/}" 5287 if test "x$tool_basename" = "x$tool_specified"; then 5288 # A command without a complete path is provided, search $PATH. 5289 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5290 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5291 # Extract the first word of "$tool_basename", so it can be a program name with args. 5292 set dummy $tool_basename; ac_word=$2 5293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5294 $as_echo_n "checking for $ac_word... " >&6; } 5295 if ${ac_cv_path_BASENAME+:} false; then : 5296 $as_echo_n "(cached) " >&6 5297 else 5298 case $BASENAME in 5299 [\\/]* | ?:[\\/]*) 5300 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5301 ;; 5302 *) 5303 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5304 for as_dir in $PATH 5305 do 5306 IFS=$as_save_IFS 5307 test -z "$as_dir" && as_dir=. 5308 for ac_exec_ext in '' $ac_executable_extensions; do 5309 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5310 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5311 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5312 break 2 5313 fi 5314 done 5315 done 5316 IFS=$as_save_IFS 5317 5318 ;; 5319 esac 5320 fi 5321 BASENAME=$ac_cv_path_BASENAME 5322 if test -n "$BASENAME"; then 5323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5324 $as_echo "$BASENAME" >&6; } 5325 else 5326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5327 $as_echo "no" >&6; } 5328 fi 5329 5330 5331 if test "x$BASENAME" = x; then 5332 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5333 fi 5334 else 5335 # Otherwise we believe it is a complete path. Use it as it is. 5336 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5337 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5339 $as_echo_n "checking for BASENAME... " >&6; } 5340 if test ! -x "$tool_specified"; then 5341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5342 $as_echo "not found" >&6; } 5343 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5344 fi 5345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5346 $as_echo "$tool_specified" >&6; } 5347 fi 5348 fi 5349 fi 5350 5351 fi 5352 5353 5354 5355 if test "x$BASENAME" = x; then 5356 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5357 fi 5358 5359 5360 5361 5362 5363 # Publish this variable in the help. 5364 5365 5366 if [ -z "${BASH+x}" ]; then 5367 # The variable is not set by user, try to locate tool using the code snippet 5368 for ac_prog in bash 5369 do 5370 # Extract the first word of "$ac_prog", so it can be a program name with args. 5371 set dummy $ac_prog; ac_word=$2 5372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5373 $as_echo_n "checking for $ac_word... " >&6; } 5374 if ${ac_cv_path_BASH+:} false; then : 5375 $as_echo_n "(cached) " >&6 5376 else 5377 case $BASH in 5378 [\\/]* | ?:[\\/]*) 5379 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5380 ;; 5381 *) 5382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5383 for as_dir in $PATH 5384 do 5385 IFS=$as_save_IFS 5386 test -z "$as_dir" && as_dir=. 5387 for ac_exec_ext in '' $ac_executable_extensions; do 5388 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5389 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5390 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5391 break 2 5392 fi 5393 done 5394 done 5395 IFS=$as_save_IFS 5396 5397 ;; 5398 esac 5399 fi 5400 BASH=$ac_cv_path_BASH 5401 if test -n "$BASH"; then 5402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5403 $as_echo "$BASH" >&6; } 5404 else 5405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5406 $as_echo "no" >&6; } 5407 fi 5408 5409 5410 test -n "$BASH" && break 5411 done 5412 5413 else 5414 # The variable is set, but is it from the command line or the environment? 5415 5416 # Try to remove the string !BASH! from our list. 5417 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5418 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5419 # If it failed, the variable was not from the command line. Ignore it, 5420 # but warn the user (except for BASH, which is always set by the calling BASH). 5421 if test "xBASH" != xBASH; then 5422 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5423 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5424 fi 5425 # Try to locate tool using the code snippet 5426 for ac_prog in bash 5427 do 5428 # Extract the first word of "$ac_prog", so it can be a program name with args. 5429 set dummy $ac_prog; ac_word=$2 5430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5431 $as_echo_n "checking for $ac_word... " >&6; } 5432 if ${ac_cv_path_BASH+:} false; then : 5433 $as_echo_n "(cached) " >&6 5434 else 5435 case $BASH in 5436 [\\/]* | ?:[\\/]*) 5437 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5438 ;; 5439 *) 5440 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5441 for as_dir in $PATH 5442 do 5443 IFS=$as_save_IFS 5444 test -z "$as_dir" && as_dir=. 5445 for ac_exec_ext in '' $ac_executable_extensions; do 5446 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5447 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5448 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5449 break 2 5450 fi 5451 done 5452 done 5453 IFS=$as_save_IFS 5454 5455 ;; 5456 esac 5457 fi 5458 BASH=$ac_cv_path_BASH 5459 if test -n "$BASH"; then 5460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5461 $as_echo "$BASH" >&6; } 5462 else 5463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5464 $as_echo "no" >&6; } 5465 fi 5466 5467 5468 test -n "$BASH" && break 5469 done 5470 5471 else 5472 # If it succeeded, then it was overridden by the user. We will use it 5473 # for the tool. 5474 5475 # First remove it from the list of overridden variables, so we can test 5476 # for unknown variables in the end. 5477 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5478 5479 # Check if we try to supply an empty value 5480 if test "x$BASH" = x; then 5481 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5482 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5484 $as_echo_n "checking for BASH... " >&6; } 5485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5486 $as_echo "disabled" >&6; } 5487 else 5488 # Check if the provided tool contains a complete path. 5489 tool_specified="$BASH" 5490 tool_basename="${tool_specified##*/}" 5491 if test "x$tool_basename" = "x$tool_specified"; then 5492 # A command without a complete path is provided, search $PATH. 5493 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5494 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5495 # Extract the first word of "$tool_basename", so it can be a program name with args. 5496 set dummy $tool_basename; ac_word=$2 5497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5498 $as_echo_n "checking for $ac_word... " >&6; } 5499 if ${ac_cv_path_BASH+:} false; then : 5500 $as_echo_n "(cached) " >&6 5501 else 5502 case $BASH in 5503 [\\/]* | ?:[\\/]*) 5504 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5505 ;; 5506 *) 5507 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5508 for as_dir in $PATH 5509 do 5510 IFS=$as_save_IFS 5511 test -z "$as_dir" && as_dir=. 5512 for ac_exec_ext in '' $ac_executable_extensions; do 5513 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5514 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5515 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5516 break 2 5517 fi 5518 done 5519 done 5520 IFS=$as_save_IFS 5521 5522 ;; 5523 esac 5524 fi 5525 BASH=$ac_cv_path_BASH 5526 if test -n "$BASH"; then 5527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5528 $as_echo "$BASH" >&6; } 5529 else 5530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5531 $as_echo "no" >&6; } 5532 fi 5533 5534 5535 if test "x$BASH" = x; then 5536 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5537 fi 5538 else 5539 # Otherwise we believe it is a complete path. Use it as it is. 5540 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5541 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5543 $as_echo_n "checking for BASH... " >&6; } 5544 if test ! -x "$tool_specified"; then 5545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5546 $as_echo "not found" >&6; } 5547 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5548 fi 5549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5550 $as_echo "$tool_specified" >&6; } 5551 fi 5552 fi 5553 fi 5554 5555 fi 5556 5557 5558 5559 if test "x$BASH" = x; then 5560 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5561 fi 5562 5563 5564 5565 5566 5567 # Publish this variable in the help. 5568 5569 5570 if [ -z "${CAT+x}" ]; then 5571 # The variable is not set by user, try to locate tool using the code snippet 5572 for ac_prog in cat 5573 do 5574 # Extract the first word of "$ac_prog", so it can be a program name with args. 5575 set dummy $ac_prog; ac_word=$2 5576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5577 $as_echo_n "checking for $ac_word... " >&6; } 5578 if ${ac_cv_path_CAT+:} false; then : 5579 $as_echo_n "(cached) " >&6 5580 else 5581 case $CAT in 5582 [\\/]* | ?:[\\/]*) 5583 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5584 ;; 5585 *) 5586 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5587 for as_dir in $PATH 5588 do 5589 IFS=$as_save_IFS 5590 test -z "$as_dir" && as_dir=. 5591 for ac_exec_ext in '' $ac_executable_extensions; do 5592 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5593 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5594 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5595 break 2 5596 fi 5597 done 5598 done 5599 IFS=$as_save_IFS 5600 5601 ;; 5602 esac 5603 fi 5604 CAT=$ac_cv_path_CAT 5605 if test -n "$CAT"; then 5606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5607 $as_echo "$CAT" >&6; } 5608 else 5609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5610 $as_echo "no" >&6; } 5611 fi 5612 5613 5614 test -n "$CAT" && break 5615 done 5616 5617 else 5618 # The variable is set, but is it from the command line or the environment? 5619 5620 # Try to remove the string !CAT! from our list. 5621 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5622 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5623 # If it failed, the variable was not from the command line. Ignore it, 5624 # but warn the user (except for BASH, which is always set by the calling BASH). 5625 if test "xCAT" != xBASH; then 5626 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5627 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5628 fi 5629 # Try to locate tool using the code snippet 5630 for ac_prog in cat 5631 do 5632 # Extract the first word of "$ac_prog", so it can be a program name with args. 5633 set dummy $ac_prog; ac_word=$2 5634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5635 $as_echo_n "checking for $ac_word... " >&6; } 5636 if ${ac_cv_path_CAT+:} false; then : 5637 $as_echo_n "(cached) " >&6 5638 else 5639 case $CAT in 5640 [\\/]* | ?:[\\/]*) 5641 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5642 ;; 5643 *) 5644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5645 for as_dir in $PATH 5646 do 5647 IFS=$as_save_IFS 5648 test -z "$as_dir" && as_dir=. 5649 for ac_exec_ext in '' $ac_executable_extensions; do 5650 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5651 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5652 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5653 break 2 5654 fi 5655 done 5656 done 5657 IFS=$as_save_IFS 5658 5659 ;; 5660 esac 5661 fi 5662 CAT=$ac_cv_path_CAT 5663 if test -n "$CAT"; then 5664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5665 $as_echo "$CAT" >&6; } 5666 else 5667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5668 $as_echo "no" >&6; } 5669 fi 5670 5671 5672 test -n "$CAT" && break 5673 done 5674 5675 else 5676 # If it succeeded, then it was overridden by the user. We will use it 5677 # for the tool. 5678 5679 # First remove it from the list of overridden variables, so we can test 5680 # for unknown variables in the end. 5681 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5682 5683 # Check if we try to supply an empty value 5684 if test "x$CAT" = x; then 5685 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5686 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5688 $as_echo_n "checking for CAT... " >&6; } 5689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5690 $as_echo "disabled" >&6; } 5691 else 5692 # Check if the provided tool contains a complete path. 5693 tool_specified="$CAT" 5694 tool_basename="${tool_specified##*/}" 5695 if test "x$tool_basename" = "x$tool_specified"; then 5696 # A command without a complete path is provided, search $PATH. 5697 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5698 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5699 # Extract the first word of "$tool_basename", so it can be a program name with args. 5700 set dummy $tool_basename; ac_word=$2 5701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5702 $as_echo_n "checking for $ac_word... " >&6; } 5703 if ${ac_cv_path_CAT+:} false; then : 5704 $as_echo_n "(cached) " >&6 5705 else 5706 case $CAT in 5707 [\\/]* | ?:[\\/]*) 5708 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5709 ;; 5710 *) 5711 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5712 for as_dir in $PATH 5713 do 5714 IFS=$as_save_IFS 5715 test -z "$as_dir" && as_dir=. 5716 for ac_exec_ext in '' $ac_executable_extensions; do 5717 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5718 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5720 break 2 5721 fi 5722 done 5723 done 5724 IFS=$as_save_IFS 5725 5726 ;; 5727 esac 5728 fi 5729 CAT=$ac_cv_path_CAT 5730 if test -n "$CAT"; then 5731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5732 $as_echo "$CAT" >&6; } 5733 else 5734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5735 $as_echo "no" >&6; } 5736 fi 5737 5738 5739 if test "x$CAT" = x; then 5740 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5741 fi 5742 else 5743 # Otherwise we believe it is a complete path. Use it as it is. 5744 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5745 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5747 $as_echo_n "checking for CAT... " >&6; } 5748 if test ! -x "$tool_specified"; then 5749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5750 $as_echo "not found" >&6; } 5751 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5752 fi 5753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5754 $as_echo "$tool_specified" >&6; } 5755 fi 5756 fi 5757 fi 5758 5759 fi 5760 5761 5762 5763 if test "x$CAT" = x; then 5764 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5765 fi 5766 5767 5768 5769 5770 5771 # Publish this variable in the help. 5772 5773 5774 if [ -z "${CHMOD+x}" ]; then 5775 # The variable is not set by user, try to locate tool using the code snippet 5776 for ac_prog in chmod 5777 do 5778 # Extract the first word of "$ac_prog", so it can be a program name with args. 5779 set dummy $ac_prog; ac_word=$2 5780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5781 $as_echo_n "checking for $ac_word... " >&6; } 5782 if ${ac_cv_path_CHMOD+:} false; then : 5783 $as_echo_n "(cached) " >&6 5784 else 5785 case $CHMOD in 5786 [\\/]* | ?:[\\/]*) 5787 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5788 ;; 5789 *) 5790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5791 for as_dir in $PATH 5792 do 5793 IFS=$as_save_IFS 5794 test -z "$as_dir" && as_dir=. 5795 for ac_exec_ext in '' $ac_executable_extensions; do 5796 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5797 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5799 break 2 5800 fi 5801 done 5802 done 5803 IFS=$as_save_IFS 5804 5805 ;; 5806 esac 5807 fi 5808 CHMOD=$ac_cv_path_CHMOD 5809 if test -n "$CHMOD"; then 5810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5811 $as_echo "$CHMOD" >&6; } 5812 else 5813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5814 $as_echo "no" >&6; } 5815 fi 5816 5817 5818 test -n "$CHMOD" && break 5819 done 5820 5821 else 5822 # The variable is set, but is it from the command line or the environment? 5823 5824 # Try to remove the string !CHMOD! from our list. 5825 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5826 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5827 # If it failed, the variable was not from the command line. Ignore it, 5828 # but warn the user (except for BASH, which is always set by the calling BASH). 5829 if test "xCHMOD" != xBASH; then 5830 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5831 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5832 fi 5833 # Try to locate tool using the code snippet 5834 for ac_prog in chmod 5835 do 5836 # Extract the first word of "$ac_prog", so it can be a program name with args. 5837 set dummy $ac_prog; ac_word=$2 5838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5839 $as_echo_n "checking for $ac_word... " >&6; } 5840 if ${ac_cv_path_CHMOD+:} false; then : 5841 $as_echo_n "(cached) " >&6 5842 else 5843 case $CHMOD in 5844 [\\/]* | ?:[\\/]*) 5845 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5846 ;; 5847 *) 5848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5849 for as_dir in $PATH 5850 do 5851 IFS=$as_save_IFS 5852 test -z "$as_dir" && as_dir=. 5853 for ac_exec_ext in '' $ac_executable_extensions; do 5854 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5855 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5856 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5857 break 2 5858 fi 5859 done 5860 done 5861 IFS=$as_save_IFS 5862 5863 ;; 5864 esac 5865 fi 5866 CHMOD=$ac_cv_path_CHMOD 5867 if test -n "$CHMOD"; then 5868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5869 $as_echo "$CHMOD" >&6; } 5870 else 5871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5872 $as_echo "no" >&6; } 5873 fi 5874 5875 5876 test -n "$CHMOD" && break 5877 done 5878 5879 else 5880 # If it succeeded, then it was overridden by the user. We will use it 5881 # for the tool. 5882 5883 # First remove it from the list of overridden variables, so we can test 5884 # for unknown variables in the end. 5885 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5886 5887 # Check if we try to supply an empty value 5888 if test "x$CHMOD" = x; then 5889 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5890 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5892 $as_echo_n "checking for CHMOD... " >&6; } 5893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5894 $as_echo "disabled" >&6; } 5895 else 5896 # Check if the provided tool contains a complete path. 5897 tool_specified="$CHMOD" 5898 tool_basename="${tool_specified##*/}" 5899 if test "x$tool_basename" = "x$tool_specified"; then 5900 # A command without a complete path is provided, search $PATH. 5901 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5902 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5903 # Extract the first word of "$tool_basename", so it can be a program name with args. 5904 set dummy $tool_basename; ac_word=$2 5905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5906 $as_echo_n "checking for $ac_word... " >&6; } 5907 if ${ac_cv_path_CHMOD+:} false; then : 5908 $as_echo_n "(cached) " >&6 5909 else 5910 case $CHMOD in 5911 [\\/]* | ?:[\\/]*) 5912 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5913 ;; 5914 *) 5915 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5916 for as_dir in $PATH 5917 do 5918 IFS=$as_save_IFS 5919 test -z "$as_dir" && as_dir=. 5920 for ac_exec_ext in '' $ac_executable_extensions; do 5921 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5922 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5923 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5924 break 2 5925 fi 5926 done 5927 done 5928 IFS=$as_save_IFS 5929 5930 ;; 5931 esac 5932 fi 5933 CHMOD=$ac_cv_path_CHMOD 5934 if test -n "$CHMOD"; then 5935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5936 $as_echo "$CHMOD" >&6; } 5937 else 5938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5939 $as_echo "no" >&6; } 5940 fi 5941 5942 5943 if test "x$CHMOD" = x; then 5944 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5945 fi 5946 else 5947 # Otherwise we believe it is a complete path. Use it as it is. 5948 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 5949 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 5950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5951 $as_echo_n "checking for CHMOD... " >&6; } 5952 if test ! -x "$tool_specified"; then 5953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5954 $as_echo "not found" >&6; } 5955 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 5956 fi 5957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5958 $as_echo "$tool_specified" >&6; } 5959 fi 5960 fi 5961 fi 5962 5963 fi 5964 5965 5966 5967 if test "x$CHMOD" = x; then 5968 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 5969 fi 5970 5971 5972 5973 5974 5975 # Publish this variable in the help. 5976 5977 5978 if [ -z "${CMP+x}" ]; then 5979 # The variable is not set by user, try to locate tool using the code snippet 5980 for ac_prog in cmp 5981 do 5982 # Extract the first word of "$ac_prog", so it can be a program name with args. 5983 set dummy $ac_prog; ac_word=$2 5984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5985 $as_echo_n "checking for $ac_word... " >&6; } 5986 if ${ac_cv_path_CMP+:} false; then : 5987 $as_echo_n "(cached) " >&6 5988 else 5989 case $CMP in 5990 [\\/]* | ?:[\\/]*) 5991 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 5992 ;; 5993 *) 5994 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5995 for as_dir in $PATH 5996 do 5997 IFS=$as_save_IFS 5998 test -z "$as_dir" && as_dir=. 5999 for ac_exec_ext in '' $ac_executable_extensions; do 6000 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6001 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6002 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6003 break 2 6004 fi 6005 done 6006 done 6007 IFS=$as_save_IFS 6008 6009 ;; 6010 esac 6011 fi 6012 CMP=$ac_cv_path_CMP 6013 if test -n "$CMP"; then 6014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6015 $as_echo "$CMP" >&6; } 6016 else 6017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6018 $as_echo "no" >&6; } 6019 fi 6020 6021 6022 test -n "$CMP" && break 6023 done 6024 6025 else 6026 # The variable is set, but is it from the command line or the environment? 6027 6028 # Try to remove the string !CMP! from our list. 6029 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6030 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6031 # If it failed, the variable was not from the command line. Ignore it, 6032 # but warn the user (except for BASH, which is always set by the calling BASH). 6033 if test "xCMP" != xBASH; then 6034 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6035 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6036 fi 6037 # Try to locate tool using the code snippet 6038 for ac_prog in cmp 6039 do 6040 # Extract the first word of "$ac_prog", so it can be a program name with args. 6041 set dummy $ac_prog; ac_word=$2 6042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6043 $as_echo_n "checking for $ac_word... " >&6; } 6044 if ${ac_cv_path_CMP+:} false; then : 6045 $as_echo_n "(cached) " >&6 6046 else 6047 case $CMP in 6048 [\\/]* | ?:[\\/]*) 6049 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6050 ;; 6051 *) 6052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6053 for as_dir in $PATH 6054 do 6055 IFS=$as_save_IFS 6056 test -z "$as_dir" && as_dir=. 6057 for ac_exec_ext in '' $ac_executable_extensions; do 6058 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6059 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6060 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6061 break 2 6062 fi 6063 done 6064 done 6065 IFS=$as_save_IFS 6066 6067 ;; 6068 esac 6069 fi 6070 CMP=$ac_cv_path_CMP 6071 if test -n "$CMP"; then 6072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6073 $as_echo "$CMP" >&6; } 6074 else 6075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6076 $as_echo "no" >&6; } 6077 fi 6078 6079 6080 test -n "$CMP" && break 6081 done 6082 6083 else 6084 # If it succeeded, then it was overridden by the user. We will use it 6085 # for the tool. 6086 6087 # First remove it from the list of overridden variables, so we can test 6088 # for unknown variables in the end. 6089 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6090 6091 # Check if we try to supply an empty value 6092 if test "x$CMP" = x; then 6093 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6094 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6096 $as_echo_n "checking for CMP... " >&6; } 6097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6098 $as_echo "disabled" >&6; } 6099 else 6100 # Check if the provided tool contains a complete path. 6101 tool_specified="$CMP" 6102 tool_basename="${tool_specified##*/}" 6103 if test "x$tool_basename" = "x$tool_specified"; then 6104 # A command without a complete path is provided, search $PATH. 6105 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6106 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6107 # Extract the first word of "$tool_basename", so it can be a program name with args. 6108 set dummy $tool_basename; ac_word=$2 6109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6110 $as_echo_n "checking for $ac_word... " >&6; } 6111 if ${ac_cv_path_CMP+:} false; then : 6112 $as_echo_n "(cached) " >&6 6113 else 6114 case $CMP in 6115 [\\/]* | ?:[\\/]*) 6116 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6117 ;; 6118 *) 6119 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6120 for as_dir in $PATH 6121 do 6122 IFS=$as_save_IFS 6123 test -z "$as_dir" && as_dir=. 6124 for ac_exec_ext in '' $ac_executable_extensions; do 6125 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6126 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6127 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6128 break 2 6129 fi 6130 done 6131 done 6132 IFS=$as_save_IFS 6133 6134 ;; 6135 esac 6136 fi 6137 CMP=$ac_cv_path_CMP 6138 if test -n "$CMP"; then 6139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6140 $as_echo "$CMP" >&6; } 6141 else 6142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6143 $as_echo "no" >&6; } 6144 fi 6145 6146 6147 if test "x$CMP" = x; then 6148 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6149 fi 6150 else 6151 # Otherwise we believe it is a complete path. Use it as it is. 6152 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6153 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6155 $as_echo_n "checking for CMP... " >&6; } 6156 if test ! -x "$tool_specified"; then 6157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6158 $as_echo "not found" >&6; } 6159 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6160 fi 6161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6162 $as_echo "$tool_specified" >&6; } 6163 fi 6164 fi 6165 fi 6166 6167 fi 6168 6169 6170 6171 if test "x$CMP" = x; then 6172 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6173 fi 6174 6175 6176 6177 6178 6179 # Publish this variable in the help. 6180 6181 6182 if [ -z "${COMM+x}" ]; then 6183 # The variable is not set by user, try to locate tool using the code snippet 6184 for ac_prog in comm 6185 do 6186 # Extract the first word of "$ac_prog", so it can be a program name with args. 6187 set dummy $ac_prog; ac_word=$2 6188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6189 $as_echo_n "checking for $ac_word... " >&6; } 6190 if ${ac_cv_path_COMM+:} false; then : 6191 $as_echo_n "(cached) " >&6 6192 else 6193 case $COMM in 6194 [\\/]* | ?:[\\/]*) 6195 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6196 ;; 6197 *) 6198 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6199 for as_dir in $PATH 6200 do 6201 IFS=$as_save_IFS 6202 test -z "$as_dir" && as_dir=. 6203 for ac_exec_ext in '' $ac_executable_extensions; do 6204 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6205 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6206 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6207 break 2 6208 fi 6209 done 6210 done 6211 IFS=$as_save_IFS 6212 6213 ;; 6214 esac 6215 fi 6216 COMM=$ac_cv_path_COMM 6217 if test -n "$COMM"; then 6218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6219 $as_echo "$COMM" >&6; } 6220 else 6221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6222 $as_echo "no" >&6; } 6223 fi 6224 6225 6226 test -n "$COMM" && break 6227 done 6228 6229 else 6230 # The variable is set, but is it from the command line or the environment? 6231 6232 # Try to remove the string !COMM! from our list. 6233 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6234 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6235 # If it failed, the variable was not from the command line. Ignore it, 6236 # but warn the user (except for BASH, which is always set by the calling BASH). 6237 if test "xCOMM" != xBASH; then 6238 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6239 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6240 fi 6241 # Try to locate tool using the code snippet 6242 for ac_prog in comm 6243 do 6244 # Extract the first word of "$ac_prog", so it can be a program name with args. 6245 set dummy $ac_prog; ac_word=$2 6246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6247 $as_echo_n "checking for $ac_word... " >&6; } 6248 if ${ac_cv_path_COMM+:} false; then : 6249 $as_echo_n "(cached) " >&6 6250 else 6251 case $COMM in 6252 [\\/]* | ?:[\\/]*) 6253 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6254 ;; 6255 *) 6256 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6257 for as_dir in $PATH 6258 do 6259 IFS=$as_save_IFS 6260 test -z "$as_dir" && as_dir=. 6261 for ac_exec_ext in '' $ac_executable_extensions; do 6262 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6263 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6264 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6265 break 2 6266 fi 6267 done 6268 done 6269 IFS=$as_save_IFS 6270 6271 ;; 6272 esac 6273 fi 6274 COMM=$ac_cv_path_COMM 6275 if test -n "$COMM"; then 6276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6277 $as_echo "$COMM" >&6; } 6278 else 6279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6280 $as_echo "no" >&6; } 6281 fi 6282 6283 6284 test -n "$COMM" && break 6285 done 6286 6287 else 6288 # If it succeeded, then it was overridden by the user. We will use it 6289 # for the tool. 6290 6291 # First remove it from the list of overridden variables, so we can test 6292 # for unknown variables in the end. 6293 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6294 6295 # Check if we try to supply an empty value 6296 if test "x$COMM" = x; then 6297 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6298 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6300 $as_echo_n "checking for COMM... " >&6; } 6301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6302 $as_echo "disabled" >&6; } 6303 else 6304 # Check if the provided tool contains a complete path. 6305 tool_specified="$COMM" 6306 tool_basename="${tool_specified##*/}" 6307 if test "x$tool_basename" = "x$tool_specified"; then 6308 # A command without a complete path is provided, search $PATH. 6309 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6310 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6311 # Extract the first word of "$tool_basename", so it can be a program name with args. 6312 set dummy $tool_basename; ac_word=$2 6313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6314 $as_echo_n "checking for $ac_word... " >&6; } 6315 if ${ac_cv_path_COMM+:} false; then : 6316 $as_echo_n "(cached) " >&6 6317 else 6318 case $COMM in 6319 [\\/]* | ?:[\\/]*) 6320 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6321 ;; 6322 *) 6323 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6324 for as_dir in $PATH 6325 do 6326 IFS=$as_save_IFS 6327 test -z "$as_dir" && as_dir=. 6328 for ac_exec_ext in '' $ac_executable_extensions; do 6329 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6330 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6331 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6332 break 2 6333 fi 6334 done 6335 done 6336 IFS=$as_save_IFS 6337 6338 ;; 6339 esac 6340 fi 6341 COMM=$ac_cv_path_COMM 6342 if test -n "$COMM"; then 6343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6344 $as_echo "$COMM" >&6; } 6345 else 6346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6347 $as_echo "no" >&6; } 6348 fi 6349 6350 6351 if test "x$COMM" = x; then 6352 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6353 fi 6354 else 6355 # Otherwise we believe it is a complete path. Use it as it is. 6356 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6357 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6359 $as_echo_n "checking for COMM... " >&6; } 6360 if test ! -x "$tool_specified"; then 6361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6362 $as_echo "not found" >&6; } 6363 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6364 fi 6365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6366 $as_echo "$tool_specified" >&6; } 6367 fi 6368 fi 6369 fi 6370 6371 fi 6372 6373 6374 6375 if test "x$COMM" = x; then 6376 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6377 fi 6378 6379 6380 6381 6382 6383 # Publish this variable in the help. 6384 6385 6386 if [ -z "${CP+x}" ]; then 6387 # The variable is not set by user, try to locate tool using the code snippet 6388 for ac_prog in cp 6389 do 6390 # Extract the first word of "$ac_prog", so it can be a program name with args. 6391 set dummy $ac_prog; ac_word=$2 6392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6393 $as_echo_n "checking for $ac_word... " >&6; } 6394 if ${ac_cv_path_CP+:} false; then : 6395 $as_echo_n "(cached) " >&6 6396 else 6397 case $CP in 6398 [\\/]* | ?:[\\/]*) 6399 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6400 ;; 6401 *) 6402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6403 for as_dir in $PATH 6404 do 6405 IFS=$as_save_IFS 6406 test -z "$as_dir" && as_dir=. 6407 for ac_exec_ext in '' $ac_executable_extensions; do 6408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6409 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6411 break 2 6412 fi 6413 done 6414 done 6415 IFS=$as_save_IFS 6416 6417 ;; 6418 esac 6419 fi 6420 CP=$ac_cv_path_CP 6421 if test -n "$CP"; then 6422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6423 $as_echo "$CP" >&6; } 6424 else 6425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6426 $as_echo "no" >&6; } 6427 fi 6428 6429 6430 test -n "$CP" && break 6431 done 6432 6433 else 6434 # The variable is set, but is it from the command line or the environment? 6435 6436 # Try to remove the string !CP! from our list. 6437 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6438 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6439 # If it failed, the variable was not from the command line. Ignore it, 6440 # but warn the user (except for BASH, which is always set by the calling BASH). 6441 if test "xCP" != xBASH; then 6442 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6443 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6444 fi 6445 # Try to locate tool using the code snippet 6446 for ac_prog in cp 6447 do 6448 # Extract the first word of "$ac_prog", so it can be a program name with args. 6449 set dummy $ac_prog; ac_word=$2 6450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6451 $as_echo_n "checking for $ac_word... " >&6; } 6452 if ${ac_cv_path_CP+:} false; then : 6453 $as_echo_n "(cached) " >&6 6454 else 6455 case $CP in 6456 [\\/]* | ?:[\\/]*) 6457 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6458 ;; 6459 *) 6460 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6461 for as_dir in $PATH 6462 do 6463 IFS=$as_save_IFS 6464 test -z "$as_dir" && as_dir=. 6465 for ac_exec_ext in '' $ac_executable_extensions; do 6466 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6467 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6468 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6469 break 2 6470 fi 6471 done 6472 done 6473 IFS=$as_save_IFS 6474 6475 ;; 6476 esac 6477 fi 6478 CP=$ac_cv_path_CP 6479 if test -n "$CP"; then 6480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6481 $as_echo "$CP" >&6; } 6482 else 6483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6484 $as_echo "no" >&6; } 6485 fi 6486 6487 6488 test -n "$CP" && break 6489 done 6490 6491 else 6492 # If it succeeded, then it was overridden by the user. We will use it 6493 # for the tool. 6494 6495 # First remove it from the list of overridden variables, so we can test 6496 # for unknown variables in the end. 6497 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6498 6499 # Check if we try to supply an empty value 6500 if test "x$CP" = x; then 6501 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6502 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6504 $as_echo_n "checking for CP... " >&6; } 6505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6506 $as_echo "disabled" >&6; } 6507 else 6508 # Check if the provided tool contains a complete path. 6509 tool_specified="$CP" 6510 tool_basename="${tool_specified##*/}" 6511 if test "x$tool_basename" = "x$tool_specified"; then 6512 # A command without a complete path is provided, search $PATH. 6513 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6514 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6515 # Extract the first word of "$tool_basename", so it can be a program name with args. 6516 set dummy $tool_basename; ac_word=$2 6517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6518 $as_echo_n "checking for $ac_word... " >&6; } 6519 if ${ac_cv_path_CP+:} false; then : 6520 $as_echo_n "(cached) " >&6 6521 else 6522 case $CP in 6523 [\\/]* | ?:[\\/]*) 6524 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6525 ;; 6526 *) 6527 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6528 for as_dir in $PATH 6529 do 6530 IFS=$as_save_IFS 6531 test -z "$as_dir" && as_dir=. 6532 for ac_exec_ext in '' $ac_executable_extensions; do 6533 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6534 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6535 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6536 break 2 6537 fi 6538 done 6539 done 6540 IFS=$as_save_IFS 6541 6542 ;; 6543 esac 6544 fi 6545 CP=$ac_cv_path_CP 6546 if test -n "$CP"; then 6547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6548 $as_echo "$CP" >&6; } 6549 else 6550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6551 $as_echo "no" >&6; } 6552 fi 6553 6554 6555 if test "x$CP" = x; then 6556 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6557 fi 6558 else 6559 # Otherwise we believe it is a complete path. Use it as it is. 6560 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6561 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6563 $as_echo_n "checking for CP... " >&6; } 6564 if test ! -x "$tool_specified"; then 6565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6566 $as_echo "not found" >&6; } 6567 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6568 fi 6569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6570 $as_echo "$tool_specified" >&6; } 6571 fi 6572 fi 6573 fi 6574 6575 fi 6576 6577 6578 6579 if test "x$CP" = x; then 6580 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6581 fi 6582 6583 6584 6585 6586 6587 # Publish this variable in the help. 6588 6589 6590 if [ -z "${CUT+x}" ]; then 6591 # The variable is not set by user, try to locate tool using the code snippet 6592 for ac_prog in cut 6593 do 6594 # Extract the first word of "$ac_prog", so it can be a program name with args. 6595 set dummy $ac_prog; ac_word=$2 6596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6597 $as_echo_n "checking for $ac_word... " >&6; } 6598 if ${ac_cv_path_CUT+:} false; then : 6599 $as_echo_n "(cached) " >&6 6600 else 6601 case $CUT in 6602 [\\/]* | ?:[\\/]*) 6603 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6604 ;; 6605 *) 6606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6607 for as_dir in $PATH 6608 do 6609 IFS=$as_save_IFS 6610 test -z "$as_dir" && as_dir=. 6611 for ac_exec_ext in '' $ac_executable_extensions; do 6612 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6613 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6615 break 2 6616 fi 6617 done 6618 done 6619 IFS=$as_save_IFS 6620 6621 ;; 6622 esac 6623 fi 6624 CUT=$ac_cv_path_CUT 6625 if test -n "$CUT"; then 6626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6627 $as_echo "$CUT" >&6; } 6628 else 6629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6630 $as_echo "no" >&6; } 6631 fi 6632 6633 6634 test -n "$CUT" && break 6635 done 6636 6637 else 6638 # The variable is set, but is it from the command line or the environment? 6639 6640 # Try to remove the string !CUT! from our list. 6641 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6642 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6643 # If it failed, the variable was not from the command line. Ignore it, 6644 # but warn the user (except for BASH, which is always set by the calling BASH). 6645 if test "xCUT" != xBASH; then 6646 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6647 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6648 fi 6649 # Try to locate tool using the code snippet 6650 for ac_prog in cut 6651 do 6652 # Extract the first word of "$ac_prog", so it can be a program name with args. 6653 set dummy $ac_prog; ac_word=$2 6654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6655 $as_echo_n "checking for $ac_word... " >&6; } 6656 if ${ac_cv_path_CUT+:} false; then : 6657 $as_echo_n "(cached) " >&6 6658 else 6659 case $CUT in 6660 [\\/]* | ?:[\\/]*) 6661 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6662 ;; 6663 *) 6664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6665 for as_dir in $PATH 6666 do 6667 IFS=$as_save_IFS 6668 test -z "$as_dir" && as_dir=. 6669 for ac_exec_ext in '' $ac_executable_extensions; do 6670 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6671 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6672 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6673 break 2 6674 fi 6675 done 6676 done 6677 IFS=$as_save_IFS 6678 6679 ;; 6680 esac 6681 fi 6682 CUT=$ac_cv_path_CUT 6683 if test -n "$CUT"; then 6684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6685 $as_echo "$CUT" >&6; } 6686 else 6687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6688 $as_echo "no" >&6; } 6689 fi 6690 6691 6692 test -n "$CUT" && break 6693 done 6694 6695 else 6696 # If it succeeded, then it was overridden by the user. We will use it 6697 # for the tool. 6698 6699 # First remove it from the list of overridden variables, so we can test 6700 # for unknown variables in the end. 6701 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6702 6703 # Check if we try to supply an empty value 6704 if test "x$CUT" = x; then 6705 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6706 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6708 $as_echo_n "checking for CUT... " >&6; } 6709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6710 $as_echo "disabled" >&6; } 6711 else 6712 # Check if the provided tool contains a complete path. 6713 tool_specified="$CUT" 6714 tool_basename="${tool_specified##*/}" 6715 if test "x$tool_basename" = "x$tool_specified"; then 6716 # A command without a complete path is provided, search $PATH. 6717 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6718 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6719 # Extract the first word of "$tool_basename", so it can be a program name with args. 6720 set dummy $tool_basename; ac_word=$2 6721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6722 $as_echo_n "checking for $ac_word... " >&6; } 6723 if ${ac_cv_path_CUT+:} false; then : 6724 $as_echo_n "(cached) " >&6 6725 else 6726 case $CUT in 6727 [\\/]* | ?:[\\/]*) 6728 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6729 ;; 6730 *) 6731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6732 for as_dir in $PATH 6733 do 6734 IFS=$as_save_IFS 6735 test -z "$as_dir" && as_dir=. 6736 for ac_exec_ext in '' $ac_executable_extensions; do 6737 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6738 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6740 break 2 6741 fi 6742 done 6743 done 6744 IFS=$as_save_IFS 6745 6746 ;; 6747 esac 6748 fi 6749 CUT=$ac_cv_path_CUT 6750 if test -n "$CUT"; then 6751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6752 $as_echo "$CUT" >&6; } 6753 else 6754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6755 $as_echo "no" >&6; } 6756 fi 6757 6758 6759 if test "x$CUT" = x; then 6760 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6761 fi 6762 else 6763 # Otherwise we believe it is a complete path. Use it as it is. 6764 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6765 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6767 $as_echo_n "checking for CUT... " >&6; } 6768 if test ! -x "$tool_specified"; then 6769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6770 $as_echo "not found" >&6; } 6771 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6772 fi 6773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6774 $as_echo "$tool_specified" >&6; } 6775 fi 6776 fi 6777 fi 6778 6779 fi 6780 6781 6782 6783 if test "x$CUT" = x; then 6784 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6785 fi 6786 6787 6788 6789 6790 6791 # Publish this variable in the help. 6792 6793 6794 if [ -z "${DATE+x}" ]; then 6795 # The variable is not set by user, try to locate tool using the code snippet 6796 for ac_prog in date 6797 do 6798 # Extract the first word of "$ac_prog", so it can be a program name with args. 6799 set dummy $ac_prog; ac_word=$2 6800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6801 $as_echo_n "checking for $ac_word... " >&6; } 6802 if ${ac_cv_path_DATE+:} false; then : 6803 $as_echo_n "(cached) " >&6 6804 else 6805 case $DATE in 6806 [\\/]* | ?:[\\/]*) 6807 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6808 ;; 6809 *) 6810 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6811 for as_dir in $PATH 6812 do 6813 IFS=$as_save_IFS 6814 test -z "$as_dir" && as_dir=. 6815 for ac_exec_ext in '' $ac_executable_extensions; do 6816 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6817 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6818 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6819 break 2 6820 fi 6821 done 6822 done 6823 IFS=$as_save_IFS 6824 6825 ;; 6826 esac 6827 fi 6828 DATE=$ac_cv_path_DATE 6829 if test -n "$DATE"; then 6830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6831 $as_echo "$DATE" >&6; } 6832 else 6833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6834 $as_echo "no" >&6; } 6835 fi 6836 6837 6838 test -n "$DATE" && break 6839 done 6840 6841 else 6842 # The variable is set, but is it from the command line or the environment? 6843 6844 # Try to remove the string !DATE! from our list. 6845 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6846 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6847 # If it failed, the variable was not from the command line. Ignore it, 6848 # but warn the user (except for BASH, which is always set by the calling BASH). 6849 if test "xDATE" != xBASH; then 6850 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6851 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6852 fi 6853 # Try to locate tool using the code snippet 6854 for ac_prog in date 6855 do 6856 # Extract the first word of "$ac_prog", so it can be a program name with args. 6857 set dummy $ac_prog; ac_word=$2 6858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6859 $as_echo_n "checking for $ac_word... " >&6; } 6860 if ${ac_cv_path_DATE+:} false; then : 6861 $as_echo_n "(cached) " >&6 6862 else 6863 case $DATE in 6864 [\\/]* | ?:[\\/]*) 6865 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6866 ;; 6867 *) 6868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6869 for as_dir in $PATH 6870 do 6871 IFS=$as_save_IFS 6872 test -z "$as_dir" && as_dir=. 6873 for ac_exec_ext in '' $ac_executable_extensions; do 6874 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6875 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6876 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6877 break 2 6878 fi 6879 done 6880 done 6881 IFS=$as_save_IFS 6882 6883 ;; 6884 esac 6885 fi 6886 DATE=$ac_cv_path_DATE 6887 if test -n "$DATE"; then 6888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6889 $as_echo "$DATE" >&6; } 6890 else 6891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6892 $as_echo "no" >&6; } 6893 fi 6894 6895 6896 test -n "$DATE" && break 6897 done 6898 6899 else 6900 # If it succeeded, then it was overridden by the user. We will use it 6901 # for the tool. 6902 6903 # First remove it from the list of overridden variables, so we can test 6904 # for unknown variables in the end. 6905 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6906 6907 # Check if we try to supply an empty value 6908 if test "x$DATE" = x; then 6909 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6910 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6912 $as_echo_n "checking for DATE... " >&6; } 6913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6914 $as_echo "disabled" >&6; } 6915 else 6916 # Check if the provided tool contains a complete path. 6917 tool_specified="$DATE" 6918 tool_basename="${tool_specified##*/}" 6919 if test "x$tool_basename" = "x$tool_specified"; then 6920 # A command without a complete path is provided, search $PATH. 6921 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 6922 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 6923 # Extract the first word of "$tool_basename", so it can be a program name with args. 6924 set dummy $tool_basename; ac_word=$2 6925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6926 $as_echo_n "checking for $ac_word... " >&6; } 6927 if ${ac_cv_path_DATE+:} false; then : 6928 $as_echo_n "(cached) " >&6 6929 else 6930 case $DATE in 6931 [\\/]* | ?:[\\/]*) 6932 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6933 ;; 6934 *) 6935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6936 for as_dir in $PATH 6937 do 6938 IFS=$as_save_IFS 6939 test -z "$as_dir" && as_dir=. 6940 for ac_exec_ext in '' $ac_executable_extensions; do 6941 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6942 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6944 break 2 6945 fi 6946 done 6947 done 6948 IFS=$as_save_IFS 6949 6950 ;; 6951 esac 6952 fi 6953 DATE=$ac_cv_path_DATE 6954 if test -n "$DATE"; then 6955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6956 $as_echo "$DATE" >&6; } 6957 else 6958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6959 $as_echo "no" >&6; } 6960 fi 6961 6962 6963 if test "x$DATE" = x; then 6964 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6965 fi 6966 else 6967 # Otherwise we believe it is a complete path. Use it as it is. 6968 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 6969 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 6970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6971 $as_echo_n "checking for DATE... " >&6; } 6972 if test ! -x "$tool_specified"; then 6973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6974 $as_echo "not found" >&6; } 6975 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 6976 fi 6977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6978 $as_echo "$tool_specified" >&6; } 6979 fi 6980 fi 6981 fi 6982 6983 fi 6984 6985 6986 6987 if test "x$DATE" = x; then 6988 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 6989 fi 6990 6991 6992 6993 6994 6995 # Publish this variable in the help. 6996 6997 6998 if [ -z "${DIFF+x}" ]; then 6999 # The variable is not set by user, try to locate tool using the code snippet 7000 for ac_prog in gdiff diff 7001 do 7002 # Extract the first word of "$ac_prog", so it can be a program name with args. 7003 set dummy $ac_prog; ac_word=$2 7004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7005 $as_echo_n "checking for $ac_word... " >&6; } 7006 if ${ac_cv_path_DIFF+:} false; then : 7007 $as_echo_n "(cached) " >&6 7008 else 7009 case $DIFF in 7010 [\\/]* | ?:[\\/]*) 7011 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7012 ;; 7013 *) 7014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7015 for as_dir in $PATH 7016 do 7017 IFS=$as_save_IFS 7018 test -z "$as_dir" && as_dir=. 7019 for ac_exec_ext in '' $ac_executable_extensions; do 7020 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7021 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7023 break 2 7024 fi 7025 done 7026 done 7027 IFS=$as_save_IFS 7028 7029 ;; 7030 esac 7031 fi 7032 DIFF=$ac_cv_path_DIFF 7033 if test -n "$DIFF"; then 7034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7035 $as_echo "$DIFF" >&6; } 7036 else 7037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7038 $as_echo "no" >&6; } 7039 fi 7040 7041 7042 test -n "$DIFF" && break 7043 done 7044 7045 else 7046 # The variable is set, but is it from the command line or the environment? 7047 7048 # Try to remove the string !DIFF! from our list. 7049 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7050 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7051 # If it failed, the variable was not from the command line. Ignore it, 7052 # but warn the user (except for BASH, which is always set by the calling BASH). 7053 if test "xDIFF" != xBASH; then 7054 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7055 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7056 fi 7057 # Try to locate tool using the code snippet 7058 for ac_prog in gdiff diff 7059 do 7060 # Extract the first word of "$ac_prog", so it can be a program name with args. 7061 set dummy $ac_prog; ac_word=$2 7062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7063 $as_echo_n "checking for $ac_word... " >&6; } 7064 if ${ac_cv_path_DIFF+:} false; then : 7065 $as_echo_n "(cached) " >&6 7066 else 7067 case $DIFF in 7068 [\\/]* | ?:[\\/]*) 7069 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7070 ;; 7071 *) 7072 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7073 for as_dir in $PATH 7074 do 7075 IFS=$as_save_IFS 7076 test -z "$as_dir" && as_dir=. 7077 for ac_exec_ext in '' $ac_executable_extensions; do 7078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7079 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7081 break 2 7082 fi 7083 done 7084 done 7085 IFS=$as_save_IFS 7086 7087 ;; 7088 esac 7089 fi 7090 DIFF=$ac_cv_path_DIFF 7091 if test -n "$DIFF"; then 7092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7093 $as_echo "$DIFF" >&6; } 7094 else 7095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7096 $as_echo "no" >&6; } 7097 fi 7098 7099 7100 test -n "$DIFF" && break 7101 done 7102 7103 else 7104 # If it succeeded, then it was overridden by the user. We will use it 7105 # for the tool. 7106 7107 # First remove it from the list of overridden variables, so we can test 7108 # for unknown variables in the end. 7109 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7110 7111 # Check if we try to supply an empty value 7112 if test "x$DIFF" = x; then 7113 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7114 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7116 $as_echo_n "checking for DIFF... " >&6; } 7117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7118 $as_echo "disabled" >&6; } 7119 else 7120 # Check if the provided tool contains a complete path. 7121 tool_specified="$DIFF" 7122 tool_basename="${tool_specified##*/}" 7123 if test "x$tool_basename" = "x$tool_specified"; then 7124 # A command without a complete path is provided, search $PATH. 7125 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7126 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7127 # Extract the first word of "$tool_basename", so it can be a program name with args. 7128 set dummy $tool_basename; ac_word=$2 7129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7130 $as_echo_n "checking for $ac_word... " >&6; } 7131 if ${ac_cv_path_DIFF+:} false; then : 7132 $as_echo_n "(cached) " >&6 7133 else 7134 case $DIFF in 7135 [\\/]* | ?:[\\/]*) 7136 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7137 ;; 7138 *) 7139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7140 for as_dir in $PATH 7141 do 7142 IFS=$as_save_IFS 7143 test -z "$as_dir" && as_dir=. 7144 for ac_exec_ext in '' $ac_executable_extensions; do 7145 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7146 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7147 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7148 break 2 7149 fi 7150 done 7151 done 7152 IFS=$as_save_IFS 7153 7154 ;; 7155 esac 7156 fi 7157 DIFF=$ac_cv_path_DIFF 7158 if test -n "$DIFF"; then 7159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7160 $as_echo "$DIFF" >&6; } 7161 else 7162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7163 $as_echo "no" >&6; } 7164 fi 7165 7166 7167 if test "x$DIFF" = x; then 7168 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7169 fi 7170 else 7171 # Otherwise we believe it is a complete path. Use it as it is. 7172 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7173 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7175 $as_echo_n "checking for DIFF... " >&6; } 7176 if test ! -x "$tool_specified"; then 7177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7178 $as_echo "not found" >&6; } 7179 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7180 fi 7181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7182 $as_echo "$tool_specified" >&6; } 7183 fi 7184 fi 7185 fi 7186 7187 fi 7188 7189 7190 7191 if test "x$DIFF" = x; then 7192 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7193 fi 7194 7195 7196 7197 7198 7199 # Publish this variable in the help. 7200 7201 7202 if [ -z "${DIRNAME+x}" ]; then 7203 # The variable is not set by user, try to locate tool using the code snippet 7204 for ac_prog in dirname 7205 do 7206 # Extract the first word of "$ac_prog", so it can be a program name with args. 7207 set dummy $ac_prog; ac_word=$2 7208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7209 $as_echo_n "checking for $ac_word... " >&6; } 7210 if ${ac_cv_path_DIRNAME+:} false; then : 7211 $as_echo_n "(cached) " >&6 7212 else 7213 case $DIRNAME in 7214 [\\/]* | ?:[\\/]*) 7215 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7216 ;; 7217 *) 7218 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7219 for as_dir in $PATH 7220 do 7221 IFS=$as_save_IFS 7222 test -z "$as_dir" && as_dir=. 7223 for ac_exec_ext in '' $ac_executable_extensions; do 7224 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7225 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7226 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7227 break 2 7228 fi 7229 done 7230 done 7231 IFS=$as_save_IFS 7232 7233 ;; 7234 esac 7235 fi 7236 DIRNAME=$ac_cv_path_DIRNAME 7237 if test -n "$DIRNAME"; then 7238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7239 $as_echo "$DIRNAME" >&6; } 7240 else 7241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7242 $as_echo "no" >&6; } 7243 fi 7244 7245 7246 test -n "$DIRNAME" && break 7247 done 7248 7249 else 7250 # The variable is set, but is it from the command line or the environment? 7251 7252 # Try to remove the string !DIRNAME! from our list. 7253 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7254 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7255 # If it failed, the variable was not from the command line. Ignore it, 7256 # but warn the user (except for BASH, which is always set by the calling BASH). 7257 if test "xDIRNAME" != xBASH; then 7258 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7259 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7260 fi 7261 # Try to locate tool using the code snippet 7262 for ac_prog in dirname 7263 do 7264 # Extract the first word of "$ac_prog", so it can be a program name with args. 7265 set dummy $ac_prog; ac_word=$2 7266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7267 $as_echo_n "checking for $ac_word... " >&6; } 7268 if ${ac_cv_path_DIRNAME+:} false; then : 7269 $as_echo_n "(cached) " >&6 7270 else 7271 case $DIRNAME in 7272 [\\/]* | ?:[\\/]*) 7273 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7274 ;; 7275 *) 7276 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7277 for as_dir in $PATH 7278 do 7279 IFS=$as_save_IFS 7280 test -z "$as_dir" && as_dir=. 7281 for ac_exec_ext in '' $ac_executable_extensions; do 7282 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7283 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7284 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7285 break 2 7286 fi 7287 done 7288 done 7289 IFS=$as_save_IFS 7290 7291 ;; 7292 esac 7293 fi 7294 DIRNAME=$ac_cv_path_DIRNAME 7295 if test -n "$DIRNAME"; then 7296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7297 $as_echo "$DIRNAME" >&6; } 7298 else 7299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7300 $as_echo "no" >&6; } 7301 fi 7302 7303 7304 test -n "$DIRNAME" && break 7305 done 7306 7307 else 7308 # If it succeeded, then it was overridden by the user. We will use it 7309 # for the tool. 7310 7311 # First remove it from the list of overridden variables, so we can test 7312 # for unknown variables in the end. 7313 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7314 7315 # Check if we try to supply an empty value 7316 if test "x$DIRNAME" = x; then 7317 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7318 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7320 $as_echo_n "checking for DIRNAME... " >&6; } 7321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7322 $as_echo "disabled" >&6; } 7323 else 7324 # Check if the provided tool contains a complete path. 7325 tool_specified="$DIRNAME" 7326 tool_basename="${tool_specified##*/}" 7327 if test "x$tool_basename" = "x$tool_specified"; then 7328 # A command without a complete path is provided, search $PATH. 7329 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7330 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7331 # Extract the first word of "$tool_basename", so it can be a program name with args. 7332 set dummy $tool_basename; ac_word=$2 7333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7334 $as_echo_n "checking for $ac_word... " >&6; } 7335 if ${ac_cv_path_DIRNAME+:} false; then : 7336 $as_echo_n "(cached) " >&6 7337 else 7338 case $DIRNAME in 7339 [\\/]* | ?:[\\/]*) 7340 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7341 ;; 7342 *) 7343 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7344 for as_dir in $PATH 7345 do 7346 IFS=$as_save_IFS 7347 test -z "$as_dir" && as_dir=. 7348 for ac_exec_ext in '' $ac_executable_extensions; do 7349 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7350 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7351 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7352 break 2 7353 fi 7354 done 7355 done 7356 IFS=$as_save_IFS 7357 7358 ;; 7359 esac 7360 fi 7361 DIRNAME=$ac_cv_path_DIRNAME 7362 if test -n "$DIRNAME"; then 7363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7364 $as_echo "$DIRNAME" >&6; } 7365 else 7366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7367 $as_echo "no" >&6; } 7368 fi 7369 7370 7371 if test "x$DIRNAME" = x; then 7372 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7373 fi 7374 else 7375 # Otherwise we believe it is a complete path. Use it as it is. 7376 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7377 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7379 $as_echo_n "checking for DIRNAME... " >&6; } 7380 if test ! -x "$tool_specified"; then 7381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7382 $as_echo "not found" >&6; } 7383 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7384 fi 7385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7386 $as_echo "$tool_specified" >&6; } 7387 fi 7388 fi 7389 fi 7390 7391 fi 7392 7393 7394 7395 if test "x$DIRNAME" = x; then 7396 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7397 fi 7398 7399 7400 7401 7402 7403 # Publish this variable in the help. 7404 7405 7406 if [ -z "${ECHO+x}" ]; then 7407 # The variable is not set by user, try to locate tool using the code snippet 7408 for ac_prog in echo 7409 do 7410 # Extract the first word of "$ac_prog", so it can be a program name with args. 7411 set dummy $ac_prog; ac_word=$2 7412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7413 $as_echo_n "checking for $ac_word... " >&6; } 7414 if ${ac_cv_path_ECHO+:} false; then : 7415 $as_echo_n "(cached) " >&6 7416 else 7417 case $ECHO in 7418 [\\/]* | ?:[\\/]*) 7419 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7420 ;; 7421 *) 7422 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7423 for as_dir in $PATH 7424 do 7425 IFS=$as_save_IFS 7426 test -z "$as_dir" && as_dir=. 7427 for ac_exec_ext in '' $ac_executable_extensions; do 7428 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7429 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7430 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7431 break 2 7432 fi 7433 done 7434 done 7435 IFS=$as_save_IFS 7436 7437 ;; 7438 esac 7439 fi 7440 ECHO=$ac_cv_path_ECHO 7441 if test -n "$ECHO"; then 7442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7443 $as_echo "$ECHO" >&6; } 7444 else 7445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7446 $as_echo "no" >&6; } 7447 fi 7448 7449 7450 test -n "$ECHO" && break 7451 done 7452 7453 else 7454 # The variable is set, but is it from the command line or the environment? 7455 7456 # Try to remove the string !ECHO! from our list. 7457 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7458 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7459 # If it failed, the variable was not from the command line. Ignore it, 7460 # but warn the user (except for BASH, which is always set by the calling BASH). 7461 if test "xECHO" != xBASH; then 7462 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7463 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7464 fi 7465 # Try to locate tool using the code snippet 7466 for ac_prog in echo 7467 do 7468 # Extract the first word of "$ac_prog", so it can be a program name with args. 7469 set dummy $ac_prog; ac_word=$2 7470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7471 $as_echo_n "checking for $ac_word... " >&6; } 7472 if ${ac_cv_path_ECHO+:} false; then : 7473 $as_echo_n "(cached) " >&6 7474 else 7475 case $ECHO in 7476 [\\/]* | ?:[\\/]*) 7477 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7478 ;; 7479 *) 7480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7481 for as_dir in $PATH 7482 do 7483 IFS=$as_save_IFS 7484 test -z "$as_dir" && as_dir=. 7485 for ac_exec_ext in '' $ac_executable_extensions; do 7486 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7487 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7488 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7489 break 2 7490 fi 7491 done 7492 done 7493 IFS=$as_save_IFS 7494 7495 ;; 7496 esac 7497 fi 7498 ECHO=$ac_cv_path_ECHO 7499 if test -n "$ECHO"; then 7500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7501 $as_echo "$ECHO" >&6; } 7502 else 7503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7504 $as_echo "no" >&6; } 7505 fi 7506 7507 7508 test -n "$ECHO" && break 7509 done 7510 7511 else 7512 # If it succeeded, then it was overridden by the user. We will use it 7513 # for the tool. 7514 7515 # First remove it from the list of overridden variables, so we can test 7516 # for unknown variables in the end. 7517 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7518 7519 # Check if we try to supply an empty value 7520 if test "x$ECHO" = x; then 7521 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7522 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7524 $as_echo_n "checking for ECHO... " >&6; } 7525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7526 $as_echo "disabled" >&6; } 7527 else 7528 # Check if the provided tool contains a complete path. 7529 tool_specified="$ECHO" 7530 tool_basename="${tool_specified##*/}" 7531 if test "x$tool_basename" = "x$tool_specified"; then 7532 # A command without a complete path is provided, search $PATH. 7533 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7534 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7535 # Extract the first word of "$tool_basename", so it can be a program name with args. 7536 set dummy $tool_basename; ac_word=$2 7537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7538 $as_echo_n "checking for $ac_word... " >&6; } 7539 if ${ac_cv_path_ECHO+:} false; then : 7540 $as_echo_n "(cached) " >&6 7541 else 7542 case $ECHO in 7543 [\\/]* | ?:[\\/]*) 7544 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7545 ;; 7546 *) 7547 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7548 for as_dir in $PATH 7549 do 7550 IFS=$as_save_IFS 7551 test -z "$as_dir" && as_dir=. 7552 for ac_exec_ext in '' $ac_executable_extensions; do 7553 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7554 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7555 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7556 break 2 7557 fi 7558 done 7559 done 7560 IFS=$as_save_IFS 7561 7562 ;; 7563 esac 7564 fi 7565 ECHO=$ac_cv_path_ECHO 7566 if test -n "$ECHO"; then 7567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7568 $as_echo "$ECHO" >&6; } 7569 else 7570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7571 $as_echo "no" >&6; } 7572 fi 7573 7574 7575 if test "x$ECHO" = x; then 7576 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7577 fi 7578 else 7579 # Otherwise we believe it is a complete path. Use it as it is. 7580 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7581 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7583 $as_echo_n "checking for ECHO... " >&6; } 7584 if test ! -x "$tool_specified"; then 7585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7586 $as_echo "not found" >&6; } 7587 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7588 fi 7589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7590 $as_echo "$tool_specified" >&6; } 7591 fi 7592 fi 7593 fi 7594 7595 fi 7596 7597 7598 7599 if test "x$ECHO" = x; then 7600 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7601 fi 7602 7603 7604 7605 7606 7607 # Publish this variable in the help. 7608 7609 7610 if [ -z "${EXPR+x}" ]; then 7611 # The variable is not set by user, try to locate tool using the code snippet 7612 for ac_prog in expr 7613 do 7614 # Extract the first word of "$ac_prog", so it can be a program name with args. 7615 set dummy $ac_prog; ac_word=$2 7616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7617 $as_echo_n "checking for $ac_word... " >&6; } 7618 if ${ac_cv_path_EXPR+:} false; then : 7619 $as_echo_n "(cached) " >&6 7620 else 7621 case $EXPR in 7622 [\\/]* | ?:[\\/]*) 7623 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7624 ;; 7625 *) 7626 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7627 for as_dir in $PATH 7628 do 7629 IFS=$as_save_IFS 7630 test -z "$as_dir" && as_dir=. 7631 for ac_exec_ext in '' $ac_executable_extensions; do 7632 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7633 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7634 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7635 break 2 7636 fi 7637 done 7638 done 7639 IFS=$as_save_IFS 7640 7641 ;; 7642 esac 7643 fi 7644 EXPR=$ac_cv_path_EXPR 7645 if test -n "$EXPR"; then 7646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7647 $as_echo "$EXPR" >&6; } 7648 else 7649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7650 $as_echo "no" >&6; } 7651 fi 7652 7653 7654 test -n "$EXPR" && break 7655 done 7656 7657 else 7658 # The variable is set, but is it from the command line or the environment? 7659 7660 # Try to remove the string !EXPR! from our list. 7661 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7662 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7663 # If it failed, the variable was not from the command line. Ignore it, 7664 # but warn the user (except for BASH, which is always set by the calling BASH). 7665 if test "xEXPR" != xBASH; then 7666 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7667 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7668 fi 7669 # Try to locate tool using the code snippet 7670 for ac_prog in expr 7671 do 7672 # Extract the first word of "$ac_prog", so it can be a program name with args. 7673 set dummy $ac_prog; ac_word=$2 7674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7675 $as_echo_n "checking for $ac_word... " >&6; } 7676 if ${ac_cv_path_EXPR+:} false; then : 7677 $as_echo_n "(cached) " >&6 7678 else 7679 case $EXPR in 7680 [\\/]* | ?:[\\/]*) 7681 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7682 ;; 7683 *) 7684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7685 for as_dir in $PATH 7686 do 7687 IFS=$as_save_IFS 7688 test -z "$as_dir" && as_dir=. 7689 for ac_exec_ext in '' $ac_executable_extensions; do 7690 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7691 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7693 break 2 7694 fi 7695 done 7696 done 7697 IFS=$as_save_IFS 7698 7699 ;; 7700 esac 7701 fi 7702 EXPR=$ac_cv_path_EXPR 7703 if test -n "$EXPR"; then 7704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7705 $as_echo "$EXPR" >&6; } 7706 else 7707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7708 $as_echo "no" >&6; } 7709 fi 7710 7711 7712 test -n "$EXPR" && break 7713 done 7714 7715 else 7716 # If it succeeded, then it was overridden by the user. We will use it 7717 # for the tool. 7718 7719 # First remove it from the list of overridden variables, so we can test 7720 # for unknown variables in the end. 7721 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7722 7723 # Check if we try to supply an empty value 7724 if test "x$EXPR" = x; then 7725 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7726 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7728 $as_echo_n "checking for EXPR... " >&6; } 7729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7730 $as_echo "disabled" >&6; } 7731 else 7732 # Check if the provided tool contains a complete path. 7733 tool_specified="$EXPR" 7734 tool_basename="${tool_specified##*/}" 7735 if test "x$tool_basename" = "x$tool_specified"; then 7736 # A command without a complete path is provided, search $PATH. 7737 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7738 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7739 # Extract the first word of "$tool_basename", so it can be a program name with args. 7740 set dummy $tool_basename; ac_word=$2 7741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7742 $as_echo_n "checking for $ac_word... " >&6; } 7743 if ${ac_cv_path_EXPR+:} false; then : 7744 $as_echo_n "(cached) " >&6 7745 else 7746 case $EXPR in 7747 [\\/]* | ?:[\\/]*) 7748 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7749 ;; 7750 *) 7751 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7752 for as_dir in $PATH 7753 do 7754 IFS=$as_save_IFS 7755 test -z "$as_dir" && as_dir=. 7756 for ac_exec_ext in '' $ac_executable_extensions; do 7757 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7758 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7759 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7760 break 2 7761 fi 7762 done 7763 done 7764 IFS=$as_save_IFS 7765 7766 ;; 7767 esac 7768 fi 7769 EXPR=$ac_cv_path_EXPR 7770 if test -n "$EXPR"; then 7771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7772 $as_echo "$EXPR" >&6; } 7773 else 7774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7775 $as_echo "no" >&6; } 7776 fi 7777 7778 7779 if test "x$EXPR" = x; then 7780 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7781 fi 7782 else 7783 # Otherwise we believe it is a complete path. Use it as it is. 7784 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7785 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7787 $as_echo_n "checking for EXPR... " >&6; } 7788 if test ! -x "$tool_specified"; then 7789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7790 $as_echo "not found" >&6; } 7791 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7792 fi 7793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7794 $as_echo "$tool_specified" >&6; } 7795 fi 7796 fi 7797 fi 7798 7799 fi 7800 7801 7802 7803 if test "x$EXPR" = x; then 7804 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7805 fi 7806 7807 7808 7809 7810 7811 # Publish this variable in the help. 7812 7813 7814 if [ -z "${FILE+x}" ]; then 7815 # The variable is not set by user, try to locate tool using the code snippet 7816 for ac_prog in file 7817 do 7818 # Extract the first word of "$ac_prog", so it can be a program name with args. 7819 set dummy $ac_prog; ac_word=$2 7820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7821 $as_echo_n "checking for $ac_word... " >&6; } 7822 if ${ac_cv_path_FILE+:} false; then : 7823 $as_echo_n "(cached) " >&6 7824 else 7825 case $FILE in 7826 [\\/]* | ?:[\\/]*) 7827 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7828 ;; 7829 *) 7830 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7831 for as_dir in $PATH 7832 do 7833 IFS=$as_save_IFS 7834 test -z "$as_dir" && as_dir=. 7835 for ac_exec_ext in '' $ac_executable_extensions; do 7836 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7837 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7838 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7839 break 2 7840 fi 7841 done 7842 done 7843 IFS=$as_save_IFS 7844 7845 ;; 7846 esac 7847 fi 7848 FILE=$ac_cv_path_FILE 7849 if test -n "$FILE"; then 7850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7851 $as_echo "$FILE" >&6; } 7852 else 7853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7854 $as_echo "no" >&6; } 7855 fi 7856 7857 7858 test -n "$FILE" && break 7859 done 7860 7861 else 7862 # The variable is set, but is it from the command line or the environment? 7863 7864 # Try to remove the string !FILE! from our list. 7865 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7866 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7867 # If it failed, the variable was not from the command line. Ignore it, 7868 # but warn the user (except for BASH, which is always set by the calling BASH). 7869 if test "xFILE" != xBASH; then 7870 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7871 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7872 fi 7873 # Try to locate tool using the code snippet 7874 for ac_prog in file 7875 do 7876 # Extract the first word of "$ac_prog", so it can be a program name with args. 7877 set dummy $ac_prog; ac_word=$2 7878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7879 $as_echo_n "checking for $ac_word... " >&6; } 7880 if ${ac_cv_path_FILE+:} false; then : 7881 $as_echo_n "(cached) " >&6 7882 else 7883 case $FILE in 7884 [\\/]* | ?:[\\/]*) 7885 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7886 ;; 7887 *) 7888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7889 for as_dir in $PATH 7890 do 7891 IFS=$as_save_IFS 7892 test -z "$as_dir" && as_dir=. 7893 for ac_exec_ext in '' $ac_executable_extensions; do 7894 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7895 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7896 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7897 break 2 7898 fi 7899 done 7900 done 7901 IFS=$as_save_IFS 7902 7903 ;; 7904 esac 7905 fi 7906 FILE=$ac_cv_path_FILE 7907 if test -n "$FILE"; then 7908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7909 $as_echo "$FILE" >&6; } 7910 else 7911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7912 $as_echo "no" >&6; } 7913 fi 7914 7915 7916 test -n "$FILE" && break 7917 done 7918 7919 else 7920 # If it succeeded, then it was overridden by the user. We will use it 7921 # for the tool. 7922 7923 # First remove it from the list of overridden variables, so we can test 7924 # for unknown variables in the end. 7925 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7926 7927 # Check if we try to supply an empty value 7928 if test "x$FILE" = x; then 7929 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 7930 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 7931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7932 $as_echo_n "checking for FILE... " >&6; } 7933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7934 $as_echo "disabled" >&6; } 7935 else 7936 # Check if the provided tool contains a complete path. 7937 tool_specified="$FILE" 7938 tool_basename="${tool_specified##*/}" 7939 if test "x$tool_basename" = "x$tool_specified"; then 7940 # A command without a complete path is provided, search $PATH. 7941 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 7942 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 7943 # Extract the first word of "$tool_basename", so it can be a program name with args. 7944 set dummy $tool_basename; ac_word=$2 7945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7946 $as_echo_n "checking for $ac_word... " >&6; } 7947 if ${ac_cv_path_FILE+:} false; then : 7948 $as_echo_n "(cached) " >&6 7949 else 7950 case $FILE in 7951 [\\/]* | ?:[\\/]*) 7952 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7953 ;; 7954 *) 7955 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7956 for as_dir in $PATH 7957 do 7958 IFS=$as_save_IFS 7959 test -z "$as_dir" && as_dir=. 7960 for ac_exec_ext in '' $ac_executable_extensions; do 7961 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7962 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7963 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7964 break 2 7965 fi 7966 done 7967 done 7968 IFS=$as_save_IFS 7969 7970 ;; 7971 esac 7972 fi 7973 FILE=$ac_cv_path_FILE 7974 if test -n "$FILE"; then 7975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7976 $as_echo "$FILE" >&6; } 7977 else 7978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7979 $as_echo "no" >&6; } 7980 fi 7981 7982 7983 if test "x$FILE" = x; then 7984 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7985 fi 7986 else 7987 # Otherwise we believe it is a complete path. Use it as it is. 7988 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 7989 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 7990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7991 $as_echo_n "checking for FILE... " >&6; } 7992 if test ! -x "$tool_specified"; then 7993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7994 $as_echo "not found" >&6; } 7995 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 7996 fi 7997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7998 $as_echo "$tool_specified" >&6; } 7999 fi 8000 fi 8001 fi 8002 8003 fi 8004 8005 8006 8007 if test "x$FILE" = x; then 8008 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8009 fi 8010 8011 8012 8013 8014 8015 # Publish this variable in the help. 8016 8017 8018 if [ -z "${FIND+x}" ]; then 8019 # The variable is not set by user, try to locate tool using the code snippet 8020 for ac_prog in find 8021 do 8022 # Extract the first word of "$ac_prog", so it can be a program name with args. 8023 set dummy $ac_prog; ac_word=$2 8024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8025 $as_echo_n "checking for $ac_word... " >&6; } 8026 if ${ac_cv_path_FIND+:} false; then : 8027 $as_echo_n "(cached) " >&6 8028 else 8029 case $FIND in 8030 [\\/]* | ?:[\\/]*) 8031 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8032 ;; 8033 *) 8034 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8035 for as_dir in $PATH 8036 do 8037 IFS=$as_save_IFS 8038 test -z "$as_dir" && as_dir=. 8039 for ac_exec_ext in '' $ac_executable_extensions; do 8040 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8041 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8042 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8043 break 2 8044 fi 8045 done 8046 done 8047 IFS=$as_save_IFS 8048 8049 ;; 8050 esac 8051 fi 8052 FIND=$ac_cv_path_FIND 8053 if test -n "$FIND"; then 8054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8055 $as_echo "$FIND" >&6; } 8056 else 8057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8058 $as_echo "no" >&6; } 8059 fi 8060 8061 8062 test -n "$FIND" && break 8063 done 8064 8065 else 8066 # The variable is set, but is it from the command line or the environment? 8067 8068 # Try to remove the string !FIND! from our list. 8069 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8070 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8071 # If it failed, the variable was not from the command line. Ignore it, 8072 # but warn the user (except for BASH, which is always set by the calling BASH). 8073 if test "xFIND" != xBASH; then 8074 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8075 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8076 fi 8077 # Try to locate tool using the code snippet 8078 for ac_prog in find 8079 do 8080 # Extract the first word of "$ac_prog", so it can be a program name with args. 8081 set dummy $ac_prog; ac_word=$2 8082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8083 $as_echo_n "checking for $ac_word... " >&6; } 8084 if ${ac_cv_path_FIND+:} false; then : 8085 $as_echo_n "(cached) " >&6 8086 else 8087 case $FIND in 8088 [\\/]* | ?:[\\/]*) 8089 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8090 ;; 8091 *) 8092 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8093 for as_dir in $PATH 8094 do 8095 IFS=$as_save_IFS 8096 test -z "$as_dir" && as_dir=. 8097 for ac_exec_ext in '' $ac_executable_extensions; do 8098 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8099 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8100 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8101 break 2 8102 fi 8103 done 8104 done 8105 IFS=$as_save_IFS 8106 8107 ;; 8108 esac 8109 fi 8110 FIND=$ac_cv_path_FIND 8111 if test -n "$FIND"; then 8112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8113 $as_echo "$FIND" >&6; } 8114 else 8115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8116 $as_echo "no" >&6; } 8117 fi 8118 8119 8120 test -n "$FIND" && break 8121 done 8122 8123 else 8124 # If it succeeded, then it was overridden by the user. We will use it 8125 # for the tool. 8126 8127 # First remove it from the list of overridden variables, so we can test 8128 # for unknown variables in the end. 8129 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8130 8131 # Check if we try to supply an empty value 8132 if test "x$FIND" = x; then 8133 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8134 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8136 $as_echo_n "checking for FIND... " >&6; } 8137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8138 $as_echo "disabled" >&6; } 8139 else 8140 # Check if the provided tool contains a complete path. 8141 tool_specified="$FIND" 8142 tool_basename="${tool_specified##*/}" 8143 if test "x$tool_basename" = "x$tool_specified"; then 8144 # A command without a complete path is provided, search $PATH. 8145 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8146 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8147 # Extract the first word of "$tool_basename", so it can be a program name with args. 8148 set dummy $tool_basename; ac_word=$2 8149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8150 $as_echo_n "checking for $ac_word... " >&6; } 8151 if ${ac_cv_path_FIND+:} false; then : 8152 $as_echo_n "(cached) " >&6 8153 else 8154 case $FIND in 8155 [\\/]* | ?:[\\/]*) 8156 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8157 ;; 8158 *) 8159 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8160 for as_dir in $PATH 8161 do 8162 IFS=$as_save_IFS 8163 test -z "$as_dir" && as_dir=. 8164 for ac_exec_ext in '' $ac_executable_extensions; do 8165 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8166 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8167 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8168 break 2 8169 fi 8170 done 8171 done 8172 IFS=$as_save_IFS 8173 8174 ;; 8175 esac 8176 fi 8177 FIND=$ac_cv_path_FIND 8178 if test -n "$FIND"; then 8179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8180 $as_echo "$FIND" >&6; } 8181 else 8182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8183 $as_echo "no" >&6; } 8184 fi 8185 8186 8187 if test "x$FIND" = x; then 8188 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8189 fi 8190 else 8191 # Otherwise we believe it is a complete path. Use it as it is. 8192 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8193 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8195 $as_echo_n "checking for FIND... " >&6; } 8196 if test ! -x "$tool_specified"; then 8197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8198 $as_echo "not found" >&6; } 8199 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8200 fi 8201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8202 $as_echo "$tool_specified" >&6; } 8203 fi 8204 fi 8205 fi 8206 8207 fi 8208 8209 8210 8211 if test "x$FIND" = x; then 8212 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8213 fi 8214 8215 8216 8217 8218 8219 # Publish this variable in the help. 8220 8221 8222 if [ -z "${HEAD+x}" ]; then 8223 # The variable is not set by user, try to locate tool using the code snippet 8224 for ac_prog in head 8225 do 8226 # Extract the first word of "$ac_prog", so it can be a program name with args. 8227 set dummy $ac_prog; ac_word=$2 8228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8229 $as_echo_n "checking for $ac_word... " >&6; } 8230 if ${ac_cv_path_HEAD+:} false; then : 8231 $as_echo_n "(cached) " >&6 8232 else 8233 case $HEAD in 8234 [\\/]* | ?:[\\/]*) 8235 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8236 ;; 8237 *) 8238 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8239 for as_dir in $PATH 8240 do 8241 IFS=$as_save_IFS 8242 test -z "$as_dir" && as_dir=. 8243 for ac_exec_ext in '' $ac_executable_extensions; do 8244 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8245 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8246 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8247 break 2 8248 fi 8249 done 8250 done 8251 IFS=$as_save_IFS 8252 8253 ;; 8254 esac 8255 fi 8256 HEAD=$ac_cv_path_HEAD 8257 if test -n "$HEAD"; then 8258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8259 $as_echo "$HEAD" >&6; } 8260 else 8261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8262 $as_echo "no" >&6; } 8263 fi 8264 8265 8266 test -n "$HEAD" && break 8267 done 8268 8269 else 8270 # The variable is set, but is it from the command line or the environment? 8271 8272 # Try to remove the string !HEAD! from our list. 8273 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8274 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8275 # If it failed, the variable was not from the command line. Ignore it, 8276 # but warn the user (except for BASH, which is always set by the calling BASH). 8277 if test "xHEAD" != xBASH; then 8278 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8279 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8280 fi 8281 # Try to locate tool using the code snippet 8282 for ac_prog in head 8283 do 8284 # Extract the first word of "$ac_prog", so it can be a program name with args. 8285 set dummy $ac_prog; ac_word=$2 8286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8287 $as_echo_n "checking for $ac_word... " >&6; } 8288 if ${ac_cv_path_HEAD+:} false; then : 8289 $as_echo_n "(cached) " >&6 8290 else 8291 case $HEAD in 8292 [\\/]* | ?:[\\/]*) 8293 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8294 ;; 8295 *) 8296 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8297 for as_dir in $PATH 8298 do 8299 IFS=$as_save_IFS 8300 test -z "$as_dir" && as_dir=. 8301 for ac_exec_ext in '' $ac_executable_extensions; do 8302 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8303 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8304 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8305 break 2 8306 fi 8307 done 8308 done 8309 IFS=$as_save_IFS 8310 8311 ;; 8312 esac 8313 fi 8314 HEAD=$ac_cv_path_HEAD 8315 if test -n "$HEAD"; then 8316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8317 $as_echo "$HEAD" >&6; } 8318 else 8319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8320 $as_echo "no" >&6; } 8321 fi 8322 8323 8324 test -n "$HEAD" && break 8325 done 8326 8327 else 8328 # If it succeeded, then it was overridden by the user. We will use it 8329 # for the tool. 8330 8331 # First remove it from the list of overridden variables, so we can test 8332 # for unknown variables in the end. 8333 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8334 8335 # Check if we try to supply an empty value 8336 if test "x$HEAD" = x; then 8337 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8338 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8340 $as_echo_n "checking for HEAD... " >&6; } 8341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8342 $as_echo "disabled" >&6; } 8343 else 8344 # Check if the provided tool contains a complete path. 8345 tool_specified="$HEAD" 8346 tool_basename="${tool_specified##*/}" 8347 if test "x$tool_basename" = "x$tool_specified"; then 8348 # A command without a complete path is provided, search $PATH. 8349 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8350 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8351 # Extract the first word of "$tool_basename", so it can be a program name with args. 8352 set dummy $tool_basename; ac_word=$2 8353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8354 $as_echo_n "checking for $ac_word... " >&6; } 8355 if ${ac_cv_path_HEAD+:} false; then : 8356 $as_echo_n "(cached) " >&6 8357 else 8358 case $HEAD in 8359 [\\/]* | ?:[\\/]*) 8360 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8361 ;; 8362 *) 8363 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8364 for as_dir in $PATH 8365 do 8366 IFS=$as_save_IFS 8367 test -z "$as_dir" && as_dir=. 8368 for ac_exec_ext in '' $ac_executable_extensions; do 8369 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8370 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8371 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8372 break 2 8373 fi 8374 done 8375 done 8376 IFS=$as_save_IFS 8377 8378 ;; 8379 esac 8380 fi 8381 HEAD=$ac_cv_path_HEAD 8382 if test -n "$HEAD"; then 8383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8384 $as_echo "$HEAD" >&6; } 8385 else 8386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8387 $as_echo "no" >&6; } 8388 fi 8389 8390 8391 if test "x$HEAD" = x; then 8392 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8393 fi 8394 else 8395 # Otherwise we believe it is a complete path. Use it as it is. 8396 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8397 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8399 $as_echo_n "checking for HEAD... " >&6; } 8400 if test ! -x "$tool_specified"; then 8401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8402 $as_echo "not found" >&6; } 8403 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8404 fi 8405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8406 $as_echo "$tool_specified" >&6; } 8407 fi 8408 fi 8409 fi 8410 8411 fi 8412 8413 8414 8415 if test "x$HEAD" = x; then 8416 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8417 fi 8418 8419 8420 8421 8422 8423 # Publish this variable in the help. 8424 8425 8426 if [ -z "${GUNZIP+x}" ]; then 8427 # The variable is not set by user, try to locate tool using the code snippet 8428 for ac_prog in gunzip 8429 do 8430 # Extract the first word of "$ac_prog", so it can be a program name with args. 8431 set dummy $ac_prog; ac_word=$2 8432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8433 $as_echo_n "checking for $ac_word... " >&6; } 8434 if ${ac_cv_path_GUNZIP+:} false; then : 8435 $as_echo_n "(cached) " >&6 8436 else 8437 case $GUNZIP in 8438 [\\/]* | ?:[\\/]*) 8439 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8440 ;; 8441 *) 8442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8443 for as_dir in $PATH 8444 do 8445 IFS=$as_save_IFS 8446 test -z "$as_dir" && as_dir=. 8447 for ac_exec_ext in '' $ac_executable_extensions; do 8448 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8449 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8450 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8451 break 2 8452 fi 8453 done 8454 done 8455 IFS=$as_save_IFS 8456 8457 ;; 8458 esac 8459 fi 8460 GUNZIP=$ac_cv_path_GUNZIP 8461 if test -n "$GUNZIP"; then 8462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8463 $as_echo "$GUNZIP" >&6; } 8464 else 8465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8466 $as_echo "no" >&6; } 8467 fi 8468 8469 8470 test -n "$GUNZIP" && break 8471 done 8472 8473 else 8474 # The variable is set, but is it from the command line or the environment? 8475 8476 # Try to remove the string !GUNZIP! from our list. 8477 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8478 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8479 # If it failed, the variable was not from the command line. Ignore it, 8480 # but warn the user (except for BASH, which is always set by the calling BASH). 8481 if test "xGUNZIP" != xBASH; then 8482 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8483 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8484 fi 8485 # Try to locate tool using the code snippet 8486 for ac_prog in gunzip 8487 do 8488 # Extract the first word of "$ac_prog", so it can be a program name with args. 8489 set dummy $ac_prog; ac_word=$2 8490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8491 $as_echo_n "checking for $ac_word... " >&6; } 8492 if ${ac_cv_path_GUNZIP+:} false; then : 8493 $as_echo_n "(cached) " >&6 8494 else 8495 case $GUNZIP in 8496 [\\/]* | ?:[\\/]*) 8497 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8498 ;; 8499 *) 8500 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8501 for as_dir in $PATH 8502 do 8503 IFS=$as_save_IFS 8504 test -z "$as_dir" && as_dir=. 8505 for ac_exec_ext in '' $ac_executable_extensions; do 8506 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8507 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8508 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8509 break 2 8510 fi 8511 done 8512 done 8513 IFS=$as_save_IFS 8514 8515 ;; 8516 esac 8517 fi 8518 GUNZIP=$ac_cv_path_GUNZIP 8519 if test -n "$GUNZIP"; then 8520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8521 $as_echo "$GUNZIP" >&6; } 8522 else 8523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8524 $as_echo "no" >&6; } 8525 fi 8526 8527 8528 test -n "$GUNZIP" && break 8529 done 8530 8531 else 8532 # If it succeeded, then it was overridden by the user. We will use it 8533 # for the tool. 8534 8535 # First remove it from the list of overridden variables, so we can test 8536 # for unknown variables in the end. 8537 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8538 8539 # Check if we try to supply an empty value 8540 if test "x$GUNZIP" = x; then 8541 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8542 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8544 $as_echo_n "checking for GUNZIP... " >&6; } 8545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8546 $as_echo "disabled" >&6; } 8547 else 8548 # Check if the provided tool contains a complete path. 8549 tool_specified="$GUNZIP" 8550 tool_basename="${tool_specified##*/}" 8551 if test "x$tool_basename" = "x$tool_specified"; then 8552 # A command without a complete path is provided, search $PATH. 8553 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8554 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8555 # Extract the first word of "$tool_basename", so it can be a program name with args. 8556 set dummy $tool_basename; ac_word=$2 8557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8558 $as_echo_n "checking for $ac_word... " >&6; } 8559 if ${ac_cv_path_GUNZIP+:} false; then : 8560 $as_echo_n "(cached) " >&6 8561 else 8562 case $GUNZIP in 8563 [\\/]* | ?:[\\/]*) 8564 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8565 ;; 8566 *) 8567 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8568 for as_dir in $PATH 8569 do 8570 IFS=$as_save_IFS 8571 test -z "$as_dir" && as_dir=. 8572 for ac_exec_ext in '' $ac_executable_extensions; do 8573 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8574 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8575 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8576 break 2 8577 fi 8578 done 8579 done 8580 IFS=$as_save_IFS 8581 8582 ;; 8583 esac 8584 fi 8585 GUNZIP=$ac_cv_path_GUNZIP 8586 if test -n "$GUNZIP"; then 8587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8588 $as_echo "$GUNZIP" >&6; } 8589 else 8590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8591 $as_echo "no" >&6; } 8592 fi 8593 8594 8595 if test "x$GUNZIP" = x; then 8596 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8597 fi 8598 else 8599 # Otherwise we believe it is a complete path. Use it as it is. 8600 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8601 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8603 $as_echo_n "checking for GUNZIP... " >&6; } 8604 if test ! -x "$tool_specified"; then 8605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8606 $as_echo "not found" >&6; } 8607 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8608 fi 8609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8610 $as_echo "$tool_specified" >&6; } 8611 fi 8612 fi 8613 fi 8614 8615 fi 8616 8617 8618 8619 if test "x$GUNZIP" = x; then 8620 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8621 fi 8622 8623 8624 8625 8626 8627 # Publish this variable in the help. 8628 8629 8630 if [ -z "${GZIP+x}" ]; then 8631 # The variable is not set by user, try to locate tool using the code snippet 8632 for ac_prog in pigz gzip 8633 do 8634 # Extract the first word of "$ac_prog", so it can be a program name with args. 8635 set dummy $ac_prog; ac_word=$2 8636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8637 $as_echo_n "checking for $ac_word... " >&6; } 8638 if ${ac_cv_path_GZIP+:} false; then : 8639 $as_echo_n "(cached) " >&6 8640 else 8641 case $GZIP in 8642 [\\/]* | ?:[\\/]*) 8643 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8644 ;; 8645 *) 8646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8647 for as_dir in $PATH 8648 do 8649 IFS=$as_save_IFS 8650 test -z "$as_dir" && as_dir=. 8651 for ac_exec_ext in '' $ac_executable_extensions; do 8652 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8653 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8654 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8655 break 2 8656 fi 8657 done 8658 done 8659 IFS=$as_save_IFS 8660 8661 ;; 8662 esac 8663 fi 8664 GZIP=$ac_cv_path_GZIP 8665 if test -n "$GZIP"; then 8666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8667 $as_echo "$GZIP" >&6; } 8668 else 8669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8670 $as_echo "no" >&6; } 8671 fi 8672 8673 8674 test -n "$GZIP" && break 8675 done 8676 8677 else 8678 # The variable is set, but is it from the command line or the environment? 8679 8680 # Try to remove the string !GZIP! from our list. 8681 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8682 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8683 # If it failed, the variable was not from the command line. Ignore it, 8684 # but warn the user (except for BASH, which is always set by the calling BASH). 8685 if test "xGZIP" != xBASH; then 8686 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8687 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8688 fi 8689 # Try to locate tool using the code snippet 8690 for ac_prog in pigz gzip 8691 do 8692 # Extract the first word of "$ac_prog", so it can be a program name with args. 8693 set dummy $ac_prog; ac_word=$2 8694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8695 $as_echo_n "checking for $ac_word... " >&6; } 8696 if ${ac_cv_path_GZIP+:} false; then : 8697 $as_echo_n "(cached) " >&6 8698 else 8699 case $GZIP in 8700 [\\/]* | ?:[\\/]*) 8701 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8702 ;; 8703 *) 8704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8705 for as_dir in $PATH 8706 do 8707 IFS=$as_save_IFS 8708 test -z "$as_dir" && as_dir=. 8709 for ac_exec_ext in '' $ac_executable_extensions; do 8710 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8711 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8713 break 2 8714 fi 8715 done 8716 done 8717 IFS=$as_save_IFS 8718 8719 ;; 8720 esac 8721 fi 8722 GZIP=$ac_cv_path_GZIP 8723 if test -n "$GZIP"; then 8724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8725 $as_echo "$GZIP" >&6; } 8726 else 8727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8728 $as_echo "no" >&6; } 8729 fi 8730 8731 8732 test -n "$GZIP" && break 8733 done 8734 8735 else 8736 # If it succeeded, then it was overridden by the user. We will use it 8737 # for the tool. 8738 8739 # First remove it from the list of overridden variables, so we can test 8740 # for unknown variables in the end. 8741 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8742 8743 # Check if we try to supply an empty value 8744 if test "x$GZIP" = x; then 8745 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8746 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8748 $as_echo_n "checking for GZIP... " >&6; } 8749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8750 $as_echo "disabled" >&6; } 8751 else 8752 # Check if the provided tool contains a complete path. 8753 tool_specified="$GZIP" 8754 tool_basename="${tool_specified##*/}" 8755 if test "x$tool_basename" = "x$tool_specified"; then 8756 # A command without a complete path is provided, search $PATH. 8757 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8758 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8759 # Extract the first word of "$tool_basename", so it can be a program name with args. 8760 set dummy $tool_basename; ac_word=$2 8761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8762 $as_echo_n "checking for $ac_word... " >&6; } 8763 if ${ac_cv_path_GZIP+:} false; then : 8764 $as_echo_n "(cached) " >&6 8765 else 8766 case $GZIP in 8767 [\\/]* | ?:[\\/]*) 8768 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8769 ;; 8770 *) 8771 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8772 for as_dir in $PATH 8773 do 8774 IFS=$as_save_IFS 8775 test -z "$as_dir" && as_dir=. 8776 for ac_exec_ext in '' $ac_executable_extensions; do 8777 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8778 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8779 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8780 break 2 8781 fi 8782 done 8783 done 8784 IFS=$as_save_IFS 8785 8786 ;; 8787 esac 8788 fi 8789 GZIP=$ac_cv_path_GZIP 8790 if test -n "$GZIP"; then 8791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8792 $as_echo "$GZIP" >&6; } 8793 else 8794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8795 $as_echo "no" >&6; } 8796 fi 8797 8798 8799 if test "x$GZIP" = x; then 8800 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8801 fi 8802 else 8803 # Otherwise we believe it is a complete path. Use it as it is. 8804 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8805 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8807 $as_echo_n "checking for GZIP... " >&6; } 8808 if test ! -x "$tool_specified"; then 8809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8810 $as_echo "not found" >&6; } 8811 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8812 fi 8813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8814 $as_echo "$tool_specified" >&6; } 8815 fi 8816 fi 8817 fi 8818 8819 fi 8820 8821 8822 8823 if test "x$GZIP" = x; then 8824 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8825 fi 8826 8827 8828 8829 8830 8831 # Publish this variable in the help. 8832 8833 8834 if [ -z "${LN+x}" ]; then 8835 # The variable is not set by user, try to locate tool using the code snippet 8836 for ac_prog in ln 8837 do 8838 # Extract the first word of "$ac_prog", so it can be a program name with args. 8839 set dummy $ac_prog; ac_word=$2 8840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8841 $as_echo_n "checking for $ac_word... " >&6; } 8842 if ${ac_cv_path_LN+:} false; then : 8843 $as_echo_n "(cached) " >&6 8844 else 8845 case $LN in 8846 [\\/]* | ?:[\\/]*) 8847 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8848 ;; 8849 *) 8850 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8851 for as_dir in $PATH 8852 do 8853 IFS=$as_save_IFS 8854 test -z "$as_dir" && as_dir=. 8855 for ac_exec_ext in '' $ac_executable_extensions; do 8856 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8857 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8858 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8859 break 2 8860 fi 8861 done 8862 done 8863 IFS=$as_save_IFS 8864 8865 ;; 8866 esac 8867 fi 8868 LN=$ac_cv_path_LN 8869 if test -n "$LN"; then 8870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8871 $as_echo "$LN" >&6; } 8872 else 8873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8874 $as_echo "no" >&6; } 8875 fi 8876 8877 8878 test -n "$LN" && break 8879 done 8880 8881 else 8882 # The variable is set, but is it from the command line or the environment? 8883 8884 # Try to remove the string !LN! from our list. 8885 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8886 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8887 # If it failed, the variable was not from the command line. Ignore it, 8888 # but warn the user (except for BASH, which is always set by the calling BASH). 8889 if test "xLN" != xBASH; then 8890 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8891 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8892 fi 8893 # Try to locate tool using the code snippet 8894 for ac_prog in ln 8895 do 8896 # Extract the first word of "$ac_prog", so it can be a program name with args. 8897 set dummy $ac_prog; ac_word=$2 8898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8899 $as_echo_n "checking for $ac_word... " >&6; } 8900 if ${ac_cv_path_LN+:} false; then : 8901 $as_echo_n "(cached) " >&6 8902 else 8903 case $LN in 8904 [\\/]* | ?:[\\/]*) 8905 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8906 ;; 8907 *) 8908 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8909 for as_dir in $PATH 8910 do 8911 IFS=$as_save_IFS 8912 test -z "$as_dir" && as_dir=. 8913 for ac_exec_ext in '' $ac_executable_extensions; do 8914 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8915 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8916 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8917 break 2 8918 fi 8919 done 8920 done 8921 IFS=$as_save_IFS 8922 8923 ;; 8924 esac 8925 fi 8926 LN=$ac_cv_path_LN 8927 if test -n "$LN"; then 8928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8929 $as_echo "$LN" >&6; } 8930 else 8931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8932 $as_echo "no" >&6; } 8933 fi 8934 8935 8936 test -n "$LN" && break 8937 done 8938 8939 else 8940 # If it succeeded, then it was overridden by the user. We will use it 8941 # for the tool. 8942 8943 # First remove it from the list of overridden variables, so we can test 8944 # for unknown variables in the end. 8945 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8946 8947 # Check if we try to supply an empty value 8948 if test "x$LN" = x; then 8949 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 8950 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 8951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8952 $as_echo_n "checking for LN... " >&6; } 8953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8954 $as_echo "disabled" >&6; } 8955 else 8956 # Check if the provided tool contains a complete path. 8957 tool_specified="$LN" 8958 tool_basename="${tool_specified##*/}" 8959 if test "x$tool_basename" = "x$tool_specified"; then 8960 # A command without a complete path is provided, search $PATH. 8961 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 8962 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 8963 # Extract the first word of "$tool_basename", so it can be a program name with args. 8964 set dummy $tool_basename; ac_word=$2 8965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8966 $as_echo_n "checking for $ac_word... " >&6; } 8967 if ${ac_cv_path_LN+:} false; then : 8968 $as_echo_n "(cached) " >&6 8969 else 8970 case $LN in 8971 [\\/]* | ?:[\\/]*) 8972 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8973 ;; 8974 *) 8975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8976 for as_dir in $PATH 8977 do 8978 IFS=$as_save_IFS 8979 test -z "$as_dir" && as_dir=. 8980 for ac_exec_ext in '' $ac_executable_extensions; do 8981 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8982 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8983 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8984 break 2 8985 fi 8986 done 8987 done 8988 IFS=$as_save_IFS 8989 8990 ;; 8991 esac 8992 fi 8993 LN=$ac_cv_path_LN 8994 if test -n "$LN"; then 8995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8996 $as_echo "$LN" >&6; } 8997 else 8998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8999 $as_echo "no" >&6; } 9000 fi 9001 9002 9003 if test "x$LN" = x; then 9004 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9005 fi 9006 else 9007 # Otherwise we believe it is a complete path. Use it as it is. 9008 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9009 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9011 $as_echo_n "checking for LN... " >&6; } 9012 if test ! -x "$tool_specified"; then 9013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9014 $as_echo "not found" >&6; } 9015 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9016 fi 9017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9018 $as_echo "$tool_specified" >&6; } 9019 fi 9020 fi 9021 fi 9022 9023 fi 9024 9025 9026 9027 if test "x$LN" = x; then 9028 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9029 fi 9030 9031 9032 9033 9034 9035 # Publish this variable in the help. 9036 9037 9038 if [ -z "${LS+x}" ]; then 9039 # The variable is not set by user, try to locate tool using the code snippet 9040 for ac_prog in ls 9041 do 9042 # Extract the first word of "$ac_prog", so it can be a program name with args. 9043 set dummy $ac_prog; ac_word=$2 9044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9045 $as_echo_n "checking for $ac_word... " >&6; } 9046 if ${ac_cv_path_LS+:} false; then : 9047 $as_echo_n "(cached) " >&6 9048 else 9049 case $LS in 9050 [\\/]* | ?:[\\/]*) 9051 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9052 ;; 9053 *) 9054 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9055 for as_dir in $PATH 9056 do 9057 IFS=$as_save_IFS 9058 test -z "$as_dir" && as_dir=. 9059 for ac_exec_ext in '' $ac_executable_extensions; do 9060 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9061 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9062 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9063 break 2 9064 fi 9065 done 9066 done 9067 IFS=$as_save_IFS 9068 9069 ;; 9070 esac 9071 fi 9072 LS=$ac_cv_path_LS 9073 if test -n "$LS"; then 9074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9075 $as_echo "$LS" >&6; } 9076 else 9077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9078 $as_echo "no" >&6; } 9079 fi 9080 9081 9082 test -n "$LS" && break 9083 done 9084 9085 else 9086 # The variable is set, but is it from the command line or the environment? 9087 9088 # Try to remove the string !LS! from our list. 9089 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9090 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9091 # If it failed, the variable was not from the command line. Ignore it, 9092 # but warn the user (except for BASH, which is always set by the calling BASH). 9093 if test "xLS" != xBASH; then 9094 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9095 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9096 fi 9097 # Try to locate tool using the code snippet 9098 for ac_prog in ls 9099 do 9100 # Extract the first word of "$ac_prog", so it can be a program name with args. 9101 set dummy $ac_prog; ac_word=$2 9102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9103 $as_echo_n "checking for $ac_word... " >&6; } 9104 if ${ac_cv_path_LS+:} false; then : 9105 $as_echo_n "(cached) " >&6 9106 else 9107 case $LS in 9108 [\\/]* | ?:[\\/]*) 9109 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9110 ;; 9111 *) 9112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9113 for as_dir in $PATH 9114 do 9115 IFS=$as_save_IFS 9116 test -z "$as_dir" && as_dir=. 9117 for ac_exec_ext in '' $ac_executable_extensions; do 9118 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9119 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9121 break 2 9122 fi 9123 done 9124 done 9125 IFS=$as_save_IFS 9126 9127 ;; 9128 esac 9129 fi 9130 LS=$ac_cv_path_LS 9131 if test -n "$LS"; then 9132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9133 $as_echo "$LS" >&6; } 9134 else 9135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9136 $as_echo "no" >&6; } 9137 fi 9138 9139 9140 test -n "$LS" && break 9141 done 9142 9143 else 9144 # If it succeeded, then it was overridden by the user. We will use it 9145 # for the tool. 9146 9147 # First remove it from the list of overridden variables, so we can test 9148 # for unknown variables in the end. 9149 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9150 9151 # Check if we try to supply an empty value 9152 if test "x$LS" = x; then 9153 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9154 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9156 $as_echo_n "checking for LS... " >&6; } 9157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9158 $as_echo "disabled" >&6; } 9159 else 9160 # Check if the provided tool contains a complete path. 9161 tool_specified="$LS" 9162 tool_basename="${tool_specified##*/}" 9163 if test "x$tool_basename" = "x$tool_specified"; then 9164 # A command without a complete path is provided, search $PATH. 9165 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9166 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9167 # Extract the first word of "$tool_basename", so it can be a program name with args. 9168 set dummy $tool_basename; ac_word=$2 9169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9170 $as_echo_n "checking for $ac_word... " >&6; } 9171 if ${ac_cv_path_LS+:} false; then : 9172 $as_echo_n "(cached) " >&6 9173 else 9174 case $LS in 9175 [\\/]* | ?:[\\/]*) 9176 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9177 ;; 9178 *) 9179 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9180 for as_dir in $PATH 9181 do 9182 IFS=$as_save_IFS 9183 test -z "$as_dir" && as_dir=. 9184 for ac_exec_ext in '' $ac_executable_extensions; do 9185 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9186 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9187 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9188 break 2 9189 fi 9190 done 9191 done 9192 IFS=$as_save_IFS 9193 9194 ;; 9195 esac 9196 fi 9197 LS=$ac_cv_path_LS 9198 if test -n "$LS"; then 9199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9200 $as_echo "$LS" >&6; } 9201 else 9202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9203 $as_echo "no" >&6; } 9204 fi 9205 9206 9207 if test "x$LS" = x; then 9208 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9209 fi 9210 else 9211 # Otherwise we believe it is a complete path. Use it as it is. 9212 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9213 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9215 $as_echo_n "checking for LS... " >&6; } 9216 if test ! -x "$tool_specified"; then 9217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9218 $as_echo "not found" >&6; } 9219 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9220 fi 9221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9222 $as_echo "$tool_specified" >&6; } 9223 fi 9224 fi 9225 fi 9226 9227 fi 9228 9229 9230 9231 if test "x$LS" = x; then 9232 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9233 fi 9234 9235 9236 9237 9238 9239 # Publish this variable in the help. 9240 9241 9242 if [ -z "${MKDIR+x}" ]; then 9243 # The variable is not set by user, try to locate tool using the code snippet 9244 for ac_prog in mkdir 9245 do 9246 # Extract the first word of "$ac_prog", so it can be a program name with args. 9247 set dummy $ac_prog; ac_word=$2 9248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9249 $as_echo_n "checking for $ac_word... " >&6; } 9250 if ${ac_cv_path_MKDIR+:} false; then : 9251 $as_echo_n "(cached) " >&6 9252 else 9253 case $MKDIR in 9254 [\\/]* | ?:[\\/]*) 9255 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9256 ;; 9257 *) 9258 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9259 for as_dir in $PATH 9260 do 9261 IFS=$as_save_IFS 9262 test -z "$as_dir" && as_dir=. 9263 for ac_exec_ext in '' $ac_executable_extensions; do 9264 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9265 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9266 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9267 break 2 9268 fi 9269 done 9270 done 9271 IFS=$as_save_IFS 9272 9273 ;; 9274 esac 9275 fi 9276 MKDIR=$ac_cv_path_MKDIR 9277 if test -n "$MKDIR"; then 9278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9279 $as_echo "$MKDIR" >&6; } 9280 else 9281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9282 $as_echo "no" >&6; } 9283 fi 9284 9285 9286 test -n "$MKDIR" && break 9287 done 9288 9289 else 9290 # The variable is set, but is it from the command line or the environment? 9291 9292 # Try to remove the string !MKDIR! from our list. 9293 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9294 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9295 # If it failed, the variable was not from the command line. Ignore it, 9296 # but warn the user (except for BASH, which is always set by the calling BASH). 9297 if test "xMKDIR" != xBASH; then 9298 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9299 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9300 fi 9301 # Try to locate tool using the code snippet 9302 for ac_prog in mkdir 9303 do 9304 # Extract the first word of "$ac_prog", so it can be a program name with args. 9305 set dummy $ac_prog; ac_word=$2 9306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9307 $as_echo_n "checking for $ac_word... " >&6; } 9308 if ${ac_cv_path_MKDIR+:} false; then : 9309 $as_echo_n "(cached) " >&6 9310 else 9311 case $MKDIR in 9312 [\\/]* | ?:[\\/]*) 9313 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9314 ;; 9315 *) 9316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9317 for as_dir in $PATH 9318 do 9319 IFS=$as_save_IFS 9320 test -z "$as_dir" && as_dir=. 9321 for ac_exec_ext in '' $ac_executable_extensions; do 9322 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9323 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9325 break 2 9326 fi 9327 done 9328 done 9329 IFS=$as_save_IFS 9330 9331 ;; 9332 esac 9333 fi 9334 MKDIR=$ac_cv_path_MKDIR 9335 if test -n "$MKDIR"; then 9336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9337 $as_echo "$MKDIR" >&6; } 9338 else 9339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9340 $as_echo "no" >&6; } 9341 fi 9342 9343 9344 test -n "$MKDIR" && break 9345 done 9346 9347 else 9348 # If it succeeded, then it was overridden by the user. We will use it 9349 # for the tool. 9350 9351 # First remove it from the list of overridden variables, so we can test 9352 # for unknown variables in the end. 9353 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9354 9355 # Check if we try to supply an empty value 9356 if test "x$MKDIR" = x; then 9357 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9358 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9360 $as_echo_n "checking for MKDIR... " >&6; } 9361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9362 $as_echo "disabled" >&6; } 9363 else 9364 # Check if the provided tool contains a complete path. 9365 tool_specified="$MKDIR" 9366 tool_basename="${tool_specified##*/}" 9367 if test "x$tool_basename" = "x$tool_specified"; then 9368 # A command without a complete path is provided, search $PATH. 9369 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9370 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9371 # Extract the first word of "$tool_basename", so it can be a program name with args. 9372 set dummy $tool_basename; ac_word=$2 9373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9374 $as_echo_n "checking for $ac_word... " >&6; } 9375 if ${ac_cv_path_MKDIR+:} false; then : 9376 $as_echo_n "(cached) " >&6 9377 else 9378 case $MKDIR in 9379 [\\/]* | ?:[\\/]*) 9380 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9381 ;; 9382 *) 9383 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9384 for as_dir in $PATH 9385 do 9386 IFS=$as_save_IFS 9387 test -z "$as_dir" && as_dir=. 9388 for ac_exec_ext in '' $ac_executable_extensions; do 9389 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9390 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9391 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9392 break 2 9393 fi 9394 done 9395 done 9396 IFS=$as_save_IFS 9397 9398 ;; 9399 esac 9400 fi 9401 MKDIR=$ac_cv_path_MKDIR 9402 if test -n "$MKDIR"; then 9403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9404 $as_echo "$MKDIR" >&6; } 9405 else 9406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9407 $as_echo "no" >&6; } 9408 fi 9409 9410 9411 if test "x$MKDIR" = x; then 9412 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9413 fi 9414 else 9415 # Otherwise we believe it is a complete path. Use it as it is. 9416 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9417 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9419 $as_echo_n "checking for MKDIR... " >&6; } 9420 if test ! -x "$tool_specified"; then 9421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9422 $as_echo "not found" >&6; } 9423 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9424 fi 9425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9426 $as_echo "$tool_specified" >&6; } 9427 fi 9428 fi 9429 fi 9430 9431 fi 9432 9433 9434 9435 if test "x$MKDIR" = x; then 9436 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9437 fi 9438 9439 9440 9441 9442 9443 # Publish this variable in the help. 9444 9445 9446 if [ -z "${MKTEMP+x}" ]; then 9447 # The variable is not set by user, try to locate tool using the code snippet 9448 for ac_prog in mktemp 9449 do 9450 # Extract the first word of "$ac_prog", so it can be a program name with args. 9451 set dummy $ac_prog; ac_word=$2 9452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9453 $as_echo_n "checking for $ac_word... " >&6; } 9454 if ${ac_cv_path_MKTEMP+:} false; then : 9455 $as_echo_n "(cached) " >&6 9456 else 9457 case $MKTEMP in 9458 [\\/]* | ?:[\\/]*) 9459 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9460 ;; 9461 *) 9462 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9463 for as_dir in $PATH 9464 do 9465 IFS=$as_save_IFS 9466 test -z "$as_dir" && as_dir=. 9467 for ac_exec_ext in '' $ac_executable_extensions; do 9468 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9469 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9470 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9471 break 2 9472 fi 9473 done 9474 done 9475 IFS=$as_save_IFS 9476 9477 ;; 9478 esac 9479 fi 9480 MKTEMP=$ac_cv_path_MKTEMP 9481 if test -n "$MKTEMP"; then 9482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9483 $as_echo "$MKTEMP" >&6; } 9484 else 9485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9486 $as_echo "no" >&6; } 9487 fi 9488 9489 9490 test -n "$MKTEMP" && break 9491 done 9492 9493 else 9494 # The variable is set, but is it from the command line or the environment? 9495 9496 # Try to remove the string !MKTEMP! from our list. 9497 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9498 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9499 # If it failed, the variable was not from the command line. Ignore it, 9500 # but warn the user (except for BASH, which is always set by the calling BASH). 9501 if test "xMKTEMP" != xBASH; then 9502 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9503 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9504 fi 9505 # Try to locate tool using the code snippet 9506 for ac_prog in mktemp 9507 do 9508 # Extract the first word of "$ac_prog", so it can be a program name with args. 9509 set dummy $ac_prog; ac_word=$2 9510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9511 $as_echo_n "checking for $ac_word... " >&6; } 9512 if ${ac_cv_path_MKTEMP+:} false; then : 9513 $as_echo_n "(cached) " >&6 9514 else 9515 case $MKTEMP in 9516 [\\/]* | ?:[\\/]*) 9517 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9518 ;; 9519 *) 9520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9521 for as_dir in $PATH 9522 do 9523 IFS=$as_save_IFS 9524 test -z "$as_dir" && as_dir=. 9525 for ac_exec_ext in '' $ac_executable_extensions; do 9526 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9527 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9528 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9529 break 2 9530 fi 9531 done 9532 done 9533 IFS=$as_save_IFS 9534 9535 ;; 9536 esac 9537 fi 9538 MKTEMP=$ac_cv_path_MKTEMP 9539 if test -n "$MKTEMP"; then 9540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9541 $as_echo "$MKTEMP" >&6; } 9542 else 9543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9544 $as_echo "no" >&6; } 9545 fi 9546 9547 9548 test -n "$MKTEMP" && break 9549 done 9550 9551 else 9552 # If it succeeded, then it was overridden by the user. We will use it 9553 # for the tool. 9554 9555 # First remove it from the list of overridden variables, so we can test 9556 # for unknown variables in the end. 9557 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9558 9559 # Check if we try to supply an empty value 9560 if test "x$MKTEMP" = x; then 9561 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9562 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9564 $as_echo_n "checking for MKTEMP... " >&6; } 9565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9566 $as_echo "disabled" >&6; } 9567 else 9568 # Check if the provided tool contains a complete path. 9569 tool_specified="$MKTEMP" 9570 tool_basename="${tool_specified##*/}" 9571 if test "x$tool_basename" = "x$tool_specified"; then 9572 # A command without a complete path is provided, search $PATH. 9573 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9574 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9575 # Extract the first word of "$tool_basename", so it can be a program name with args. 9576 set dummy $tool_basename; ac_word=$2 9577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9578 $as_echo_n "checking for $ac_word... " >&6; } 9579 if ${ac_cv_path_MKTEMP+:} false; then : 9580 $as_echo_n "(cached) " >&6 9581 else 9582 case $MKTEMP in 9583 [\\/]* | ?:[\\/]*) 9584 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9585 ;; 9586 *) 9587 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9588 for as_dir in $PATH 9589 do 9590 IFS=$as_save_IFS 9591 test -z "$as_dir" && as_dir=. 9592 for ac_exec_ext in '' $ac_executable_extensions; do 9593 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9594 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9595 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9596 break 2 9597 fi 9598 done 9599 done 9600 IFS=$as_save_IFS 9601 9602 ;; 9603 esac 9604 fi 9605 MKTEMP=$ac_cv_path_MKTEMP 9606 if test -n "$MKTEMP"; then 9607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9608 $as_echo "$MKTEMP" >&6; } 9609 else 9610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9611 $as_echo "no" >&6; } 9612 fi 9613 9614 9615 if test "x$MKTEMP" = x; then 9616 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9617 fi 9618 else 9619 # Otherwise we believe it is a complete path. Use it as it is. 9620 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9621 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9623 $as_echo_n "checking for MKTEMP... " >&6; } 9624 if test ! -x "$tool_specified"; then 9625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9626 $as_echo "not found" >&6; } 9627 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9628 fi 9629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9630 $as_echo "$tool_specified" >&6; } 9631 fi 9632 fi 9633 fi 9634 9635 fi 9636 9637 9638 9639 if test "x$MKTEMP" = x; then 9640 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9641 fi 9642 9643 9644 9645 9646 9647 # Publish this variable in the help. 9648 9649 9650 if [ -z "${MV+x}" ]; then 9651 # The variable is not set by user, try to locate tool using the code snippet 9652 for ac_prog in mv 9653 do 9654 # Extract the first word of "$ac_prog", so it can be a program name with args. 9655 set dummy $ac_prog; ac_word=$2 9656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9657 $as_echo_n "checking for $ac_word... " >&6; } 9658 if ${ac_cv_path_MV+:} false; then : 9659 $as_echo_n "(cached) " >&6 9660 else 9661 case $MV in 9662 [\\/]* | ?:[\\/]*) 9663 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9664 ;; 9665 *) 9666 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9667 for as_dir in $PATH 9668 do 9669 IFS=$as_save_IFS 9670 test -z "$as_dir" && as_dir=. 9671 for ac_exec_ext in '' $ac_executable_extensions; do 9672 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9673 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9674 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9675 break 2 9676 fi 9677 done 9678 done 9679 IFS=$as_save_IFS 9680 9681 ;; 9682 esac 9683 fi 9684 MV=$ac_cv_path_MV 9685 if test -n "$MV"; then 9686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9687 $as_echo "$MV" >&6; } 9688 else 9689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9690 $as_echo "no" >&6; } 9691 fi 9692 9693 9694 test -n "$MV" && break 9695 done 9696 9697 else 9698 # The variable is set, but is it from the command line or the environment? 9699 9700 # Try to remove the string !MV! from our list. 9701 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9702 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9703 # If it failed, the variable was not from the command line. Ignore it, 9704 # but warn the user (except for BASH, which is always set by the calling BASH). 9705 if test "xMV" != xBASH; then 9706 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9707 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9708 fi 9709 # Try to locate tool using the code snippet 9710 for ac_prog in mv 9711 do 9712 # Extract the first word of "$ac_prog", so it can be a program name with args. 9713 set dummy $ac_prog; ac_word=$2 9714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9715 $as_echo_n "checking for $ac_word... " >&6; } 9716 if ${ac_cv_path_MV+:} false; then : 9717 $as_echo_n "(cached) " >&6 9718 else 9719 case $MV in 9720 [\\/]* | ?:[\\/]*) 9721 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9722 ;; 9723 *) 9724 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9725 for as_dir in $PATH 9726 do 9727 IFS=$as_save_IFS 9728 test -z "$as_dir" && as_dir=. 9729 for ac_exec_ext in '' $ac_executable_extensions; do 9730 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9731 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9733 break 2 9734 fi 9735 done 9736 done 9737 IFS=$as_save_IFS 9738 9739 ;; 9740 esac 9741 fi 9742 MV=$ac_cv_path_MV 9743 if test -n "$MV"; then 9744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9745 $as_echo "$MV" >&6; } 9746 else 9747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9748 $as_echo "no" >&6; } 9749 fi 9750 9751 9752 test -n "$MV" && break 9753 done 9754 9755 else 9756 # If it succeeded, then it was overridden by the user. We will use it 9757 # for the tool. 9758 9759 # First remove it from the list of overridden variables, so we can test 9760 # for unknown variables in the end. 9761 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9762 9763 # Check if we try to supply an empty value 9764 if test "x$MV" = x; then 9765 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9766 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9768 $as_echo_n "checking for MV... " >&6; } 9769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9770 $as_echo "disabled" >&6; } 9771 else 9772 # Check if the provided tool contains a complete path. 9773 tool_specified="$MV" 9774 tool_basename="${tool_specified##*/}" 9775 if test "x$tool_basename" = "x$tool_specified"; then 9776 # A command without a complete path is provided, search $PATH. 9777 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9778 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9779 # Extract the first word of "$tool_basename", so it can be a program name with args. 9780 set dummy $tool_basename; ac_word=$2 9781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9782 $as_echo_n "checking for $ac_word... " >&6; } 9783 if ${ac_cv_path_MV+:} false; then : 9784 $as_echo_n "(cached) " >&6 9785 else 9786 case $MV in 9787 [\\/]* | ?:[\\/]*) 9788 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9789 ;; 9790 *) 9791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9792 for as_dir in $PATH 9793 do 9794 IFS=$as_save_IFS 9795 test -z "$as_dir" && as_dir=. 9796 for ac_exec_ext in '' $ac_executable_extensions; do 9797 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9798 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9799 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9800 break 2 9801 fi 9802 done 9803 done 9804 IFS=$as_save_IFS 9805 9806 ;; 9807 esac 9808 fi 9809 MV=$ac_cv_path_MV 9810 if test -n "$MV"; then 9811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9812 $as_echo "$MV" >&6; } 9813 else 9814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9815 $as_echo "no" >&6; } 9816 fi 9817 9818 9819 if test "x$MV" = x; then 9820 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9821 fi 9822 else 9823 # Otherwise we believe it is a complete path. Use it as it is. 9824 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9825 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9827 $as_echo_n "checking for MV... " >&6; } 9828 if test ! -x "$tool_specified"; then 9829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9830 $as_echo "not found" >&6; } 9831 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9832 fi 9833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9834 $as_echo "$tool_specified" >&6; } 9835 fi 9836 fi 9837 fi 9838 9839 fi 9840 9841 9842 9843 if test "x$MV" = x; then 9844 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9845 fi 9846 9847 9848 9849 9850 9851 # Publish this variable in the help. 9852 9853 9854 if [ -z "${NAWK+x}" ]; then 9855 # The variable is not set by user, try to locate tool using the code snippet 9856 for ac_prog in nawk gawk awk 9857 do 9858 # Extract the first word of "$ac_prog", so it can be a program name with args. 9859 set dummy $ac_prog; ac_word=$2 9860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9861 $as_echo_n "checking for $ac_word... " >&6; } 9862 if ${ac_cv_path_NAWK+:} false; then : 9863 $as_echo_n "(cached) " >&6 9864 else 9865 case $NAWK in 9866 [\\/]* | ?:[\\/]*) 9867 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9868 ;; 9869 *) 9870 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9871 for as_dir in $PATH 9872 do 9873 IFS=$as_save_IFS 9874 test -z "$as_dir" && as_dir=. 9875 for ac_exec_ext in '' $ac_executable_extensions; do 9876 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9877 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9879 break 2 9880 fi 9881 done 9882 done 9883 IFS=$as_save_IFS 9884 9885 ;; 9886 esac 9887 fi 9888 NAWK=$ac_cv_path_NAWK 9889 if test -n "$NAWK"; then 9890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9891 $as_echo "$NAWK" >&6; } 9892 else 9893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9894 $as_echo "no" >&6; } 9895 fi 9896 9897 9898 test -n "$NAWK" && break 9899 done 9900 9901 else 9902 # The variable is set, but is it from the command line or the environment? 9903 9904 # Try to remove the string !NAWK! from our list. 9905 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9906 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9907 # If it failed, the variable was not from the command line. Ignore it, 9908 # but warn the user (except for BASH, which is always set by the calling BASH). 9909 if test "xNAWK" != xBASH; then 9910 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9911 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9912 fi 9913 # Try to locate tool using the code snippet 9914 for ac_prog in nawk gawk awk 9915 do 9916 # Extract the first word of "$ac_prog", so it can be a program name with args. 9917 set dummy $ac_prog; ac_word=$2 9918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9919 $as_echo_n "checking for $ac_word... " >&6; } 9920 if ${ac_cv_path_NAWK+:} false; then : 9921 $as_echo_n "(cached) " >&6 9922 else 9923 case $NAWK in 9924 [\\/]* | ?:[\\/]*) 9925 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9926 ;; 9927 *) 9928 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9929 for as_dir in $PATH 9930 do 9931 IFS=$as_save_IFS 9932 test -z "$as_dir" && as_dir=. 9933 for ac_exec_ext in '' $ac_executable_extensions; do 9934 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9935 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9936 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9937 break 2 9938 fi 9939 done 9940 done 9941 IFS=$as_save_IFS 9942 9943 ;; 9944 esac 9945 fi 9946 NAWK=$ac_cv_path_NAWK 9947 if test -n "$NAWK"; then 9948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9949 $as_echo "$NAWK" >&6; } 9950 else 9951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9952 $as_echo "no" >&6; } 9953 fi 9954 9955 9956 test -n "$NAWK" && break 9957 done 9958 9959 else 9960 # If it succeeded, then it was overridden by the user. We will use it 9961 # for the tool. 9962 9963 # First remove it from the list of overridden variables, so we can test 9964 # for unknown variables in the end. 9965 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9966 9967 # Check if we try to supply an empty value 9968 if test "x$NAWK" = x; then 9969 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 9970 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 9971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9972 $as_echo_n "checking for NAWK... " >&6; } 9973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9974 $as_echo "disabled" >&6; } 9975 else 9976 # Check if the provided tool contains a complete path. 9977 tool_specified="$NAWK" 9978 tool_basename="${tool_specified##*/}" 9979 if test "x$tool_basename" = "x$tool_specified"; then 9980 # A command without a complete path is provided, search $PATH. 9981 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 9982 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 9983 # Extract the first word of "$tool_basename", so it can be a program name with args. 9984 set dummy $tool_basename; ac_word=$2 9985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9986 $as_echo_n "checking for $ac_word... " >&6; } 9987 if ${ac_cv_path_NAWK+:} false; then : 9988 $as_echo_n "(cached) " >&6 9989 else 9990 case $NAWK in 9991 [\\/]* | ?:[\\/]*) 9992 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9993 ;; 9994 *) 9995 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9996 for as_dir in $PATH 9997 do 9998 IFS=$as_save_IFS 9999 test -z "$as_dir" && as_dir=. 10000 for ac_exec_ext in '' $ac_executable_extensions; do 10001 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10002 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10003 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10004 break 2 10005 fi 10006 done 10007 done 10008 IFS=$as_save_IFS 10009 10010 ;; 10011 esac 10012 fi 10013 NAWK=$ac_cv_path_NAWK 10014 if test -n "$NAWK"; then 10015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10016 $as_echo "$NAWK" >&6; } 10017 else 10018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10019 $as_echo "no" >&6; } 10020 fi 10021 10022 10023 if test "x$NAWK" = x; then 10024 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10025 fi 10026 else 10027 # Otherwise we believe it is a complete path. Use it as it is. 10028 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10029 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10031 $as_echo_n "checking for NAWK... " >&6; } 10032 if test ! -x "$tool_specified"; then 10033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10034 $as_echo "not found" >&6; } 10035 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10036 fi 10037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10038 $as_echo "$tool_specified" >&6; } 10039 fi 10040 fi 10041 fi 10042 10043 fi 10044 10045 10046 10047 if test "x$NAWK" = x; then 10048 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10049 fi 10050 10051 10052 10053 10054 10055 # Publish this variable in the help. 10056 10057 10058 if [ -z "${PRINTF+x}" ]; then 10059 # The variable is not set by user, try to locate tool using the code snippet 10060 for ac_prog in printf 10061 do 10062 # Extract the first word of "$ac_prog", so it can be a program name with args. 10063 set dummy $ac_prog; ac_word=$2 10064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10065 $as_echo_n "checking for $ac_word... " >&6; } 10066 if ${ac_cv_path_PRINTF+:} false; then : 10067 $as_echo_n "(cached) " >&6 10068 else 10069 case $PRINTF in 10070 [\\/]* | ?:[\\/]*) 10071 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10072 ;; 10073 *) 10074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10075 for as_dir in $PATH 10076 do 10077 IFS=$as_save_IFS 10078 test -z "$as_dir" && as_dir=. 10079 for ac_exec_ext in '' $ac_executable_extensions; do 10080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10081 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10083 break 2 10084 fi 10085 done 10086 done 10087 IFS=$as_save_IFS 10088 10089 ;; 10090 esac 10091 fi 10092 PRINTF=$ac_cv_path_PRINTF 10093 if test -n "$PRINTF"; then 10094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10095 $as_echo "$PRINTF" >&6; } 10096 else 10097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10098 $as_echo "no" >&6; } 10099 fi 10100 10101 10102 test -n "$PRINTF" && break 10103 done 10104 10105 else 10106 # The variable is set, but is it from the command line or the environment? 10107 10108 # Try to remove the string !PRINTF! from our list. 10109 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10110 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10111 # If it failed, the variable was not from the command line. Ignore it, 10112 # but warn the user (except for BASH, which is always set by the calling BASH). 10113 if test "xPRINTF" != xBASH; then 10114 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10115 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10116 fi 10117 # Try to locate tool using the code snippet 10118 for ac_prog in printf 10119 do 10120 # Extract the first word of "$ac_prog", so it can be a program name with args. 10121 set dummy $ac_prog; ac_word=$2 10122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10123 $as_echo_n "checking for $ac_word... " >&6; } 10124 if ${ac_cv_path_PRINTF+:} false; then : 10125 $as_echo_n "(cached) " >&6 10126 else 10127 case $PRINTF in 10128 [\\/]* | ?:[\\/]*) 10129 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10130 ;; 10131 *) 10132 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10133 for as_dir in $PATH 10134 do 10135 IFS=$as_save_IFS 10136 test -z "$as_dir" && as_dir=. 10137 for ac_exec_ext in '' $ac_executable_extensions; do 10138 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10139 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10140 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10141 break 2 10142 fi 10143 done 10144 done 10145 IFS=$as_save_IFS 10146 10147 ;; 10148 esac 10149 fi 10150 PRINTF=$ac_cv_path_PRINTF 10151 if test -n "$PRINTF"; then 10152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10153 $as_echo "$PRINTF" >&6; } 10154 else 10155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10156 $as_echo "no" >&6; } 10157 fi 10158 10159 10160 test -n "$PRINTF" && break 10161 done 10162 10163 else 10164 # If it succeeded, then it was overridden by the user. We will use it 10165 # for the tool. 10166 10167 # First remove it from the list of overridden variables, so we can test 10168 # for unknown variables in the end. 10169 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10170 10171 # Check if we try to supply an empty value 10172 if test "x$PRINTF" = x; then 10173 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10174 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10176 $as_echo_n "checking for PRINTF... " >&6; } 10177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10178 $as_echo "disabled" >&6; } 10179 else 10180 # Check if the provided tool contains a complete path. 10181 tool_specified="$PRINTF" 10182 tool_basename="${tool_specified##*/}" 10183 if test "x$tool_basename" = "x$tool_specified"; then 10184 # A command without a complete path is provided, search $PATH. 10185 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10186 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10187 # Extract the first word of "$tool_basename", so it can be a program name with args. 10188 set dummy $tool_basename; ac_word=$2 10189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10190 $as_echo_n "checking for $ac_word... " >&6; } 10191 if ${ac_cv_path_PRINTF+:} false; then : 10192 $as_echo_n "(cached) " >&6 10193 else 10194 case $PRINTF in 10195 [\\/]* | ?:[\\/]*) 10196 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10197 ;; 10198 *) 10199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10200 for as_dir in $PATH 10201 do 10202 IFS=$as_save_IFS 10203 test -z "$as_dir" && as_dir=. 10204 for ac_exec_ext in '' $ac_executable_extensions; do 10205 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10206 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10208 break 2 10209 fi 10210 done 10211 done 10212 IFS=$as_save_IFS 10213 10214 ;; 10215 esac 10216 fi 10217 PRINTF=$ac_cv_path_PRINTF 10218 if test -n "$PRINTF"; then 10219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10220 $as_echo "$PRINTF" >&6; } 10221 else 10222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10223 $as_echo "no" >&6; } 10224 fi 10225 10226 10227 if test "x$PRINTF" = x; then 10228 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10229 fi 10230 else 10231 # Otherwise we believe it is a complete path. Use it as it is. 10232 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10233 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10235 $as_echo_n "checking for PRINTF... " >&6; } 10236 if test ! -x "$tool_specified"; then 10237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10238 $as_echo "not found" >&6; } 10239 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10240 fi 10241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10242 $as_echo "$tool_specified" >&6; } 10243 fi 10244 fi 10245 fi 10246 10247 fi 10248 10249 10250 10251 if test "x$PRINTF" = x; then 10252 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10253 fi 10254 10255 10256 10257 10258 10259 # Publish this variable in the help. 10260 10261 10262 if [ -z "${RM+x}" ]; then 10263 # The variable is not set by user, try to locate tool using the code snippet 10264 for ac_prog in rm 10265 do 10266 # Extract the first word of "$ac_prog", so it can be a program name with args. 10267 set dummy $ac_prog; ac_word=$2 10268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10269 $as_echo_n "checking for $ac_word... " >&6; } 10270 if ${ac_cv_path_RM+:} false; then : 10271 $as_echo_n "(cached) " >&6 10272 else 10273 case $RM in 10274 [\\/]* | ?:[\\/]*) 10275 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10276 ;; 10277 *) 10278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10279 for as_dir in $PATH 10280 do 10281 IFS=$as_save_IFS 10282 test -z "$as_dir" && as_dir=. 10283 for ac_exec_ext in '' $ac_executable_extensions; do 10284 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10285 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10287 break 2 10288 fi 10289 done 10290 done 10291 IFS=$as_save_IFS 10292 10293 ;; 10294 esac 10295 fi 10296 RM=$ac_cv_path_RM 10297 if test -n "$RM"; then 10298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10299 $as_echo "$RM" >&6; } 10300 else 10301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10302 $as_echo "no" >&6; } 10303 fi 10304 10305 10306 test -n "$RM" && break 10307 done 10308 10309 else 10310 # The variable is set, but is it from the command line or the environment? 10311 10312 # Try to remove the string !RM! from our list. 10313 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10314 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10315 # If it failed, the variable was not from the command line. Ignore it, 10316 # but warn the user (except for BASH, which is always set by the calling BASH). 10317 if test "xRM" != xBASH; then 10318 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10319 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10320 fi 10321 # Try to locate tool using the code snippet 10322 for ac_prog in rm 10323 do 10324 # Extract the first word of "$ac_prog", so it can be a program name with args. 10325 set dummy $ac_prog; ac_word=$2 10326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10327 $as_echo_n "checking for $ac_word... " >&6; } 10328 if ${ac_cv_path_RM+:} false; then : 10329 $as_echo_n "(cached) " >&6 10330 else 10331 case $RM in 10332 [\\/]* | ?:[\\/]*) 10333 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10334 ;; 10335 *) 10336 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10337 for as_dir in $PATH 10338 do 10339 IFS=$as_save_IFS 10340 test -z "$as_dir" && as_dir=. 10341 for ac_exec_ext in '' $ac_executable_extensions; do 10342 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10343 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10344 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10345 break 2 10346 fi 10347 done 10348 done 10349 IFS=$as_save_IFS 10350 10351 ;; 10352 esac 10353 fi 10354 RM=$ac_cv_path_RM 10355 if test -n "$RM"; then 10356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10357 $as_echo "$RM" >&6; } 10358 else 10359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10360 $as_echo "no" >&6; } 10361 fi 10362 10363 10364 test -n "$RM" && break 10365 done 10366 10367 else 10368 # If it succeeded, then it was overridden by the user. We will use it 10369 # for the tool. 10370 10371 # First remove it from the list of overridden variables, so we can test 10372 # for unknown variables in the end. 10373 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10374 10375 # Check if we try to supply an empty value 10376 if test "x$RM" = x; then 10377 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10378 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10380 $as_echo_n "checking for RM... " >&6; } 10381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10382 $as_echo "disabled" >&6; } 10383 else 10384 # Check if the provided tool contains a complete path. 10385 tool_specified="$RM" 10386 tool_basename="${tool_specified##*/}" 10387 if test "x$tool_basename" = "x$tool_specified"; then 10388 # A command without a complete path is provided, search $PATH. 10389 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10390 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10391 # Extract the first word of "$tool_basename", so it can be a program name with args. 10392 set dummy $tool_basename; ac_word=$2 10393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10394 $as_echo_n "checking for $ac_word... " >&6; } 10395 if ${ac_cv_path_RM+:} false; then : 10396 $as_echo_n "(cached) " >&6 10397 else 10398 case $RM in 10399 [\\/]* | ?:[\\/]*) 10400 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10401 ;; 10402 *) 10403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10404 for as_dir in $PATH 10405 do 10406 IFS=$as_save_IFS 10407 test -z "$as_dir" && as_dir=. 10408 for ac_exec_ext in '' $ac_executable_extensions; do 10409 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10410 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10412 break 2 10413 fi 10414 done 10415 done 10416 IFS=$as_save_IFS 10417 10418 ;; 10419 esac 10420 fi 10421 RM=$ac_cv_path_RM 10422 if test -n "$RM"; then 10423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10424 $as_echo "$RM" >&6; } 10425 else 10426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10427 $as_echo "no" >&6; } 10428 fi 10429 10430 10431 if test "x$RM" = x; then 10432 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10433 fi 10434 else 10435 # Otherwise we believe it is a complete path. Use it as it is. 10436 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10437 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10439 $as_echo_n "checking for RM... " >&6; } 10440 if test ! -x "$tool_specified"; then 10441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10442 $as_echo "not found" >&6; } 10443 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10444 fi 10445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10446 $as_echo "$tool_specified" >&6; } 10447 fi 10448 fi 10449 fi 10450 10451 fi 10452 10453 10454 10455 if test "x$RM" = x; then 10456 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10457 fi 10458 10459 10460 10461 10462 10463 # Publish this variable in the help. 10464 10465 10466 if [ -z "${RMDIR+x}" ]; then 10467 # The variable is not set by user, try to locate tool using the code snippet 10468 for ac_prog in rmdir 10469 do 10470 # Extract the first word of "$ac_prog", so it can be a program name with args. 10471 set dummy $ac_prog; ac_word=$2 10472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10473 $as_echo_n "checking for $ac_word... " >&6; } 10474 if ${ac_cv_path_RMDIR+:} false; then : 10475 $as_echo_n "(cached) " >&6 10476 else 10477 case $RMDIR in 10478 [\\/]* | ?:[\\/]*) 10479 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10480 ;; 10481 *) 10482 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10483 for as_dir in $PATH 10484 do 10485 IFS=$as_save_IFS 10486 test -z "$as_dir" && as_dir=. 10487 for ac_exec_ext in '' $ac_executable_extensions; do 10488 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10489 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10491 break 2 10492 fi 10493 done 10494 done 10495 IFS=$as_save_IFS 10496 10497 ;; 10498 esac 10499 fi 10500 RMDIR=$ac_cv_path_RMDIR 10501 if test -n "$RMDIR"; then 10502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10503 $as_echo "$RMDIR" >&6; } 10504 else 10505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10506 $as_echo "no" >&6; } 10507 fi 10508 10509 10510 test -n "$RMDIR" && break 10511 done 10512 10513 else 10514 # The variable is set, but is it from the command line or the environment? 10515 10516 # Try to remove the string !RMDIR! from our list. 10517 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10518 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10519 # If it failed, the variable was not from the command line. Ignore it, 10520 # but warn the user (except for BASH, which is always set by the calling BASH). 10521 if test "xRMDIR" != xBASH; then 10522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10523 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10524 fi 10525 # Try to locate tool using the code snippet 10526 for ac_prog in rmdir 10527 do 10528 # Extract the first word of "$ac_prog", so it can be a program name with args. 10529 set dummy $ac_prog; ac_word=$2 10530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10531 $as_echo_n "checking for $ac_word... " >&6; } 10532 if ${ac_cv_path_RMDIR+:} false; then : 10533 $as_echo_n "(cached) " >&6 10534 else 10535 case $RMDIR in 10536 [\\/]* | ?:[\\/]*) 10537 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10538 ;; 10539 *) 10540 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10541 for as_dir in $PATH 10542 do 10543 IFS=$as_save_IFS 10544 test -z "$as_dir" && as_dir=. 10545 for ac_exec_ext in '' $ac_executable_extensions; do 10546 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10547 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10548 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10549 break 2 10550 fi 10551 done 10552 done 10553 IFS=$as_save_IFS 10554 10555 ;; 10556 esac 10557 fi 10558 RMDIR=$ac_cv_path_RMDIR 10559 if test -n "$RMDIR"; then 10560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10561 $as_echo "$RMDIR" >&6; } 10562 else 10563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10564 $as_echo "no" >&6; } 10565 fi 10566 10567 10568 test -n "$RMDIR" && break 10569 done 10570 10571 else 10572 # If it succeeded, then it was overridden by the user. We will use it 10573 # for the tool. 10574 10575 # First remove it from the list of overridden variables, so we can test 10576 # for unknown variables in the end. 10577 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10578 10579 # Check if we try to supply an empty value 10580 if test "x$RMDIR" = x; then 10581 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10582 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10584 $as_echo_n "checking for RMDIR... " >&6; } 10585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10586 $as_echo "disabled" >&6; } 10587 else 10588 # Check if the provided tool contains a complete path. 10589 tool_specified="$RMDIR" 10590 tool_basename="${tool_specified##*/}" 10591 if test "x$tool_basename" = "x$tool_specified"; then 10592 # A command without a complete path is provided, search $PATH. 10593 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10594 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10595 # Extract the first word of "$tool_basename", so it can be a program name with args. 10596 set dummy $tool_basename; ac_word=$2 10597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10598 $as_echo_n "checking for $ac_word... " >&6; } 10599 if ${ac_cv_path_RMDIR+:} false; then : 10600 $as_echo_n "(cached) " >&6 10601 else 10602 case $RMDIR in 10603 [\\/]* | ?:[\\/]*) 10604 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10605 ;; 10606 *) 10607 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10608 for as_dir in $PATH 10609 do 10610 IFS=$as_save_IFS 10611 test -z "$as_dir" && as_dir=. 10612 for ac_exec_ext in '' $ac_executable_extensions; do 10613 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10614 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10615 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10616 break 2 10617 fi 10618 done 10619 done 10620 IFS=$as_save_IFS 10621 10622 ;; 10623 esac 10624 fi 10625 RMDIR=$ac_cv_path_RMDIR 10626 if test -n "$RMDIR"; then 10627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10628 $as_echo "$RMDIR" >&6; } 10629 else 10630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10631 $as_echo "no" >&6; } 10632 fi 10633 10634 10635 if test "x$RMDIR" = x; then 10636 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10637 fi 10638 else 10639 # Otherwise we believe it is a complete path. Use it as it is. 10640 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10641 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10643 $as_echo_n "checking for RMDIR... " >&6; } 10644 if test ! -x "$tool_specified"; then 10645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10646 $as_echo "not found" >&6; } 10647 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10648 fi 10649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10650 $as_echo "$tool_specified" >&6; } 10651 fi 10652 fi 10653 fi 10654 10655 fi 10656 10657 10658 10659 if test "x$RMDIR" = x; then 10660 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10661 fi 10662 10663 10664 10665 10666 10667 # Publish this variable in the help. 10668 10669 10670 if [ -z "${SH+x}" ]; then 10671 # The variable is not set by user, try to locate tool using the code snippet 10672 for ac_prog in sh 10673 do 10674 # Extract the first word of "$ac_prog", so it can be a program name with args. 10675 set dummy $ac_prog; ac_word=$2 10676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10677 $as_echo_n "checking for $ac_word... " >&6; } 10678 if ${ac_cv_path_SH+:} false; then : 10679 $as_echo_n "(cached) " >&6 10680 else 10681 case $SH in 10682 [\\/]* | ?:[\\/]*) 10683 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10684 ;; 10685 *) 10686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10687 for as_dir in $PATH 10688 do 10689 IFS=$as_save_IFS 10690 test -z "$as_dir" && as_dir=. 10691 for ac_exec_ext in '' $ac_executable_extensions; do 10692 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10693 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10695 break 2 10696 fi 10697 done 10698 done 10699 IFS=$as_save_IFS 10700 10701 ;; 10702 esac 10703 fi 10704 SH=$ac_cv_path_SH 10705 if test -n "$SH"; then 10706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10707 $as_echo "$SH" >&6; } 10708 else 10709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10710 $as_echo "no" >&6; } 10711 fi 10712 10713 10714 test -n "$SH" && break 10715 done 10716 10717 else 10718 # The variable is set, but is it from the command line or the environment? 10719 10720 # Try to remove the string !SH! from our list. 10721 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10722 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10723 # If it failed, the variable was not from the command line. Ignore it, 10724 # but warn the user (except for BASH, which is always set by the calling BASH). 10725 if test "xSH" != xBASH; then 10726 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10727 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10728 fi 10729 # Try to locate tool using the code snippet 10730 for ac_prog in sh 10731 do 10732 # Extract the first word of "$ac_prog", so it can be a program name with args. 10733 set dummy $ac_prog; ac_word=$2 10734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10735 $as_echo_n "checking for $ac_word... " >&6; } 10736 if ${ac_cv_path_SH+:} false; then : 10737 $as_echo_n "(cached) " >&6 10738 else 10739 case $SH in 10740 [\\/]* | ?:[\\/]*) 10741 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10742 ;; 10743 *) 10744 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10745 for as_dir in $PATH 10746 do 10747 IFS=$as_save_IFS 10748 test -z "$as_dir" && as_dir=. 10749 for ac_exec_ext in '' $ac_executable_extensions; do 10750 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10751 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10752 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10753 break 2 10754 fi 10755 done 10756 done 10757 IFS=$as_save_IFS 10758 10759 ;; 10760 esac 10761 fi 10762 SH=$ac_cv_path_SH 10763 if test -n "$SH"; then 10764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10765 $as_echo "$SH" >&6; } 10766 else 10767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10768 $as_echo "no" >&6; } 10769 fi 10770 10771 10772 test -n "$SH" && break 10773 done 10774 10775 else 10776 # If it succeeded, then it was overridden by the user. We will use it 10777 # for the tool. 10778 10779 # First remove it from the list of overridden variables, so we can test 10780 # for unknown variables in the end. 10781 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10782 10783 # Check if we try to supply an empty value 10784 if test "x$SH" = x; then 10785 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10786 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10788 $as_echo_n "checking for SH... " >&6; } 10789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10790 $as_echo "disabled" >&6; } 10791 else 10792 # Check if the provided tool contains a complete path. 10793 tool_specified="$SH" 10794 tool_basename="${tool_specified##*/}" 10795 if test "x$tool_basename" = "x$tool_specified"; then 10796 # A command without a complete path is provided, search $PATH. 10797 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10798 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10799 # Extract the first word of "$tool_basename", so it can be a program name with args. 10800 set dummy $tool_basename; ac_word=$2 10801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10802 $as_echo_n "checking for $ac_word... " >&6; } 10803 if ${ac_cv_path_SH+:} false; then : 10804 $as_echo_n "(cached) " >&6 10805 else 10806 case $SH in 10807 [\\/]* | ?:[\\/]*) 10808 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10809 ;; 10810 *) 10811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10812 for as_dir in $PATH 10813 do 10814 IFS=$as_save_IFS 10815 test -z "$as_dir" && as_dir=. 10816 for ac_exec_ext in '' $ac_executable_extensions; do 10817 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10818 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10819 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10820 break 2 10821 fi 10822 done 10823 done 10824 IFS=$as_save_IFS 10825 10826 ;; 10827 esac 10828 fi 10829 SH=$ac_cv_path_SH 10830 if test -n "$SH"; then 10831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10832 $as_echo "$SH" >&6; } 10833 else 10834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10835 $as_echo "no" >&6; } 10836 fi 10837 10838 10839 if test "x$SH" = x; then 10840 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10841 fi 10842 else 10843 # Otherwise we believe it is a complete path. Use it as it is. 10844 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10845 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10847 $as_echo_n "checking for SH... " >&6; } 10848 if test ! -x "$tool_specified"; then 10849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10850 $as_echo "not found" >&6; } 10851 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10852 fi 10853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10854 $as_echo "$tool_specified" >&6; } 10855 fi 10856 fi 10857 fi 10858 10859 fi 10860 10861 10862 10863 if test "x$SH" = x; then 10864 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10865 fi 10866 10867 10868 10869 10870 10871 # Publish this variable in the help. 10872 10873 10874 if [ -z "${SORT+x}" ]; then 10875 # The variable is not set by user, try to locate tool using the code snippet 10876 for ac_prog in sort 10877 do 10878 # Extract the first word of "$ac_prog", so it can be a program name with args. 10879 set dummy $ac_prog; ac_word=$2 10880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10881 $as_echo_n "checking for $ac_word... " >&6; } 10882 if ${ac_cv_path_SORT+:} false; then : 10883 $as_echo_n "(cached) " >&6 10884 else 10885 case $SORT in 10886 [\\/]* | ?:[\\/]*) 10887 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10888 ;; 10889 *) 10890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10891 for as_dir in $PATH 10892 do 10893 IFS=$as_save_IFS 10894 test -z "$as_dir" && as_dir=. 10895 for ac_exec_ext in '' $ac_executable_extensions; do 10896 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10897 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10898 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10899 break 2 10900 fi 10901 done 10902 done 10903 IFS=$as_save_IFS 10904 10905 ;; 10906 esac 10907 fi 10908 SORT=$ac_cv_path_SORT 10909 if test -n "$SORT"; then 10910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10911 $as_echo "$SORT" >&6; } 10912 else 10913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10914 $as_echo "no" >&6; } 10915 fi 10916 10917 10918 test -n "$SORT" && break 10919 done 10920 10921 else 10922 # The variable is set, but is it from the command line or the environment? 10923 10924 # Try to remove the string !SORT! from our list. 10925 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 10926 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10927 # If it failed, the variable was not from the command line. Ignore it, 10928 # but warn the user (except for BASH, which is always set by the calling BASH). 10929 if test "xSORT" != xBASH; then 10930 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 10931 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 10932 fi 10933 # Try to locate tool using the code snippet 10934 for ac_prog in sort 10935 do 10936 # Extract the first word of "$ac_prog", so it can be a program name with args. 10937 set dummy $ac_prog; ac_word=$2 10938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10939 $as_echo_n "checking for $ac_word... " >&6; } 10940 if ${ac_cv_path_SORT+:} false; then : 10941 $as_echo_n "(cached) " >&6 10942 else 10943 case $SORT in 10944 [\\/]* | ?:[\\/]*) 10945 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10946 ;; 10947 *) 10948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10949 for as_dir in $PATH 10950 do 10951 IFS=$as_save_IFS 10952 test -z "$as_dir" && as_dir=. 10953 for ac_exec_ext in '' $ac_executable_extensions; do 10954 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10955 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10956 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10957 break 2 10958 fi 10959 done 10960 done 10961 IFS=$as_save_IFS 10962 10963 ;; 10964 esac 10965 fi 10966 SORT=$ac_cv_path_SORT 10967 if test -n "$SORT"; then 10968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10969 $as_echo "$SORT" >&6; } 10970 else 10971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10972 $as_echo "no" >&6; } 10973 fi 10974 10975 10976 test -n "$SORT" && break 10977 done 10978 10979 else 10980 # If it succeeded, then it was overridden by the user. We will use it 10981 # for the tool. 10982 10983 # First remove it from the list of overridden variables, so we can test 10984 # for unknown variables in the end. 10985 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10986 10987 # Check if we try to supply an empty value 10988 if test "x$SORT" = x; then 10989 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 10990 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 10991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 10992 $as_echo_n "checking for SORT... " >&6; } 10993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10994 $as_echo "disabled" >&6; } 10995 else 10996 # Check if the provided tool contains a complete path. 10997 tool_specified="$SORT" 10998 tool_basename="${tool_specified##*/}" 10999 if test "x$tool_basename" = "x$tool_specified"; then 11000 # A command without a complete path is provided, search $PATH. 11001 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 11002 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 11003 # Extract the first word of "$tool_basename", so it can be a program name with args. 11004 set dummy $tool_basename; ac_word=$2 11005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11006 $as_echo_n "checking for $ac_word... " >&6; } 11007 if ${ac_cv_path_SORT+:} false; then : 11008 $as_echo_n "(cached) " >&6 11009 else 11010 case $SORT in 11011 [\\/]* | ?:[\\/]*) 11012 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11013 ;; 11014 *) 11015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11016 for as_dir in $PATH 11017 do 11018 IFS=$as_save_IFS 11019 test -z "$as_dir" && as_dir=. 11020 for ac_exec_ext in '' $ac_executable_extensions; do 11021 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11022 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11023 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11024 break 2 11025 fi 11026 done 11027 done 11028 IFS=$as_save_IFS 11029 11030 ;; 11031 esac 11032 fi 11033 SORT=$ac_cv_path_SORT 11034 if test -n "$SORT"; then 11035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11036 $as_echo "$SORT" >&6; } 11037 else 11038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11039 $as_echo "no" >&6; } 11040 fi 11041 11042 11043 if test "x$SORT" = x; then 11044 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11045 fi 11046 else 11047 # Otherwise we believe it is a complete path. Use it as it is. 11048 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11049 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11051 $as_echo_n "checking for SORT... " >&6; } 11052 if test ! -x "$tool_specified"; then 11053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11054 $as_echo "not found" >&6; } 11055 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11056 fi 11057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11058 $as_echo "$tool_specified" >&6; } 11059 fi 11060 fi 11061 fi 11062 11063 fi 11064 11065 11066 11067 if test "x$SORT" = x; then 11068 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11069 fi 11070 11071 11072 11073 11074 11075 # Publish this variable in the help. 11076 11077 11078 if [ -z "${TAIL+x}" ]; then 11079 # The variable is not set by user, try to locate tool using the code snippet 11080 for ac_prog in tail 11081 do 11082 # Extract the first word of "$ac_prog", so it can be a program name with args. 11083 set dummy $ac_prog; ac_word=$2 11084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11085 $as_echo_n "checking for $ac_word... " >&6; } 11086 if ${ac_cv_path_TAIL+:} false; then : 11087 $as_echo_n "(cached) " >&6 11088 else 11089 case $TAIL in 11090 [\\/]* | ?:[\\/]*) 11091 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11092 ;; 11093 *) 11094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11095 for as_dir in $PATH 11096 do 11097 IFS=$as_save_IFS 11098 test -z "$as_dir" && as_dir=. 11099 for ac_exec_ext in '' $ac_executable_extensions; do 11100 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11101 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11102 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11103 break 2 11104 fi 11105 done 11106 done 11107 IFS=$as_save_IFS 11108 11109 ;; 11110 esac 11111 fi 11112 TAIL=$ac_cv_path_TAIL 11113 if test -n "$TAIL"; then 11114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11115 $as_echo "$TAIL" >&6; } 11116 else 11117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11118 $as_echo "no" >&6; } 11119 fi 11120 11121 11122 test -n "$TAIL" && break 11123 done 11124 11125 else 11126 # The variable is set, but is it from the command line or the environment? 11127 11128 # Try to remove the string !TAIL! from our list. 11129 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11130 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11131 # If it failed, the variable was not from the command line. Ignore it, 11132 # but warn the user (except for BASH, which is always set by the calling BASH). 11133 if test "xTAIL" != xBASH; then 11134 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11135 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11136 fi 11137 # Try to locate tool using the code snippet 11138 for ac_prog in tail 11139 do 11140 # Extract the first word of "$ac_prog", so it can be a program name with args. 11141 set dummy $ac_prog; ac_word=$2 11142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11143 $as_echo_n "checking for $ac_word... " >&6; } 11144 if ${ac_cv_path_TAIL+:} false; then : 11145 $as_echo_n "(cached) " >&6 11146 else 11147 case $TAIL in 11148 [\\/]* | ?:[\\/]*) 11149 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11150 ;; 11151 *) 11152 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11153 for as_dir in $PATH 11154 do 11155 IFS=$as_save_IFS 11156 test -z "$as_dir" && as_dir=. 11157 for ac_exec_ext in '' $ac_executable_extensions; do 11158 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11159 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11160 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11161 break 2 11162 fi 11163 done 11164 done 11165 IFS=$as_save_IFS 11166 11167 ;; 11168 esac 11169 fi 11170 TAIL=$ac_cv_path_TAIL 11171 if test -n "$TAIL"; then 11172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11173 $as_echo "$TAIL" >&6; } 11174 else 11175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11176 $as_echo "no" >&6; } 11177 fi 11178 11179 11180 test -n "$TAIL" && break 11181 done 11182 11183 else 11184 # If it succeeded, then it was overridden by the user. We will use it 11185 # for the tool. 11186 11187 # First remove it from the list of overridden variables, so we can test 11188 # for unknown variables in the end. 11189 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11190 11191 # Check if we try to supply an empty value 11192 if test "x$TAIL" = x; then 11193 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11194 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11196 $as_echo_n "checking for TAIL... " >&6; } 11197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11198 $as_echo "disabled" >&6; } 11199 else 11200 # Check if the provided tool contains a complete path. 11201 tool_specified="$TAIL" 11202 tool_basename="${tool_specified##*/}" 11203 if test "x$tool_basename" = "x$tool_specified"; then 11204 # A command without a complete path is provided, search $PATH. 11205 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11206 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11207 # Extract the first word of "$tool_basename", so it can be a program name with args. 11208 set dummy $tool_basename; ac_word=$2 11209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11210 $as_echo_n "checking for $ac_word... " >&6; } 11211 if ${ac_cv_path_TAIL+:} false; then : 11212 $as_echo_n "(cached) " >&6 11213 else 11214 case $TAIL in 11215 [\\/]* | ?:[\\/]*) 11216 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11217 ;; 11218 *) 11219 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11220 for as_dir in $PATH 11221 do 11222 IFS=$as_save_IFS 11223 test -z "$as_dir" && as_dir=. 11224 for ac_exec_ext in '' $ac_executable_extensions; do 11225 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11226 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11227 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11228 break 2 11229 fi 11230 done 11231 done 11232 IFS=$as_save_IFS 11233 11234 ;; 11235 esac 11236 fi 11237 TAIL=$ac_cv_path_TAIL 11238 if test -n "$TAIL"; then 11239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11240 $as_echo "$TAIL" >&6; } 11241 else 11242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11243 $as_echo "no" >&6; } 11244 fi 11245 11246 11247 if test "x$TAIL" = x; then 11248 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11249 fi 11250 else 11251 # Otherwise we believe it is a complete path. Use it as it is. 11252 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11253 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11255 $as_echo_n "checking for TAIL... " >&6; } 11256 if test ! -x "$tool_specified"; then 11257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11258 $as_echo "not found" >&6; } 11259 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11260 fi 11261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11262 $as_echo "$tool_specified" >&6; } 11263 fi 11264 fi 11265 fi 11266 11267 fi 11268 11269 11270 11271 if test "x$TAIL" = x; then 11272 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11273 fi 11274 11275 11276 11277 11278 11279 # Publish this variable in the help. 11280 11281 11282 if [ -z "${TAR+x}" ]; then 11283 # The variable is not set by user, try to locate tool using the code snippet 11284 for ac_prog in gtar tar 11285 do 11286 # Extract the first word of "$ac_prog", so it can be a program name with args. 11287 set dummy $ac_prog; ac_word=$2 11288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11289 $as_echo_n "checking for $ac_word... " >&6; } 11290 if ${ac_cv_path_TAR+:} false; then : 11291 $as_echo_n "(cached) " >&6 11292 else 11293 case $TAR in 11294 [\\/]* | ?:[\\/]*) 11295 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11296 ;; 11297 *) 11298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11299 for as_dir in $PATH 11300 do 11301 IFS=$as_save_IFS 11302 test -z "$as_dir" && as_dir=. 11303 for ac_exec_ext in '' $ac_executable_extensions; do 11304 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11305 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11306 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11307 break 2 11308 fi 11309 done 11310 done 11311 IFS=$as_save_IFS 11312 11313 ;; 11314 esac 11315 fi 11316 TAR=$ac_cv_path_TAR 11317 if test -n "$TAR"; then 11318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11319 $as_echo "$TAR" >&6; } 11320 else 11321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11322 $as_echo "no" >&6; } 11323 fi 11324 11325 11326 test -n "$TAR" && break 11327 done 11328 11329 else 11330 # The variable is set, but is it from the command line or the environment? 11331 11332 # Try to remove the string !TAR! from our list. 11333 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11334 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11335 # If it failed, the variable was not from the command line. Ignore it, 11336 # but warn the user (except for BASH, which is always set by the calling BASH). 11337 if test "xTAR" != xBASH; then 11338 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11339 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11340 fi 11341 # Try to locate tool using the code snippet 11342 for ac_prog in gtar tar 11343 do 11344 # Extract the first word of "$ac_prog", so it can be a program name with args. 11345 set dummy $ac_prog; ac_word=$2 11346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11347 $as_echo_n "checking for $ac_word... " >&6; } 11348 if ${ac_cv_path_TAR+:} false; then : 11349 $as_echo_n "(cached) " >&6 11350 else 11351 case $TAR in 11352 [\\/]* | ?:[\\/]*) 11353 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11354 ;; 11355 *) 11356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11357 for as_dir in $PATH 11358 do 11359 IFS=$as_save_IFS 11360 test -z "$as_dir" && as_dir=. 11361 for ac_exec_ext in '' $ac_executable_extensions; do 11362 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11363 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11364 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11365 break 2 11366 fi 11367 done 11368 done 11369 IFS=$as_save_IFS 11370 11371 ;; 11372 esac 11373 fi 11374 TAR=$ac_cv_path_TAR 11375 if test -n "$TAR"; then 11376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11377 $as_echo "$TAR" >&6; } 11378 else 11379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11380 $as_echo "no" >&6; } 11381 fi 11382 11383 11384 test -n "$TAR" && break 11385 done 11386 11387 else 11388 # If it succeeded, then it was overridden by the user. We will use it 11389 # for the tool. 11390 11391 # First remove it from the list of overridden variables, so we can test 11392 # for unknown variables in the end. 11393 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11394 11395 # Check if we try to supply an empty value 11396 if test "x$TAR" = x; then 11397 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11398 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11400 $as_echo_n "checking for TAR... " >&6; } 11401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11402 $as_echo "disabled" >&6; } 11403 else 11404 # Check if the provided tool contains a complete path. 11405 tool_specified="$TAR" 11406 tool_basename="${tool_specified##*/}" 11407 if test "x$tool_basename" = "x$tool_specified"; then 11408 # A command without a complete path is provided, search $PATH. 11409 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11410 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11411 # Extract the first word of "$tool_basename", so it can be a program name with args. 11412 set dummy $tool_basename; ac_word=$2 11413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11414 $as_echo_n "checking for $ac_word... " >&6; } 11415 if ${ac_cv_path_TAR+:} false; then : 11416 $as_echo_n "(cached) " >&6 11417 else 11418 case $TAR in 11419 [\\/]* | ?:[\\/]*) 11420 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11421 ;; 11422 *) 11423 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11424 for as_dir in $PATH 11425 do 11426 IFS=$as_save_IFS 11427 test -z "$as_dir" && as_dir=. 11428 for ac_exec_ext in '' $ac_executable_extensions; do 11429 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11430 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11431 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11432 break 2 11433 fi 11434 done 11435 done 11436 IFS=$as_save_IFS 11437 11438 ;; 11439 esac 11440 fi 11441 TAR=$ac_cv_path_TAR 11442 if test -n "$TAR"; then 11443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11444 $as_echo "$TAR" >&6; } 11445 else 11446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11447 $as_echo "no" >&6; } 11448 fi 11449 11450 11451 if test "x$TAR" = x; then 11452 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11453 fi 11454 else 11455 # Otherwise we believe it is a complete path. Use it as it is. 11456 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11457 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11459 $as_echo_n "checking for TAR... " >&6; } 11460 if test ! -x "$tool_specified"; then 11461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11462 $as_echo "not found" >&6; } 11463 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11464 fi 11465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11466 $as_echo "$tool_specified" >&6; } 11467 fi 11468 fi 11469 fi 11470 11471 fi 11472 11473 11474 11475 if test "x$TAR" = x; then 11476 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11477 fi 11478 11479 11480 11481 11482 11483 # Publish this variable in the help. 11484 11485 11486 if [ -z "${TEE+x}" ]; then 11487 # The variable is not set by user, try to locate tool using the code snippet 11488 for ac_prog in tee 11489 do 11490 # Extract the first word of "$ac_prog", so it can be a program name with args. 11491 set dummy $ac_prog; ac_word=$2 11492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11493 $as_echo_n "checking for $ac_word... " >&6; } 11494 if ${ac_cv_path_TEE+:} false; then : 11495 $as_echo_n "(cached) " >&6 11496 else 11497 case $TEE in 11498 [\\/]* | ?:[\\/]*) 11499 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11500 ;; 11501 *) 11502 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11503 for as_dir in $PATH 11504 do 11505 IFS=$as_save_IFS 11506 test -z "$as_dir" && as_dir=. 11507 for ac_exec_ext in '' $ac_executable_extensions; do 11508 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11509 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11511 break 2 11512 fi 11513 done 11514 done 11515 IFS=$as_save_IFS 11516 11517 ;; 11518 esac 11519 fi 11520 TEE=$ac_cv_path_TEE 11521 if test -n "$TEE"; then 11522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11523 $as_echo "$TEE" >&6; } 11524 else 11525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11526 $as_echo "no" >&6; } 11527 fi 11528 11529 11530 test -n "$TEE" && break 11531 done 11532 11533 else 11534 # The variable is set, but is it from the command line or the environment? 11535 11536 # Try to remove the string !TEE! from our list. 11537 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11538 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11539 # If it failed, the variable was not from the command line. Ignore it, 11540 # but warn the user (except for BASH, which is always set by the calling BASH). 11541 if test "xTEE" != xBASH; then 11542 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11543 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11544 fi 11545 # Try to locate tool using the code snippet 11546 for ac_prog in tee 11547 do 11548 # Extract the first word of "$ac_prog", so it can be a program name with args. 11549 set dummy $ac_prog; ac_word=$2 11550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11551 $as_echo_n "checking for $ac_word... " >&6; } 11552 if ${ac_cv_path_TEE+:} false; then : 11553 $as_echo_n "(cached) " >&6 11554 else 11555 case $TEE in 11556 [\\/]* | ?:[\\/]*) 11557 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11558 ;; 11559 *) 11560 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11561 for as_dir in $PATH 11562 do 11563 IFS=$as_save_IFS 11564 test -z "$as_dir" && as_dir=. 11565 for ac_exec_ext in '' $ac_executable_extensions; do 11566 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11567 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11568 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11569 break 2 11570 fi 11571 done 11572 done 11573 IFS=$as_save_IFS 11574 11575 ;; 11576 esac 11577 fi 11578 TEE=$ac_cv_path_TEE 11579 if test -n "$TEE"; then 11580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11581 $as_echo "$TEE" >&6; } 11582 else 11583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11584 $as_echo "no" >&6; } 11585 fi 11586 11587 11588 test -n "$TEE" && break 11589 done 11590 11591 else 11592 # If it succeeded, then it was overridden by the user. We will use it 11593 # for the tool. 11594 11595 # First remove it from the list of overridden variables, so we can test 11596 # for unknown variables in the end. 11597 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11598 11599 # Check if we try to supply an empty value 11600 if test "x$TEE" = x; then 11601 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11602 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11604 $as_echo_n "checking for TEE... " >&6; } 11605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11606 $as_echo "disabled" >&6; } 11607 else 11608 # Check if the provided tool contains a complete path. 11609 tool_specified="$TEE" 11610 tool_basename="${tool_specified##*/}" 11611 if test "x$tool_basename" = "x$tool_specified"; then 11612 # A command without a complete path is provided, search $PATH. 11613 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11614 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11615 # Extract the first word of "$tool_basename", so it can be a program name with args. 11616 set dummy $tool_basename; ac_word=$2 11617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11618 $as_echo_n "checking for $ac_word... " >&6; } 11619 if ${ac_cv_path_TEE+:} false; then : 11620 $as_echo_n "(cached) " >&6 11621 else 11622 case $TEE in 11623 [\\/]* | ?:[\\/]*) 11624 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11625 ;; 11626 *) 11627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11628 for as_dir in $PATH 11629 do 11630 IFS=$as_save_IFS 11631 test -z "$as_dir" && as_dir=. 11632 for ac_exec_ext in '' $ac_executable_extensions; do 11633 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11634 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11635 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11636 break 2 11637 fi 11638 done 11639 done 11640 IFS=$as_save_IFS 11641 11642 ;; 11643 esac 11644 fi 11645 TEE=$ac_cv_path_TEE 11646 if test -n "$TEE"; then 11647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11648 $as_echo "$TEE" >&6; } 11649 else 11650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11651 $as_echo "no" >&6; } 11652 fi 11653 11654 11655 if test "x$TEE" = x; then 11656 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11657 fi 11658 else 11659 # Otherwise we believe it is a complete path. Use it as it is. 11660 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11661 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11663 $as_echo_n "checking for TEE... " >&6; } 11664 if test ! -x "$tool_specified"; then 11665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11666 $as_echo "not found" >&6; } 11667 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11668 fi 11669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11670 $as_echo "$tool_specified" >&6; } 11671 fi 11672 fi 11673 fi 11674 11675 fi 11676 11677 11678 11679 if test "x$TEE" = x; then 11680 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11681 fi 11682 11683 11684 11685 11686 11687 # Publish this variable in the help. 11688 11689 11690 if [ -z "${TOUCH+x}" ]; then 11691 # The variable is not set by user, try to locate tool using the code snippet 11692 for ac_prog in touch 11693 do 11694 # Extract the first word of "$ac_prog", so it can be a program name with args. 11695 set dummy $ac_prog; ac_word=$2 11696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11697 $as_echo_n "checking for $ac_word... " >&6; } 11698 if ${ac_cv_path_TOUCH+:} false; then : 11699 $as_echo_n "(cached) " >&6 11700 else 11701 case $TOUCH in 11702 [\\/]* | ?:[\\/]*) 11703 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11704 ;; 11705 *) 11706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11707 for as_dir in $PATH 11708 do 11709 IFS=$as_save_IFS 11710 test -z "$as_dir" && as_dir=. 11711 for ac_exec_ext in '' $ac_executable_extensions; do 11712 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11713 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11714 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11715 break 2 11716 fi 11717 done 11718 done 11719 IFS=$as_save_IFS 11720 11721 ;; 11722 esac 11723 fi 11724 TOUCH=$ac_cv_path_TOUCH 11725 if test -n "$TOUCH"; then 11726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11727 $as_echo "$TOUCH" >&6; } 11728 else 11729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11730 $as_echo "no" >&6; } 11731 fi 11732 11733 11734 test -n "$TOUCH" && break 11735 done 11736 11737 else 11738 # The variable is set, but is it from the command line or the environment? 11739 11740 # Try to remove the string !TOUCH! from our list. 11741 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11742 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11743 # If it failed, the variable was not from the command line. Ignore it, 11744 # but warn the user (except for BASH, which is always set by the calling BASH). 11745 if test "xTOUCH" != xBASH; then 11746 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11747 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11748 fi 11749 # Try to locate tool using the code snippet 11750 for ac_prog in touch 11751 do 11752 # Extract the first word of "$ac_prog", so it can be a program name with args. 11753 set dummy $ac_prog; ac_word=$2 11754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11755 $as_echo_n "checking for $ac_word... " >&6; } 11756 if ${ac_cv_path_TOUCH+:} false; then : 11757 $as_echo_n "(cached) " >&6 11758 else 11759 case $TOUCH in 11760 [\\/]* | ?:[\\/]*) 11761 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11762 ;; 11763 *) 11764 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11765 for as_dir in $PATH 11766 do 11767 IFS=$as_save_IFS 11768 test -z "$as_dir" && as_dir=. 11769 for ac_exec_ext in '' $ac_executable_extensions; do 11770 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11771 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11772 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11773 break 2 11774 fi 11775 done 11776 done 11777 IFS=$as_save_IFS 11778 11779 ;; 11780 esac 11781 fi 11782 TOUCH=$ac_cv_path_TOUCH 11783 if test -n "$TOUCH"; then 11784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11785 $as_echo "$TOUCH" >&6; } 11786 else 11787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11788 $as_echo "no" >&6; } 11789 fi 11790 11791 11792 test -n "$TOUCH" && break 11793 done 11794 11795 else 11796 # If it succeeded, then it was overridden by the user. We will use it 11797 # for the tool. 11798 11799 # First remove it from the list of overridden variables, so we can test 11800 # for unknown variables in the end. 11801 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11802 11803 # Check if we try to supply an empty value 11804 if test "x$TOUCH" = x; then 11805 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11806 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11808 $as_echo_n "checking for TOUCH... " >&6; } 11809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11810 $as_echo "disabled" >&6; } 11811 else 11812 # Check if the provided tool contains a complete path. 11813 tool_specified="$TOUCH" 11814 tool_basename="${tool_specified##*/}" 11815 if test "x$tool_basename" = "x$tool_specified"; then 11816 # A command without a complete path is provided, search $PATH. 11817 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11818 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11819 # Extract the first word of "$tool_basename", so it can be a program name with args. 11820 set dummy $tool_basename; ac_word=$2 11821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11822 $as_echo_n "checking for $ac_word... " >&6; } 11823 if ${ac_cv_path_TOUCH+:} false; then : 11824 $as_echo_n "(cached) " >&6 11825 else 11826 case $TOUCH in 11827 [\\/]* | ?:[\\/]*) 11828 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11829 ;; 11830 *) 11831 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11832 for as_dir in $PATH 11833 do 11834 IFS=$as_save_IFS 11835 test -z "$as_dir" && as_dir=. 11836 for ac_exec_ext in '' $ac_executable_extensions; do 11837 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11838 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11839 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11840 break 2 11841 fi 11842 done 11843 done 11844 IFS=$as_save_IFS 11845 11846 ;; 11847 esac 11848 fi 11849 TOUCH=$ac_cv_path_TOUCH 11850 if test -n "$TOUCH"; then 11851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11852 $as_echo "$TOUCH" >&6; } 11853 else 11854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11855 $as_echo "no" >&6; } 11856 fi 11857 11858 11859 if test "x$TOUCH" = x; then 11860 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11861 fi 11862 else 11863 # Otherwise we believe it is a complete path. Use it as it is. 11864 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11865 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11867 $as_echo_n "checking for TOUCH... " >&6; } 11868 if test ! -x "$tool_specified"; then 11869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11870 $as_echo "not found" >&6; } 11871 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11872 fi 11873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11874 $as_echo "$tool_specified" >&6; } 11875 fi 11876 fi 11877 fi 11878 11879 fi 11880 11881 11882 11883 if test "x$TOUCH" = x; then 11884 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11885 fi 11886 11887 11888 11889 11890 11891 # Publish this variable in the help. 11892 11893 11894 if [ -z "${TR+x}" ]; then 11895 # The variable is not set by user, try to locate tool using the code snippet 11896 for ac_prog in tr 11897 do 11898 # Extract the first word of "$ac_prog", so it can be a program name with args. 11899 set dummy $ac_prog; ac_word=$2 11900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11901 $as_echo_n "checking for $ac_word... " >&6; } 11902 if ${ac_cv_path_TR+:} false; then : 11903 $as_echo_n "(cached) " >&6 11904 else 11905 case $TR in 11906 [\\/]* | ?:[\\/]*) 11907 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11908 ;; 11909 *) 11910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11911 for as_dir in $PATH 11912 do 11913 IFS=$as_save_IFS 11914 test -z "$as_dir" && as_dir=. 11915 for ac_exec_ext in '' $ac_executable_extensions; do 11916 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11917 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11918 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11919 break 2 11920 fi 11921 done 11922 done 11923 IFS=$as_save_IFS 11924 11925 ;; 11926 esac 11927 fi 11928 TR=$ac_cv_path_TR 11929 if test -n "$TR"; then 11930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11931 $as_echo "$TR" >&6; } 11932 else 11933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11934 $as_echo "no" >&6; } 11935 fi 11936 11937 11938 test -n "$TR" && break 11939 done 11940 11941 else 11942 # The variable is set, but is it from the command line or the environment? 11943 11944 # Try to remove the string !TR! from our list. 11945 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 11946 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11947 # If it failed, the variable was not from the command line. Ignore it, 11948 # but warn the user (except for BASH, which is always set by the calling BASH). 11949 if test "xTR" != xBASH; then 11950 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 11951 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 11952 fi 11953 # Try to locate tool using the code snippet 11954 for ac_prog in tr 11955 do 11956 # Extract the first word of "$ac_prog", so it can be a program name with args. 11957 set dummy $ac_prog; ac_word=$2 11958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11959 $as_echo_n "checking for $ac_word... " >&6; } 11960 if ${ac_cv_path_TR+:} false; then : 11961 $as_echo_n "(cached) " >&6 11962 else 11963 case $TR in 11964 [\\/]* | ?:[\\/]*) 11965 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11966 ;; 11967 *) 11968 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11969 for as_dir in $PATH 11970 do 11971 IFS=$as_save_IFS 11972 test -z "$as_dir" && as_dir=. 11973 for ac_exec_ext in '' $ac_executable_extensions; do 11974 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11975 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11976 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11977 break 2 11978 fi 11979 done 11980 done 11981 IFS=$as_save_IFS 11982 11983 ;; 11984 esac 11985 fi 11986 TR=$ac_cv_path_TR 11987 if test -n "$TR"; then 11988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11989 $as_echo "$TR" >&6; } 11990 else 11991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11992 $as_echo "no" >&6; } 11993 fi 11994 11995 11996 test -n "$TR" && break 11997 done 11998 11999 else 12000 # If it succeeded, then it was overridden by the user. We will use it 12001 # for the tool. 12002 12003 # First remove it from the list of overridden variables, so we can test 12004 # for unknown variables in the end. 12005 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12006 12007 # Check if we try to supply an empty value 12008 if test "x$TR" = x; then 12009 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12010 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12012 $as_echo_n "checking for TR... " >&6; } 12013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12014 $as_echo "disabled" >&6; } 12015 else 12016 # Check if the provided tool contains a complete path. 12017 tool_specified="$TR" 12018 tool_basename="${tool_specified##*/}" 12019 if test "x$tool_basename" = "x$tool_specified"; then 12020 # A command without a complete path is provided, search $PATH. 12021 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12022 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12023 # Extract the first word of "$tool_basename", so it can be a program name with args. 12024 set dummy $tool_basename; ac_word=$2 12025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12026 $as_echo_n "checking for $ac_word... " >&6; } 12027 if ${ac_cv_path_TR+:} false; then : 12028 $as_echo_n "(cached) " >&6 12029 else 12030 case $TR in 12031 [\\/]* | ?:[\\/]*) 12032 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12033 ;; 12034 *) 12035 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12036 for as_dir in $PATH 12037 do 12038 IFS=$as_save_IFS 12039 test -z "$as_dir" && as_dir=. 12040 for ac_exec_ext in '' $ac_executable_extensions; do 12041 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12042 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12043 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12044 break 2 12045 fi 12046 done 12047 done 12048 IFS=$as_save_IFS 12049 12050 ;; 12051 esac 12052 fi 12053 TR=$ac_cv_path_TR 12054 if test -n "$TR"; then 12055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12056 $as_echo "$TR" >&6; } 12057 else 12058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12059 $as_echo "no" >&6; } 12060 fi 12061 12062 12063 if test "x$TR" = x; then 12064 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12065 fi 12066 else 12067 # Otherwise we believe it is a complete path. Use it as it is. 12068 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12069 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12071 $as_echo_n "checking for TR... " >&6; } 12072 if test ! -x "$tool_specified"; then 12073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12074 $as_echo "not found" >&6; } 12075 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12076 fi 12077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12078 $as_echo "$tool_specified" >&6; } 12079 fi 12080 fi 12081 fi 12082 12083 fi 12084 12085 12086 12087 if test "x$TR" = x; then 12088 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12089 fi 12090 12091 12092 12093 12094 12095 # Publish this variable in the help. 12096 12097 12098 if [ -z "${UNAME+x}" ]; then 12099 # The variable is not set by user, try to locate tool using the code snippet 12100 for ac_prog in uname 12101 do 12102 # Extract the first word of "$ac_prog", so it can be a program name with args. 12103 set dummy $ac_prog; ac_word=$2 12104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12105 $as_echo_n "checking for $ac_word... " >&6; } 12106 if ${ac_cv_path_UNAME+:} false; then : 12107 $as_echo_n "(cached) " >&6 12108 else 12109 case $UNAME in 12110 [\\/]* | ?:[\\/]*) 12111 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12112 ;; 12113 *) 12114 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12115 for as_dir in $PATH 12116 do 12117 IFS=$as_save_IFS 12118 test -z "$as_dir" && as_dir=. 12119 for ac_exec_ext in '' $ac_executable_extensions; do 12120 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12121 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12122 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12123 break 2 12124 fi 12125 done 12126 done 12127 IFS=$as_save_IFS 12128 12129 ;; 12130 esac 12131 fi 12132 UNAME=$ac_cv_path_UNAME 12133 if test -n "$UNAME"; then 12134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12135 $as_echo "$UNAME" >&6; } 12136 else 12137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12138 $as_echo "no" >&6; } 12139 fi 12140 12141 12142 test -n "$UNAME" && break 12143 done 12144 12145 else 12146 # The variable is set, but is it from the command line or the environment? 12147 12148 # Try to remove the string !UNAME! from our list. 12149 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12150 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12151 # If it failed, the variable was not from the command line. Ignore it, 12152 # but warn the user (except for BASH, which is always set by the calling BASH). 12153 if test "xUNAME" != xBASH; then 12154 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12155 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12156 fi 12157 # Try to locate tool using the code snippet 12158 for ac_prog in uname 12159 do 12160 # Extract the first word of "$ac_prog", so it can be a program name with args. 12161 set dummy $ac_prog; ac_word=$2 12162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12163 $as_echo_n "checking for $ac_word... " >&6; } 12164 if ${ac_cv_path_UNAME+:} false; then : 12165 $as_echo_n "(cached) " >&6 12166 else 12167 case $UNAME in 12168 [\\/]* | ?:[\\/]*) 12169 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12170 ;; 12171 *) 12172 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12173 for as_dir in $PATH 12174 do 12175 IFS=$as_save_IFS 12176 test -z "$as_dir" && as_dir=. 12177 for ac_exec_ext in '' $ac_executable_extensions; do 12178 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12179 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12180 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12181 break 2 12182 fi 12183 done 12184 done 12185 IFS=$as_save_IFS 12186 12187 ;; 12188 esac 12189 fi 12190 UNAME=$ac_cv_path_UNAME 12191 if test -n "$UNAME"; then 12192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12193 $as_echo "$UNAME" >&6; } 12194 else 12195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12196 $as_echo "no" >&6; } 12197 fi 12198 12199 12200 test -n "$UNAME" && break 12201 done 12202 12203 else 12204 # If it succeeded, then it was overridden by the user. We will use it 12205 # for the tool. 12206 12207 # First remove it from the list of overridden variables, so we can test 12208 # for unknown variables in the end. 12209 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12210 12211 # Check if we try to supply an empty value 12212 if test "x$UNAME" = x; then 12213 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12214 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12216 $as_echo_n "checking for UNAME... " >&6; } 12217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12218 $as_echo "disabled" >&6; } 12219 else 12220 # Check if the provided tool contains a complete path. 12221 tool_specified="$UNAME" 12222 tool_basename="${tool_specified##*/}" 12223 if test "x$tool_basename" = "x$tool_specified"; then 12224 # A command without a complete path is provided, search $PATH. 12225 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12226 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12227 # Extract the first word of "$tool_basename", so it can be a program name with args. 12228 set dummy $tool_basename; ac_word=$2 12229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12230 $as_echo_n "checking for $ac_word... " >&6; } 12231 if ${ac_cv_path_UNAME+:} false; then : 12232 $as_echo_n "(cached) " >&6 12233 else 12234 case $UNAME in 12235 [\\/]* | ?:[\\/]*) 12236 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12237 ;; 12238 *) 12239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12240 for as_dir in $PATH 12241 do 12242 IFS=$as_save_IFS 12243 test -z "$as_dir" && as_dir=. 12244 for ac_exec_ext in '' $ac_executable_extensions; do 12245 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12246 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12247 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12248 break 2 12249 fi 12250 done 12251 done 12252 IFS=$as_save_IFS 12253 12254 ;; 12255 esac 12256 fi 12257 UNAME=$ac_cv_path_UNAME 12258 if test -n "$UNAME"; then 12259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12260 $as_echo "$UNAME" >&6; } 12261 else 12262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12263 $as_echo "no" >&6; } 12264 fi 12265 12266 12267 if test "x$UNAME" = x; then 12268 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12269 fi 12270 else 12271 # Otherwise we believe it is a complete path. Use it as it is. 12272 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12273 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12275 $as_echo_n "checking for UNAME... " >&6; } 12276 if test ! -x "$tool_specified"; then 12277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12278 $as_echo "not found" >&6; } 12279 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12280 fi 12281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12282 $as_echo "$tool_specified" >&6; } 12283 fi 12284 fi 12285 fi 12286 12287 fi 12288 12289 12290 12291 if test "x$UNAME" = x; then 12292 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12293 fi 12294 12295 12296 12297 12298 12299 # Publish this variable in the help. 12300 12301 12302 if [ -z "${UNIQ+x}" ]; then 12303 # The variable is not set by user, try to locate tool using the code snippet 12304 for ac_prog in uniq 12305 do 12306 # Extract the first word of "$ac_prog", so it can be a program name with args. 12307 set dummy $ac_prog; ac_word=$2 12308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12309 $as_echo_n "checking for $ac_word... " >&6; } 12310 if ${ac_cv_path_UNIQ+:} false; then : 12311 $as_echo_n "(cached) " >&6 12312 else 12313 case $UNIQ in 12314 [\\/]* | ?:[\\/]*) 12315 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12316 ;; 12317 *) 12318 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12319 for as_dir in $PATH 12320 do 12321 IFS=$as_save_IFS 12322 test -z "$as_dir" && as_dir=. 12323 for ac_exec_ext in '' $ac_executable_extensions; do 12324 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12325 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12326 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12327 break 2 12328 fi 12329 done 12330 done 12331 IFS=$as_save_IFS 12332 12333 ;; 12334 esac 12335 fi 12336 UNIQ=$ac_cv_path_UNIQ 12337 if test -n "$UNIQ"; then 12338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12339 $as_echo "$UNIQ" >&6; } 12340 else 12341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12342 $as_echo "no" >&6; } 12343 fi 12344 12345 12346 test -n "$UNIQ" && break 12347 done 12348 12349 else 12350 # The variable is set, but is it from the command line or the environment? 12351 12352 # Try to remove the string !UNIQ! from our list. 12353 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12354 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12355 # If it failed, the variable was not from the command line. Ignore it, 12356 # but warn the user (except for BASH, which is always set by the calling BASH). 12357 if test "xUNIQ" != xBASH; then 12358 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12359 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12360 fi 12361 # Try to locate tool using the code snippet 12362 for ac_prog in uniq 12363 do 12364 # Extract the first word of "$ac_prog", so it can be a program name with args. 12365 set dummy $ac_prog; ac_word=$2 12366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12367 $as_echo_n "checking for $ac_word... " >&6; } 12368 if ${ac_cv_path_UNIQ+:} false; then : 12369 $as_echo_n "(cached) " >&6 12370 else 12371 case $UNIQ in 12372 [\\/]* | ?:[\\/]*) 12373 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12374 ;; 12375 *) 12376 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12377 for as_dir in $PATH 12378 do 12379 IFS=$as_save_IFS 12380 test -z "$as_dir" && as_dir=. 12381 for ac_exec_ext in '' $ac_executable_extensions; do 12382 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12383 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12384 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12385 break 2 12386 fi 12387 done 12388 done 12389 IFS=$as_save_IFS 12390 12391 ;; 12392 esac 12393 fi 12394 UNIQ=$ac_cv_path_UNIQ 12395 if test -n "$UNIQ"; then 12396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12397 $as_echo "$UNIQ" >&6; } 12398 else 12399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12400 $as_echo "no" >&6; } 12401 fi 12402 12403 12404 test -n "$UNIQ" && break 12405 done 12406 12407 else 12408 # If it succeeded, then it was overridden by the user. We will use it 12409 # for the tool. 12410 12411 # First remove it from the list of overridden variables, so we can test 12412 # for unknown variables in the end. 12413 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12414 12415 # Check if we try to supply an empty value 12416 if test "x$UNIQ" = x; then 12417 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12418 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12420 $as_echo_n "checking for UNIQ... " >&6; } 12421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12422 $as_echo "disabled" >&6; } 12423 else 12424 # Check if the provided tool contains a complete path. 12425 tool_specified="$UNIQ" 12426 tool_basename="${tool_specified##*/}" 12427 if test "x$tool_basename" = "x$tool_specified"; then 12428 # A command without a complete path is provided, search $PATH. 12429 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12430 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12431 # Extract the first word of "$tool_basename", so it can be a program name with args. 12432 set dummy $tool_basename; ac_word=$2 12433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12434 $as_echo_n "checking for $ac_word... " >&6; } 12435 if ${ac_cv_path_UNIQ+:} false; then : 12436 $as_echo_n "(cached) " >&6 12437 else 12438 case $UNIQ in 12439 [\\/]* | ?:[\\/]*) 12440 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12441 ;; 12442 *) 12443 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12444 for as_dir in $PATH 12445 do 12446 IFS=$as_save_IFS 12447 test -z "$as_dir" && as_dir=. 12448 for ac_exec_ext in '' $ac_executable_extensions; do 12449 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12450 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12451 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12452 break 2 12453 fi 12454 done 12455 done 12456 IFS=$as_save_IFS 12457 12458 ;; 12459 esac 12460 fi 12461 UNIQ=$ac_cv_path_UNIQ 12462 if test -n "$UNIQ"; then 12463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12464 $as_echo "$UNIQ" >&6; } 12465 else 12466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12467 $as_echo "no" >&6; } 12468 fi 12469 12470 12471 if test "x$UNIQ" = x; then 12472 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12473 fi 12474 else 12475 # Otherwise we believe it is a complete path. Use it as it is. 12476 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12477 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12479 $as_echo_n "checking for UNIQ... " >&6; } 12480 if test ! -x "$tool_specified"; then 12481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12482 $as_echo "not found" >&6; } 12483 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12484 fi 12485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12486 $as_echo "$tool_specified" >&6; } 12487 fi 12488 fi 12489 fi 12490 12491 fi 12492 12493 12494 12495 if test "x$UNIQ" = x; then 12496 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12497 fi 12498 12499 12500 12501 12502 12503 # Publish this variable in the help. 12504 12505 12506 if [ -z "${WC+x}" ]; then 12507 # The variable is not set by user, try to locate tool using the code snippet 12508 for ac_prog in wc 12509 do 12510 # Extract the first word of "$ac_prog", so it can be a program name with args. 12511 set dummy $ac_prog; ac_word=$2 12512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12513 $as_echo_n "checking for $ac_word... " >&6; } 12514 if ${ac_cv_path_WC+:} false; then : 12515 $as_echo_n "(cached) " >&6 12516 else 12517 case $WC in 12518 [\\/]* | ?:[\\/]*) 12519 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12520 ;; 12521 *) 12522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12523 for as_dir in $PATH 12524 do 12525 IFS=$as_save_IFS 12526 test -z "$as_dir" && as_dir=. 12527 for ac_exec_ext in '' $ac_executable_extensions; do 12528 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12529 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12531 break 2 12532 fi 12533 done 12534 done 12535 IFS=$as_save_IFS 12536 12537 ;; 12538 esac 12539 fi 12540 WC=$ac_cv_path_WC 12541 if test -n "$WC"; then 12542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12543 $as_echo "$WC" >&6; } 12544 else 12545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12546 $as_echo "no" >&6; } 12547 fi 12548 12549 12550 test -n "$WC" && break 12551 done 12552 12553 else 12554 # The variable is set, but is it from the command line or the environment? 12555 12556 # Try to remove the string !WC! from our list. 12557 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12558 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12559 # If it failed, the variable was not from the command line. Ignore it, 12560 # but warn the user (except for BASH, which is always set by the calling BASH). 12561 if test "xWC" != xBASH; then 12562 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12563 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12564 fi 12565 # Try to locate tool using the code snippet 12566 for ac_prog in wc 12567 do 12568 # Extract the first word of "$ac_prog", so it can be a program name with args. 12569 set dummy $ac_prog; ac_word=$2 12570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12571 $as_echo_n "checking for $ac_word... " >&6; } 12572 if ${ac_cv_path_WC+:} false; then : 12573 $as_echo_n "(cached) " >&6 12574 else 12575 case $WC in 12576 [\\/]* | ?:[\\/]*) 12577 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12578 ;; 12579 *) 12580 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12581 for as_dir in $PATH 12582 do 12583 IFS=$as_save_IFS 12584 test -z "$as_dir" && as_dir=. 12585 for ac_exec_ext in '' $ac_executable_extensions; do 12586 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12587 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12588 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12589 break 2 12590 fi 12591 done 12592 done 12593 IFS=$as_save_IFS 12594 12595 ;; 12596 esac 12597 fi 12598 WC=$ac_cv_path_WC 12599 if test -n "$WC"; then 12600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12601 $as_echo "$WC" >&6; } 12602 else 12603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12604 $as_echo "no" >&6; } 12605 fi 12606 12607 12608 test -n "$WC" && break 12609 done 12610 12611 else 12612 # If it succeeded, then it was overridden by the user. We will use it 12613 # for the tool. 12614 12615 # First remove it from the list of overridden variables, so we can test 12616 # for unknown variables in the end. 12617 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12618 12619 # Check if we try to supply an empty value 12620 if test "x$WC" = x; then 12621 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12622 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12624 $as_echo_n "checking for WC... " >&6; } 12625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12626 $as_echo "disabled" >&6; } 12627 else 12628 # Check if the provided tool contains a complete path. 12629 tool_specified="$WC" 12630 tool_basename="${tool_specified##*/}" 12631 if test "x$tool_basename" = "x$tool_specified"; then 12632 # A command without a complete path is provided, search $PATH. 12633 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12634 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12635 # Extract the first word of "$tool_basename", so it can be a program name with args. 12636 set dummy $tool_basename; ac_word=$2 12637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12638 $as_echo_n "checking for $ac_word... " >&6; } 12639 if ${ac_cv_path_WC+:} false; then : 12640 $as_echo_n "(cached) " >&6 12641 else 12642 case $WC in 12643 [\\/]* | ?:[\\/]*) 12644 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12645 ;; 12646 *) 12647 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12648 for as_dir in $PATH 12649 do 12650 IFS=$as_save_IFS 12651 test -z "$as_dir" && as_dir=. 12652 for ac_exec_ext in '' $ac_executable_extensions; do 12653 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12654 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12655 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12656 break 2 12657 fi 12658 done 12659 done 12660 IFS=$as_save_IFS 12661 12662 ;; 12663 esac 12664 fi 12665 WC=$ac_cv_path_WC 12666 if test -n "$WC"; then 12667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12668 $as_echo "$WC" >&6; } 12669 else 12670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12671 $as_echo "no" >&6; } 12672 fi 12673 12674 12675 if test "x$WC" = x; then 12676 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12677 fi 12678 else 12679 # Otherwise we believe it is a complete path. Use it as it is. 12680 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12681 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12683 $as_echo_n "checking for WC... " >&6; } 12684 if test ! -x "$tool_specified"; then 12685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12686 $as_echo "not found" >&6; } 12687 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12688 fi 12689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12690 $as_echo "$tool_specified" >&6; } 12691 fi 12692 fi 12693 fi 12694 12695 fi 12696 12697 12698 12699 if test "x$WC" = x; then 12700 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12701 fi 12702 12703 12704 12705 12706 12707 # Publish this variable in the help. 12708 12709 12710 if [ -z "${WHICH+x}" ]; then 12711 # The variable is not set by user, try to locate tool using the code snippet 12712 for ac_prog in which 12713 do 12714 # Extract the first word of "$ac_prog", so it can be a program name with args. 12715 set dummy $ac_prog; ac_word=$2 12716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12717 $as_echo_n "checking for $ac_word... " >&6; } 12718 if ${ac_cv_path_WHICH+:} false; then : 12719 $as_echo_n "(cached) " >&6 12720 else 12721 case $WHICH in 12722 [\\/]* | ?:[\\/]*) 12723 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12724 ;; 12725 *) 12726 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12727 for as_dir in $PATH 12728 do 12729 IFS=$as_save_IFS 12730 test -z "$as_dir" && as_dir=. 12731 for ac_exec_ext in '' $ac_executable_extensions; do 12732 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12733 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12734 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12735 break 2 12736 fi 12737 done 12738 done 12739 IFS=$as_save_IFS 12740 12741 ;; 12742 esac 12743 fi 12744 WHICH=$ac_cv_path_WHICH 12745 if test -n "$WHICH"; then 12746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12747 $as_echo "$WHICH" >&6; } 12748 else 12749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12750 $as_echo "no" >&6; } 12751 fi 12752 12753 12754 test -n "$WHICH" && break 12755 done 12756 12757 else 12758 # The variable is set, but is it from the command line or the environment? 12759 12760 # Try to remove the string !WHICH! from our list. 12761 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12762 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12763 # If it failed, the variable was not from the command line. Ignore it, 12764 # but warn the user (except for BASH, which is always set by the calling BASH). 12765 if test "xWHICH" != xBASH; then 12766 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12767 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12768 fi 12769 # Try to locate tool using the code snippet 12770 for ac_prog in which 12771 do 12772 # Extract the first word of "$ac_prog", so it can be a program name with args. 12773 set dummy $ac_prog; ac_word=$2 12774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12775 $as_echo_n "checking for $ac_word... " >&6; } 12776 if ${ac_cv_path_WHICH+:} false; then : 12777 $as_echo_n "(cached) " >&6 12778 else 12779 case $WHICH in 12780 [\\/]* | ?:[\\/]*) 12781 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12782 ;; 12783 *) 12784 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12785 for as_dir in $PATH 12786 do 12787 IFS=$as_save_IFS 12788 test -z "$as_dir" && as_dir=. 12789 for ac_exec_ext in '' $ac_executable_extensions; do 12790 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12791 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12792 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12793 break 2 12794 fi 12795 done 12796 done 12797 IFS=$as_save_IFS 12798 12799 ;; 12800 esac 12801 fi 12802 WHICH=$ac_cv_path_WHICH 12803 if test -n "$WHICH"; then 12804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12805 $as_echo "$WHICH" >&6; } 12806 else 12807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12808 $as_echo "no" >&6; } 12809 fi 12810 12811 12812 test -n "$WHICH" && break 12813 done 12814 12815 else 12816 # If it succeeded, then it was overridden by the user. We will use it 12817 # for the tool. 12818 12819 # First remove it from the list of overridden variables, so we can test 12820 # for unknown variables in the end. 12821 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12822 12823 # Check if we try to supply an empty value 12824 if test "x$WHICH" = x; then 12825 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12826 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12828 $as_echo_n "checking for WHICH... " >&6; } 12829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12830 $as_echo "disabled" >&6; } 12831 else 12832 # Check if the provided tool contains a complete path. 12833 tool_specified="$WHICH" 12834 tool_basename="${tool_specified##*/}" 12835 if test "x$tool_basename" = "x$tool_specified"; then 12836 # A command without a complete path is provided, search $PATH. 12837 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12838 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12839 # Extract the first word of "$tool_basename", so it can be a program name with args. 12840 set dummy $tool_basename; ac_word=$2 12841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12842 $as_echo_n "checking for $ac_word... " >&6; } 12843 if ${ac_cv_path_WHICH+:} false; then : 12844 $as_echo_n "(cached) " >&6 12845 else 12846 case $WHICH in 12847 [\\/]* | ?:[\\/]*) 12848 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12849 ;; 12850 *) 12851 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12852 for as_dir in $PATH 12853 do 12854 IFS=$as_save_IFS 12855 test -z "$as_dir" && as_dir=. 12856 for ac_exec_ext in '' $ac_executable_extensions; do 12857 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12858 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12859 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12860 break 2 12861 fi 12862 done 12863 done 12864 IFS=$as_save_IFS 12865 12866 ;; 12867 esac 12868 fi 12869 WHICH=$ac_cv_path_WHICH 12870 if test -n "$WHICH"; then 12871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12872 $as_echo "$WHICH" >&6; } 12873 else 12874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12875 $as_echo "no" >&6; } 12876 fi 12877 12878 12879 if test "x$WHICH" = x; then 12880 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12881 fi 12882 else 12883 # Otherwise we believe it is a complete path. Use it as it is. 12884 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12885 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12887 $as_echo_n "checking for WHICH... " >&6; } 12888 if test ! -x "$tool_specified"; then 12889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12890 $as_echo "not found" >&6; } 12891 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12892 fi 12893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12894 $as_echo "$tool_specified" >&6; } 12895 fi 12896 fi 12897 fi 12898 12899 fi 12900 12901 12902 12903 if test "x$WHICH" = x; then 12904 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12905 fi 12906 12907 12908 12909 12910 12911 # Publish this variable in the help. 12912 12913 12914 if [ -z "${XARGS+x}" ]; then 12915 # The variable is not set by user, try to locate tool using the code snippet 12916 for ac_prog in xargs 12917 do 12918 # Extract the first word of "$ac_prog", so it can be a program name with args. 12919 set dummy $ac_prog; ac_word=$2 12920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12921 $as_echo_n "checking for $ac_word... " >&6; } 12922 if ${ac_cv_path_XARGS+:} false; then : 12923 $as_echo_n "(cached) " >&6 12924 else 12925 case $XARGS in 12926 [\\/]* | ?:[\\/]*) 12927 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12928 ;; 12929 *) 12930 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12931 for as_dir in $PATH 12932 do 12933 IFS=$as_save_IFS 12934 test -z "$as_dir" && as_dir=. 12935 for ac_exec_ext in '' $ac_executable_extensions; do 12936 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12937 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12938 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12939 break 2 12940 fi 12941 done 12942 done 12943 IFS=$as_save_IFS 12944 12945 ;; 12946 esac 12947 fi 12948 XARGS=$ac_cv_path_XARGS 12949 if test -n "$XARGS"; then 12950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12951 $as_echo "$XARGS" >&6; } 12952 else 12953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12954 $as_echo "no" >&6; } 12955 fi 12956 12957 12958 test -n "$XARGS" && break 12959 done 12960 12961 else 12962 # The variable is set, but is it from the command line or the environment? 12963 12964 # Try to remove the string !XARGS! from our list. 12965 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 12966 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12967 # If it failed, the variable was not from the command line. Ignore it, 12968 # but warn the user (except for BASH, which is always set by the calling BASH). 12969 if test "xXARGS" != xBASH; then 12970 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 12971 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 12972 fi 12973 # Try to locate tool using the code snippet 12974 for ac_prog in xargs 12975 do 12976 # Extract the first word of "$ac_prog", so it can be a program name with args. 12977 set dummy $ac_prog; ac_word=$2 12978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12979 $as_echo_n "checking for $ac_word... " >&6; } 12980 if ${ac_cv_path_XARGS+:} false; then : 12981 $as_echo_n "(cached) " >&6 12982 else 12983 case $XARGS in 12984 [\\/]* | ?:[\\/]*) 12985 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12986 ;; 12987 *) 12988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12989 for as_dir in $PATH 12990 do 12991 IFS=$as_save_IFS 12992 test -z "$as_dir" && as_dir=. 12993 for ac_exec_ext in '' $ac_executable_extensions; do 12994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12995 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12997 break 2 12998 fi 12999 done 13000 done 13001 IFS=$as_save_IFS 13002 13003 ;; 13004 esac 13005 fi 13006 XARGS=$ac_cv_path_XARGS 13007 if test -n "$XARGS"; then 13008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13009 $as_echo "$XARGS" >&6; } 13010 else 13011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13012 $as_echo "no" >&6; } 13013 fi 13014 13015 13016 test -n "$XARGS" && break 13017 done 13018 13019 else 13020 # If it succeeded, then it was overridden by the user. We will use it 13021 # for the tool. 13022 13023 # First remove it from the list of overridden variables, so we can test 13024 # for unknown variables in the end. 13025 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13026 13027 # Check if we try to supply an empty value 13028 if test "x$XARGS" = x; then 13029 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13030 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13032 $as_echo_n "checking for XARGS... " >&6; } 13033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13034 $as_echo "disabled" >&6; } 13035 else 13036 # Check if the provided tool contains a complete path. 13037 tool_specified="$XARGS" 13038 tool_basename="${tool_specified##*/}" 13039 if test "x$tool_basename" = "x$tool_specified"; then 13040 # A command without a complete path is provided, search $PATH. 13041 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13042 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13043 # Extract the first word of "$tool_basename", so it can be a program name with args. 13044 set dummy $tool_basename; ac_word=$2 13045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13046 $as_echo_n "checking for $ac_word... " >&6; } 13047 if ${ac_cv_path_XARGS+:} false; then : 13048 $as_echo_n "(cached) " >&6 13049 else 13050 case $XARGS in 13051 [\\/]* | ?:[\\/]*) 13052 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13053 ;; 13054 *) 13055 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13056 for as_dir in $PATH 13057 do 13058 IFS=$as_save_IFS 13059 test -z "$as_dir" && as_dir=. 13060 for ac_exec_ext in '' $ac_executable_extensions; do 13061 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13062 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13063 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13064 break 2 13065 fi 13066 done 13067 done 13068 IFS=$as_save_IFS 13069 13070 ;; 13071 esac 13072 fi 13073 XARGS=$ac_cv_path_XARGS 13074 if test -n "$XARGS"; then 13075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13076 $as_echo "$XARGS" >&6; } 13077 else 13078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13079 $as_echo "no" >&6; } 13080 fi 13081 13082 13083 if test "x$XARGS" = x; then 13084 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13085 fi 13086 else 13087 # Otherwise we believe it is a complete path. Use it as it is. 13088 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13089 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13091 $as_echo_n "checking for XARGS... " >&6; } 13092 if test ! -x "$tool_specified"; then 13093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13094 $as_echo "not found" >&6; } 13095 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13096 fi 13097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13098 $as_echo "$tool_specified" >&6; } 13099 fi 13100 fi 13101 fi 13102 13103 fi 13104 13105 13106 13107 if test "x$XARGS" = x; then 13108 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13109 fi 13110 13111 13112 13113 # Then required tools that require some special treatment. 13114 13115 13116 # Publish this variable in the help. 13117 13118 13119 if [ -z "${AWK+x}" ]; then 13120 # The variable is not set by user, try to locate tool using the code snippet 13121 for ac_prog in gawk mawk nawk awk 13122 do 13123 # Extract the first word of "$ac_prog", so it can be a program name with args. 13124 set dummy $ac_prog; ac_word=$2 13125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13126 $as_echo_n "checking for $ac_word... " >&6; } 13127 if ${ac_cv_prog_AWK+:} false; then : 13128 $as_echo_n "(cached) " >&6 13129 else 13130 if test -n "$AWK"; then 13131 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13132 else 13133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13134 for as_dir in $PATH 13135 do 13136 IFS=$as_save_IFS 13137 test -z "$as_dir" && as_dir=. 13138 for ac_exec_ext in '' $ac_executable_extensions; do 13139 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13140 ac_cv_prog_AWK="$ac_prog" 13141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13142 break 2 13143 fi 13144 done 13145 done 13146 IFS=$as_save_IFS 13147 13148 fi 13149 fi 13150 AWK=$ac_cv_prog_AWK 13151 if test -n "$AWK"; then 13152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13153 $as_echo "$AWK" >&6; } 13154 else 13155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13156 $as_echo "no" >&6; } 13157 fi 13158 13159 13160 test -n "$AWK" && break 13161 done 13162 13163 else 13164 # The variable is set, but is it from the command line or the environment? 13165 13166 # Try to remove the string !AWK! from our list. 13167 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13168 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13169 # If it failed, the variable was not from the command line. Ignore it, 13170 # but warn the user (except for BASH, which is always set by the calling BASH). 13171 if test "xAWK" != xBASH; then 13172 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13173 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13174 fi 13175 # Try to locate tool using the code snippet 13176 for ac_prog in gawk mawk nawk awk 13177 do 13178 # Extract the first word of "$ac_prog", so it can be a program name with args. 13179 set dummy $ac_prog; ac_word=$2 13180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13181 $as_echo_n "checking for $ac_word... " >&6; } 13182 if ${ac_cv_prog_AWK+:} false; then : 13183 $as_echo_n "(cached) " >&6 13184 else 13185 if test -n "$AWK"; then 13186 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13187 else 13188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13189 for as_dir in $PATH 13190 do 13191 IFS=$as_save_IFS 13192 test -z "$as_dir" && as_dir=. 13193 for ac_exec_ext in '' $ac_executable_extensions; do 13194 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13195 ac_cv_prog_AWK="$ac_prog" 13196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13197 break 2 13198 fi 13199 done 13200 done 13201 IFS=$as_save_IFS 13202 13203 fi 13204 fi 13205 AWK=$ac_cv_prog_AWK 13206 if test -n "$AWK"; then 13207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13208 $as_echo "$AWK" >&6; } 13209 else 13210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13211 $as_echo "no" >&6; } 13212 fi 13213 13214 13215 test -n "$AWK" && break 13216 done 13217 13218 else 13219 # If it succeeded, then it was overridden by the user. We will use it 13220 # for the tool. 13221 13222 # First remove it from the list of overridden variables, so we can test 13223 # for unknown variables in the end. 13224 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13225 13226 # Check if we try to supply an empty value 13227 if test "x$AWK" = x; then 13228 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13229 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13231 $as_echo_n "checking for AWK... " >&6; } 13232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13233 $as_echo "disabled" >&6; } 13234 else 13235 # Check if the provided tool contains a complete path. 13236 tool_specified="$AWK" 13237 tool_basename="${tool_specified##*/}" 13238 if test "x$tool_basename" = "x$tool_specified"; then 13239 # A command without a complete path is provided, search $PATH. 13240 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13241 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13242 # Extract the first word of "$tool_basename", so it can be a program name with args. 13243 set dummy $tool_basename; ac_word=$2 13244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13245 $as_echo_n "checking for $ac_word... " >&6; } 13246 if ${ac_cv_path_AWK+:} false; then : 13247 $as_echo_n "(cached) " >&6 13248 else 13249 case $AWK in 13250 [\\/]* | ?:[\\/]*) 13251 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13252 ;; 13253 *) 13254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13255 for as_dir in $PATH 13256 do 13257 IFS=$as_save_IFS 13258 test -z "$as_dir" && as_dir=. 13259 for ac_exec_ext in '' $ac_executable_extensions; do 13260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13261 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13263 break 2 13264 fi 13265 done 13266 done 13267 IFS=$as_save_IFS 13268 13269 ;; 13270 esac 13271 fi 13272 AWK=$ac_cv_path_AWK 13273 if test -n "$AWK"; then 13274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13275 $as_echo "$AWK" >&6; } 13276 else 13277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13278 $as_echo "no" >&6; } 13279 fi 13280 13281 13282 if test "x$AWK" = x; then 13283 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13284 fi 13285 else 13286 # Otherwise we believe it is a complete path. Use it as it is. 13287 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13288 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13290 $as_echo_n "checking for AWK... " >&6; } 13291 if test ! -x "$tool_specified"; then 13292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13293 $as_echo "not found" >&6; } 13294 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13295 fi 13296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13297 $as_echo "$tool_specified" >&6; } 13298 fi 13299 fi 13300 fi 13301 13302 fi 13303 13304 13305 if test "x$AWK" = x; then 13306 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13307 fi 13308 13309 13310 13311 13312 # Publish this variable in the help. 13313 13314 13315 if [ -z "${GREP+x}" ]; then 13316 # The variable is not set by user, try to locate tool using the code snippet 13317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13318 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13319 if ${ac_cv_path_GREP+:} false; then : 13320 $as_echo_n "(cached) " >&6 13321 else 13322 if test -z "$GREP"; then 13323 ac_path_GREP_found=false 13324 # Loop through the user's path and test for each of PROGNAME-LIST 13325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13326 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13327 do 13328 IFS=$as_save_IFS 13329 test -z "$as_dir" && as_dir=. 13330 for ac_prog in grep ggrep; do 13331 for ac_exec_ext in '' $ac_executable_extensions; do 13332 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13333 as_fn_executable_p "$ac_path_GREP" || continue 13334 # Check for GNU ac_path_GREP and select it if it is found. 13335 # Check for GNU $ac_path_GREP 13336 case `"$ac_path_GREP" --version 2>&1` in 13337 *GNU*) 13338 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13339 *) 13340 ac_count=0 13341 $as_echo_n 0123456789 >"conftest.in" 13342 while : 13343 do 13344 cat "conftest.in" "conftest.in" >"conftest.tmp" 13345 mv "conftest.tmp" "conftest.in" 13346 cp "conftest.in" "conftest.nl" 13347 $as_echo 'GREP' >> "conftest.nl" 13348 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13349 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13350 as_fn_arith $ac_count + 1 && ac_count=$as_val 13351 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13352 # Best one so far, save it but keep looking for a better one 13353 ac_cv_path_GREP="$ac_path_GREP" 13354 ac_path_GREP_max=$ac_count 13355 fi 13356 # 10*(2^10) chars as input seems more than enough 13357 test $ac_count -gt 10 && break 13358 done 13359 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13360 esac 13361 13362 $ac_path_GREP_found && break 3 13363 done 13364 done 13365 done 13366 IFS=$as_save_IFS 13367 if test -z "$ac_cv_path_GREP"; then 13368 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13369 fi 13370 else 13371 ac_cv_path_GREP=$GREP 13372 fi 13373 13374 fi 13375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13376 $as_echo "$ac_cv_path_GREP" >&6; } 13377 GREP="$ac_cv_path_GREP" 13378 13379 13380 else 13381 # The variable is set, but is it from the command line or the environment? 13382 13383 # Try to remove the string !GREP! from our list. 13384 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13385 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13386 # If it failed, the variable was not from the command line. Ignore it, 13387 # but warn the user (except for BASH, which is always set by the calling BASH). 13388 if test "xGREP" != xBASH; then 13389 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13390 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13391 fi 13392 # Try to locate tool using the code snippet 13393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13394 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13395 if ${ac_cv_path_GREP+:} false; then : 13396 $as_echo_n "(cached) " >&6 13397 else 13398 if test -z "$GREP"; then 13399 ac_path_GREP_found=false 13400 # Loop through the user's path and test for each of PROGNAME-LIST 13401 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13402 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13403 do 13404 IFS=$as_save_IFS 13405 test -z "$as_dir" && as_dir=. 13406 for ac_prog in grep ggrep; do 13407 for ac_exec_ext in '' $ac_executable_extensions; do 13408 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13409 as_fn_executable_p "$ac_path_GREP" || continue 13410 # Check for GNU ac_path_GREP and select it if it is found. 13411 # Check for GNU $ac_path_GREP 13412 case `"$ac_path_GREP" --version 2>&1` in 13413 *GNU*) 13414 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13415 *) 13416 ac_count=0 13417 $as_echo_n 0123456789 >"conftest.in" 13418 while : 13419 do 13420 cat "conftest.in" "conftest.in" >"conftest.tmp" 13421 mv "conftest.tmp" "conftest.in" 13422 cp "conftest.in" "conftest.nl" 13423 $as_echo 'GREP' >> "conftest.nl" 13424 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13425 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13426 as_fn_arith $ac_count + 1 && ac_count=$as_val 13427 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13428 # Best one so far, save it but keep looking for a better one 13429 ac_cv_path_GREP="$ac_path_GREP" 13430 ac_path_GREP_max=$ac_count 13431 fi 13432 # 10*(2^10) chars as input seems more than enough 13433 test $ac_count -gt 10 && break 13434 done 13435 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13436 esac 13437 13438 $ac_path_GREP_found && break 3 13439 done 13440 done 13441 done 13442 IFS=$as_save_IFS 13443 if test -z "$ac_cv_path_GREP"; then 13444 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13445 fi 13446 else 13447 ac_cv_path_GREP=$GREP 13448 fi 13449 13450 fi 13451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13452 $as_echo "$ac_cv_path_GREP" >&6; } 13453 GREP="$ac_cv_path_GREP" 13454 13455 13456 else 13457 # If it succeeded, then it was overridden by the user. We will use it 13458 # for the tool. 13459 13460 # First remove it from the list of overridden variables, so we can test 13461 # for unknown variables in the end. 13462 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13463 13464 # Check if we try to supply an empty value 13465 if test "x$GREP" = x; then 13466 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13467 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13469 $as_echo_n "checking for GREP... " >&6; } 13470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13471 $as_echo "disabled" >&6; } 13472 else 13473 # Check if the provided tool contains a complete path. 13474 tool_specified="$GREP" 13475 tool_basename="${tool_specified##*/}" 13476 if test "x$tool_basename" = "x$tool_specified"; then 13477 # A command without a complete path is provided, search $PATH. 13478 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13479 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13480 # Extract the first word of "$tool_basename", so it can be a program name with args. 13481 set dummy $tool_basename; ac_word=$2 13482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13483 $as_echo_n "checking for $ac_word... " >&6; } 13484 if ${ac_cv_path_GREP+:} false; then : 13485 $as_echo_n "(cached) " >&6 13486 else 13487 case $GREP in 13488 [\\/]* | ?:[\\/]*) 13489 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13490 ;; 13491 *) 13492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13493 for as_dir in $PATH 13494 do 13495 IFS=$as_save_IFS 13496 test -z "$as_dir" && as_dir=. 13497 for ac_exec_ext in '' $ac_executable_extensions; do 13498 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13499 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13500 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13501 break 2 13502 fi 13503 done 13504 done 13505 IFS=$as_save_IFS 13506 13507 ;; 13508 esac 13509 fi 13510 GREP=$ac_cv_path_GREP 13511 if test -n "$GREP"; then 13512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13513 $as_echo "$GREP" >&6; } 13514 else 13515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13516 $as_echo "no" >&6; } 13517 fi 13518 13519 13520 if test "x$GREP" = x; then 13521 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13522 fi 13523 else 13524 # Otherwise we believe it is a complete path. Use it as it is. 13525 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13526 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13528 $as_echo_n "checking for GREP... " >&6; } 13529 if test ! -x "$tool_specified"; then 13530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13531 $as_echo "not found" >&6; } 13532 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13533 fi 13534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13535 $as_echo "$tool_specified" >&6; } 13536 fi 13537 fi 13538 fi 13539 13540 fi 13541 13542 13543 if test "x$GREP" = x; then 13544 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13545 fi 13546 13547 13548 13549 13550 # Publish this variable in the help. 13551 13552 13553 if [ -z "${EGREP+x}" ]; then 13554 # The variable is not set by user, try to locate tool using the code snippet 13555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13556 $as_echo_n "checking for egrep... " >&6; } 13557 if ${ac_cv_path_EGREP+:} false; then : 13558 $as_echo_n "(cached) " >&6 13559 else 13560 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13561 then ac_cv_path_EGREP="$GREP -E" 13562 else 13563 if test -z "$EGREP"; then 13564 ac_path_EGREP_found=false 13565 # Loop through the user's path and test for each of PROGNAME-LIST 13566 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13567 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13568 do 13569 IFS=$as_save_IFS 13570 test -z "$as_dir" && as_dir=. 13571 for ac_prog in egrep; do 13572 for ac_exec_ext in '' $ac_executable_extensions; do 13573 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13574 as_fn_executable_p "$ac_path_EGREP" || continue 13575 # Check for GNU ac_path_EGREP and select it if it is found. 13576 # Check for GNU $ac_path_EGREP 13577 case `"$ac_path_EGREP" --version 2>&1` in 13578 *GNU*) 13579 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13580 *) 13581 ac_count=0 13582 $as_echo_n 0123456789 >"conftest.in" 13583 while : 13584 do 13585 cat "conftest.in" "conftest.in" >"conftest.tmp" 13586 mv "conftest.tmp" "conftest.in" 13587 cp "conftest.in" "conftest.nl" 13588 $as_echo 'EGREP' >> "conftest.nl" 13589 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13590 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13591 as_fn_arith $ac_count + 1 && ac_count=$as_val 13592 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13593 # Best one so far, save it but keep looking for a better one 13594 ac_cv_path_EGREP="$ac_path_EGREP" 13595 ac_path_EGREP_max=$ac_count 13596 fi 13597 # 10*(2^10) chars as input seems more than enough 13598 test $ac_count -gt 10 && break 13599 done 13600 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13601 esac 13602 13603 $ac_path_EGREP_found && break 3 13604 done 13605 done 13606 done 13607 IFS=$as_save_IFS 13608 if test -z "$ac_cv_path_EGREP"; then 13609 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13610 fi 13611 else 13612 ac_cv_path_EGREP=$EGREP 13613 fi 13614 13615 fi 13616 fi 13617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13618 $as_echo "$ac_cv_path_EGREP" >&6; } 13619 EGREP="$ac_cv_path_EGREP" 13620 13621 13622 else 13623 # The variable is set, but is it from the command line or the environment? 13624 13625 # Try to remove the string !EGREP! from our list. 13626 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13627 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13628 # If it failed, the variable was not from the command line. Ignore it, 13629 # but warn the user (except for BASH, which is always set by the calling BASH). 13630 if test "xEGREP" != xBASH; then 13631 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13632 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13633 fi 13634 # Try to locate tool using the code snippet 13635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13636 $as_echo_n "checking for egrep... " >&6; } 13637 if ${ac_cv_path_EGREP+:} false; then : 13638 $as_echo_n "(cached) " >&6 13639 else 13640 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13641 then ac_cv_path_EGREP="$GREP -E" 13642 else 13643 if test -z "$EGREP"; then 13644 ac_path_EGREP_found=false 13645 # Loop through the user's path and test for each of PROGNAME-LIST 13646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13647 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13648 do 13649 IFS=$as_save_IFS 13650 test -z "$as_dir" && as_dir=. 13651 for ac_prog in egrep; do 13652 for ac_exec_ext in '' $ac_executable_extensions; do 13653 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13654 as_fn_executable_p "$ac_path_EGREP" || continue 13655 # Check for GNU ac_path_EGREP and select it if it is found. 13656 # Check for GNU $ac_path_EGREP 13657 case `"$ac_path_EGREP" --version 2>&1` in 13658 *GNU*) 13659 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13660 *) 13661 ac_count=0 13662 $as_echo_n 0123456789 >"conftest.in" 13663 while : 13664 do 13665 cat "conftest.in" "conftest.in" >"conftest.tmp" 13666 mv "conftest.tmp" "conftest.in" 13667 cp "conftest.in" "conftest.nl" 13668 $as_echo 'EGREP' >> "conftest.nl" 13669 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13670 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13671 as_fn_arith $ac_count + 1 && ac_count=$as_val 13672 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13673 # Best one so far, save it but keep looking for a better one 13674 ac_cv_path_EGREP="$ac_path_EGREP" 13675 ac_path_EGREP_max=$ac_count 13676 fi 13677 # 10*(2^10) chars as input seems more than enough 13678 test $ac_count -gt 10 && break 13679 done 13680 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13681 esac 13682 13683 $ac_path_EGREP_found && break 3 13684 done 13685 done 13686 done 13687 IFS=$as_save_IFS 13688 if test -z "$ac_cv_path_EGREP"; then 13689 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13690 fi 13691 else 13692 ac_cv_path_EGREP=$EGREP 13693 fi 13694 13695 fi 13696 fi 13697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13698 $as_echo "$ac_cv_path_EGREP" >&6; } 13699 EGREP="$ac_cv_path_EGREP" 13700 13701 13702 else 13703 # If it succeeded, then it was overridden by the user. We will use it 13704 # for the tool. 13705 13706 # First remove it from the list of overridden variables, so we can test 13707 # for unknown variables in the end. 13708 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13709 13710 # Check if we try to supply an empty value 13711 if test "x$EGREP" = x; then 13712 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13713 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13715 $as_echo_n "checking for EGREP... " >&6; } 13716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13717 $as_echo "disabled" >&6; } 13718 else 13719 # Check if the provided tool contains a complete path. 13720 tool_specified="$EGREP" 13721 tool_basename="${tool_specified##*/}" 13722 if test "x$tool_basename" = "x$tool_specified"; then 13723 # A command without a complete path is provided, search $PATH. 13724 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13725 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13726 # Extract the first word of "$tool_basename", so it can be a program name with args. 13727 set dummy $tool_basename; ac_word=$2 13728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13729 $as_echo_n "checking for $ac_word... " >&6; } 13730 if ${ac_cv_path_EGREP+:} false; then : 13731 $as_echo_n "(cached) " >&6 13732 else 13733 case $EGREP in 13734 [\\/]* | ?:[\\/]*) 13735 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13736 ;; 13737 *) 13738 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13739 for as_dir in $PATH 13740 do 13741 IFS=$as_save_IFS 13742 test -z "$as_dir" && as_dir=. 13743 for ac_exec_ext in '' $ac_executable_extensions; do 13744 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13745 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13746 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13747 break 2 13748 fi 13749 done 13750 done 13751 IFS=$as_save_IFS 13752 13753 ;; 13754 esac 13755 fi 13756 EGREP=$ac_cv_path_EGREP 13757 if test -n "$EGREP"; then 13758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13759 $as_echo "$EGREP" >&6; } 13760 else 13761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13762 $as_echo "no" >&6; } 13763 fi 13764 13765 13766 if test "x$EGREP" = x; then 13767 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13768 fi 13769 else 13770 # Otherwise we believe it is a complete path. Use it as it is. 13771 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13772 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13774 $as_echo_n "checking for EGREP... " >&6; } 13775 if test ! -x "$tool_specified"; then 13776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13777 $as_echo "not found" >&6; } 13778 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13779 fi 13780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13781 $as_echo "$tool_specified" >&6; } 13782 fi 13783 fi 13784 fi 13785 13786 fi 13787 13788 13789 if test "x$EGREP" = x; then 13790 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13791 fi 13792 13793 13794 13795 13796 # Publish this variable in the help. 13797 13798 13799 if [ -z "${FGREP+x}" ]; then 13800 # The variable is not set by user, try to locate tool using the code snippet 13801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13802 $as_echo_n "checking for fgrep... " >&6; } 13803 if ${ac_cv_path_FGREP+:} false; then : 13804 $as_echo_n "(cached) " >&6 13805 else 13806 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13807 then ac_cv_path_FGREP="$GREP -F" 13808 else 13809 if test -z "$FGREP"; then 13810 ac_path_FGREP_found=false 13811 # Loop through the user's path and test for each of PROGNAME-LIST 13812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13813 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13814 do 13815 IFS=$as_save_IFS 13816 test -z "$as_dir" && as_dir=. 13817 for ac_prog in fgrep; do 13818 for ac_exec_ext in '' $ac_executable_extensions; do 13819 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13820 as_fn_executable_p "$ac_path_FGREP" || continue 13821 # Check for GNU ac_path_FGREP and select it if it is found. 13822 # Check for GNU $ac_path_FGREP 13823 case `"$ac_path_FGREP" --version 2>&1` in 13824 *GNU*) 13825 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13826 *) 13827 ac_count=0 13828 $as_echo_n 0123456789 >"conftest.in" 13829 while : 13830 do 13831 cat "conftest.in" "conftest.in" >"conftest.tmp" 13832 mv "conftest.tmp" "conftest.in" 13833 cp "conftest.in" "conftest.nl" 13834 $as_echo 'FGREP' >> "conftest.nl" 13835 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13836 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13837 as_fn_arith $ac_count + 1 && ac_count=$as_val 13838 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13839 # Best one so far, save it but keep looking for a better one 13840 ac_cv_path_FGREP="$ac_path_FGREP" 13841 ac_path_FGREP_max=$ac_count 13842 fi 13843 # 10*(2^10) chars as input seems more than enough 13844 test $ac_count -gt 10 && break 13845 done 13846 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13847 esac 13848 13849 $ac_path_FGREP_found && break 3 13850 done 13851 done 13852 done 13853 IFS=$as_save_IFS 13854 if test -z "$ac_cv_path_FGREP"; then 13855 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13856 fi 13857 else 13858 ac_cv_path_FGREP=$FGREP 13859 fi 13860 13861 fi 13862 fi 13863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13864 $as_echo "$ac_cv_path_FGREP" >&6; } 13865 FGREP="$ac_cv_path_FGREP" 13866 13867 13868 else 13869 # The variable is set, but is it from the command line or the environment? 13870 13871 # Try to remove the string !FGREP! from our list. 13872 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13873 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13874 # If it failed, the variable was not from the command line. Ignore it, 13875 # but warn the user (except for BASH, which is always set by the calling BASH). 13876 if test "xFGREP" != xBASH; then 13877 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13878 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13879 fi 13880 # Try to locate tool using the code snippet 13881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13882 $as_echo_n "checking for fgrep... " >&6; } 13883 if ${ac_cv_path_FGREP+:} false; then : 13884 $as_echo_n "(cached) " >&6 13885 else 13886 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13887 then ac_cv_path_FGREP="$GREP -F" 13888 else 13889 if test -z "$FGREP"; then 13890 ac_path_FGREP_found=false 13891 # Loop through the user's path and test for each of PROGNAME-LIST 13892 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13893 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13894 do 13895 IFS=$as_save_IFS 13896 test -z "$as_dir" && as_dir=. 13897 for ac_prog in fgrep; do 13898 for ac_exec_ext in '' $ac_executable_extensions; do 13899 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13900 as_fn_executable_p "$ac_path_FGREP" || continue 13901 # Check for GNU ac_path_FGREP and select it if it is found. 13902 # Check for GNU $ac_path_FGREP 13903 case `"$ac_path_FGREP" --version 2>&1` in 13904 *GNU*) 13905 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13906 *) 13907 ac_count=0 13908 $as_echo_n 0123456789 >"conftest.in" 13909 while : 13910 do 13911 cat "conftest.in" "conftest.in" >"conftest.tmp" 13912 mv "conftest.tmp" "conftest.in" 13913 cp "conftest.in" "conftest.nl" 13914 $as_echo 'FGREP' >> "conftest.nl" 13915 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13916 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13917 as_fn_arith $ac_count + 1 && ac_count=$as_val 13918 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13919 # Best one so far, save it but keep looking for a better one 13920 ac_cv_path_FGREP="$ac_path_FGREP" 13921 ac_path_FGREP_max=$ac_count 13922 fi 13923 # 10*(2^10) chars as input seems more than enough 13924 test $ac_count -gt 10 && break 13925 done 13926 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13927 esac 13928 13929 $ac_path_FGREP_found && break 3 13930 done 13931 done 13932 done 13933 IFS=$as_save_IFS 13934 if test -z "$ac_cv_path_FGREP"; then 13935 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13936 fi 13937 else 13938 ac_cv_path_FGREP=$FGREP 13939 fi 13940 13941 fi 13942 fi 13943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13944 $as_echo "$ac_cv_path_FGREP" >&6; } 13945 FGREP="$ac_cv_path_FGREP" 13946 13947 13948 else 13949 # If it succeeded, then it was overridden by the user. We will use it 13950 # for the tool. 13951 13952 # First remove it from the list of overridden variables, so we can test 13953 # for unknown variables in the end. 13954 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13955 13956 # Check if we try to supply an empty value 13957 if test "x$FGREP" = x; then 13958 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 13959 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 13960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13961 $as_echo_n "checking for FGREP... " >&6; } 13962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13963 $as_echo "disabled" >&6; } 13964 else 13965 # Check if the provided tool contains a complete path. 13966 tool_specified="$FGREP" 13967 tool_basename="${tool_specified##*/}" 13968 if test "x$tool_basename" = "x$tool_specified"; then 13969 # A command without a complete path is provided, search $PATH. 13970 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 13971 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 13972 # Extract the first word of "$tool_basename", so it can be a program name with args. 13973 set dummy $tool_basename; ac_word=$2 13974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13975 $as_echo_n "checking for $ac_word... " >&6; } 13976 if ${ac_cv_path_FGREP+:} false; then : 13977 $as_echo_n "(cached) " >&6 13978 else 13979 case $FGREP in 13980 [\\/]* | ?:[\\/]*) 13981 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 13982 ;; 13983 *) 13984 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13985 for as_dir in $PATH 13986 do 13987 IFS=$as_save_IFS 13988 test -z "$as_dir" && as_dir=. 13989 for ac_exec_ext in '' $ac_executable_extensions; do 13990 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13991 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 13992 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13993 break 2 13994 fi 13995 done 13996 done 13997 IFS=$as_save_IFS 13998 13999 ;; 14000 esac 14001 fi 14002 FGREP=$ac_cv_path_FGREP 14003 if test -n "$FGREP"; then 14004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14005 $as_echo "$FGREP" >&6; } 14006 else 14007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14008 $as_echo "no" >&6; } 14009 fi 14010 14011 14012 if test "x$FGREP" = x; then 14013 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14014 fi 14015 else 14016 # Otherwise we believe it is a complete path. Use it as it is. 14017 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14018 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14020 $as_echo_n "checking for FGREP... " >&6; } 14021 if test ! -x "$tool_specified"; then 14022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14023 $as_echo "not found" >&6; } 14024 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14025 fi 14026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14027 $as_echo "$tool_specified" >&6; } 14028 fi 14029 fi 14030 fi 14031 14032 fi 14033 14034 14035 if test "x$FGREP" = x; then 14036 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14037 fi 14038 14039 14040 14041 14042 # Publish this variable in the help. 14043 14044 14045 if [ -z "${SED+x}" ]; then 14046 # The variable is not set by user, try to locate tool using the code snippet 14047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14048 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14049 if ${ac_cv_path_SED+:} false; then : 14050 $as_echo_n "(cached) " >&6 14051 else 14052 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14053 for ac_i in 1 2 3 4 5 6 7; do 14054 ac_script="$ac_script$as_nl$ac_script" 14055 done 14056 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14057 { ac_script=; unset ac_script;} 14058 if test -z "$SED"; then 14059 ac_path_SED_found=false 14060 # Loop through the user's path and test for each of PROGNAME-LIST 14061 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14062 for as_dir in $PATH 14063 do 14064 IFS=$as_save_IFS 14065 test -z "$as_dir" && as_dir=. 14066 for ac_prog in sed gsed; do 14067 for ac_exec_ext in '' $ac_executable_extensions; do 14068 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14069 as_fn_executable_p "$ac_path_SED" || continue 14070 # Check for GNU ac_path_SED and select it if it is found. 14071 # Check for GNU $ac_path_SED 14072 case `"$ac_path_SED" --version 2>&1` in 14073 *GNU*) 14074 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14075 *) 14076 ac_count=0 14077 $as_echo_n 0123456789 >"conftest.in" 14078 while : 14079 do 14080 cat "conftest.in" "conftest.in" >"conftest.tmp" 14081 mv "conftest.tmp" "conftest.in" 14082 cp "conftest.in" "conftest.nl" 14083 $as_echo '' >> "conftest.nl" 14084 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14085 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14086 as_fn_arith $ac_count + 1 && ac_count=$as_val 14087 if test $ac_count -gt ${ac_path_SED_max-0}; then 14088 # Best one so far, save it but keep looking for a better one 14089 ac_cv_path_SED="$ac_path_SED" 14090 ac_path_SED_max=$ac_count 14091 fi 14092 # 10*(2^10) chars as input seems more than enough 14093 test $ac_count -gt 10 && break 14094 done 14095 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14096 esac 14097 14098 $ac_path_SED_found && break 3 14099 done 14100 done 14101 done 14102 IFS=$as_save_IFS 14103 if test -z "$ac_cv_path_SED"; then 14104 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14105 fi 14106 else 14107 ac_cv_path_SED=$SED 14108 fi 14109 14110 fi 14111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14112 $as_echo "$ac_cv_path_SED" >&6; } 14113 SED="$ac_cv_path_SED" 14114 rm -f conftest.sed 14115 14116 else 14117 # The variable is set, but is it from the command line or the environment? 14118 14119 # Try to remove the string !SED! from our list. 14120 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14121 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14122 # If it failed, the variable was not from the command line. Ignore it, 14123 # but warn the user (except for BASH, which is always set by the calling BASH). 14124 if test "xSED" != xBASH; then 14125 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14126 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14127 fi 14128 # Try to locate tool using the code snippet 14129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14130 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14131 if ${ac_cv_path_SED+:} false; then : 14132 $as_echo_n "(cached) " >&6 14133 else 14134 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14135 for ac_i in 1 2 3 4 5 6 7; do 14136 ac_script="$ac_script$as_nl$ac_script" 14137 done 14138 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14139 { ac_script=; unset ac_script;} 14140 if test -z "$SED"; then 14141 ac_path_SED_found=false 14142 # Loop through the user's path and test for each of PROGNAME-LIST 14143 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14144 for as_dir in $PATH 14145 do 14146 IFS=$as_save_IFS 14147 test -z "$as_dir" && as_dir=. 14148 for ac_prog in sed gsed; do 14149 for ac_exec_ext in '' $ac_executable_extensions; do 14150 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14151 as_fn_executable_p "$ac_path_SED" || continue 14152 # Check for GNU ac_path_SED and select it if it is found. 14153 # Check for GNU $ac_path_SED 14154 case `"$ac_path_SED" --version 2>&1` in 14155 *GNU*) 14156 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14157 *) 14158 ac_count=0 14159 $as_echo_n 0123456789 >"conftest.in" 14160 while : 14161 do 14162 cat "conftest.in" "conftest.in" >"conftest.tmp" 14163 mv "conftest.tmp" "conftest.in" 14164 cp "conftest.in" "conftest.nl" 14165 $as_echo '' >> "conftest.nl" 14166 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14167 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14168 as_fn_arith $ac_count + 1 && ac_count=$as_val 14169 if test $ac_count -gt ${ac_path_SED_max-0}; then 14170 # Best one so far, save it but keep looking for a better one 14171 ac_cv_path_SED="$ac_path_SED" 14172 ac_path_SED_max=$ac_count 14173 fi 14174 # 10*(2^10) chars as input seems more than enough 14175 test $ac_count -gt 10 && break 14176 done 14177 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14178 esac 14179 14180 $ac_path_SED_found && break 3 14181 done 14182 done 14183 done 14184 IFS=$as_save_IFS 14185 if test -z "$ac_cv_path_SED"; then 14186 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14187 fi 14188 else 14189 ac_cv_path_SED=$SED 14190 fi 14191 14192 fi 14193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14194 $as_echo "$ac_cv_path_SED" >&6; } 14195 SED="$ac_cv_path_SED" 14196 rm -f conftest.sed 14197 14198 else 14199 # If it succeeded, then it was overridden by the user. We will use it 14200 # for the tool. 14201 14202 # First remove it from the list of overridden variables, so we can test 14203 # for unknown variables in the end. 14204 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14205 14206 # Check if we try to supply an empty value 14207 if test "x$SED" = x; then 14208 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14209 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14211 $as_echo_n "checking for SED... " >&6; } 14212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14213 $as_echo "disabled" >&6; } 14214 else 14215 # Check if the provided tool contains a complete path. 14216 tool_specified="$SED" 14217 tool_basename="${tool_specified##*/}" 14218 if test "x$tool_basename" = "x$tool_specified"; then 14219 # A command without a complete path is provided, search $PATH. 14220 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14221 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14222 # Extract the first word of "$tool_basename", so it can be a program name with args. 14223 set dummy $tool_basename; ac_word=$2 14224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14225 $as_echo_n "checking for $ac_word... " >&6; } 14226 if ${ac_cv_path_SED+:} false; then : 14227 $as_echo_n "(cached) " >&6 14228 else 14229 case $SED in 14230 [\\/]* | ?:[\\/]*) 14231 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14232 ;; 14233 *) 14234 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14235 for as_dir in $PATH 14236 do 14237 IFS=$as_save_IFS 14238 test -z "$as_dir" && as_dir=. 14239 for ac_exec_ext in '' $ac_executable_extensions; do 14240 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14241 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14242 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14243 break 2 14244 fi 14245 done 14246 done 14247 IFS=$as_save_IFS 14248 14249 ;; 14250 esac 14251 fi 14252 SED=$ac_cv_path_SED 14253 if test -n "$SED"; then 14254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14255 $as_echo "$SED" >&6; } 14256 else 14257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14258 $as_echo "no" >&6; } 14259 fi 14260 14261 14262 if test "x$SED" = x; then 14263 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14264 fi 14265 else 14266 # Otherwise we believe it is a complete path. Use it as it is. 14267 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14268 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14270 $as_echo_n "checking for SED... " >&6; } 14271 if test ! -x "$tool_specified"; then 14272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14273 $as_echo "not found" >&6; } 14274 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14275 fi 14276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14277 $as_echo "$tool_specified" >&6; } 14278 fi 14279 fi 14280 fi 14281 14282 fi 14283 14284 14285 if test "x$SED" = x; then 14286 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14287 fi 14288 14289 14290 14291 # Always force rm. 14292 RM="$RM -f" 14293 14294 # pwd behaves differently on various platforms and some don't support the -L flag. 14295 # Always use the bash builtin pwd to get uniform behavior. 14296 THEPWDCMD=pwd 14297 14298 # These are not required on all platforms 14299 14300 14301 # Publish this variable in the help. 14302 14303 14304 if [ -z "${CYGPATH+x}" ]; then 14305 # The variable is not set by user, try to locate tool using the code snippet 14306 for ac_prog in cygpath 14307 do 14308 # Extract the first word of "$ac_prog", so it can be a program name with args. 14309 set dummy $ac_prog; ac_word=$2 14310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14311 $as_echo_n "checking for $ac_word... " >&6; } 14312 if ${ac_cv_path_CYGPATH+:} false; then : 14313 $as_echo_n "(cached) " >&6 14314 else 14315 case $CYGPATH in 14316 [\\/]* | ?:[\\/]*) 14317 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14318 ;; 14319 *) 14320 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14321 for as_dir in $PATH 14322 do 14323 IFS=$as_save_IFS 14324 test -z "$as_dir" && as_dir=. 14325 for ac_exec_ext in '' $ac_executable_extensions; do 14326 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14327 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14328 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14329 break 2 14330 fi 14331 done 14332 done 14333 IFS=$as_save_IFS 14334 14335 ;; 14336 esac 14337 fi 14338 CYGPATH=$ac_cv_path_CYGPATH 14339 if test -n "$CYGPATH"; then 14340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14341 $as_echo "$CYGPATH" >&6; } 14342 else 14343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14344 $as_echo "no" >&6; } 14345 fi 14346 14347 14348 test -n "$CYGPATH" && break 14349 done 14350 14351 else 14352 # The variable is set, but is it from the command line or the environment? 14353 14354 # Try to remove the string !CYGPATH! from our list. 14355 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14356 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14357 # If it failed, the variable was not from the command line. Ignore it, 14358 # but warn the user (except for BASH, which is always set by the calling BASH). 14359 if test "xCYGPATH" != xBASH; then 14360 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14361 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14362 fi 14363 # Try to locate tool using the code snippet 14364 for ac_prog in cygpath 14365 do 14366 # Extract the first word of "$ac_prog", so it can be a program name with args. 14367 set dummy $ac_prog; ac_word=$2 14368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14369 $as_echo_n "checking for $ac_word... " >&6; } 14370 if ${ac_cv_path_CYGPATH+:} false; then : 14371 $as_echo_n "(cached) " >&6 14372 else 14373 case $CYGPATH in 14374 [\\/]* | ?:[\\/]*) 14375 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14376 ;; 14377 *) 14378 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14379 for as_dir in $PATH 14380 do 14381 IFS=$as_save_IFS 14382 test -z "$as_dir" && as_dir=. 14383 for ac_exec_ext in '' $ac_executable_extensions; do 14384 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14385 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14386 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14387 break 2 14388 fi 14389 done 14390 done 14391 IFS=$as_save_IFS 14392 14393 ;; 14394 esac 14395 fi 14396 CYGPATH=$ac_cv_path_CYGPATH 14397 if test -n "$CYGPATH"; then 14398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14399 $as_echo "$CYGPATH" >&6; } 14400 else 14401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14402 $as_echo "no" >&6; } 14403 fi 14404 14405 14406 test -n "$CYGPATH" && break 14407 done 14408 14409 else 14410 # If it succeeded, then it was overridden by the user. We will use it 14411 # for the tool. 14412 14413 # First remove it from the list of overridden variables, so we can test 14414 # for unknown variables in the end. 14415 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14416 14417 # Check if we try to supply an empty value 14418 if test "x$CYGPATH" = x; then 14419 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14420 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14422 $as_echo_n "checking for CYGPATH... " >&6; } 14423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14424 $as_echo "disabled" >&6; } 14425 else 14426 # Check if the provided tool contains a complete path. 14427 tool_specified="$CYGPATH" 14428 tool_basename="${tool_specified##*/}" 14429 if test "x$tool_basename" = "x$tool_specified"; then 14430 # A command without a complete path is provided, search $PATH. 14431 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14432 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14433 # Extract the first word of "$tool_basename", so it can be a program name with args. 14434 set dummy $tool_basename; ac_word=$2 14435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14436 $as_echo_n "checking for $ac_word... " >&6; } 14437 if ${ac_cv_path_CYGPATH+:} false; then : 14438 $as_echo_n "(cached) " >&6 14439 else 14440 case $CYGPATH in 14441 [\\/]* | ?:[\\/]*) 14442 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14443 ;; 14444 *) 14445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14446 for as_dir in $PATH 14447 do 14448 IFS=$as_save_IFS 14449 test -z "$as_dir" && as_dir=. 14450 for ac_exec_ext in '' $ac_executable_extensions; do 14451 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14452 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14454 break 2 14455 fi 14456 done 14457 done 14458 IFS=$as_save_IFS 14459 14460 ;; 14461 esac 14462 fi 14463 CYGPATH=$ac_cv_path_CYGPATH 14464 if test -n "$CYGPATH"; then 14465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14466 $as_echo "$CYGPATH" >&6; } 14467 else 14468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14469 $as_echo "no" >&6; } 14470 fi 14471 14472 14473 if test "x$CYGPATH" = x; then 14474 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14475 fi 14476 else 14477 # Otherwise we believe it is a complete path. Use it as it is. 14478 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14479 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14481 $as_echo_n "checking for CYGPATH... " >&6; } 14482 if test ! -x "$tool_specified"; then 14483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14484 $as_echo "not found" >&6; } 14485 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14486 fi 14487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14488 $as_echo "$tool_specified" >&6; } 14489 fi 14490 fi 14491 fi 14492 14493 fi 14494 14495 14496 14497 14498 # Publish this variable in the help. 14499 14500 14501 if [ -z "${READLINK+x}" ]; then 14502 # The variable is not set by user, try to locate tool using the code snippet 14503 for ac_prog in greadlink readlink 14504 do 14505 # Extract the first word of "$ac_prog", so it can be a program name with args. 14506 set dummy $ac_prog; ac_word=$2 14507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14508 $as_echo_n "checking for $ac_word... " >&6; } 14509 if ${ac_cv_path_READLINK+:} false; then : 14510 $as_echo_n "(cached) " >&6 14511 else 14512 case $READLINK in 14513 [\\/]* | ?:[\\/]*) 14514 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14515 ;; 14516 *) 14517 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14518 for as_dir in $PATH 14519 do 14520 IFS=$as_save_IFS 14521 test -z "$as_dir" && as_dir=. 14522 for ac_exec_ext in '' $ac_executable_extensions; do 14523 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14524 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14526 break 2 14527 fi 14528 done 14529 done 14530 IFS=$as_save_IFS 14531 14532 ;; 14533 esac 14534 fi 14535 READLINK=$ac_cv_path_READLINK 14536 if test -n "$READLINK"; then 14537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14538 $as_echo "$READLINK" >&6; } 14539 else 14540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14541 $as_echo "no" >&6; } 14542 fi 14543 14544 14545 test -n "$READLINK" && break 14546 done 14547 14548 else 14549 # The variable is set, but is it from the command line or the environment? 14550 14551 # Try to remove the string !READLINK! from our list. 14552 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14553 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14554 # If it failed, the variable was not from the command line. Ignore it, 14555 # but warn the user (except for BASH, which is always set by the calling BASH). 14556 if test "xREADLINK" != xBASH; then 14557 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14558 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14559 fi 14560 # Try to locate tool using the code snippet 14561 for ac_prog in greadlink readlink 14562 do 14563 # Extract the first word of "$ac_prog", so it can be a program name with args. 14564 set dummy $ac_prog; ac_word=$2 14565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14566 $as_echo_n "checking for $ac_word... " >&6; } 14567 if ${ac_cv_path_READLINK+:} false; then : 14568 $as_echo_n "(cached) " >&6 14569 else 14570 case $READLINK in 14571 [\\/]* | ?:[\\/]*) 14572 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14573 ;; 14574 *) 14575 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14576 for as_dir in $PATH 14577 do 14578 IFS=$as_save_IFS 14579 test -z "$as_dir" && as_dir=. 14580 for ac_exec_ext in '' $ac_executable_extensions; do 14581 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14582 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14583 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14584 break 2 14585 fi 14586 done 14587 done 14588 IFS=$as_save_IFS 14589 14590 ;; 14591 esac 14592 fi 14593 READLINK=$ac_cv_path_READLINK 14594 if test -n "$READLINK"; then 14595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14596 $as_echo "$READLINK" >&6; } 14597 else 14598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14599 $as_echo "no" >&6; } 14600 fi 14601 14602 14603 test -n "$READLINK" && break 14604 done 14605 14606 else 14607 # If it succeeded, then it was overridden by the user. We will use it 14608 # for the tool. 14609 14610 # First remove it from the list of overridden variables, so we can test 14611 # for unknown variables in the end. 14612 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14613 14614 # Check if we try to supply an empty value 14615 if test "x$READLINK" = x; then 14616 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14617 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14619 $as_echo_n "checking for READLINK... " >&6; } 14620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14621 $as_echo "disabled" >&6; } 14622 else 14623 # Check if the provided tool contains a complete path. 14624 tool_specified="$READLINK" 14625 tool_basename="${tool_specified##*/}" 14626 if test "x$tool_basename" = "x$tool_specified"; then 14627 # A command without a complete path is provided, search $PATH. 14628 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14629 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14630 # Extract the first word of "$tool_basename", so it can be a program name with args. 14631 set dummy $tool_basename; ac_word=$2 14632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14633 $as_echo_n "checking for $ac_word... " >&6; } 14634 if ${ac_cv_path_READLINK+:} false; then : 14635 $as_echo_n "(cached) " >&6 14636 else 14637 case $READLINK in 14638 [\\/]* | ?:[\\/]*) 14639 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14640 ;; 14641 *) 14642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14643 for as_dir in $PATH 14644 do 14645 IFS=$as_save_IFS 14646 test -z "$as_dir" && as_dir=. 14647 for ac_exec_ext in '' $ac_executable_extensions; do 14648 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14649 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14651 break 2 14652 fi 14653 done 14654 done 14655 IFS=$as_save_IFS 14656 14657 ;; 14658 esac 14659 fi 14660 READLINK=$ac_cv_path_READLINK 14661 if test -n "$READLINK"; then 14662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14663 $as_echo "$READLINK" >&6; } 14664 else 14665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14666 $as_echo "no" >&6; } 14667 fi 14668 14669 14670 if test "x$READLINK" = x; then 14671 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14672 fi 14673 else 14674 # Otherwise we believe it is a complete path. Use it as it is. 14675 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14676 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14678 $as_echo_n "checking for READLINK... " >&6; } 14679 if test ! -x "$tool_specified"; then 14680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14681 $as_echo "not found" >&6; } 14682 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14683 fi 14684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14685 $as_echo "$tool_specified" >&6; } 14686 fi 14687 fi 14688 fi 14689 14690 fi 14691 14692 14693 14694 14695 # Publish this variable in the help. 14696 14697 14698 if [ -z "${DF+x}" ]; then 14699 # The variable is not set by user, try to locate tool using the code snippet 14700 for ac_prog in df 14701 do 14702 # Extract the first word of "$ac_prog", so it can be a program name with args. 14703 set dummy $ac_prog; ac_word=$2 14704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14705 $as_echo_n "checking for $ac_word... " >&6; } 14706 if ${ac_cv_path_DF+:} false; then : 14707 $as_echo_n "(cached) " >&6 14708 else 14709 case $DF in 14710 [\\/]* | ?:[\\/]*) 14711 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14712 ;; 14713 *) 14714 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14715 for as_dir in $PATH 14716 do 14717 IFS=$as_save_IFS 14718 test -z "$as_dir" && as_dir=. 14719 for ac_exec_ext in '' $ac_executable_extensions; do 14720 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14721 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14722 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14723 break 2 14724 fi 14725 done 14726 done 14727 IFS=$as_save_IFS 14728 14729 ;; 14730 esac 14731 fi 14732 DF=$ac_cv_path_DF 14733 if test -n "$DF"; then 14734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14735 $as_echo "$DF" >&6; } 14736 else 14737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14738 $as_echo "no" >&6; } 14739 fi 14740 14741 14742 test -n "$DF" && break 14743 done 14744 14745 else 14746 # The variable is set, but is it from the command line or the environment? 14747 14748 # Try to remove the string !DF! from our list. 14749 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14750 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14751 # If it failed, the variable was not from the command line. Ignore it, 14752 # but warn the user (except for BASH, which is always set by the calling BASH). 14753 if test "xDF" != xBASH; then 14754 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14755 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14756 fi 14757 # Try to locate tool using the code snippet 14758 for ac_prog in df 14759 do 14760 # Extract the first word of "$ac_prog", so it can be a program name with args. 14761 set dummy $ac_prog; ac_word=$2 14762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14763 $as_echo_n "checking for $ac_word... " >&6; } 14764 if ${ac_cv_path_DF+:} false; then : 14765 $as_echo_n "(cached) " >&6 14766 else 14767 case $DF in 14768 [\\/]* | ?:[\\/]*) 14769 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14770 ;; 14771 *) 14772 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14773 for as_dir in $PATH 14774 do 14775 IFS=$as_save_IFS 14776 test -z "$as_dir" && as_dir=. 14777 for ac_exec_ext in '' $ac_executable_extensions; do 14778 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14779 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14780 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14781 break 2 14782 fi 14783 done 14784 done 14785 IFS=$as_save_IFS 14786 14787 ;; 14788 esac 14789 fi 14790 DF=$ac_cv_path_DF 14791 if test -n "$DF"; then 14792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14793 $as_echo "$DF" >&6; } 14794 else 14795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14796 $as_echo "no" >&6; } 14797 fi 14798 14799 14800 test -n "$DF" && break 14801 done 14802 14803 else 14804 # If it succeeded, then it was overridden by the user. We will use it 14805 # for the tool. 14806 14807 # First remove it from the list of overridden variables, so we can test 14808 # for unknown variables in the end. 14809 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14810 14811 # Check if we try to supply an empty value 14812 if test "x$DF" = x; then 14813 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14814 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14816 $as_echo_n "checking for DF... " >&6; } 14817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14818 $as_echo "disabled" >&6; } 14819 else 14820 # Check if the provided tool contains a complete path. 14821 tool_specified="$DF" 14822 tool_basename="${tool_specified##*/}" 14823 if test "x$tool_basename" = "x$tool_specified"; then 14824 # A command without a complete path is provided, search $PATH. 14825 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14826 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14827 # Extract the first word of "$tool_basename", so it can be a program name with args. 14828 set dummy $tool_basename; ac_word=$2 14829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14830 $as_echo_n "checking for $ac_word... " >&6; } 14831 if ${ac_cv_path_DF+:} false; then : 14832 $as_echo_n "(cached) " >&6 14833 else 14834 case $DF in 14835 [\\/]* | ?:[\\/]*) 14836 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14837 ;; 14838 *) 14839 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14840 for as_dir in $PATH 14841 do 14842 IFS=$as_save_IFS 14843 test -z "$as_dir" && as_dir=. 14844 for ac_exec_ext in '' $ac_executable_extensions; do 14845 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14846 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14847 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14848 break 2 14849 fi 14850 done 14851 done 14852 IFS=$as_save_IFS 14853 14854 ;; 14855 esac 14856 fi 14857 DF=$ac_cv_path_DF 14858 if test -n "$DF"; then 14859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14860 $as_echo "$DF" >&6; } 14861 else 14862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14863 $as_echo "no" >&6; } 14864 fi 14865 14866 14867 if test "x$DF" = x; then 14868 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14869 fi 14870 else 14871 # Otherwise we believe it is a complete path. Use it as it is. 14872 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14873 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14875 $as_echo_n "checking for DF... " >&6; } 14876 if test ! -x "$tool_specified"; then 14877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14878 $as_echo "not found" >&6; } 14879 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14880 fi 14881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14882 $as_echo "$tool_specified" >&6; } 14883 fi 14884 fi 14885 fi 14886 14887 fi 14888 14889 14890 14891 14892 # Publish this variable in the help. 14893 14894 14895 if [ -z "${CPIO+x}" ]; then 14896 # The variable is not set by user, try to locate tool using the code snippet 14897 for ac_prog in cpio bsdcpio 14898 do 14899 # Extract the first word of "$ac_prog", so it can be a program name with args. 14900 set dummy $ac_prog; ac_word=$2 14901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14902 $as_echo_n "checking for $ac_word... " >&6; } 14903 if ${ac_cv_path_CPIO+:} false; then : 14904 $as_echo_n "(cached) " >&6 14905 else 14906 case $CPIO in 14907 [\\/]* | ?:[\\/]*) 14908 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14909 ;; 14910 *) 14911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14912 for as_dir in $PATH 14913 do 14914 IFS=$as_save_IFS 14915 test -z "$as_dir" && as_dir=. 14916 for ac_exec_ext in '' $ac_executable_extensions; do 14917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14918 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14920 break 2 14921 fi 14922 done 14923 done 14924 IFS=$as_save_IFS 14925 14926 ;; 14927 esac 14928 fi 14929 CPIO=$ac_cv_path_CPIO 14930 if test -n "$CPIO"; then 14931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14932 $as_echo "$CPIO" >&6; } 14933 else 14934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14935 $as_echo "no" >&6; } 14936 fi 14937 14938 14939 test -n "$CPIO" && break 14940 done 14941 14942 else 14943 # The variable is set, but is it from the command line or the environment? 14944 14945 # Try to remove the string !CPIO! from our list. 14946 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 14947 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14948 # If it failed, the variable was not from the command line. Ignore it, 14949 # but warn the user (except for BASH, which is always set by the calling BASH). 14950 if test "xCPIO" != xBASH; then 14951 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 14952 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 14953 fi 14954 # Try to locate tool using the code snippet 14955 for ac_prog in cpio bsdcpio 14956 do 14957 # Extract the first word of "$ac_prog", so it can be a program name with args. 14958 set dummy $ac_prog; ac_word=$2 14959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14960 $as_echo_n "checking for $ac_word... " >&6; } 14961 if ${ac_cv_path_CPIO+:} false; then : 14962 $as_echo_n "(cached) " >&6 14963 else 14964 case $CPIO in 14965 [\\/]* | ?:[\\/]*) 14966 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14967 ;; 14968 *) 14969 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14970 for as_dir in $PATH 14971 do 14972 IFS=$as_save_IFS 14973 test -z "$as_dir" && as_dir=. 14974 for ac_exec_ext in '' $ac_executable_extensions; do 14975 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14976 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14977 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14978 break 2 14979 fi 14980 done 14981 done 14982 IFS=$as_save_IFS 14983 14984 ;; 14985 esac 14986 fi 14987 CPIO=$ac_cv_path_CPIO 14988 if test -n "$CPIO"; then 14989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14990 $as_echo "$CPIO" >&6; } 14991 else 14992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14993 $as_echo "no" >&6; } 14994 fi 14995 14996 14997 test -n "$CPIO" && break 14998 done 14999 15000 else 15001 # If it succeeded, then it was overridden by the user. We will use it 15002 # for the tool. 15003 15004 # First remove it from the list of overridden variables, so we can test 15005 # for unknown variables in the end. 15006 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15007 15008 # Check if we try to supply an empty value 15009 if test "x$CPIO" = x; then 15010 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15011 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15013 $as_echo_n "checking for CPIO... " >&6; } 15014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15015 $as_echo "disabled" >&6; } 15016 else 15017 # Check if the provided tool contains a complete path. 15018 tool_specified="$CPIO" 15019 tool_basename="${tool_specified##*/}" 15020 if test "x$tool_basename" = "x$tool_specified"; then 15021 # A command without a complete path is provided, search $PATH. 15022 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15023 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15024 # Extract the first word of "$tool_basename", so it can be a program name with args. 15025 set dummy $tool_basename; ac_word=$2 15026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15027 $as_echo_n "checking for $ac_word... " >&6; } 15028 if ${ac_cv_path_CPIO+:} false; then : 15029 $as_echo_n "(cached) " >&6 15030 else 15031 case $CPIO in 15032 [\\/]* | ?:[\\/]*) 15033 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15034 ;; 15035 *) 15036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15037 for as_dir in $PATH 15038 do 15039 IFS=$as_save_IFS 15040 test -z "$as_dir" && as_dir=. 15041 for ac_exec_ext in '' $ac_executable_extensions; do 15042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15043 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15045 break 2 15046 fi 15047 done 15048 done 15049 IFS=$as_save_IFS 15050 15051 ;; 15052 esac 15053 fi 15054 CPIO=$ac_cv_path_CPIO 15055 if test -n "$CPIO"; then 15056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15057 $as_echo "$CPIO" >&6; } 15058 else 15059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15060 $as_echo "no" >&6; } 15061 fi 15062 15063 15064 if test "x$CPIO" = x; then 15065 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15066 fi 15067 else 15068 # Otherwise we believe it is a complete path. Use it as it is. 15069 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15070 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15072 $as_echo_n "checking for CPIO... " >&6; } 15073 if test ! -x "$tool_specified"; then 15074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15075 $as_echo "not found" >&6; } 15076 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15077 fi 15078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15079 $as_echo "$tool_specified" >&6; } 15080 fi 15081 fi 15082 fi 15083 15084 fi 15085 15086 15087 15088 15089 # Publish this variable in the help. 15090 15091 15092 if [ -z "${NICE+x}" ]; then 15093 # The variable is not set by user, try to locate tool using the code snippet 15094 for ac_prog in nice 15095 do 15096 # Extract the first word of "$ac_prog", so it can be a program name with args. 15097 set dummy $ac_prog; ac_word=$2 15098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15099 $as_echo_n "checking for $ac_word... " >&6; } 15100 if ${ac_cv_path_NICE+:} false; then : 15101 $as_echo_n "(cached) " >&6 15102 else 15103 case $NICE in 15104 [\\/]* | ?:[\\/]*) 15105 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15106 ;; 15107 *) 15108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15109 for as_dir in $PATH 15110 do 15111 IFS=$as_save_IFS 15112 test -z "$as_dir" && as_dir=. 15113 for ac_exec_ext in '' $ac_executable_extensions; do 15114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15115 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15117 break 2 15118 fi 15119 done 15120 done 15121 IFS=$as_save_IFS 15122 15123 ;; 15124 esac 15125 fi 15126 NICE=$ac_cv_path_NICE 15127 if test -n "$NICE"; then 15128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15129 $as_echo "$NICE" >&6; } 15130 else 15131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15132 $as_echo "no" >&6; } 15133 fi 15134 15135 15136 test -n "$NICE" && break 15137 done 15138 15139 else 15140 # The variable is set, but is it from the command line or the environment? 15141 15142 # Try to remove the string !NICE! from our list. 15143 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15144 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15145 # If it failed, the variable was not from the command line. Ignore it, 15146 # but warn the user (except for BASH, which is always set by the calling BASH). 15147 if test "xNICE" != xBASH; then 15148 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15149 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15150 fi 15151 # Try to locate tool using the code snippet 15152 for ac_prog in nice 15153 do 15154 # Extract the first word of "$ac_prog", so it can be a program name with args. 15155 set dummy $ac_prog; ac_word=$2 15156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15157 $as_echo_n "checking for $ac_word... " >&6; } 15158 if ${ac_cv_path_NICE+:} false; then : 15159 $as_echo_n "(cached) " >&6 15160 else 15161 case $NICE in 15162 [\\/]* | ?:[\\/]*) 15163 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15164 ;; 15165 *) 15166 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15167 for as_dir in $PATH 15168 do 15169 IFS=$as_save_IFS 15170 test -z "$as_dir" && as_dir=. 15171 for ac_exec_ext in '' $ac_executable_extensions; do 15172 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15173 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15174 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15175 break 2 15176 fi 15177 done 15178 done 15179 IFS=$as_save_IFS 15180 15181 ;; 15182 esac 15183 fi 15184 NICE=$ac_cv_path_NICE 15185 if test -n "$NICE"; then 15186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15187 $as_echo "$NICE" >&6; } 15188 else 15189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15190 $as_echo "no" >&6; } 15191 fi 15192 15193 15194 test -n "$NICE" && break 15195 done 15196 15197 else 15198 # If it succeeded, then it was overridden by the user. We will use it 15199 # for the tool. 15200 15201 # First remove it from the list of overridden variables, so we can test 15202 # for unknown variables in the end. 15203 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15204 15205 # Check if we try to supply an empty value 15206 if test "x$NICE" = x; then 15207 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15208 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15210 $as_echo_n "checking for NICE... " >&6; } 15211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15212 $as_echo "disabled" >&6; } 15213 else 15214 # Check if the provided tool contains a complete path. 15215 tool_specified="$NICE" 15216 tool_basename="${tool_specified##*/}" 15217 if test "x$tool_basename" = "x$tool_specified"; then 15218 # A command without a complete path is provided, search $PATH. 15219 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15220 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15221 # Extract the first word of "$tool_basename", so it can be a program name with args. 15222 set dummy $tool_basename; ac_word=$2 15223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15224 $as_echo_n "checking for $ac_word... " >&6; } 15225 if ${ac_cv_path_NICE+:} false; then : 15226 $as_echo_n "(cached) " >&6 15227 else 15228 case $NICE in 15229 [\\/]* | ?:[\\/]*) 15230 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15231 ;; 15232 *) 15233 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15234 for as_dir in $PATH 15235 do 15236 IFS=$as_save_IFS 15237 test -z "$as_dir" && as_dir=. 15238 for ac_exec_ext in '' $ac_executable_extensions; do 15239 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15240 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15241 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15242 break 2 15243 fi 15244 done 15245 done 15246 IFS=$as_save_IFS 15247 15248 ;; 15249 esac 15250 fi 15251 NICE=$ac_cv_path_NICE 15252 if test -n "$NICE"; then 15253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15254 $as_echo "$NICE" >&6; } 15255 else 15256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15257 $as_echo "no" >&6; } 15258 fi 15259 15260 15261 if test "x$NICE" = x; then 15262 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15263 fi 15264 else 15265 # Otherwise we believe it is a complete path. Use it as it is. 15266 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15267 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15269 $as_echo_n "checking for NICE... " >&6; } 15270 if test ! -x "$tool_specified"; then 15271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15272 $as_echo "not found" >&6; } 15273 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15274 fi 15275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15276 $as_echo "$tool_specified" >&6; } 15277 fi 15278 fi 15279 fi 15280 15281 fi 15282 15283 15284 15285 15286 # Now we can determine OpenJDK build and target platforms. This is required to 15287 # have early on. 15288 # Make sure we can run config.sub. 15289 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15290 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15291 15292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15293 $as_echo_n "checking build system type... " >&6; } 15294 if ${ac_cv_build+:} false; then : 15295 $as_echo_n "(cached) " >&6 15296 else 15297 ac_build_alias=$build_alias 15298 test "x$ac_build_alias" = x && 15299 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15300 test "x$ac_build_alias" = x && 15301 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15302 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15303 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15304 15305 fi 15306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15307 $as_echo "$ac_cv_build" >&6; } 15308 case $ac_cv_build in 15309 *-*-*) ;; 15310 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15311 esac 15312 build=$ac_cv_build 15313 ac_save_IFS=$IFS; IFS='-' 15314 set x $ac_cv_build 15315 shift 15316 build_cpu=$1 15317 build_vendor=$2 15318 shift; shift 15319 # Remember, the first character of IFS is used to create $*, 15320 # except with old shells: 15321 build_os=$* 15322 IFS=$ac_save_IFS 15323 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15324 15325 15326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15327 $as_echo_n "checking host system type... " >&6; } 15328 if ${ac_cv_host+:} false; then : 15329 $as_echo_n "(cached) " >&6 15330 else 15331 if test "x$host_alias" = x; then 15332 ac_cv_host=$ac_cv_build 15333 else 15334 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15335 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15336 fi 15337 15338 fi 15339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15340 $as_echo "$ac_cv_host" >&6; } 15341 case $ac_cv_host in 15342 *-*-*) ;; 15343 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15344 esac 15345 host=$ac_cv_host 15346 ac_save_IFS=$IFS; IFS='-' 15347 set x $ac_cv_host 15348 shift 15349 host_cpu=$1 15350 host_vendor=$2 15351 shift; shift 15352 # Remember, the first character of IFS is used to create $*, 15353 # except with old shells: 15354 host_os=$* 15355 IFS=$ac_save_IFS 15356 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15357 15358 15359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15360 $as_echo_n "checking target system type... " >&6; } 15361 if ${ac_cv_target+:} false; then : 15362 $as_echo_n "(cached) " >&6 15363 else 15364 if test "x$target_alias" = x; then 15365 ac_cv_target=$ac_cv_host 15366 else 15367 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15368 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15369 fi 15370 15371 fi 15372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15373 $as_echo "$ac_cv_target" >&6; } 15374 case $ac_cv_target in 15375 *-*-*) ;; 15376 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15377 esac 15378 target=$ac_cv_target 15379 ac_save_IFS=$IFS; IFS='-' 15380 set x $ac_cv_target 15381 shift 15382 target_cpu=$1 15383 target_vendor=$2 15384 shift; shift 15385 # Remember, the first character of IFS is used to create $*, 15386 # except with old shells: 15387 target_os=$* 15388 IFS=$ac_save_IFS 15389 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15390 15391 15392 # The aliases save the names the user supplied, while $host etc. 15393 # will get canonicalized. 15394 test -n "$target_alias" && 15395 test "$program_prefix$program_suffix$program_transform_name" = \ 15396 NONENONEs,x,x, && 15397 program_prefix=${target_alias}- 15398 15399 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15400 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15401 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15402 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15403 # to use the configure naming style. 15404 15405 15406 15407 15408 15409 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15410 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15411 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15412 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15413 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15414 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15415 15416 15417 15418 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15419 15420 case "$build_os" in 15421 *linux*) 15422 VAR_OS=linux 15423 VAR_OS_TYPE=unix 15424 ;; 15425 *solaris*) 15426 VAR_OS=solaris 15427 VAR_OS_TYPE=unix 15428 ;; 15429 *darwin*) 15430 VAR_OS=macosx 15431 VAR_OS_TYPE=unix 15432 ;; 15433 *bsd*) 15434 VAR_OS=bsd 15435 VAR_OS_TYPE=unix 15436 ;; 15437 *cygwin*) 15438 VAR_OS=windows 15439 VAR_OS_ENV=windows.cygwin 15440 ;; 15441 *mingw*) 15442 VAR_OS=windows 15443 VAR_OS_ENV=windows.msys 15444 ;; 15445 *aix*) 15446 VAR_OS=aix 15447 VAR_OS_TYPE=unix 15448 ;; 15449 *) 15450 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15451 ;; 15452 esac 15453 15454 15455 # First argument is the cpu name from the trip/quad 15456 case "$build_cpu" in 15457 x86_64) 15458 VAR_CPU=x86_64 15459 VAR_CPU_ARCH=x86 15460 VAR_CPU_BITS=64 15461 VAR_CPU_ENDIAN=little 15462 ;; 15463 i?86) 15464 VAR_CPU=x86 15465 VAR_CPU_ARCH=x86 15466 VAR_CPU_BITS=32 15467 VAR_CPU_ENDIAN=little 15468 ;; 15469 arm*) 15470 VAR_CPU=arm 15471 VAR_CPU_ARCH=arm 15472 VAR_CPU_BITS=32 15473 VAR_CPU_ENDIAN=little 15474 ;; 15475 aarch64) 15476 VAR_CPU=aarch64 15477 VAR_CPU_ARCH=aarch64 15478 VAR_CPU_BITS=64 15479 VAR_CPU_ENDIAN=little 15480 ;; 15481 powerpc) 15482 VAR_CPU=ppc 15483 VAR_CPU_ARCH=ppc 15484 VAR_CPU_BITS=32 15485 VAR_CPU_ENDIAN=big 15486 ;; 15487 powerpc64) 15488 VAR_CPU=ppc64 15489 VAR_CPU_ARCH=ppc 15490 VAR_CPU_BITS=64 15491 VAR_CPU_ENDIAN=big 15492 ;; 15493 powerpc64le) 15494 VAR_CPU=ppc64le 15495 VAR_CPU_ARCH=ppc 15496 VAR_CPU_BITS=64 15497 VAR_CPU_ENDIAN=little 15498 ;; 15499 s390) 15500 VAR_CPU=s390 15501 VAR_CPU_ARCH=s390 15502 VAR_CPU_BITS=32 15503 VAR_CPU_ENDIAN=big 15504 ;; 15505 s390x) 15506 VAR_CPU=s390x 15507 VAR_CPU_ARCH=s390 15508 VAR_CPU_BITS=64 15509 VAR_CPU_ENDIAN=big 15510 ;; 15511 sparc) 15512 VAR_CPU=sparc 15513 VAR_CPU_ARCH=sparc 15514 VAR_CPU_BITS=32 15515 VAR_CPU_ENDIAN=big 15516 ;; 15517 sparcv9|sparc64) 15518 VAR_CPU=sparcv9 15519 VAR_CPU_ARCH=sparc 15520 VAR_CPU_BITS=64 15521 VAR_CPU_ENDIAN=big 15522 ;; 15523 *) 15524 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15525 ;; 15526 esac 15527 15528 # ..and setup our own variables. (Do this explicitely to facilitate searching) 15529 OPENJDK_BUILD_OS="$VAR_OS" 15530 if test "x$VAR_OS_TYPE" != x; then 15531 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15532 else 15533 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15534 fi 15535 if test "x$VAR_OS_ENV" != x; then 15536 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15537 else 15538 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15539 fi 15540 OPENJDK_BUILD_CPU="$VAR_CPU" 15541 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15542 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15543 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15544 15545 15546 15547 15548 15549 15550 15551 15552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15553 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15555 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15556 15557 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15558 15559 case "$host_os" in 15560 *linux*) 15561 VAR_OS=linux 15562 VAR_OS_TYPE=unix 15563 ;; 15564 *solaris*) 15565 VAR_OS=solaris 15566 VAR_OS_TYPE=unix 15567 ;; 15568 *darwin*) 15569 VAR_OS=macosx 15570 VAR_OS_TYPE=unix 15571 ;; 15572 *bsd*) 15573 VAR_OS=bsd 15574 VAR_OS_TYPE=unix 15575 ;; 15576 *cygwin*) 15577 VAR_OS=windows 15578 VAR_OS_ENV=windows.cygwin 15579 ;; 15580 *mingw*) 15581 VAR_OS=windows 15582 VAR_OS_ENV=windows.msys 15583 ;; 15584 *aix*) 15585 VAR_OS=aix 15586 VAR_OS_TYPE=unix 15587 ;; 15588 *) 15589 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15590 ;; 15591 esac 15592 15593 15594 # First argument is the cpu name from the trip/quad 15595 case "$host_cpu" in 15596 x86_64) 15597 VAR_CPU=x86_64 15598 VAR_CPU_ARCH=x86 15599 VAR_CPU_BITS=64 15600 VAR_CPU_ENDIAN=little 15601 ;; 15602 i?86) 15603 VAR_CPU=x86 15604 VAR_CPU_ARCH=x86 15605 VAR_CPU_BITS=32 15606 VAR_CPU_ENDIAN=little 15607 ;; 15608 arm*) 15609 VAR_CPU=arm 15610 VAR_CPU_ARCH=arm 15611 VAR_CPU_BITS=32 15612 VAR_CPU_ENDIAN=little 15613 ;; 15614 aarch64) 15615 VAR_CPU=aarch64 15616 VAR_CPU_ARCH=aarch64 15617 VAR_CPU_BITS=64 15618 VAR_CPU_ENDIAN=little 15619 ;; 15620 powerpc) 15621 VAR_CPU=ppc 15622 VAR_CPU_ARCH=ppc 15623 VAR_CPU_BITS=32 15624 VAR_CPU_ENDIAN=big 15625 ;; 15626 powerpc64) 15627 VAR_CPU=ppc64 15628 VAR_CPU_ARCH=ppc 15629 VAR_CPU_BITS=64 15630 VAR_CPU_ENDIAN=big 15631 ;; 15632 powerpc64le) 15633 VAR_CPU=ppc64le 15634 VAR_CPU_ARCH=ppc 15635 VAR_CPU_BITS=64 15636 VAR_CPU_ENDIAN=little 15637 ;; 15638 s390) 15639 VAR_CPU=s390 15640 VAR_CPU_ARCH=s390 15641 VAR_CPU_BITS=32 15642 VAR_CPU_ENDIAN=big 15643 ;; 15644 s390x) 15645 VAR_CPU=s390x 15646 VAR_CPU_ARCH=s390 15647 VAR_CPU_BITS=64 15648 VAR_CPU_ENDIAN=big 15649 ;; 15650 sparc) 15651 VAR_CPU=sparc 15652 VAR_CPU_ARCH=sparc 15653 VAR_CPU_BITS=32 15654 VAR_CPU_ENDIAN=big 15655 ;; 15656 sparcv9|sparc64) 15657 VAR_CPU=sparcv9 15658 VAR_CPU_ARCH=sparc 15659 VAR_CPU_BITS=64 15660 VAR_CPU_ENDIAN=big 15661 ;; 15662 *) 15663 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 15664 ;; 15665 esac 15666 15667 # ... and setup our own variables. (Do this explicitely to facilitate searching) 15668 OPENJDK_TARGET_OS="$VAR_OS" 15669 if test "x$VAR_OS_TYPE" != x; then 15670 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 15671 else 15672 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 15673 fi 15674 if test "x$VAR_OS_ENV" != x; then 15675 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 15676 else 15677 OPENJDK_TARGET_OS_ENV="$VAR_OS" 15678 fi 15679 OPENJDK_TARGET_CPU="$VAR_CPU" 15680 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 15681 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 15682 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15683 15684 15685 15686 15687 15688 15689 15690 15691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 15692 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 15693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 15694 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 15695 15696 15697 15698 # Check whether --with-target-bits was given. 15699 if test "${with_target_bits+set}" = set; then : 15700 withval=$with_target_bits; 15701 fi 15702 15703 15704 # We have three types of compiles: 15705 # native == normal compilation, target system == build system 15706 # cross == traditional cross compilation, target system != build system; special toolchain needed 15707 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 15708 # 15709 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 15710 # We're doing a proper cross-compilation 15711 COMPILE_TYPE="cross" 15712 else 15713 COMPILE_TYPE="native" 15714 fi 15715 15716 if test "x$with_target_bits" != x; then 15717 if test "x$COMPILE_TYPE" = "xcross"; then 15718 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 15719 fi 15720 15721 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15722 # A reduced build is requested 15723 COMPILE_TYPE="reduced" 15724 OPENJDK_TARGET_CPU_BITS=32 15725 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 15726 OPENJDK_TARGET_CPU=x86 15727 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 15728 OPENJDK_TARGET_CPU=sparc 15729 else 15730 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 15731 fi 15732 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 15733 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 15734 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 15735 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 15736 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 15737 else 15738 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 15739 fi 15740 fi 15741 15742 15743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 15744 $as_echo_n "checking compilation type... " >&6; } 15745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 15746 $as_echo "$COMPILE_TYPE" >&6; } 15747 15748 15749 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 15750 REQUIRED_OS_NAME=SunOS 15751 REQUIRED_OS_VERSION=5.10 15752 fi 15753 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 15754 REQUIRED_OS_NAME=Linux 15755 REQUIRED_OS_VERSION=2.6 15756 fi 15757 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 15758 REQUIRED_OS_NAME=Windows 15759 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 15760 REQUIRED_OS_VERSION=5.2 15761 else 15762 REQUIRED_OS_VERSION=5.1 15763 fi 15764 fi 15765 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 15766 REQUIRED_OS_NAME=Darwin 15767 REQUIRED_OS_VERSION=11.2 15768 fi 15769 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 15770 REQUIRED_OS_NAME=AIX 15771 REQUIRED_OS_VERSION=7.1 15772 fi 15773 15774 15775 15776 15777 15778 15779 # Also store the legacy naming of the cpu. 15780 # Ie i586 and amd64 instead of x86 and x86_64 15781 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 15782 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15783 OPENJDK_TARGET_CPU_LEGACY="i586" 15784 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15785 # On all platforms except MacOSX replace x86_64 with amd64. 15786 OPENJDK_TARGET_CPU_LEGACY="amd64" 15787 fi 15788 15789 15790 # And the second legacy naming of the cpu. 15791 # Ie i386 and amd64 instead of x86 and x86_64. 15792 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 15793 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15794 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 15795 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15796 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 15797 fi 15798 15799 15800 # This is the name of the cpu (but using i386 and amd64 instead of 15801 # x86 and x86_64, respectively), preceeded by a /, to be used when 15802 # locating libraries. On macosx, it's empty, though. 15803 OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB" 15804 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15805 OPENJDK_TARGET_CPU_LIBDIR="" 15806 fi 15807 15808 15809 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15810 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15811 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 15812 OPENJDK_TARGET_CPU_ISADIR="" 15813 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15814 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15815 OPENJDK_TARGET_CPU_ISADIR="/amd64" 15816 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15817 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 15818 fi 15819 fi 15820 15821 15822 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 15823 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 15824 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 15825 # On linux only, we replace x86 with i386. 15826 OPENJDK_TARGET_CPU_OSARCH="i386" 15827 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15828 # On all platforms except macosx, we replace x86_64 with amd64. 15829 OPENJDK_TARGET_CPU_OSARCH="amd64" 15830 fi 15831 15832 15833 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 15834 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15835 OPENJDK_TARGET_CPU_JLI="i386" 15836 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15837 # On all platforms except macosx, we replace x86_64 with amd64. 15838 OPENJDK_TARGET_CPU_JLI="amd64" 15839 fi 15840 # Now setup the -D flags for building libjli. 15841 OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'" 15842 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15843 if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then 15844 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 15845 elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 15846 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 15847 fi 15848 fi 15849 15850 15851 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15852 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 15853 else 15854 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 15855 fi 15856 15857 15858 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 15859 # Macosx is osx and x86_64 is x64 15860 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15861 OPENJDK_TARGET_OS_BUNDLE="osx" 15862 else 15863 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 15864 fi 15865 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15866 OPENJDK_TARGET_CPU_BUNDLE="x64" 15867 else 15868 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 15869 fi 15870 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 15871 15872 15873 15874 15875 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15876 A_LP64="LP64:=" 15877 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 15878 # unpack200.exe 15879 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 15880 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 15881 fi 15882 fi 15883 LP64=$A_LP64 15884 15885 15886 if test "x$COMPILE_TYPE" = "xcross"; then 15887 # FIXME: ... or should this include reduced builds..? 15888 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 15889 else 15890 DEFINE_CROSS_COMPILE_ARCH="" 15891 fi 15892 15893 15894 # Convert openjdk platform names to hotspot names 15895 15896 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 15897 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15898 HOTSPOT_TARGET_OS=bsd 15899 fi 15900 15901 15902 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 15903 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 15904 HOTSPOT_TARGET_OS_TYPE=posix 15905 fi 15906 15907 15908 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 15909 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15910 HOTSPOT_TARGET_CPU=x86_32 15911 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15912 HOTSPOT_TARGET_CPU=sparc 15913 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 15914 HOTSPOT_TARGET_CPU=ppc_64 15915 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 15916 HOTSPOT_TARGET_CPU=ppc_64 15917 fi 15918 15919 15920 # This is identical with OPENJDK_*, but define anyway for consistency. 15921 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 15922 15923 15924 # Setup HOTSPOT_TARGET_CPU_DEFINE 15925 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15926 HOTSPOT_TARGET_CPU_DEFINE=IA32 15927 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15928 HOTSPOT_TARGET_CPU_DEFINE=AMD64 15929 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15930 HOTSPOT_TARGET_CPU_DEFINE=SPARC 15931 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 15932 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 15933 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 15934 HOTSPOT_TARGET_CPU_DEFINE=PPC64 15935 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 15936 HOTSPOT_TARGET_CPU_DEFINE=PPC64 15937 15938 # The cpu defines below are for zero, we don't support them directly. 15939 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 15940 HOTSPOT_TARGET_CPU_DEFINE=SPARC 15941 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 15942 HOTSPOT_TARGET_CPU_DEFINE=PPC32 15943 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 15944 HOTSPOT_TARGET_CPU_DEFINE=S390 15945 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 15946 HOTSPOT_TARGET_CPU_DEFINE=S390 15947 elif test "x$OPENJDK_TARGET_CPU" != x; then 15948 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 15949 fi 15950 15951 15952 15953 15954 # Also store the legacy naming of the cpu. 15955 # Ie i586 and amd64 instead of x86 and x86_64 15956 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 15957 if test "x$OPENJDK_BUILD_CPU" = xx86; then 15958 OPENJDK_BUILD_CPU_LEGACY="i586" 15959 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15960 # On all platforms except MacOSX replace x86_64 with amd64. 15961 OPENJDK_BUILD_CPU_LEGACY="amd64" 15962 fi 15963 15964 15965 # And the second legacy naming of the cpu. 15966 # Ie i386 and amd64 instead of x86 and x86_64. 15967 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 15968 if test "x$OPENJDK_BUILD_CPU" = xx86; then 15969 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 15970 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15971 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 15972 fi 15973 15974 15975 # This is the name of the cpu (but using i386 and amd64 instead of 15976 # x86 and x86_64, respectively), preceeded by a /, to be used when 15977 # locating libraries. On macosx, it's empty, though. 15978 OPENJDK_BUILD_CPU_LIBDIR="/$OPENJDK_BUILD_CPU_LEGACY_LIB" 15979 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 15980 OPENJDK_BUILD_CPU_LIBDIR="" 15981 fi 15982 15983 15984 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15985 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15986 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 15987 OPENJDK_BUILD_CPU_ISADIR="" 15988 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 15989 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15990 OPENJDK_BUILD_CPU_ISADIR="/amd64" 15991 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 15992 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 15993 fi 15994 fi 15995 15996 15997 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 15998 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 15999 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 16000 # On linux only, we replace x86 with i386. 16001 OPENJDK_BUILD_CPU_OSARCH="i386" 16002 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16003 # On all platforms except macosx, we replace x86_64 with amd64. 16004 OPENJDK_BUILD_CPU_OSARCH="amd64" 16005 fi 16006 16007 16008 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16009 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16010 OPENJDK_BUILD_CPU_JLI="i386" 16011 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16012 # On all platforms except macosx, we replace x86_64 with amd64. 16013 OPENJDK_BUILD_CPU_JLI="amd64" 16014 fi 16015 # Now setup the -D flags for building libjli. 16016 OPENJDK_BUILD_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_BUILD_CPU_JLI\"'" 16017 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16018 if test "x$OPENJDK_BUILD_CPU_ARCH" = xsparc; then 16019 OPENJDK_BUILD_CPU_JLI_CFLAGS="$OPENJDK_BUILD_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 16020 elif test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 16021 OPENJDK_BUILD_CPU_JLI_CFLAGS="$OPENJDK_BUILD_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 16022 fi 16023 fi 16024 16025 16026 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16027 OPENJDK_BUILD_OS_EXPORT_DIR=macosx 16028 else 16029 OPENJDK_BUILD_OS_EXPORT_DIR=${OPENJDK_BUILD_OS_TYPE} 16030 fi 16031 16032 16033 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16034 # Macosx is osx and x86_64 is x64 16035 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16036 OPENJDK_BUILD_OS_BUNDLE="osx" 16037 else 16038 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16039 fi 16040 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16041 OPENJDK_BUILD_CPU_BUNDLE="x64" 16042 else 16043 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16044 fi 16045 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16046 16047 16048 16049 16050 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16051 A_LP64="LP64:=" 16052 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16053 # unpack200.exe 16054 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16055 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16056 fi 16057 fi 16058 LP64=$A_LP64 16059 16060 16061 if test "x$COMPILE_TYPE" = "xcross"; then 16062 # FIXME: ... or should this include reduced builds..? 16063 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16064 else 16065 DEFINE_CROSS_COMPILE_ARCH="" 16066 fi 16067 16068 16069 # Convert openjdk platform names to hotspot names 16070 16071 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16072 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16073 HOTSPOT_BUILD_OS=bsd 16074 fi 16075 16076 16077 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16078 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16079 HOTSPOT_BUILD_OS_TYPE=posix 16080 fi 16081 16082 16083 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16084 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16085 HOTSPOT_BUILD_CPU=x86_32 16086 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16087 HOTSPOT_BUILD_CPU=sparc 16088 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16089 HOTSPOT_BUILD_CPU=ppc_64 16090 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16091 HOTSPOT_BUILD_CPU=ppc_64 16092 fi 16093 16094 16095 # This is identical with OPENJDK_*, but define anyway for consistency. 16096 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16097 16098 16099 # Setup HOTSPOT_BUILD_CPU_DEFINE 16100 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16101 HOTSPOT_BUILD_CPU_DEFINE=IA32 16102 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16103 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16104 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16105 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16106 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16107 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16108 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16109 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16110 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16111 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16112 16113 # The cpu defines below are for zero, we don't support them directly. 16114 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16115 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16116 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16117 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16118 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16119 HOTSPOT_BUILD_CPU_DEFINE=S390 16120 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16121 HOTSPOT_BUILD_CPU_DEFINE=S390 16122 elif test "x$OPENJDK_BUILD_CPU" != x; then 16123 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16124 fi 16125 16126 16127 16128 16129 # ZERO_ARCHDEF is used to enable architecture-specific code. 16130 # This is used in legacy hotspot build. 16131 ZERO_ARCHDEF="$HOTSPOT_TARGET_CPU_DEFINE" 16132 16133 16134 16135 16136 16137 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16138 16139 # Save the current directory this script was started from 16140 CURDIR="$PWD" 16141 16142 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16143 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16144 # was not available at that time. 16145 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16146 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16147 ORIGINAL_PATH="$REWRITTEN_PATH" 16148 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16149 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16150 fi 16151 16152 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16153 PATH_SEP=";" 16154 16155 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16156 if test $SRC_ROOT_LENGTH -gt 100; then 16157 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16158 fi 16159 16160 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16162 $as_echo_n "checking cygwin release... " >&6; } 16163 CYGWIN_VERSION=`$UNAME -r` 16164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16165 $as_echo "$CYGWIN_VERSION" >&6; } 16166 WINDOWS_ENV_VENDOR='cygwin' 16167 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16168 16169 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16170 if test "x$CYGWIN_VERSION_OLD" != x; then 16171 { $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 16172 $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;} 16173 as_fn_error $? "Cannot continue" "$LINENO" 5 16174 fi 16175 if test "x$CYGPATH" = x; then 16176 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16177 fi 16178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16179 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16180 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16181 cygwin_winpath_root=`cd / ; cmd /c cd | $GREP ".*"` 16182 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16183 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16185 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16186 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16187 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16188 if test "x$test_cygdrive_prefix" = x; then 16189 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16190 fi 16191 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16193 $as_echo_n "checking msys release... " >&6; } 16194 MSYS_VERSION=`$UNAME -r` 16195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16196 $as_echo "$MSYS_VERSION" >&6; } 16197 16198 WINDOWS_ENV_VENDOR='msys' 16199 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16200 16201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16202 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16203 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16204 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16205 16206 windows_path="$MSYS_ROOT_PATH" 16207 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16208 unix_path=`$CYGPATH -u "$windows_path"` 16209 MSYS_ROOT_PATH="$unix_path" 16210 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16211 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16212 MSYS_ROOT_PATH="$unix_path" 16213 fi 16214 16215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16216 $as_echo "$MSYS_ROOT_PATH" >&6; } 16217 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16218 else 16219 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16220 fi 16221 16222 # Test if windows or unix (cygwin/msys) find is first in path. 16223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16224 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16225 FIND_BINARY_OUTPUT=`find --version 2>&1` 16226 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16228 $as_echo "unix style" >&6; } 16229 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16231 $as_echo "Windows" >&6; } 16232 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16233 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16234 { $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 16235 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16236 as_fn_error $? "Cannot continue" "$LINENO" 5 16237 else 16238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16239 $as_echo "unknown" >&6; } 16240 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16241 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16242 fi 16243 16244 else 16245 PATH_SEP=":" 16246 fi 16247 16248 16249 # We get the top-level directory from the supporting wrappers. 16250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16251 $as_echo_n "checking for top-level directory... " >&6; } 16252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16253 $as_echo "$TOPDIR" >&6; } 16254 16255 16256 # Save the original version of TOPDIR for string comparisons 16257 ORIGINAL_TOPDIR="$TOPDIR" 16258 16259 16260 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16261 16262 # Only process if variable expands to non-empty 16263 16264 if test "x$CURDIR" != x; then 16265 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16266 16267 # Input might be given as Windows format, start by converting to 16268 # unix format. 16269 path="$CURDIR" 16270 new_path=`$CYGPATH -u "$path"` 16271 16272 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16273 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16274 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16275 # "foo.exe" is OK but "foo" is an error. 16276 # 16277 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16278 # It is also a way to make sure we got the proper file name for the real test later on. 16279 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16280 if test "x$test_shortpath" = x; then 16281 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16282 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16283 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16284 fi 16285 16286 # Call helper function which possibly converts this using DOS-style short mode. 16287 # If so, the updated path is stored in $new_path. 16288 16289 input_path="$new_path" 16290 # Check if we need to convert this using DOS-style short mode. If the path 16291 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16292 # take no chances and rewrite it. 16293 # Note: m4 eats our [], so we need to use [ and ] instead. 16294 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16295 if test "x$has_forbidden_chars" != x; then 16296 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16297 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16298 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16299 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16300 # Going to short mode and back again did indeed matter. Since short mode is 16301 # case insensitive, let's make it lowercase to improve readability. 16302 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16303 # Now convert it back to Unix-style (cygpath) 16304 input_path=`$CYGPATH -u "$shortmode_path"` 16305 new_path="$input_path" 16306 fi 16307 fi 16308 16309 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16310 if test "x$test_cygdrive_prefix" = x; then 16311 # As a simple fix, exclude /usr/bin since it's not a real path. 16312 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16313 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16314 # a path prefixed by /cygdrive for fixpath to work. 16315 new_path="$CYGWIN_ROOT_PATH$input_path" 16316 fi 16317 fi 16318 16319 16320 if test "x$path" != "x$new_path"; then 16321 CURDIR="$new_path" 16322 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16323 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16324 fi 16325 16326 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16327 16328 path="$CURDIR" 16329 has_colon=`$ECHO $path | $GREP ^.:` 16330 new_path="$path" 16331 if test "x$has_colon" = x; then 16332 # Not in mixed or Windows style, start by that. 16333 new_path=`cmd //c echo $path` 16334 fi 16335 16336 16337 input_path="$new_path" 16338 # Check if we need to convert this using DOS-style short mode. If the path 16339 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16340 # take no chances and rewrite it. 16341 # Note: m4 eats our [], so we need to use [ and ] instead. 16342 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16343 if test "x$has_forbidden_chars" != x; then 16344 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16345 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16346 fi 16347 16348 16349 windows_path="$new_path" 16350 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16351 unix_path=`$CYGPATH -u "$windows_path"` 16352 new_path="$unix_path" 16353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16354 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16355 new_path="$unix_path" 16356 fi 16357 16358 if test "x$path" != "x$new_path"; then 16359 CURDIR="$new_path" 16360 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16361 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16362 fi 16363 16364 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16365 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16366 16367 else 16368 # We're on a unix platform. Hooray! :) 16369 path="$CURDIR" 16370 has_space=`$ECHO "$path" | $GREP " "` 16371 if test "x$has_space" != x; then 16372 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16373 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16374 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16375 fi 16376 16377 # Use eval to expand a potential ~ 16378 eval path="$path" 16379 if test ! -f "$path" && test ! -d "$path"; then 16380 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16381 fi 16382 16383 if test -d "$path"; then 16384 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16385 else 16386 dir="`$DIRNAME "$path"`" 16387 base="`$BASENAME "$path"`" 16388 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16389 fi 16390 fi 16391 fi 16392 16393 16394 # Only process if variable expands to non-empty 16395 16396 if test "x$TOPDIR" != x; then 16397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16398 16399 # Input might be given as Windows format, start by converting to 16400 # unix format. 16401 path="$TOPDIR" 16402 new_path=`$CYGPATH -u "$path"` 16403 16404 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16405 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16406 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16407 # "foo.exe" is OK but "foo" is an error. 16408 # 16409 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16410 # It is also a way to make sure we got the proper file name for the real test later on. 16411 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16412 if test "x$test_shortpath" = x; then 16413 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16414 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16415 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16416 fi 16417 16418 # Call helper function which possibly converts this using DOS-style short mode. 16419 # If so, the updated path is stored in $new_path. 16420 16421 input_path="$new_path" 16422 # Check if we need to convert this using DOS-style short mode. If the path 16423 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16424 # take no chances and rewrite it. 16425 # Note: m4 eats our [], so we need to use [ and ] instead. 16426 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16427 if test "x$has_forbidden_chars" != x; then 16428 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16429 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16430 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16431 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16432 # Going to short mode and back again did indeed matter. Since short mode is 16433 # case insensitive, let's make it lowercase to improve readability. 16434 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16435 # Now convert it back to Unix-style (cygpath) 16436 input_path=`$CYGPATH -u "$shortmode_path"` 16437 new_path="$input_path" 16438 fi 16439 fi 16440 16441 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16442 if test "x$test_cygdrive_prefix" = x; then 16443 # As a simple fix, exclude /usr/bin since it's not a real path. 16444 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16445 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16446 # a path prefixed by /cygdrive for fixpath to work. 16447 new_path="$CYGWIN_ROOT_PATH$input_path" 16448 fi 16449 fi 16450 16451 16452 if test "x$path" != "x$new_path"; then 16453 TOPDIR="$new_path" 16454 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16455 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16456 fi 16457 16458 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16459 16460 path="$TOPDIR" 16461 has_colon=`$ECHO $path | $GREP ^.:` 16462 new_path="$path" 16463 if test "x$has_colon" = x; then 16464 # Not in mixed or Windows style, start by that. 16465 new_path=`cmd //c echo $path` 16466 fi 16467 16468 16469 input_path="$new_path" 16470 # Check if we need to convert this using DOS-style short mode. If the path 16471 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16472 # take no chances and rewrite it. 16473 # Note: m4 eats our [], so we need to use [ and ] instead. 16474 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16475 if test "x$has_forbidden_chars" != x; then 16476 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16477 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16478 fi 16479 16480 16481 windows_path="$new_path" 16482 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16483 unix_path=`$CYGPATH -u "$windows_path"` 16484 new_path="$unix_path" 16485 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16486 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16487 new_path="$unix_path" 16488 fi 16489 16490 if test "x$path" != "x$new_path"; then 16491 TOPDIR="$new_path" 16492 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16493 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16494 fi 16495 16496 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16497 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16498 16499 else 16500 # We're on a unix platform. Hooray! :) 16501 path="$TOPDIR" 16502 has_space=`$ECHO "$path" | $GREP " "` 16503 if test "x$has_space" != x; then 16504 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16505 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16506 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16507 fi 16508 16509 # Use eval to expand a potential ~ 16510 eval path="$path" 16511 if test ! -f "$path" && test ! -d "$path"; then 16512 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16513 fi 16514 16515 if test -d "$path"; then 16516 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16517 else 16518 dir="`$DIRNAME "$path"`" 16519 base="`$BASENAME "$path"`" 16520 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16521 fi 16522 fi 16523 fi 16524 16525 # SRC_ROOT is a traditional alias for TOPDIR. 16526 SRC_ROOT=$TOPDIR 16527 16528 # Calculate a canonical version of TOPDIR for string comparisons 16529 CANONICAL_TOPDIR=$TOPDIR 16530 16531 if test "x$OPENJDK_BUILD_OS" != xwindows; then 16532 # Follow a chain of symbolic links. Use readlink 16533 # where it exists, else fall back to horribly 16534 # complicated shell code. 16535 if test "x$READLINK_TESTED" != yes; then 16536 # On MacOSX there is a readlink tool with a different 16537 # purpose than the GNU readlink tool. Check the found readlink. 16538 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 16539 if test "x$ISGNU" = x; then 16540 # A readlink that we do not know how to use. 16541 # Are there other non-GNU readlinks out there? 16542 READLINK_TESTED=yes 16543 READLINK= 16544 fi 16545 fi 16546 16547 if test "x$READLINK" != x; then 16548 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 16549 else 16550 # Save the current directory for restoring afterwards 16551 STARTDIR=$PWD 16552 COUNTER=0 16553 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 16554 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 16555 cd $sym_link_dir 16556 # Use -P flag to resolve symlinks in directories. 16557 cd `$THEPWDCMD -P` 16558 sym_link_dir=`$THEPWDCMD -P` 16559 # Resolve file symlinks 16560 while test $COUNTER -lt 20; do 16561 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 16562 if test "x$ISLINK" == x; then 16563 # This is not a symbolic link! We are done! 16564 break 16565 fi 16566 # Again resolve directory symlinks since the target of the just found 16567 # link could be in a different directory 16568 cd `$DIRNAME $ISLINK` 16569 sym_link_dir=`$THEPWDCMD -P` 16570 sym_link_file=`$BASENAME $ISLINK` 16571 let COUNTER=COUNTER+1 16572 done 16573 cd $STARTDIR 16574 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 16575 fi 16576 fi 16577 16578 16579 16580 # Locate the directory of this script. 16581 AUTOCONF_DIR=$TOPDIR/common/autoconf 16582 16583 # Setup username (for use in adhoc version strings etc) 16584 # Outer [ ] to quote m4. 16585 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16586 16587 16588 16589 # Check if it's a pure open build or if custom sources are to be used. 16590 16591 # Check whether --enable-openjdk-only was given. 16592 if test "${enable_openjdk_only+set}" = set; then : 16593 enableval=$enable_openjdk_only; 16594 else 16595 enable_openjdk_only="no" 16596 fi 16597 16598 16599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16600 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16602 $as_echo "$enable_openjdk_only" >&6; } 16603 if test "x$enable_openjdk_only" = "xyes"; then 16604 SUPPRESS_CUSTOM_EXTENSIONS="true" 16605 elif test "x$enable_openjdk_only" = "xno"; then 16606 SUPPRESS_CUSTOM_EXTENSIONS="false" 16607 else 16608 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16609 fi 16610 16611 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16612 # the IncludeCustomExtension macro. 16613 16614 16615 # Check whether --with-custom-make-dir was given. 16616 if test "${with_custom_make_dir+set}" = set; then : 16617 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 16618 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16619 fi 16620 16621 16622 16623 16624 # These are needed to be able to create a configuration name (and thus the output directory) 16625 16626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16627 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16628 16629 # Check whether --with-jdk-variant was given. 16630 if test "${with_jdk_variant+set}" = set; then : 16631 withval=$with_jdk_variant; 16632 fi 16633 16634 16635 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16636 JDK_VARIANT="normal" 16637 else 16638 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16639 fi 16640 16641 16642 16643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16644 $as_echo "$JDK_VARIANT" >&6; } 16645 16646 16647 DEBUG_LEVEL="release" 16648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16649 $as_echo_n "checking which debug level to use... " >&6; } 16650 # Check whether --enable-debug was given. 16651 if test "${enable_debug+set}" = set; then : 16652 enableval=$enable_debug; 16653 ENABLE_DEBUG="${enableval}" 16654 DEBUG_LEVEL="fastdebug" 16655 16656 else 16657 ENABLE_DEBUG="no" 16658 fi 16659 16660 16661 16662 # Check whether --with-debug-level was given. 16663 if test "${with_debug_level+set}" = set; then : 16664 withval=$with_debug_level; 16665 DEBUG_LEVEL="${withval}" 16666 if test "x$ENABLE_DEBUG" = xyes; then 16667 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16668 fi 16669 16670 fi 16671 16672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16673 $as_echo "$DEBUG_LEVEL" >&6; } 16674 16675 if test "x$DEBUG_LEVEL" != xrelease && \ 16676 test "x$DEBUG_LEVEL" != xoptimized && \ 16677 test "x$DEBUG_LEVEL" != xfastdebug && \ 16678 test "x$DEBUG_LEVEL" != xslowdebug; then 16679 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16680 fi 16681 16682 # Translate DEBUG_LEVEL to debug level used by Hotspot 16683 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16684 if test "x$DEBUG_LEVEL" = xrelease; then 16685 HOTSPOT_DEBUG_LEVEL="product" 16686 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16687 HOTSPOT_DEBUG_LEVEL="debug" 16688 fi 16689 16690 if test "x$DEBUG_LEVEL" = xoptimized; then 16691 # The debug level 'optimized' is a little special because it is currently only 16692 # applicable to the HotSpot build where it means to build a completely 16693 # optimized version of the VM without any debugging code (like for the 16694 # 'release' debug level which is called 'product' in the HotSpot build) but 16695 # with the exception that it can contain additional code which is otherwise 16696 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16697 # test new and/or experimental features which are not intended for customer 16698 # shipment. Because these new features need to be tested and benchmarked in 16699 # real world scenarios, we want to build the containing JDK at the 'release' 16700 # debug level. 16701 DEBUG_LEVEL="release" 16702 fi 16703 16704 16705 16706 16707 16708 16709 # Check whether --with-jvm-variants was given. 16710 if test "${with_jvm_variants+set}" = set; then : 16711 withval=$with_jvm_variants; 16712 fi 16713 16714 16715 if test "x$with_jvm_variants" = x; then 16716 with_jvm_variants="server" 16717 fi 16718 JVM_VARIANTS_OPT="$with_jvm_variants" 16719 16720 # Has the user listed more than one variant? 16721 # Additional [] needed to keep m4 from mangling shell constructs. 16722 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 16723 BUILDING_MULTIPLE_JVM_VARIANTS=true 16724 else 16725 BUILDING_MULTIPLE_JVM_VARIANTS=false 16726 fi 16727 # Replace the commas with AND for use in the build directory name. 16728 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 16729 16730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 16731 $as_echo_n "checking which variants of the JVM to build... " >&6; } 16732 # JVM_VARIANTS is a space-separated list. 16733 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 16734 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 16735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 16736 $as_echo "$JVM_VARIANTS" >&6; } 16737 16738 # Check that the selected variants are valid 16739 16740 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 16741 # Notice that the original variant failes on SLES 10 and 11 16742 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 16743 STACK=${JVM_VARIANTS// /$'\n'} 16744 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16745 if test "x$INVALID_VARIANTS" != x; then 16746 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 16747 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 16748 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 16749 fi 16750 16751 # All "special" variants share the same output directory ("server") 16752 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 16753 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 16754 STACK=${JVM_VARIANTS// /$'\n'} 16755 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16756 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 16757 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 16758 fi 16759 16760 16761 16762 16763 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 16764 # zero behaves as a platform and rewrites these values. This is really weird. :( 16765 # We are guaranteed that we do not build any other variants when building zero. 16766 HOTSPOT_TARGET_CPU=zero 16767 HOTSPOT_TARGET_CPU_ARCH=zero 16768 fi 16769 16770 16771 # With basic setup done, call the custom early hook. 16772 16773 16774 # Check if we have devkits, extra paths or sysroot set. 16775 16776 16777 # Check whether --with-devkit was given. 16778 if test "${with_devkit+set}" = set; then : 16779 withval=$with_devkit; 16780 16781 # Only process if variable expands to non-empty 16782 16783 if test "x$with_devkit" != x; then 16784 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16785 16786 # Input might be given as Windows format, start by converting to 16787 # unix format. 16788 path="$with_devkit" 16789 new_path=`$CYGPATH -u "$path"` 16790 16791 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16792 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16793 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16794 # "foo.exe" is OK but "foo" is an error. 16795 # 16796 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16797 # It is also a way to make sure we got the proper file name for the real test later on. 16798 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16799 if test "x$test_shortpath" = x; then 16800 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16801 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16802 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 16803 fi 16804 16805 # Call helper function which possibly converts this using DOS-style short mode. 16806 # If so, the updated path is stored in $new_path. 16807 16808 input_path="$new_path" 16809 # Check if we need to convert this using DOS-style short mode. If the path 16810 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16811 # take no chances and rewrite it. 16812 # Note: m4 eats our [], so we need to use [ and ] instead. 16813 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16814 if test "x$has_forbidden_chars" != x; then 16815 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16816 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16817 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16818 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16819 # Going to short mode and back again did indeed matter. Since short mode is 16820 # case insensitive, let's make it lowercase to improve readability. 16821 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16822 # Now convert it back to Unix-style (cygpath) 16823 input_path=`$CYGPATH -u "$shortmode_path"` 16824 new_path="$input_path" 16825 fi 16826 fi 16827 16828 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16829 if test "x$test_cygdrive_prefix" = x; then 16830 # As a simple fix, exclude /usr/bin since it's not a real path. 16831 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16832 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16833 # a path prefixed by /cygdrive for fixpath to work. 16834 new_path="$CYGWIN_ROOT_PATH$input_path" 16835 fi 16836 fi 16837 16838 16839 if test "x$path" != "x$new_path"; then 16840 with_devkit="$new_path" 16841 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16842 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16843 fi 16844 16845 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16846 16847 path="$with_devkit" 16848 has_colon=`$ECHO $path | $GREP ^.:` 16849 new_path="$path" 16850 if test "x$has_colon" = x; then 16851 # Not in mixed or Windows style, start by that. 16852 new_path=`cmd //c echo $path` 16853 fi 16854 16855 16856 input_path="$new_path" 16857 # Check if we need to convert this using DOS-style short mode. If the path 16858 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16859 # take no chances and rewrite it. 16860 # Note: m4 eats our [], so we need to use [ and ] instead. 16861 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16862 if test "x$has_forbidden_chars" != x; then 16863 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16864 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16865 fi 16866 16867 16868 windows_path="$new_path" 16869 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16870 unix_path=`$CYGPATH -u "$windows_path"` 16871 new_path="$unix_path" 16872 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16873 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16874 new_path="$unix_path" 16875 fi 16876 16877 if test "x$path" != "x$new_path"; then 16878 with_devkit="$new_path" 16879 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16880 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16881 fi 16882 16883 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16884 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16885 16886 else 16887 # We're on a unix platform. Hooray! :) 16888 path="$with_devkit" 16889 has_space=`$ECHO "$path" | $GREP " "` 16890 if test "x$has_space" != x; then 16891 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16892 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16893 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16894 fi 16895 16896 # Use eval to expand a potential ~ 16897 eval path="$path" 16898 if test ! -f "$path" && test ! -d "$path"; then 16899 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 16900 fi 16901 16902 if test -d "$path"; then 16903 with_devkit="`cd "$path"; $THEPWDCMD -L`" 16904 else 16905 dir="`$DIRNAME "$path"`" 16906 base="`$BASENAME "$path"`" 16907 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 16908 fi 16909 fi 16910 fi 16911 16912 DEVKIT_ROOT="$with_devkit" 16913 # Check for a meta data info file in the root of the devkit 16914 if test -f "$DEVKIT_ROOT/devkit.info"; then 16915 . $DEVKIT_ROOT/devkit.info 16916 # This potentially sets the following: 16917 # A descriptive name of the devkit 16918 16919 if test "x$DEVKIT_NAME" = x; then 16920 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 16921 fi 16922 16923 # Corresponds to --with-extra-path 16924 16925 if test "x$DEVKIT_EXTRA_PATH" = x; then 16926 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 16927 fi 16928 16929 # Corresponds to --with-toolchain-path 16930 16931 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16932 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 16933 fi 16934 16935 # Corresponds to --with-sysroot 16936 16937 if test "x$DEVKIT_SYSROOT" = x; then 16938 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 16939 fi 16940 16941 16942 # Identifies the Visual Studio version in the devkit 16943 16944 if test "x$DEVKIT_VS_VERSION" = x; then 16945 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 16946 fi 16947 16948 # The Visual Studio include environment variable 16949 16950 if test "x$DEVKIT_VS_INCLUDE" = x; then 16951 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 16952 fi 16953 16954 # The Visual Studio lib environment variable 16955 16956 if test "x$DEVKIT_VS_LIB" = x; then 16957 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 16958 fi 16959 16960 # Corresponds to --with-msvcr-dll 16961 16962 if test "x$DEVKIT_MSVCR_DLL" = x; then 16963 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 16964 fi 16965 16966 # Corresponds to --with-msvcp-dll 16967 16968 if test "x$DEVKIT_MSVCP_DLL" = x; then 16969 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 16970 fi 16971 16972 fi 16973 16974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 16975 $as_echo_n "checking for devkit... " >&6; } 16976 if test "x$DEVKIT_NAME" != x; then 16977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 16978 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 16979 else 16980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 16981 $as_echo "$DEVKIT_ROOT" >&6; } 16982 fi 16983 16984 16985 if test "x$DEVKIT_EXTRA_PATH" != x; then 16986 if test "x$EXTRA_PATH" = x; then 16987 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 16988 else 16989 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 16990 fi 16991 fi 16992 16993 16994 # Fallback default of just /bin if DEVKIT_PATH is not defined 16995 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16996 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 16997 fi 16998 16999 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 17000 if test "x$TOOLCHAIN_PATH" = x; then 17001 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 17002 else 17003 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17004 fi 17005 fi 17006 17007 17008 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17009 # places for backwards compatiblity. 17010 if test "x$DEVKIT_SYSROOT" != x; then 17011 SYSROOT="$DEVKIT_SYSROOT" 17012 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17013 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17014 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17015 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17016 fi 17017 17018 17019 fi 17020 17021 17022 # You can force the sysroot if the sysroot encoded into the compiler tools 17023 # is not correct. 17024 17025 # Check whether --with-sys-root was given. 17026 if test "${with_sys_root+set}" = set; then : 17027 withval=$with_sys_root; SYSROOT=$with_sys_root 17028 17029 fi 17030 17031 17032 17033 # Check whether --with-sysroot was given. 17034 if test "${with_sysroot+set}" = set; then : 17035 withval=$with_sysroot; SYSROOT=$with_sysroot 17036 17037 fi 17038 17039 17040 17041 # Check whether --with-tools-dir was given. 17042 if test "${with_tools_dir+set}" = set; then : 17043 withval=$with_tools_dir; 17044 if test "x$with_tools_dir" != x; then 17045 if test "x$TOOLCHAIN_PATH" = x; then 17046 TOOLCHAIN_PATH="$with_tools_dir" 17047 else 17048 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17049 fi 17050 fi 17051 17052 17053 fi 17054 17055 17056 17057 # Check whether --with-toolchain-path was given. 17058 if test "${with_toolchain_path+set}" = set; then : 17059 withval=$with_toolchain_path; 17060 if test "x$with_toolchain_path" != x; then 17061 if test "x$TOOLCHAIN_PATH" = x; then 17062 TOOLCHAIN_PATH="$with_toolchain_path" 17063 else 17064 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17065 fi 17066 fi 17067 17068 17069 fi 17070 17071 17072 17073 # Check whether --with-extra-path was given. 17074 if test "${with_extra_path+set}" = set; then : 17075 withval=$with_extra_path; 17076 if test "x$with_extra_path" != x; then 17077 if test "x$EXTRA_PATH" = x; then 17078 EXTRA_PATH="$with_extra_path" 17079 else 17080 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17081 fi 17082 fi 17083 17084 17085 fi 17086 17087 17088 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17089 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17090 # If not, detect if Xcode is installed by running xcodebuild -version 17091 # if no Xcode installed, xcodebuild exits with 1 17092 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17093 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17094 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17095 # fall back on the stub binary in /usr/bin/xcodebuild 17096 # Extract the first word of "xcodebuild", so it can be a program name with args. 17097 set dummy xcodebuild; ac_word=$2 17098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17099 $as_echo_n "checking for $ac_word... " >&6; } 17100 if ${ac_cv_path_XCODEBUILD+:} false; then : 17101 $as_echo_n "(cached) " >&6 17102 else 17103 case $XCODEBUILD in 17104 [\\/]* | ?:[\\/]*) 17105 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17106 ;; 17107 *) 17108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17109 for as_dir in $TOOLCHAIN_PATH 17110 do 17111 IFS=$as_save_IFS 17112 test -z "$as_dir" && as_dir=. 17113 for ac_exec_ext in '' $ac_executable_extensions; do 17114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17115 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17117 break 2 17118 fi 17119 done 17120 done 17121 IFS=$as_save_IFS 17122 17123 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17124 ;; 17125 esac 17126 fi 17127 XCODEBUILD=$ac_cv_path_XCODEBUILD 17128 if test -n "$XCODEBUILD"; then 17129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17130 $as_echo "$XCODEBUILD" >&6; } 17131 else 17132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17133 $as_echo "no" >&6; } 17134 fi 17135 17136 17137 else 17138 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17139 # when only the command line tools are installed there are no SDKs, so headers 17140 # are copied into the system frameworks 17141 XCODEBUILD= 17142 17143 fi 17144 17145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17146 $as_echo_n "checking for sdk name... " >&6; } 17147 17148 # Check whether --with-sdk-name was given. 17149 if test "${with_sdk_name+set}" = set; then : 17150 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17151 17152 fi 17153 17154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17155 $as_echo "$SDKNAME" >&6; } 17156 17157 # if toolchain path is specified then don't rely on system headers, they may not compile 17158 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17159 test -z "$TOOLCHAIN_PATH" && \ 17160 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17161 17162 if test -z "$SYSROOT"; then 17163 if test -n "$XCODEBUILD"; then 17164 # if we don't have system headers, use default SDK name (last resort) 17165 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17166 SDKNAME=${SDKNAME:-macosx} 17167 fi 17168 17169 if test -n "$SDKNAME"; then 17170 # Call xcodebuild to determine SYSROOT 17171 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17172 fi 17173 else 17174 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17175 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 17176 fi 17177 fi 17178 else 17179 # warn user if --with-sdk-name was also set 17180 if test -n "$with_sdk_name"; then 17181 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17182 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17183 fi 17184 fi 17185 17186 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17187 # If no system framework headers, then SYSROOT must be set, or we won't build 17188 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 17189 fi 17190 17191 # Perform a basic sanity test 17192 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17193 if test -z "$SYSROOT"; then 17194 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 17195 else 17196 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17197 fi 17198 fi 17199 17200 # set SDKROOT too, Xcode tools will pick it up 17201 SDKROOT=$SYSROOT 17202 17203 fi 17204 17205 # Prepend the extra path to the global path 17206 17207 if test "x$EXTRA_PATH" != x; then 17208 if test "x$PATH" = x; then 17209 PATH="$EXTRA_PATH" 17210 else 17211 PATH="$EXTRA_PATH:$PATH" 17212 fi 17213 fi 17214 17215 17216 if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 17217 # Add extra search paths on solaris for utilities like ar, as, dtrace etc... 17218 PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin:/usr/sbin" 17219 fi 17220 17221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17222 $as_echo_n "checking for sysroot... " >&6; } 17223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17224 $as_echo "$SYSROOT" >&6; } 17225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17226 $as_echo_n "checking for toolchain path... " >&6; } 17227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17228 $as_echo "$TOOLCHAIN_PATH" >&6; } 17229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17230 $as_echo_n "checking for extra path... " >&6; } 17231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17232 $as_echo "$EXTRA_PATH" >&6; } 17233 17234 17235 # To properly create a configuration name, we need to have the OpenJDK target 17236 # and options (variants and debug level) parsed. 17237 17238 17239 17240 # Check whether --with-conf-name was given. 17241 if test "${with_conf_name+set}" = set; then : 17242 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17243 fi 17244 17245 17246 # Test from where we are running configure, in or outside of src root. 17247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17248 $as_echo_n "checking where to store configuration... " >&6; } 17249 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 17250 || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \ 17251 || test "x$CURDIR" = "x$SRC_ROOT/make" ; then 17252 # We are running configure from the src root. 17253 # Create a default ./build/target-variant-debuglevel output root. 17254 if test "x${CONF_NAME}" = x; then 17255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17256 $as_echo "in default location" >&6; } 17257 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17258 else 17259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17260 $as_echo "in build directory with custom name" >&6; } 17261 fi 17262 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 17263 $MKDIR -p "$OUTPUT_ROOT" 17264 if test ! -d "$OUTPUT_ROOT"; then 17265 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 17266 fi 17267 else 17268 # We are running configure from outside of the src dir. 17269 # Then use the current directory as output dir! 17270 # If configuration is situated in normal build directory, just use the build 17271 # directory name as configuration name, otherwise use the complete path. 17272 if test "x${CONF_NAME}" = x; then 17273 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 17274 fi 17275 OUTPUT_ROOT="$CURDIR" 17276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17277 $as_echo "in current directory" >&6; } 17278 17279 # WARNING: This might be a bad thing to do. You need to be sure you want to 17280 # have a configuration in this directory. Do some sanity checks! 17281 17282 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 17283 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17284 # other files 17285 files_present=`$LS $OUTPUT_ROOT` 17286 # Configure has already touched config.log and confdefs.h in the current dir when this check 17287 # is performed. 17288 filtered_files=`$ECHO "$files_present" \ 17289 | $SED -e 's/config.log//g' \ 17290 -e 's/configure.log//g' \ 17291 -e 's/confdefs.h//g' \ 17292 -e 's/ //g' \ 17293 | $TR -d '\n'` 17294 if test "x$filtered_files" != x; then 17295 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17296 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17297 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17298 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17299 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17300 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17301 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17302 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17303 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17304 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17305 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 17306 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 17307 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17308 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17309 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17310 fi 17311 fi 17312 fi 17313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17314 $as_echo_n "checking what configuration name to use... " >&6; } 17315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17316 $as_echo "$CONF_NAME" >&6; } 17317 17318 17319 # Only process if variable expands to non-empty 17320 17321 if test "x$OUTPUT_ROOT" != x; then 17322 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17323 17324 # Input might be given as Windows format, start by converting to 17325 # unix format. 17326 path="$OUTPUT_ROOT" 17327 new_path=`$CYGPATH -u "$path"` 17328 17329 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17330 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17331 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17332 # "foo.exe" is OK but "foo" is an error. 17333 # 17334 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17335 # It is also a way to make sure we got the proper file name for the real test later on. 17336 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17337 if test "x$test_shortpath" = x; then 17338 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17339 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17340 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 17341 fi 17342 17343 # Call helper function which possibly converts this using DOS-style short mode. 17344 # If so, the updated path is stored in $new_path. 17345 17346 input_path="$new_path" 17347 # Check if we need to convert this using DOS-style short mode. If the path 17348 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17349 # take no chances and rewrite it. 17350 # Note: m4 eats our [], so we need to use [ and ] instead. 17351 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17352 if test "x$has_forbidden_chars" != x; then 17353 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17354 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17355 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17356 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17357 # Going to short mode and back again did indeed matter. Since short mode is 17358 # case insensitive, let's make it lowercase to improve readability. 17359 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17360 # Now convert it back to Unix-style (cygpath) 17361 input_path=`$CYGPATH -u "$shortmode_path"` 17362 new_path="$input_path" 17363 fi 17364 fi 17365 17366 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17367 if test "x$test_cygdrive_prefix" = x; then 17368 # As a simple fix, exclude /usr/bin since it's not a real path. 17369 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17370 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17371 # a path prefixed by /cygdrive for fixpath to work. 17372 new_path="$CYGWIN_ROOT_PATH$input_path" 17373 fi 17374 fi 17375 17376 17377 if test "x$path" != "x$new_path"; then 17378 OUTPUT_ROOT="$new_path" 17379 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17380 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17381 fi 17382 17383 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17384 17385 path="$OUTPUT_ROOT" 17386 has_colon=`$ECHO $path | $GREP ^.:` 17387 new_path="$path" 17388 if test "x$has_colon" = x; then 17389 # Not in mixed or Windows style, start by that. 17390 new_path=`cmd //c echo $path` 17391 fi 17392 17393 17394 input_path="$new_path" 17395 # Check if we need to convert this using DOS-style short mode. If the path 17396 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17397 # take no chances and rewrite it. 17398 # Note: m4 eats our [], so we need to use [ and ] instead. 17399 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17400 if test "x$has_forbidden_chars" != x; then 17401 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17402 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17403 fi 17404 17405 17406 windows_path="$new_path" 17407 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17408 unix_path=`$CYGPATH -u "$windows_path"` 17409 new_path="$unix_path" 17410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17411 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17412 new_path="$unix_path" 17413 fi 17414 17415 if test "x$path" != "x$new_path"; then 17416 OUTPUT_ROOT="$new_path" 17417 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17418 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17419 fi 17420 17421 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17422 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17423 17424 else 17425 # We're on a unix platform. Hooray! :) 17426 path="$OUTPUT_ROOT" 17427 has_space=`$ECHO "$path" | $GREP " "` 17428 if test "x$has_space" != x; then 17429 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17430 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17431 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17432 fi 17433 17434 # Use eval to expand a potential ~ 17435 eval path="$path" 17436 if test ! -f "$path" && test ! -d "$path"; then 17437 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 17438 fi 17439 17440 if test -d "$path"; then 17441 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 17442 else 17443 dir="`$DIRNAME "$path"`" 17444 base="`$BASENAME "$path"`" 17445 OUTPUT_ROOT="`cd "$dir"; $THEPWDCMD -L`/$base" 17446 fi 17447 fi 17448 fi 17449 17450 17451 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUT_ROOT/configure-support" 17452 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17453 17454 SPEC=$OUTPUT_ROOT/spec.gmk 17455 17456 CONF_NAME=$CONF_NAME 17457 17458 OUTPUT_ROOT=$OUTPUT_ROOT 17459 17460 17461 17462 # The spec.gmk file contains all variables for the make system. 17463 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17464 17465 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17466 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17467 17468 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17469 ac_config_files="$ac_config_files $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17470 17471 # The compare.sh is used to compare the build output to other builds. 17472 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17473 17474 # The generated Makefile knows where the spec.gmk is and where the source is. 17475 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 17476 # which will look for generated configurations 17477 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 17478 17479 17480 17481 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17482 17483 for ac_prog in apt-get yum port pkgutil pkgadd 17484 do 17485 # Extract the first word of "$ac_prog", so it can be a program name with args. 17486 set dummy $ac_prog; ac_word=$2 17487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17488 $as_echo_n "checking for $ac_word... " >&6; } 17489 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17490 $as_echo_n "(cached) " >&6 17491 else 17492 if test -n "$PKGHANDLER"; then 17493 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17494 else 17495 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17496 for as_dir in $PATH 17497 do 17498 IFS=$as_save_IFS 17499 test -z "$as_dir" && as_dir=. 17500 for ac_exec_ext in '' $ac_executable_extensions; do 17501 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17502 ac_cv_prog_PKGHANDLER="$ac_prog" 17503 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17504 break 2 17505 fi 17506 done 17507 done 17508 IFS=$as_save_IFS 17509 17510 fi 17511 fi 17512 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17513 if test -n "$PKGHANDLER"; then 17514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17515 $as_echo "$PKGHANDLER" >&6; } 17516 else 17517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17518 $as_echo "no" >&6; } 17519 fi 17520 17521 17522 test -n "$PKGHANDLER" && break 17523 done 17524 17525 17526 17527 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17528 17529 17530 17531 # Publish this variable in the help. 17532 17533 17534 if [ -z "${MAKE+x}" ]; then 17535 # The variable is not set by user, try to locate tool using the code snippet 17536 17537 # Try our hardest to locate a correct version of GNU make 17538 for ac_prog in gmake 17539 do 17540 # Extract the first word of "$ac_prog", so it can be a program name with args. 17541 set dummy $ac_prog; ac_word=$2 17542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17543 $as_echo_n "checking for $ac_word... " >&6; } 17544 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17545 $as_echo_n "(cached) " >&6 17546 else 17547 case $CHECK_GMAKE in 17548 [\\/]* | ?:[\\/]*) 17549 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17550 ;; 17551 *) 17552 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17553 for as_dir in $PATH 17554 do 17555 IFS=$as_save_IFS 17556 test -z "$as_dir" && as_dir=. 17557 for ac_exec_ext in '' $ac_executable_extensions; do 17558 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17559 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17560 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17561 break 2 17562 fi 17563 done 17564 done 17565 IFS=$as_save_IFS 17566 17567 ;; 17568 esac 17569 fi 17570 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17571 if test -n "$CHECK_GMAKE"; then 17572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17573 $as_echo "$CHECK_GMAKE" >&6; } 17574 else 17575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17576 $as_echo "no" >&6; } 17577 fi 17578 17579 17580 test -n "$CHECK_GMAKE" && break 17581 done 17582 17583 17584 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17585 DESCRIPTION="gmake in PATH" 17586 17587 # On Cygwin, we require a newer version of make than on other platforms 17588 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17589 MAKE_VERSION_EXPR="-e 4\." 17590 MAKE_REQUIRED_VERSION="4.0" 17591 else 17592 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17593 MAKE_REQUIRED_VERSION="3.81" 17594 fi 17595 17596 if test "x$MAKE_CANDIDATE" != x; then 17597 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17598 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17599 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17600 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17601 if test "x$IS_GNU_MAKE" = x; then 17602 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17603 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17604 else 17605 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17606 if test "x$IS_MODERN_MAKE" = x; then 17607 { $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 17608 $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;} 17609 else 17610 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17611 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17612 MAKE_EXPECTED_ENV='cygwin' 17613 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17614 MAKE_EXPECTED_ENV='msys' 17615 else 17616 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17617 fi 17618 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17619 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17620 else 17621 # Not relevant for non-Windows 17622 IS_MAKE_CORRECT_ENV=true 17623 fi 17624 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17625 { $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 17626 $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;} 17627 else 17628 FOUND_MAKE=$MAKE_CANDIDATE 17629 17630 # Only process if variable expands to non-empty 17631 17632 if test "x$FOUND_MAKE" != x; then 17633 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17634 17635 # First separate the path from the arguments. This will split at the first 17636 # space. 17637 complete="$FOUND_MAKE" 17638 path="${complete%% *}" 17639 tmp="$complete EOL" 17640 arguments="${tmp#* }" 17641 17642 # Input might be given as Windows format, start by converting to 17643 # unix format. 17644 new_path=`$CYGPATH -u "$path"` 17645 17646 # Now try to locate executable using which 17647 new_path=`$WHICH "$new_path" 2> /dev/null` 17648 # bat and cmd files are not always considered executable in cygwin causing which 17649 # to not find them 17650 if test "x$new_path" = x \ 17651 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17652 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17653 new_path=`$CYGPATH -u "$path"` 17654 fi 17655 if test "x$new_path" = x; then 17656 # Oops. Which didn't find the executable. 17657 # The splitting of arguments from the executable at a space might have been incorrect, 17658 # since paths with space are more likely in Windows. Give it another try with the whole 17659 # argument. 17660 path="$complete" 17661 arguments="EOL" 17662 new_path=`$CYGPATH -u "$path"` 17663 new_path=`$WHICH "$new_path" 2> /dev/null` 17664 # bat and cmd files are not always considered executable in cygwin causing which 17665 # to not find them 17666 if test "x$new_path" = x \ 17667 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17668 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17669 new_path=`$CYGPATH -u "$path"` 17670 fi 17671 if test "x$new_path" = x; then 17672 # It's still not found. Now this is an unrecoverable error. 17673 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17674 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17675 has_space=`$ECHO "$complete" | $GREP " "` 17676 if test "x$has_space" != x; then 17677 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17678 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17679 fi 17680 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17681 fi 17682 fi 17683 17684 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17685 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17686 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17687 # "foo.exe" is OK but "foo" is an error. 17688 # 17689 # This test is therefore slightly more accurate than "test -f" to check for file presence. 17690 # It is also a way to make sure we got the proper file name for the real test later on. 17691 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17692 if test "x$test_shortpath" = x; then 17693 # Short path failed, file does not exist as specified. 17694 # Try adding .exe or .cmd 17695 if test -f "${new_path}.exe"; then 17696 input_to_shortpath="${new_path}.exe" 17697 elif test -f "${new_path}.cmd"; then 17698 input_to_shortpath="${new_path}.cmd" 17699 else 17700 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 17701 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 17702 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17703 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17704 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17705 fi 17706 else 17707 input_to_shortpath="$new_path" 17708 fi 17709 17710 # Call helper function which possibly converts this using DOS-style short mode. 17711 # If so, the updated path is stored in $new_path. 17712 new_path="$input_to_shortpath" 17713 17714 input_path="$input_to_shortpath" 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 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17723 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17724 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17725 # Going to short mode and back again did indeed matter. Since short mode is 17726 # case insensitive, let's make it lowercase to improve readability. 17727 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17728 # Now convert it back to Unix-style (cygpath) 17729 input_path=`$CYGPATH -u "$shortmode_path"` 17730 new_path="$input_path" 17731 fi 17732 fi 17733 17734 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17735 if test "x$test_cygdrive_prefix" = x; then 17736 # As a simple fix, exclude /usr/bin since it's not a real path. 17737 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17738 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17739 # a path prefixed by /cygdrive for fixpath to work. 17740 new_path="$CYGWIN_ROOT_PATH$input_path" 17741 fi 17742 fi 17743 17744 # remove trailing .exe if any 17745 new_path="${new_path/%.exe/}" 17746 17747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17748 17749 # First separate the path from the arguments. This will split at the first 17750 # space. 17751 complete="$FOUND_MAKE" 17752 path="${complete%% *}" 17753 tmp="$complete EOL" 17754 arguments="${tmp#* }" 17755 17756 # Input might be given as Windows format, start by converting to 17757 # unix format. 17758 new_path="$path" 17759 17760 windows_path="$new_path" 17761 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17762 unix_path=`$CYGPATH -u "$windows_path"` 17763 new_path="$unix_path" 17764 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17765 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17766 new_path="$unix_path" 17767 fi 17768 17769 17770 # Now try to locate executable using which 17771 new_path=`$WHICH "$new_path" 2> /dev/null` 17772 17773 if test "x$new_path" = x; then 17774 # Oops. Which didn't find the executable. 17775 # The splitting of arguments from the executable at a space might have been incorrect, 17776 # since paths with space are more likely in Windows. Give it another try with the whole 17777 # argument. 17778 path="$complete" 17779 arguments="EOL" 17780 new_path="$path" 17781 17782 windows_path="$new_path" 17783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17784 unix_path=`$CYGPATH -u "$windows_path"` 17785 new_path="$unix_path" 17786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17787 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17788 new_path="$unix_path" 17789 fi 17790 17791 17792 new_path=`$WHICH "$new_path" 2> /dev/null` 17793 # bat and cmd files are not always considered executable in MSYS causing which 17794 # to not find them 17795 if test "x$new_path" = x \ 17796 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17797 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17798 new_path="$path" 17799 17800 windows_path="$new_path" 17801 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17802 unix_path=`$CYGPATH -u "$windows_path"` 17803 new_path="$unix_path" 17804 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17805 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17806 new_path="$unix_path" 17807 fi 17808 17809 fi 17810 17811 if test "x$new_path" = x; then 17812 # It's still not found. Now this is an unrecoverable error. 17813 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17814 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17815 has_space=`$ECHO "$complete" | $GREP " "` 17816 if test "x$has_space" != x; then 17817 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17818 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17819 fi 17820 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17821 fi 17822 fi 17823 17824 # Now new_path has a complete unix path to the binary 17825 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17826 # Keep paths in /bin as-is, but remove trailing .exe if any 17827 new_path="${new_path/%.exe/}" 17828 # Do not save /bin paths to all_fixpath_prefixes! 17829 else 17830 # Not in mixed or Windows style, start by that. 17831 new_path=`cmd //c echo $new_path` 17832 17833 input_path="$new_path" 17834 # Check if we need to convert this using DOS-style short mode. If the path 17835 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17836 # take no chances and rewrite it. 17837 # Note: m4 eats our [], so we need to use [ and ] instead. 17838 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17839 if test "x$has_forbidden_chars" != x; then 17840 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17841 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17842 fi 17843 17844 # Output is in $new_path 17845 17846 windows_path="$new_path" 17847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17848 unix_path=`$CYGPATH -u "$windows_path"` 17849 new_path="$unix_path" 17850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17851 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17852 new_path="$unix_path" 17853 fi 17854 17855 # remove trailing .exe if any 17856 new_path="${new_path/%.exe/}" 17857 17858 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17859 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17860 fi 17861 17862 else 17863 # We're on a unix platform. Hooray! :) 17864 # First separate the path from the arguments. This will split at the first 17865 # space. 17866 complete="$FOUND_MAKE" 17867 path="${complete%% *}" 17868 tmp="$complete EOL" 17869 arguments="${tmp#* }" 17870 17871 # Cannot rely on the command "which" here since it doesn't always work. 17872 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17873 if test -z "$is_absolute_path"; then 17874 # Path to executable is not absolute. Find it. 17875 IFS_save="$IFS" 17876 IFS=: 17877 for p in $PATH; do 17878 if test -f "$p/$path" && test -x "$p/$path"; then 17879 new_path="$p/$path" 17880 break 17881 fi 17882 done 17883 IFS="$IFS_save" 17884 else 17885 # This is an absolute path, we can use it without further modifications. 17886 new_path="$path" 17887 fi 17888 17889 if test "x$new_path" = x; then 17890 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17891 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17892 has_space=`$ECHO "$complete" | $GREP " "` 17893 if test "x$has_space" != x; then 17894 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17895 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17896 fi 17897 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17898 fi 17899 fi 17900 17901 # Now join together the path and the arguments once again 17902 if test "x$arguments" != xEOL; then 17903 new_complete="$new_path ${arguments% *}" 17904 else 17905 new_complete="$new_path" 17906 fi 17907 17908 if test "x$complete" != "x$new_complete"; then 17909 FOUND_MAKE="$new_complete" 17910 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 17911 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 17912 fi 17913 fi 17914 17915 fi 17916 fi 17917 fi 17918 fi 17919 17920 17921 if test "x$FOUND_MAKE" = x; then 17922 for ac_prog in make 17923 do 17924 # Extract the first word of "$ac_prog", so it can be a program name with args. 17925 set dummy $ac_prog; ac_word=$2 17926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17927 $as_echo_n "checking for $ac_word... " >&6; } 17928 if ${ac_cv_path_CHECK_MAKE+:} false; then : 17929 $as_echo_n "(cached) " >&6 17930 else 17931 case $CHECK_MAKE in 17932 [\\/]* | ?:[\\/]*) 17933 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 17934 ;; 17935 *) 17936 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17937 for as_dir in $PATH 17938 do 17939 IFS=$as_save_IFS 17940 test -z "$as_dir" && as_dir=. 17941 for ac_exec_ext in '' $ac_executable_extensions; do 17942 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17943 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 17944 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17945 break 2 17946 fi 17947 done 17948 done 17949 IFS=$as_save_IFS 17950 17951 ;; 17952 esac 17953 fi 17954 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 17955 if test -n "$CHECK_MAKE"; then 17956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 17957 $as_echo "$CHECK_MAKE" >&6; } 17958 else 17959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17960 $as_echo "no" >&6; } 17961 fi 17962 17963 17964 test -n "$CHECK_MAKE" && break 17965 done 17966 17967 17968 MAKE_CANDIDATE=""$CHECK_MAKE"" 17969 DESCRIPTION="make in PATH" 17970 17971 # On Cygwin, we require a newer version of make than on other platforms 17972 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17973 MAKE_VERSION_EXPR="-e 4\." 17974 MAKE_REQUIRED_VERSION="4.0" 17975 else 17976 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17977 MAKE_REQUIRED_VERSION="3.81" 17978 fi 17979 17980 if test "x$MAKE_CANDIDATE" != x; then 17981 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17982 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17983 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17984 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17985 if test "x$IS_GNU_MAKE" = x; then 17986 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17987 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17988 else 17989 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17990 if test "x$IS_MODERN_MAKE" = x; then 17991 { $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 17992 $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;} 17993 else 17994 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17996 MAKE_EXPECTED_ENV='cygwin' 17997 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17998 MAKE_EXPECTED_ENV='msys' 17999 else 18000 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18001 fi 18002 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18003 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18004 else 18005 # Not relevant for non-Windows 18006 IS_MAKE_CORRECT_ENV=true 18007 fi 18008 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18009 { $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 18010 $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;} 18011 else 18012 FOUND_MAKE=$MAKE_CANDIDATE 18013 18014 # Only process if variable expands to non-empty 18015 18016 if test "x$FOUND_MAKE" != x; then 18017 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18018 18019 # First separate the path from the arguments. This will split at the first 18020 # space. 18021 complete="$FOUND_MAKE" 18022 path="${complete%% *}" 18023 tmp="$complete EOL" 18024 arguments="${tmp#* }" 18025 18026 # Input might be given as Windows format, start by converting to 18027 # unix format. 18028 new_path=`$CYGPATH -u "$path"` 18029 18030 # Now try to locate executable using which 18031 new_path=`$WHICH "$new_path" 2> /dev/null` 18032 # bat and cmd files are not always considered executable in cygwin causing which 18033 # to not find them 18034 if test "x$new_path" = x \ 18035 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18036 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18037 new_path=`$CYGPATH -u "$path"` 18038 fi 18039 if test "x$new_path" = x; then 18040 # Oops. Which didn't find the executable. 18041 # The splitting of arguments from the executable at a space might have been incorrect, 18042 # since paths with space are more likely in Windows. Give it another try with the whole 18043 # argument. 18044 path="$complete" 18045 arguments="EOL" 18046 new_path=`$CYGPATH -u "$path"` 18047 new_path=`$WHICH "$new_path" 2> /dev/null` 18048 # bat and cmd files are not always considered executable in cygwin causing which 18049 # to not find them 18050 if test "x$new_path" = x \ 18051 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18052 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18053 new_path=`$CYGPATH -u "$path"` 18054 fi 18055 if test "x$new_path" = x; then 18056 # It's still not found. Now this is an unrecoverable error. 18057 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18058 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18059 has_space=`$ECHO "$complete" | $GREP " "` 18060 if test "x$has_space" != x; then 18061 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18062 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18063 fi 18064 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18065 fi 18066 fi 18067 18068 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18069 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18070 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18071 # "foo.exe" is OK but "foo" is an error. 18072 # 18073 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18074 # It is also a way to make sure we got the proper file name for the real test later on. 18075 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18076 if test "x$test_shortpath" = x; then 18077 # Short path failed, file does not exist as specified. 18078 # Try adding .exe or .cmd 18079 if test -f "${new_path}.exe"; then 18080 input_to_shortpath="${new_path}.exe" 18081 elif test -f "${new_path}.cmd"; then 18082 input_to_shortpath="${new_path}.cmd" 18083 else 18084 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18085 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18086 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18087 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18088 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18089 fi 18090 else 18091 input_to_shortpath="$new_path" 18092 fi 18093 18094 # Call helper function which possibly converts this using DOS-style short mode. 18095 # If so, the updated path is stored in $new_path. 18096 new_path="$input_to_shortpath" 18097 18098 input_path="$input_to_shortpath" 18099 # Check if we need to convert this using DOS-style short mode. If the path 18100 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18101 # take no chances and rewrite it. 18102 # Note: m4 eats our [], so we need to use [ and ] instead. 18103 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18104 if test "x$has_forbidden_chars" != x; then 18105 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18106 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18107 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18108 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18109 # Going to short mode and back again did indeed matter. Since short mode is 18110 # case insensitive, let's make it lowercase to improve readability. 18111 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18112 # Now convert it back to Unix-style (cygpath) 18113 input_path=`$CYGPATH -u "$shortmode_path"` 18114 new_path="$input_path" 18115 fi 18116 fi 18117 18118 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18119 if test "x$test_cygdrive_prefix" = x; then 18120 # As a simple fix, exclude /usr/bin since it's not a real path. 18121 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18122 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18123 # a path prefixed by /cygdrive for fixpath to work. 18124 new_path="$CYGWIN_ROOT_PATH$input_path" 18125 fi 18126 fi 18127 18128 # remove trailing .exe if any 18129 new_path="${new_path/%.exe/}" 18130 18131 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18132 18133 # First separate the path from the arguments. This will split at the first 18134 # space. 18135 complete="$FOUND_MAKE" 18136 path="${complete%% *}" 18137 tmp="$complete EOL" 18138 arguments="${tmp#* }" 18139 18140 # Input might be given as Windows format, start by converting to 18141 # unix format. 18142 new_path="$path" 18143 18144 windows_path="$new_path" 18145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18146 unix_path=`$CYGPATH -u "$windows_path"` 18147 new_path="$unix_path" 18148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18149 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18150 new_path="$unix_path" 18151 fi 18152 18153 18154 # Now try to locate executable using which 18155 new_path=`$WHICH "$new_path" 2> /dev/null` 18156 18157 if test "x$new_path" = x; then 18158 # Oops. Which didn't find the executable. 18159 # The splitting of arguments from the executable at a space might have been incorrect, 18160 # since paths with space are more likely in Windows. Give it another try with the whole 18161 # argument. 18162 path="$complete" 18163 arguments="EOL" 18164 new_path="$path" 18165 18166 windows_path="$new_path" 18167 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18168 unix_path=`$CYGPATH -u "$windows_path"` 18169 new_path="$unix_path" 18170 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18171 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18172 new_path="$unix_path" 18173 fi 18174 18175 18176 new_path=`$WHICH "$new_path" 2> /dev/null` 18177 # bat and cmd files are not always considered executable in MSYS causing which 18178 # to not find them 18179 if test "x$new_path" = x \ 18180 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18181 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18182 new_path="$path" 18183 18184 windows_path="$new_path" 18185 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18186 unix_path=`$CYGPATH -u "$windows_path"` 18187 new_path="$unix_path" 18188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18189 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18190 new_path="$unix_path" 18191 fi 18192 18193 fi 18194 18195 if test "x$new_path" = x; then 18196 # It's still not found. Now this is an unrecoverable error. 18197 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18198 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18199 has_space=`$ECHO "$complete" | $GREP " "` 18200 if test "x$has_space" != x; then 18201 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18202 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18203 fi 18204 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18205 fi 18206 fi 18207 18208 # Now new_path has a complete unix path to the binary 18209 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18210 # Keep paths in /bin as-is, but remove trailing .exe if any 18211 new_path="${new_path/%.exe/}" 18212 # Do not save /bin paths to all_fixpath_prefixes! 18213 else 18214 # Not in mixed or Windows style, start by that. 18215 new_path=`cmd //c echo $new_path` 18216 18217 input_path="$new_path" 18218 # Check if we need to convert this using DOS-style short mode. If the path 18219 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18220 # take no chances and rewrite it. 18221 # Note: m4 eats our [], so we need to use [ and ] instead. 18222 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18223 if test "x$has_forbidden_chars" != x; then 18224 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18225 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18226 fi 18227 18228 # Output is in $new_path 18229 18230 windows_path="$new_path" 18231 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18232 unix_path=`$CYGPATH -u "$windows_path"` 18233 new_path="$unix_path" 18234 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18235 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18236 new_path="$unix_path" 18237 fi 18238 18239 # remove trailing .exe if any 18240 new_path="${new_path/%.exe/}" 18241 18242 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18243 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18244 fi 18245 18246 else 18247 # We're on a unix platform. Hooray! :) 18248 # First separate the path from the arguments. This will split at the first 18249 # space. 18250 complete="$FOUND_MAKE" 18251 path="${complete%% *}" 18252 tmp="$complete EOL" 18253 arguments="${tmp#* }" 18254 18255 # Cannot rely on the command "which" here since it doesn't always work. 18256 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18257 if test -z "$is_absolute_path"; then 18258 # Path to executable is not absolute. Find it. 18259 IFS_save="$IFS" 18260 IFS=: 18261 for p in $PATH; do 18262 if test -f "$p/$path" && test -x "$p/$path"; then 18263 new_path="$p/$path" 18264 break 18265 fi 18266 done 18267 IFS="$IFS_save" 18268 else 18269 # This is an absolute path, we can use it without further modifications. 18270 new_path="$path" 18271 fi 18272 18273 if test "x$new_path" = x; then 18274 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18275 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18276 has_space=`$ECHO "$complete" | $GREP " "` 18277 if test "x$has_space" != x; then 18278 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18279 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18280 fi 18281 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18282 fi 18283 fi 18284 18285 # Now join together the path and the arguments once again 18286 if test "x$arguments" != xEOL; then 18287 new_complete="$new_path ${arguments% *}" 18288 else 18289 new_complete="$new_path" 18290 fi 18291 18292 if test "x$complete" != "x$new_complete"; then 18293 FOUND_MAKE="$new_complete" 18294 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18295 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18296 fi 18297 fi 18298 18299 fi 18300 fi 18301 fi 18302 fi 18303 18304 fi 18305 18306 if test "x$FOUND_MAKE" = x; then 18307 if test "x$TOOLCHAIN_PATH" != x; then 18308 # We have a toolchain path, check that as well before giving up. 18309 OLD_PATH=$PATH 18310 PATH=$TOOLCHAIN_PATH:$PATH 18311 for ac_prog in gmake 18312 do 18313 # Extract the first word of "$ac_prog", so it can be a program name with args. 18314 set dummy $ac_prog; ac_word=$2 18315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18316 $as_echo_n "checking for $ac_word... " >&6; } 18317 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18318 $as_echo_n "(cached) " >&6 18319 else 18320 case $CHECK_TOOLSDIR_GMAKE in 18321 [\\/]* | ?:[\\/]*) 18322 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18323 ;; 18324 *) 18325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18326 for as_dir in $PATH 18327 do 18328 IFS=$as_save_IFS 18329 test -z "$as_dir" && as_dir=. 18330 for ac_exec_ext in '' $ac_executable_extensions; do 18331 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18332 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18333 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18334 break 2 18335 fi 18336 done 18337 done 18338 IFS=$as_save_IFS 18339 18340 ;; 18341 esac 18342 fi 18343 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18344 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18346 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18347 else 18348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18349 $as_echo "no" >&6; } 18350 fi 18351 18352 18353 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18354 done 18355 18356 18357 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18358 DESCRIPTION="gmake in tools-dir" 18359 18360 # On Cygwin, we require a newer version of make than on other platforms 18361 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18362 MAKE_VERSION_EXPR="-e 4\." 18363 MAKE_REQUIRED_VERSION="4.0" 18364 else 18365 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18366 MAKE_REQUIRED_VERSION="3.81" 18367 fi 18368 18369 if test "x$MAKE_CANDIDATE" != x; then 18370 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18371 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18372 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18373 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18374 if test "x$IS_GNU_MAKE" = x; then 18375 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18376 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18377 else 18378 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18379 if test "x$IS_MODERN_MAKE" = x; then 18380 { $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 18381 $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;} 18382 else 18383 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18385 MAKE_EXPECTED_ENV='cygwin' 18386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18387 MAKE_EXPECTED_ENV='msys' 18388 else 18389 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18390 fi 18391 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18392 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18393 else 18394 # Not relevant for non-Windows 18395 IS_MAKE_CORRECT_ENV=true 18396 fi 18397 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18398 { $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 18399 $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;} 18400 else 18401 FOUND_MAKE=$MAKE_CANDIDATE 18402 18403 # Only process if variable expands to non-empty 18404 18405 if test "x$FOUND_MAKE" != x; then 18406 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18407 18408 # First separate the path from the arguments. This will split at the first 18409 # space. 18410 complete="$FOUND_MAKE" 18411 path="${complete%% *}" 18412 tmp="$complete EOL" 18413 arguments="${tmp#* }" 18414 18415 # Input might be given as Windows format, start by converting to 18416 # unix format. 18417 new_path=`$CYGPATH -u "$path"` 18418 18419 # Now try to locate executable using which 18420 new_path=`$WHICH "$new_path" 2> /dev/null` 18421 # bat and cmd files are not always considered executable in cygwin causing which 18422 # to not find them 18423 if test "x$new_path" = x \ 18424 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18425 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18426 new_path=`$CYGPATH -u "$path"` 18427 fi 18428 if test "x$new_path" = x; then 18429 # Oops. Which didn't find the executable. 18430 # The splitting of arguments from the executable at a space might have been incorrect, 18431 # since paths with space are more likely in Windows. Give it another try with the whole 18432 # argument. 18433 path="$complete" 18434 arguments="EOL" 18435 new_path=`$CYGPATH -u "$path"` 18436 new_path=`$WHICH "$new_path" 2> /dev/null` 18437 # bat and cmd files are not always considered executable in cygwin causing which 18438 # to not find them 18439 if test "x$new_path" = x \ 18440 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18441 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18442 new_path=`$CYGPATH -u "$path"` 18443 fi 18444 if test "x$new_path" = x; then 18445 # It's still not found. Now this is an unrecoverable error. 18446 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18447 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18448 has_space=`$ECHO "$complete" | $GREP " "` 18449 if test "x$has_space" != x; then 18450 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18451 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18452 fi 18453 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18454 fi 18455 fi 18456 18457 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18458 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18459 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18460 # "foo.exe" is OK but "foo" is an error. 18461 # 18462 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18463 # It is also a way to make sure we got the proper file name for the real test later on. 18464 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18465 if test "x$test_shortpath" = x; then 18466 # Short path failed, file does not exist as specified. 18467 # Try adding .exe or .cmd 18468 if test -f "${new_path}.exe"; then 18469 input_to_shortpath="${new_path}.exe" 18470 elif test -f "${new_path}.cmd"; then 18471 input_to_shortpath="${new_path}.cmd" 18472 else 18473 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18474 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18475 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18476 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18477 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18478 fi 18479 else 18480 input_to_shortpath="$new_path" 18481 fi 18482 18483 # Call helper function which possibly converts this using DOS-style short mode. 18484 # If so, the updated path is stored in $new_path. 18485 new_path="$input_to_shortpath" 18486 18487 input_path="$input_to_shortpath" 18488 # Check if we need to convert this using DOS-style short mode. If the path 18489 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18490 # take no chances and rewrite it. 18491 # Note: m4 eats our [], so we need to use [ and ] instead. 18492 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18493 if test "x$has_forbidden_chars" != x; then 18494 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18495 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18496 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18497 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18498 # Going to short mode and back again did indeed matter. Since short mode is 18499 # case insensitive, let's make it lowercase to improve readability. 18500 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18501 # Now convert it back to Unix-style (cygpath) 18502 input_path=`$CYGPATH -u "$shortmode_path"` 18503 new_path="$input_path" 18504 fi 18505 fi 18506 18507 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18508 if test "x$test_cygdrive_prefix" = x; then 18509 # As a simple fix, exclude /usr/bin since it's not a real path. 18510 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18511 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18512 # a path prefixed by /cygdrive for fixpath to work. 18513 new_path="$CYGWIN_ROOT_PATH$input_path" 18514 fi 18515 fi 18516 18517 # remove trailing .exe if any 18518 new_path="${new_path/%.exe/}" 18519 18520 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18521 18522 # First separate the path from the arguments. This will split at the first 18523 # space. 18524 complete="$FOUND_MAKE" 18525 path="${complete%% *}" 18526 tmp="$complete EOL" 18527 arguments="${tmp#* }" 18528 18529 # Input might be given as Windows format, start by converting to 18530 # unix format. 18531 new_path="$path" 18532 18533 windows_path="$new_path" 18534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18535 unix_path=`$CYGPATH -u "$windows_path"` 18536 new_path="$unix_path" 18537 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18538 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18539 new_path="$unix_path" 18540 fi 18541 18542 18543 # Now try to locate executable using which 18544 new_path=`$WHICH "$new_path" 2> /dev/null` 18545 18546 if test "x$new_path" = x; then 18547 # Oops. Which didn't find the executable. 18548 # The splitting of arguments from the executable at a space might have been incorrect, 18549 # since paths with space are more likely in Windows. Give it another try with the whole 18550 # argument. 18551 path="$complete" 18552 arguments="EOL" 18553 new_path="$path" 18554 18555 windows_path="$new_path" 18556 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18557 unix_path=`$CYGPATH -u "$windows_path"` 18558 new_path="$unix_path" 18559 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18560 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18561 new_path="$unix_path" 18562 fi 18563 18564 18565 new_path=`$WHICH "$new_path" 2> /dev/null` 18566 # bat and cmd files are not always considered executable in MSYS causing which 18567 # to not find them 18568 if test "x$new_path" = x \ 18569 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18570 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18571 new_path="$path" 18572 18573 windows_path="$new_path" 18574 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18575 unix_path=`$CYGPATH -u "$windows_path"` 18576 new_path="$unix_path" 18577 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18578 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18579 new_path="$unix_path" 18580 fi 18581 18582 fi 18583 18584 if test "x$new_path" = x; then 18585 # It's still not found. Now this is an unrecoverable error. 18586 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18587 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18588 has_space=`$ECHO "$complete" | $GREP " "` 18589 if test "x$has_space" != x; then 18590 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18591 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18592 fi 18593 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18594 fi 18595 fi 18596 18597 # Now new_path has a complete unix path to the binary 18598 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18599 # Keep paths in /bin as-is, but remove trailing .exe if any 18600 new_path="${new_path/%.exe/}" 18601 # Do not save /bin paths to all_fixpath_prefixes! 18602 else 18603 # Not in mixed or Windows style, start by that. 18604 new_path=`cmd //c echo $new_path` 18605 18606 input_path="$new_path" 18607 # Check if we need to convert this using DOS-style short mode. If the path 18608 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18609 # take no chances and rewrite it. 18610 # Note: m4 eats our [], so we need to use [ and ] instead. 18611 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18612 if test "x$has_forbidden_chars" != x; then 18613 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18614 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18615 fi 18616 18617 # Output is in $new_path 18618 18619 windows_path="$new_path" 18620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18621 unix_path=`$CYGPATH -u "$windows_path"` 18622 new_path="$unix_path" 18623 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18624 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18625 new_path="$unix_path" 18626 fi 18627 18628 # remove trailing .exe if any 18629 new_path="${new_path/%.exe/}" 18630 18631 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18632 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18633 fi 18634 18635 else 18636 # We're on a unix platform. Hooray! :) 18637 # First separate the path from the arguments. This will split at the first 18638 # space. 18639 complete="$FOUND_MAKE" 18640 path="${complete%% *}" 18641 tmp="$complete EOL" 18642 arguments="${tmp#* }" 18643 18644 # Cannot rely on the command "which" here since it doesn't always work. 18645 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18646 if test -z "$is_absolute_path"; then 18647 # Path to executable is not absolute. Find it. 18648 IFS_save="$IFS" 18649 IFS=: 18650 for p in $PATH; do 18651 if test -f "$p/$path" && test -x "$p/$path"; then 18652 new_path="$p/$path" 18653 break 18654 fi 18655 done 18656 IFS="$IFS_save" 18657 else 18658 # This is an absolute path, we can use it without further modifications. 18659 new_path="$path" 18660 fi 18661 18662 if test "x$new_path" = x; then 18663 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18664 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18665 has_space=`$ECHO "$complete" | $GREP " "` 18666 if test "x$has_space" != x; then 18667 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18668 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18669 fi 18670 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18671 fi 18672 fi 18673 18674 # Now join together the path and the arguments once again 18675 if test "x$arguments" != xEOL; then 18676 new_complete="$new_path ${arguments% *}" 18677 else 18678 new_complete="$new_path" 18679 fi 18680 18681 if test "x$complete" != "x$new_complete"; then 18682 FOUND_MAKE="$new_complete" 18683 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18684 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18685 fi 18686 fi 18687 18688 fi 18689 fi 18690 fi 18691 fi 18692 18693 if test "x$FOUND_MAKE" = x; then 18694 for ac_prog in make 18695 do 18696 # Extract the first word of "$ac_prog", so it can be a program name with args. 18697 set dummy $ac_prog; ac_word=$2 18698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18699 $as_echo_n "checking for $ac_word... " >&6; } 18700 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 18701 $as_echo_n "(cached) " >&6 18702 else 18703 case $CHECK_TOOLSDIR_MAKE in 18704 [\\/]* | ?:[\\/]*) 18705 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 18706 ;; 18707 *) 18708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18709 for as_dir in $PATH 18710 do 18711 IFS=$as_save_IFS 18712 test -z "$as_dir" && as_dir=. 18713 for ac_exec_ext in '' $ac_executable_extensions; do 18714 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18715 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 18716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18717 break 2 18718 fi 18719 done 18720 done 18721 IFS=$as_save_IFS 18722 18723 ;; 18724 esac 18725 fi 18726 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 18727 if test -n "$CHECK_TOOLSDIR_MAKE"; then 18728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 18729 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 18730 else 18731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18732 $as_echo "no" >&6; } 18733 fi 18734 18735 18736 test -n "$CHECK_TOOLSDIR_MAKE" && break 18737 done 18738 18739 18740 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 18741 DESCRIPTION="make in tools-dir" 18742 18743 # On Cygwin, we require a newer version of make than on other platforms 18744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18745 MAKE_VERSION_EXPR="-e 4\." 18746 MAKE_REQUIRED_VERSION="4.0" 18747 else 18748 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18749 MAKE_REQUIRED_VERSION="3.81" 18750 fi 18751 18752 if test "x$MAKE_CANDIDATE" != x; then 18753 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18754 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18755 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18756 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18757 if test "x$IS_GNU_MAKE" = x; then 18758 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18759 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18760 else 18761 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18762 if test "x$IS_MODERN_MAKE" = x; then 18763 { $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 18764 $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;} 18765 else 18766 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18767 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18768 MAKE_EXPECTED_ENV='cygwin' 18769 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18770 MAKE_EXPECTED_ENV='msys' 18771 else 18772 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18773 fi 18774 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18775 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18776 else 18777 # Not relevant for non-Windows 18778 IS_MAKE_CORRECT_ENV=true 18779 fi 18780 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18781 { $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 18782 $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;} 18783 else 18784 FOUND_MAKE=$MAKE_CANDIDATE 18785 18786 # Only process if variable expands to non-empty 18787 18788 if test "x$FOUND_MAKE" != x; then 18789 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18790 18791 # First separate the path from the arguments. This will split at the first 18792 # space. 18793 complete="$FOUND_MAKE" 18794 path="${complete%% *}" 18795 tmp="$complete EOL" 18796 arguments="${tmp#* }" 18797 18798 # Input might be given as Windows format, start by converting to 18799 # unix format. 18800 new_path=`$CYGPATH -u "$path"` 18801 18802 # Now try to locate executable using which 18803 new_path=`$WHICH "$new_path" 2> /dev/null` 18804 # bat and cmd files are not always considered executable in cygwin causing which 18805 # to not find them 18806 if test "x$new_path" = x \ 18807 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18808 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18809 new_path=`$CYGPATH -u "$path"` 18810 fi 18811 if test "x$new_path" = x; then 18812 # Oops. Which didn't find the executable. 18813 # The splitting of arguments from the executable at a space might have been incorrect, 18814 # since paths with space are more likely in Windows. Give it another try with the whole 18815 # argument. 18816 path="$complete" 18817 arguments="EOL" 18818 new_path=`$CYGPATH -u "$path"` 18819 new_path=`$WHICH "$new_path" 2> /dev/null` 18820 # bat and cmd files are not always considered executable in cygwin causing which 18821 # to not find them 18822 if test "x$new_path" = x \ 18823 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18824 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18825 new_path=`$CYGPATH -u "$path"` 18826 fi 18827 if test "x$new_path" = x; then 18828 # It's still not found. Now this is an unrecoverable error. 18829 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18830 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18831 has_space=`$ECHO "$complete" | $GREP " "` 18832 if test "x$has_space" != x; then 18833 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18834 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18835 fi 18836 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18837 fi 18838 fi 18839 18840 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18841 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18842 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18843 # "foo.exe" is OK but "foo" is an error. 18844 # 18845 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18846 # It is also a way to make sure we got the proper file name for the real test later on. 18847 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18848 if test "x$test_shortpath" = x; then 18849 # Short path failed, file does not exist as specified. 18850 # Try adding .exe or .cmd 18851 if test -f "${new_path}.exe"; then 18852 input_to_shortpath="${new_path}.exe" 18853 elif test -f "${new_path}.cmd"; then 18854 input_to_shortpath="${new_path}.cmd" 18855 else 18856 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18857 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18858 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18859 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18860 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18861 fi 18862 else 18863 input_to_shortpath="$new_path" 18864 fi 18865 18866 # Call helper function which possibly converts this using DOS-style short mode. 18867 # If so, the updated path is stored in $new_path. 18868 new_path="$input_to_shortpath" 18869 18870 input_path="$input_to_shortpath" 18871 # Check if we need to convert this using DOS-style short mode. If the path 18872 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18873 # take no chances and rewrite it. 18874 # Note: m4 eats our [], so we need to use [ and ] instead. 18875 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18876 if test "x$has_forbidden_chars" != x; then 18877 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18878 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18879 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18880 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18881 # Going to short mode and back again did indeed matter. Since short mode is 18882 # case insensitive, let's make it lowercase to improve readability. 18883 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18884 # Now convert it back to Unix-style (cygpath) 18885 input_path=`$CYGPATH -u "$shortmode_path"` 18886 new_path="$input_path" 18887 fi 18888 fi 18889 18890 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18891 if test "x$test_cygdrive_prefix" = x; then 18892 # As a simple fix, exclude /usr/bin since it's not a real path. 18893 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18894 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18895 # a path prefixed by /cygdrive for fixpath to work. 18896 new_path="$CYGWIN_ROOT_PATH$input_path" 18897 fi 18898 fi 18899 18900 # remove trailing .exe if any 18901 new_path="${new_path/%.exe/}" 18902 18903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18904 18905 # First separate the path from the arguments. This will split at the first 18906 # space. 18907 complete="$FOUND_MAKE" 18908 path="${complete%% *}" 18909 tmp="$complete EOL" 18910 arguments="${tmp#* }" 18911 18912 # Input might be given as Windows format, start by converting to 18913 # unix format. 18914 new_path="$path" 18915 18916 windows_path="$new_path" 18917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18918 unix_path=`$CYGPATH -u "$windows_path"` 18919 new_path="$unix_path" 18920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18921 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18922 new_path="$unix_path" 18923 fi 18924 18925 18926 # Now try to locate executable using which 18927 new_path=`$WHICH "$new_path" 2> /dev/null` 18928 18929 if test "x$new_path" = x; then 18930 # Oops. Which didn't find the executable. 18931 # The splitting of arguments from the executable at a space might have been incorrect, 18932 # since paths with space are more likely in Windows. Give it another try with the whole 18933 # argument. 18934 path="$complete" 18935 arguments="EOL" 18936 new_path="$path" 18937 18938 windows_path="$new_path" 18939 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18940 unix_path=`$CYGPATH -u "$windows_path"` 18941 new_path="$unix_path" 18942 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18943 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18944 new_path="$unix_path" 18945 fi 18946 18947 18948 new_path=`$WHICH "$new_path" 2> /dev/null` 18949 # bat and cmd files are not always considered executable in MSYS causing which 18950 # to not find them 18951 if test "x$new_path" = x \ 18952 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18953 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18954 new_path="$path" 18955 18956 windows_path="$new_path" 18957 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18958 unix_path=`$CYGPATH -u "$windows_path"` 18959 new_path="$unix_path" 18960 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18961 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18962 new_path="$unix_path" 18963 fi 18964 18965 fi 18966 18967 if test "x$new_path" = x; then 18968 # It's still not found. Now this is an unrecoverable error. 18969 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18970 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18971 has_space=`$ECHO "$complete" | $GREP " "` 18972 if test "x$has_space" != x; then 18973 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18974 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18975 fi 18976 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18977 fi 18978 fi 18979 18980 # Now new_path has a complete unix path to the binary 18981 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18982 # Keep paths in /bin as-is, but remove trailing .exe if any 18983 new_path="${new_path/%.exe/}" 18984 # Do not save /bin paths to all_fixpath_prefixes! 18985 else 18986 # Not in mixed or Windows style, start by that. 18987 new_path=`cmd //c echo $new_path` 18988 18989 input_path="$new_path" 18990 # Check if we need to convert this using DOS-style short mode. If the path 18991 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18992 # take no chances and rewrite it. 18993 # Note: m4 eats our [], so we need to use [ and ] instead. 18994 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18995 if test "x$has_forbidden_chars" != x; then 18996 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18997 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18998 fi 18999 19000 # Output is in $new_path 19001 19002 windows_path="$new_path" 19003 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19004 unix_path=`$CYGPATH -u "$windows_path"` 19005 new_path="$unix_path" 19006 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19007 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19008 new_path="$unix_path" 19009 fi 19010 19011 # remove trailing .exe if any 19012 new_path="${new_path/%.exe/}" 19013 19014 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19015 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19016 fi 19017 19018 else 19019 # We're on a unix platform. Hooray! :) 19020 # First separate the path from the arguments. This will split at the first 19021 # space. 19022 complete="$FOUND_MAKE" 19023 path="${complete%% *}" 19024 tmp="$complete EOL" 19025 arguments="${tmp#* }" 19026 19027 # Cannot rely on the command "which" here since it doesn't always work. 19028 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19029 if test -z "$is_absolute_path"; then 19030 # Path to executable is not absolute. Find it. 19031 IFS_save="$IFS" 19032 IFS=: 19033 for p in $PATH; do 19034 if test -f "$p/$path" && test -x "$p/$path"; then 19035 new_path="$p/$path" 19036 break 19037 fi 19038 done 19039 IFS="$IFS_save" 19040 else 19041 # This is an absolute path, we can use it without further modifications. 19042 new_path="$path" 19043 fi 19044 19045 if test "x$new_path" = x; then 19046 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19047 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19048 has_space=`$ECHO "$complete" | $GREP " "` 19049 if test "x$has_space" != x; then 19050 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19051 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19052 fi 19053 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19054 fi 19055 fi 19056 19057 # Now join together the path and the arguments once again 19058 if test "x$arguments" != xEOL; then 19059 new_complete="$new_path ${arguments% *}" 19060 else 19061 new_complete="$new_path" 19062 fi 19063 19064 if test "x$complete" != "x$new_complete"; then 19065 FOUND_MAKE="$new_complete" 19066 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19067 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19068 fi 19069 fi 19070 19071 fi 19072 fi 19073 fi 19074 fi 19075 19076 fi 19077 PATH=$OLD_PATH 19078 fi 19079 fi 19080 19081 if test "x$FOUND_MAKE" = x; then 19082 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 19083 fi 19084 19085 else 19086 # The variable is set, but is it from the command line or the environment? 19087 19088 # Try to remove the string !MAKE! from our list. 19089 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19090 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19091 # If it failed, the variable was not from the command line. Ignore it, 19092 # but warn the user (except for BASH, which is always set by the calling BASH). 19093 if test "xMAKE" != xBASH; then 19094 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19095 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19096 fi 19097 # Try to locate tool using the code snippet 19098 19099 # Try our hardest to locate a correct version of GNU make 19100 for ac_prog in gmake 19101 do 19102 # Extract the first word of "$ac_prog", so it can be a program name with args. 19103 set dummy $ac_prog; ac_word=$2 19104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19105 $as_echo_n "checking for $ac_word... " >&6; } 19106 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19107 $as_echo_n "(cached) " >&6 19108 else 19109 case $CHECK_GMAKE in 19110 [\\/]* | ?:[\\/]*) 19111 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19112 ;; 19113 *) 19114 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19115 for as_dir in $PATH 19116 do 19117 IFS=$as_save_IFS 19118 test -z "$as_dir" && as_dir=. 19119 for ac_exec_ext in '' $ac_executable_extensions; do 19120 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19121 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19122 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19123 break 2 19124 fi 19125 done 19126 done 19127 IFS=$as_save_IFS 19128 19129 ;; 19130 esac 19131 fi 19132 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19133 if test -n "$CHECK_GMAKE"; then 19134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19135 $as_echo "$CHECK_GMAKE" >&6; } 19136 else 19137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19138 $as_echo "no" >&6; } 19139 fi 19140 19141 19142 test -n "$CHECK_GMAKE" && break 19143 done 19144 19145 19146 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19147 DESCRIPTION="gmake in PATH" 19148 19149 # On Cygwin, we require a newer version of make than on other platforms 19150 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19151 MAKE_VERSION_EXPR="-e 4\." 19152 MAKE_REQUIRED_VERSION="4.0" 19153 else 19154 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19155 MAKE_REQUIRED_VERSION="3.81" 19156 fi 19157 19158 if test "x$MAKE_CANDIDATE" != x; then 19159 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19160 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19161 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19162 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19163 if test "x$IS_GNU_MAKE" = x; then 19164 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19165 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19166 else 19167 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19168 if test "x$IS_MODERN_MAKE" = x; then 19169 { $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 19170 $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;} 19171 else 19172 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19173 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19174 MAKE_EXPECTED_ENV='cygwin' 19175 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19176 MAKE_EXPECTED_ENV='msys' 19177 else 19178 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19179 fi 19180 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19181 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19182 else 19183 # Not relevant for non-Windows 19184 IS_MAKE_CORRECT_ENV=true 19185 fi 19186 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19187 { $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 19188 $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;} 19189 else 19190 FOUND_MAKE=$MAKE_CANDIDATE 19191 19192 # Only process if variable expands to non-empty 19193 19194 if test "x$FOUND_MAKE" != x; then 19195 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19196 19197 # First separate the path from the arguments. This will split at the first 19198 # space. 19199 complete="$FOUND_MAKE" 19200 path="${complete%% *}" 19201 tmp="$complete EOL" 19202 arguments="${tmp#* }" 19203 19204 # Input might be given as Windows format, start by converting to 19205 # unix format. 19206 new_path=`$CYGPATH -u "$path"` 19207 19208 # Now try to locate executable using which 19209 new_path=`$WHICH "$new_path" 2> /dev/null` 19210 # bat and cmd files are not always considered executable in cygwin causing which 19211 # to not find them 19212 if test "x$new_path" = x \ 19213 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19214 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19215 new_path=`$CYGPATH -u "$path"` 19216 fi 19217 if test "x$new_path" = x; then 19218 # Oops. Which didn't find the executable. 19219 # The splitting of arguments from the executable at a space might have been incorrect, 19220 # since paths with space are more likely in Windows. Give it another try with the whole 19221 # argument. 19222 path="$complete" 19223 arguments="EOL" 19224 new_path=`$CYGPATH -u "$path"` 19225 new_path=`$WHICH "$new_path" 2> /dev/null` 19226 # bat and cmd files are not always considered executable in cygwin causing which 19227 # to not find them 19228 if test "x$new_path" = x \ 19229 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19230 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19231 new_path=`$CYGPATH -u "$path"` 19232 fi 19233 if test "x$new_path" = x; then 19234 # It's still not found. Now this is an unrecoverable error. 19235 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19236 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19237 has_space=`$ECHO "$complete" | $GREP " "` 19238 if test "x$has_space" != x; then 19239 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19240 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19241 fi 19242 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19243 fi 19244 fi 19245 19246 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19247 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19248 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19249 # "foo.exe" is OK but "foo" is an error. 19250 # 19251 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19252 # It is also a way to make sure we got the proper file name for the real test later on. 19253 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19254 if test "x$test_shortpath" = x; then 19255 # Short path failed, file does not exist as specified. 19256 # Try adding .exe or .cmd 19257 if test -f "${new_path}.exe"; then 19258 input_to_shortpath="${new_path}.exe" 19259 elif test -f "${new_path}.cmd"; then 19260 input_to_shortpath="${new_path}.cmd" 19261 else 19262 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19263 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19264 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19265 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19266 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19267 fi 19268 else 19269 input_to_shortpath="$new_path" 19270 fi 19271 19272 # Call helper function which possibly converts this using DOS-style short mode. 19273 # If so, the updated path is stored in $new_path. 19274 new_path="$input_to_shortpath" 19275 19276 input_path="$input_to_shortpath" 19277 # Check if we need to convert this using DOS-style short mode. If the path 19278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19279 # take no chances and rewrite it. 19280 # Note: m4 eats our [], so we need to use [ and ] instead. 19281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19282 if test "x$has_forbidden_chars" != x; then 19283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19284 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19285 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19286 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19287 # Going to short mode and back again did indeed matter. Since short mode is 19288 # case insensitive, let's make it lowercase to improve readability. 19289 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19290 # Now convert it back to Unix-style (cygpath) 19291 input_path=`$CYGPATH -u "$shortmode_path"` 19292 new_path="$input_path" 19293 fi 19294 fi 19295 19296 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19297 if test "x$test_cygdrive_prefix" = x; then 19298 # As a simple fix, exclude /usr/bin since it's not a real path. 19299 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19300 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19301 # a path prefixed by /cygdrive for fixpath to work. 19302 new_path="$CYGWIN_ROOT_PATH$input_path" 19303 fi 19304 fi 19305 19306 # remove trailing .exe if any 19307 new_path="${new_path/%.exe/}" 19308 19309 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19310 19311 # First separate the path from the arguments. This will split at the first 19312 # space. 19313 complete="$FOUND_MAKE" 19314 path="${complete%% *}" 19315 tmp="$complete EOL" 19316 arguments="${tmp#* }" 19317 19318 # Input might be given as Windows format, start by converting to 19319 # unix format. 19320 new_path="$path" 19321 19322 windows_path="$new_path" 19323 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19324 unix_path=`$CYGPATH -u "$windows_path"` 19325 new_path="$unix_path" 19326 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19327 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19328 new_path="$unix_path" 19329 fi 19330 19331 19332 # Now try to locate executable using which 19333 new_path=`$WHICH "$new_path" 2> /dev/null` 19334 19335 if test "x$new_path" = x; then 19336 # Oops. Which didn't find the executable. 19337 # The splitting of arguments from the executable at a space might have been incorrect, 19338 # since paths with space are more likely in Windows. Give it another try with the whole 19339 # argument. 19340 path="$complete" 19341 arguments="EOL" 19342 new_path="$path" 19343 19344 windows_path="$new_path" 19345 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19346 unix_path=`$CYGPATH -u "$windows_path"` 19347 new_path="$unix_path" 19348 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19349 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19350 new_path="$unix_path" 19351 fi 19352 19353 19354 new_path=`$WHICH "$new_path" 2> /dev/null` 19355 # bat and cmd files are not always considered executable in MSYS causing which 19356 # to not find them 19357 if test "x$new_path" = x \ 19358 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19359 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19360 new_path="$path" 19361 19362 windows_path="$new_path" 19363 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19364 unix_path=`$CYGPATH -u "$windows_path"` 19365 new_path="$unix_path" 19366 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19367 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19368 new_path="$unix_path" 19369 fi 19370 19371 fi 19372 19373 if test "x$new_path" = x; then 19374 # It's still not found. Now this is an unrecoverable error. 19375 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19376 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19377 has_space=`$ECHO "$complete" | $GREP " "` 19378 if test "x$has_space" != x; then 19379 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19380 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19381 fi 19382 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19383 fi 19384 fi 19385 19386 # Now new_path has a complete unix path to the binary 19387 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19388 # Keep paths in /bin as-is, but remove trailing .exe if any 19389 new_path="${new_path/%.exe/}" 19390 # Do not save /bin paths to all_fixpath_prefixes! 19391 else 19392 # Not in mixed or Windows style, start by that. 19393 new_path=`cmd //c echo $new_path` 19394 19395 input_path="$new_path" 19396 # Check if we need to convert this using DOS-style short mode. If the path 19397 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19398 # take no chances and rewrite it. 19399 # Note: m4 eats our [], so we need to use [ and ] instead. 19400 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19401 if test "x$has_forbidden_chars" != x; then 19402 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19403 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19404 fi 19405 19406 # Output is in $new_path 19407 19408 windows_path="$new_path" 19409 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19410 unix_path=`$CYGPATH -u "$windows_path"` 19411 new_path="$unix_path" 19412 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19413 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19414 new_path="$unix_path" 19415 fi 19416 19417 # remove trailing .exe if any 19418 new_path="${new_path/%.exe/}" 19419 19420 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19421 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19422 fi 19423 19424 else 19425 # We're on a unix platform. Hooray! :) 19426 # First separate the path from the arguments. This will split at the first 19427 # space. 19428 complete="$FOUND_MAKE" 19429 path="${complete%% *}" 19430 tmp="$complete EOL" 19431 arguments="${tmp#* }" 19432 19433 # Cannot rely on the command "which" here since it doesn't always work. 19434 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19435 if test -z "$is_absolute_path"; then 19436 # Path to executable is not absolute. Find it. 19437 IFS_save="$IFS" 19438 IFS=: 19439 for p in $PATH; do 19440 if test -f "$p/$path" && test -x "$p/$path"; then 19441 new_path="$p/$path" 19442 break 19443 fi 19444 done 19445 IFS="$IFS_save" 19446 else 19447 # This is an absolute path, we can use it without further modifications. 19448 new_path="$path" 19449 fi 19450 19451 if test "x$new_path" = x; then 19452 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19453 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19454 has_space=`$ECHO "$complete" | $GREP " "` 19455 if test "x$has_space" != x; then 19456 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19457 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19458 fi 19459 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19460 fi 19461 fi 19462 19463 # Now join together the path and the arguments once again 19464 if test "x$arguments" != xEOL; then 19465 new_complete="$new_path ${arguments% *}" 19466 else 19467 new_complete="$new_path" 19468 fi 19469 19470 if test "x$complete" != "x$new_complete"; then 19471 FOUND_MAKE="$new_complete" 19472 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19473 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19474 fi 19475 fi 19476 19477 fi 19478 fi 19479 fi 19480 fi 19481 19482 19483 if test "x$FOUND_MAKE" = x; then 19484 for ac_prog in make 19485 do 19486 # Extract the first word of "$ac_prog", so it can be a program name with args. 19487 set dummy $ac_prog; ac_word=$2 19488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19489 $as_echo_n "checking for $ac_word... " >&6; } 19490 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19491 $as_echo_n "(cached) " >&6 19492 else 19493 case $CHECK_MAKE in 19494 [\\/]* | ?:[\\/]*) 19495 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19496 ;; 19497 *) 19498 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19499 for as_dir in $PATH 19500 do 19501 IFS=$as_save_IFS 19502 test -z "$as_dir" && as_dir=. 19503 for ac_exec_ext in '' $ac_executable_extensions; do 19504 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19505 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19506 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19507 break 2 19508 fi 19509 done 19510 done 19511 IFS=$as_save_IFS 19512 19513 ;; 19514 esac 19515 fi 19516 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19517 if test -n "$CHECK_MAKE"; then 19518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19519 $as_echo "$CHECK_MAKE" >&6; } 19520 else 19521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19522 $as_echo "no" >&6; } 19523 fi 19524 19525 19526 test -n "$CHECK_MAKE" && break 19527 done 19528 19529 19530 MAKE_CANDIDATE=""$CHECK_MAKE"" 19531 DESCRIPTION="make in PATH" 19532 19533 # On Cygwin, we require a newer version of make than on other platforms 19534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19535 MAKE_VERSION_EXPR="-e 4\." 19536 MAKE_REQUIRED_VERSION="4.0" 19537 else 19538 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19539 MAKE_REQUIRED_VERSION="3.81" 19540 fi 19541 19542 if test "x$MAKE_CANDIDATE" != x; then 19543 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19544 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19545 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19546 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19547 if test "x$IS_GNU_MAKE" = x; then 19548 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19549 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19550 else 19551 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19552 if test "x$IS_MODERN_MAKE" = x; then 19553 { $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 19554 $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;} 19555 else 19556 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19557 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19558 MAKE_EXPECTED_ENV='cygwin' 19559 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19560 MAKE_EXPECTED_ENV='msys' 19561 else 19562 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19563 fi 19564 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19565 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19566 else 19567 # Not relevant for non-Windows 19568 IS_MAKE_CORRECT_ENV=true 19569 fi 19570 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19571 { $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 19572 $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;} 19573 else 19574 FOUND_MAKE=$MAKE_CANDIDATE 19575 19576 # Only process if variable expands to non-empty 19577 19578 if test "x$FOUND_MAKE" != x; then 19579 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19580 19581 # First separate the path from the arguments. This will split at the first 19582 # space. 19583 complete="$FOUND_MAKE" 19584 path="${complete%% *}" 19585 tmp="$complete EOL" 19586 arguments="${tmp#* }" 19587 19588 # Input might be given as Windows format, start by converting to 19589 # unix format. 19590 new_path=`$CYGPATH -u "$path"` 19591 19592 # Now try to locate executable using which 19593 new_path=`$WHICH "$new_path" 2> /dev/null` 19594 # bat and cmd files are not always considered executable in cygwin causing which 19595 # to not find them 19596 if test "x$new_path" = x \ 19597 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19598 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19599 new_path=`$CYGPATH -u "$path"` 19600 fi 19601 if test "x$new_path" = x; then 19602 # Oops. Which didn't find the executable. 19603 # The splitting of arguments from the executable at a space might have been incorrect, 19604 # since paths with space are more likely in Windows. Give it another try with the whole 19605 # argument. 19606 path="$complete" 19607 arguments="EOL" 19608 new_path=`$CYGPATH -u "$path"` 19609 new_path=`$WHICH "$new_path" 2> /dev/null` 19610 # bat and cmd files are not always considered executable in cygwin causing which 19611 # to not find them 19612 if test "x$new_path" = x \ 19613 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19614 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19615 new_path=`$CYGPATH -u "$path"` 19616 fi 19617 if test "x$new_path" = x; then 19618 # It's still not found. Now this is an unrecoverable error. 19619 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19620 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19621 has_space=`$ECHO "$complete" | $GREP " "` 19622 if test "x$has_space" != x; then 19623 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19624 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19625 fi 19626 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19627 fi 19628 fi 19629 19630 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19631 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19632 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19633 # "foo.exe" is OK but "foo" is an error. 19634 # 19635 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19636 # It is also a way to make sure we got the proper file name for the real test later on. 19637 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19638 if test "x$test_shortpath" = x; then 19639 # Short path failed, file does not exist as specified. 19640 # Try adding .exe or .cmd 19641 if test -f "${new_path}.exe"; then 19642 input_to_shortpath="${new_path}.exe" 19643 elif test -f "${new_path}.cmd"; then 19644 input_to_shortpath="${new_path}.cmd" 19645 else 19646 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19647 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19648 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19649 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19650 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19651 fi 19652 else 19653 input_to_shortpath="$new_path" 19654 fi 19655 19656 # Call helper function which possibly converts this using DOS-style short mode. 19657 # If so, the updated path is stored in $new_path. 19658 new_path="$input_to_shortpath" 19659 19660 input_path="$input_to_shortpath" 19661 # Check if we need to convert this using DOS-style short mode. If the path 19662 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19663 # take no chances and rewrite it. 19664 # Note: m4 eats our [], so we need to use [ and ] instead. 19665 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19666 if test "x$has_forbidden_chars" != x; then 19667 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19668 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19669 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19670 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19671 # Going to short mode and back again did indeed matter. Since short mode is 19672 # case insensitive, let's make it lowercase to improve readability. 19673 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19674 # Now convert it back to Unix-style (cygpath) 19675 input_path=`$CYGPATH -u "$shortmode_path"` 19676 new_path="$input_path" 19677 fi 19678 fi 19679 19680 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19681 if test "x$test_cygdrive_prefix" = x; then 19682 # As a simple fix, exclude /usr/bin since it's not a real path. 19683 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19684 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19685 # a path prefixed by /cygdrive for fixpath to work. 19686 new_path="$CYGWIN_ROOT_PATH$input_path" 19687 fi 19688 fi 19689 19690 # remove trailing .exe if any 19691 new_path="${new_path/%.exe/}" 19692 19693 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19694 19695 # First separate the path from the arguments. This will split at the first 19696 # space. 19697 complete="$FOUND_MAKE" 19698 path="${complete%% *}" 19699 tmp="$complete EOL" 19700 arguments="${tmp#* }" 19701 19702 # Input might be given as Windows format, start by converting to 19703 # unix format. 19704 new_path="$path" 19705 19706 windows_path="$new_path" 19707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19708 unix_path=`$CYGPATH -u "$windows_path"` 19709 new_path="$unix_path" 19710 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19711 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19712 new_path="$unix_path" 19713 fi 19714 19715 19716 # Now try to locate executable using which 19717 new_path=`$WHICH "$new_path" 2> /dev/null` 19718 19719 if test "x$new_path" = x; then 19720 # Oops. Which didn't find the executable. 19721 # The splitting of arguments from the executable at a space might have been incorrect, 19722 # since paths with space are more likely in Windows. Give it another try with the whole 19723 # argument. 19724 path="$complete" 19725 arguments="EOL" 19726 new_path="$path" 19727 19728 windows_path="$new_path" 19729 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19730 unix_path=`$CYGPATH -u "$windows_path"` 19731 new_path="$unix_path" 19732 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19733 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19734 new_path="$unix_path" 19735 fi 19736 19737 19738 new_path=`$WHICH "$new_path" 2> /dev/null` 19739 # bat and cmd files are not always considered executable in MSYS causing which 19740 # to not find them 19741 if test "x$new_path" = x \ 19742 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19743 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19744 new_path="$path" 19745 19746 windows_path="$new_path" 19747 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19748 unix_path=`$CYGPATH -u "$windows_path"` 19749 new_path="$unix_path" 19750 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19751 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19752 new_path="$unix_path" 19753 fi 19754 19755 fi 19756 19757 if test "x$new_path" = x; then 19758 # It's still not found. Now this is an unrecoverable error. 19759 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19760 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19761 has_space=`$ECHO "$complete" | $GREP " "` 19762 if test "x$has_space" != x; then 19763 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19764 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19765 fi 19766 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19767 fi 19768 fi 19769 19770 # Now new_path has a complete unix path to the binary 19771 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19772 # Keep paths in /bin as-is, but remove trailing .exe if any 19773 new_path="${new_path/%.exe/}" 19774 # Do not save /bin paths to all_fixpath_prefixes! 19775 else 19776 # Not in mixed or Windows style, start by that. 19777 new_path=`cmd //c echo $new_path` 19778 19779 input_path="$new_path" 19780 # Check if we need to convert this using DOS-style short mode. If the path 19781 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19782 # take no chances and rewrite it. 19783 # Note: m4 eats our [], so we need to use [ and ] instead. 19784 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19785 if test "x$has_forbidden_chars" != x; then 19786 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19787 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19788 fi 19789 19790 # Output is in $new_path 19791 19792 windows_path="$new_path" 19793 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19794 unix_path=`$CYGPATH -u "$windows_path"` 19795 new_path="$unix_path" 19796 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19797 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19798 new_path="$unix_path" 19799 fi 19800 19801 # remove trailing .exe if any 19802 new_path="${new_path/%.exe/}" 19803 19804 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19805 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19806 fi 19807 19808 else 19809 # We're on a unix platform. Hooray! :) 19810 # First separate the path from the arguments. This will split at the first 19811 # space. 19812 complete="$FOUND_MAKE" 19813 path="${complete%% *}" 19814 tmp="$complete EOL" 19815 arguments="${tmp#* }" 19816 19817 # Cannot rely on the command "which" here since it doesn't always work. 19818 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19819 if test -z "$is_absolute_path"; then 19820 # Path to executable is not absolute. Find it. 19821 IFS_save="$IFS" 19822 IFS=: 19823 for p in $PATH; do 19824 if test -f "$p/$path" && test -x "$p/$path"; then 19825 new_path="$p/$path" 19826 break 19827 fi 19828 done 19829 IFS="$IFS_save" 19830 else 19831 # This is an absolute path, we can use it without further modifications. 19832 new_path="$path" 19833 fi 19834 19835 if test "x$new_path" = x; then 19836 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19837 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19838 has_space=`$ECHO "$complete" | $GREP " "` 19839 if test "x$has_space" != x; then 19840 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19841 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19842 fi 19843 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19844 fi 19845 fi 19846 19847 # Now join together the path and the arguments once again 19848 if test "x$arguments" != xEOL; then 19849 new_complete="$new_path ${arguments% *}" 19850 else 19851 new_complete="$new_path" 19852 fi 19853 19854 if test "x$complete" != "x$new_complete"; then 19855 FOUND_MAKE="$new_complete" 19856 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19857 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19858 fi 19859 fi 19860 19861 fi 19862 fi 19863 fi 19864 fi 19865 19866 fi 19867 19868 if test "x$FOUND_MAKE" = x; then 19869 if test "x$TOOLCHAIN_PATH" != x; then 19870 # We have a toolchain path, check that as well before giving up. 19871 OLD_PATH=$PATH 19872 PATH=$TOOLCHAIN_PATH:$PATH 19873 for ac_prog in gmake 19874 do 19875 # Extract the first word of "$ac_prog", so it can be a program name with args. 19876 set dummy $ac_prog; ac_word=$2 19877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19878 $as_echo_n "checking for $ac_word... " >&6; } 19879 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 19880 $as_echo_n "(cached) " >&6 19881 else 19882 case $CHECK_TOOLSDIR_GMAKE in 19883 [\\/]* | ?:[\\/]*) 19884 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 19885 ;; 19886 *) 19887 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19888 for as_dir in $PATH 19889 do 19890 IFS=$as_save_IFS 19891 test -z "$as_dir" && as_dir=. 19892 for ac_exec_ext in '' $ac_executable_extensions; do 19893 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19894 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19895 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19896 break 2 19897 fi 19898 done 19899 done 19900 IFS=$as_save_IFS 19901 19902 ;; 19903 esac 19904 fi 19905 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 19906 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 19907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 19908 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 19909 else 19910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19911 $as_echo "no" >&6; } 19912 fi 19913 19914 19915 test -n "$CHECK_TOOLSDIR_GMAKE" && break 19916 done 19917 19918 19919 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 19920 DESCRIPTION="gmake in tools-dir" 19921 19922 # On Cygwin, we require a newer version of make than on other platforms 19923 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19924 MAKE_VERSION_EXPR="-e 4\." 19925 MAKE_REQUIRED_VERSION="4.0" 19926 else 19927 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19928 MAKE_REQUIRED_VERSION="3.81" 19929 fi 19930 19931 if test "x$MAKE_CANDIDATE" != x; then 19932 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19933 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19934 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19935 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19936 if test "x$IS_GNU_MAKE" = x; then 19937 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19938 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19939 else 19940 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19941 if test "x$IS_MODERN_MAKE" = x; then 19942 { $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 19943 $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;} 19944 else 19945 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19946 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19947 MAKE_EXPECTED_ENV='cygwin' 19948 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19949 MAKE_EXPECTED_ENV='msys' 19950 else 19951 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19952 fi 19953 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19954 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19955 else 19956 # Not relevant for non-Windows 19957 IS_MAKE_CORRECT_ENV=true 19958 fi 19959 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19960 { $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 19961 $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;} 19962 else 19963 FOUND_MAKE=$MAKE_CANDIDATE 19964 19965 # Only process if variable expands to non-empty 19966 19967 if test "x$FOUND_MAKE" != x; then 19968 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19969 19970 # First separate the path from the arguments. This will split at the first 19971 # space. 19972 complete="$FOUND_MAKE" 19973 path="${complete%% *}" 19974 tmp="$complete EOL" 19975 arguments="${tmp#* }" 19976 19977 # Input might be given as Windows format, start by converting to 19978 # unix format. 19979 new_path=`$CYGPATH -u "$path"` 19980 19981 # Now try to locate executable using which 19982 new_path=`$WHICH "$new_path" 2> /dev/null` 19983 # bat and cmd files are not always considered executable in cygwin causing which 19984 # to not find them 19985 if test "x$new_path" = x \ 19986 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19987 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19988 new_path=`$CYGPATH -u "$path"` 19989 fi 19990 if test "x$new_path" = x; then 19991 # Oops. Which didn't find the executable. 19992 # The splitting of arguments from the executable at a space might have been incorrect, 19993 # since paths with space are more likely in Windows. Give it another try with the whole 19994 # argument. 19995 path="$complete" 19996 arguments="EOL" 19997 new_path=`$CYGPATH -u "$path"` 19998 new_path=`$WHICH "$new_path" 2> /dev/null` 19999 # bat and cmd files are not always considered executable in cygwin causing which 20000 # to not find them 20001 if test "x$new_path" = x \ 20002 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20003 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20004 new_path=`$CYGPATH -u "$path"` 20005 fi 20006 if test "x$new_path" = x; then 20007 # It's still not found. Now this is an unrecoverable error. 20008 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20009 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20010 has_space=`$ECHO "$complete" | $GREP " "` 20011 if test "x$has_space" != x; then 20012 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20013 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20014 fi 20015 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20016 fi 20017 fi 20018 20019 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20020 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20021 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20022 # "foo.exe" is OK but "foo" is an error. 20023 # 20024 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20025 # It is also a way to make sure we got the proper file name for the real test later on. 20026 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20027 if test "x$test_shortpath" = x; then 20028 # Short path failed, file does not exist as specified. 20029 # Try adding .exe or .cmd 20030 if test -f "${new_path}.exe"; then 20031 input_to_shortpath="${new_path}.exe" 20032 elif test -f "${new_path}.cmd"; then 20033 input_to_shortpath="${new_path}.cmd" 20034 else 20035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20036 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20037 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20038 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20039 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20040 fi 20041 else 20042 input_to_shortpath="$new_path" 20043 fi 20044 20045 # Call helper function which possibly converts this using DOS-style short mode. 20046 # If so, the updated path is stored in $new_path. 20047 new_path="$input_to_shortpath" 20048 20049 input_path="$input_to_shortpath" 20050 # Check if we need to convert this using DOS-style short mode. If the path 20051 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20052 # take no chances and rewrite it. 20053 # Note: m4 eats our [], so we need to use [ and ] instead. 20054 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20055 if test "x$has_forbidden_chars" != x; then 20056 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20057 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20058 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20059 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20060 # Going to short mode and back again did indeed matter. Since short mode is 20061 # case insensitive, let's make it lowercase to improve readability. 20062 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20063 # Now convert it back to Unix-style (cygpath) 20064 input_path=`$CYGPATH -u "$shortmode_path"` 20065 new_path="$input_path" 20066 fi 20067 fi 20068 20069 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20070 if test "x$test_cygdrive_prefix" = x; then 20071 # As a simple fix, exclude /usr/bin since it's not a real path. 20072 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20073 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20074 # a path prefixed by /cygdrive for fixpath to work. 20075 new_path="$CYGWIN_ROOT_PATH$input_path" 20076 fi 20077 fi 20078 20079 # remove trailing .exe if any 20080 new_path="${new_path/%.exe/}" 20081 20082 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20083 20084 # First separate the path from the arguments. This will split at the first 20085 # space. 20086 complete="$FOUND_MAKE" 20087 path="${complete%% *}" 20088 tmp="$complete EOL" 20089 arguments="${tmp#* }" 20090 20091 # Input might be given as Windows format, start by converting to 20092 # unix format. 20093 new_path="$path" 20094 20095 windows_path="$new_path" 20096 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20097 unix_path=`$CYGPATH -u "$windows_path"` 20098 new_path="$unix_path" 20099 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20100 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20101 new_path="$unix_path" 20102 fi 20103 20104 20105 # Now try to locate executable using which 20106 new_path=`$WHICH "$new_path" 2> /dev/null` 20107 20108 if test "x$new_path" = x; then 20109 # Oops. Which didn't find the executable. 20110 # The splitting of arguments from the executable at a space might have been incorrect, 20111 # since paths with space are more likely in Windows. Give it another try with the whole 20112 # argument. 20113 path="$complete" 20114 arguments="EOL" 20115 new_path="$path" 20116 20117 windows_path="$new_path" 20118 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20119 unix_path=`$CYGPATH -u "$windows_path"` 20120 new_path="$unix_path" 20121 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20122 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20123 new_path="$unix_path" 20124 fi 20125 20126 20127 new_path=`$WHICH "$new_path" 2> /dev/null` 20128 # bat and cmd files are not always considered executable in MSYS causing which 20129 # to not find them 20130 if test "x$new_path" = x \ 20131 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20132 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20133 new_path="$path" 20134 20135 windows_path="$new_path" 20136 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20137 unix_path=`$CYGPATH -u "$windows_path"` 20138 new_path="$unix_path" 20139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20140 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20141 new_path="$unix_path" 20142 fi 20143 20144 fi 20145 20146 if test "x$new_path" = x; then 20147 # It's still not found. Now this is an unrecoverable error. 20148 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20149 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20150 has_space=`$ECHO "$complete" | $GREP " "` 20151 if test "x$has_space" != x; then 20152 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20153 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20154 fi 20155 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20156 fi 20157 fi 20158 20159 # Now new_path has a complete unix path to the binary 20160 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20161 # Keep paths in /bin as-is, but remove trailing .exe if any 20162 new_path="${new_path/%.exe/}" 20163 # Do not save /bin paths to all_fixpath_prefixes! 20164 else 20165 # Not in mixed or Windows style, start by that. 20166 new_path=`cmd //c echo $new_path` 20167 20168 input_path="$new_path" 20169 # Check if we need to convert this using DOS-style short mode. If the path 20170 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20171 # take no chances and rewrite it. 20172 # Note: m4 eats our [], so we need to use [ and ] instead. 20173 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20174 if test "x$has_forbidden_chars" != x; then 20175 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20176 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20177 fi 20178 20179 # Output is in $new_path 20180 20181 windows_path="$new_path" 20182 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20183 unix_path=`$CYGPATH -u "$windows_path"` 20184 new_path="$unix_path" 20185 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20186 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20187 new_path="$unix_path" 20188 fi 20189 20190 # remove trailing .exe if any 20191 new_path="${new_path/%.exe/}" 20192 20193 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20194 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20195 fi 20196 20197 else 20198 # We're on a unix platform. Hooray! :) 20199 # First separate the path from the arguments. This will split at the first 20200 # space. 20201 complete="$FOUND_MAKE" 20202 path="${complete%% *}" 20203 tmp="$complete EOL" 20204 arguments="${tmp#* }" 20205 20206 # Cannot rely on the command "which" here since it doesn't always work. 20207 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20208 if test -z "$is_absolute_path"; then 20209 # Path to executable is not absolute. Find it. 20210 IFS_save="$IFS" 20211 IFS=: 20212 for p in $PATH; do 20213 if test -f "$p/$path" && test -x "$p/$path"; then 20214 new_path="$p/$path" 20215 break 20216 fi 20217 done 20218 IFS="$IFS_save" 20219 else 20220 # This is an absolute path, we can use it without further modifications. 20221 new_path="$path" 20222 fi 20223 20224 if test "x$new_path" = x; then 20225 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20226 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20227 has_space=`$ECHO "$complete" | $GREP " "` 20228 if test "x$has_space" != x; then 20229 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20230 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20231 fi 20232 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20233 fi 20234 fi 20235 20236 # Now join together the path and the arguments once again 20237 if test "x$arguments" != xEOL; then 20238 new_complete="$new_path ${arguments% *}" 20239 else 20240 new_complete="$new_path" 20241 fi 20242 20243 if test "x$complete" != "x$new_complete"; then 20244 FOUND_MAKE="$new_complete" 20245 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20246 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20247 fi 20248 fi 20249 20250 fi 20251 fi 20252 fi 20253 fi 20254 20255 if test "x$FOUND_MAKE" = x; then 20256 for ac_prog in make 20257 do 20258 # Extract the first word of "$ac_prog", so it can be a program name with args. 20259 set dummy $ac_prog; ac_word=$2 20260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20261 $as_echo_n "checking for $ac_word... " >&6; } 20262 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20263 $as_echo_n "(cached) " >&6 20264 else 20265 case $CHECK_TOOLSDIR_MAKE in 20266 [\\/]* | ?:[\\/]*) 20267 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20268 ;; 20269 *) 20270 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20271 for as_dir in $PATH 20272 do 20273 IFS=$as_save_IFS 20274 test -z "$as_dir" && as_dir=. 20275 for ac_exec_ext in '' $ac_executable_extensions; do 20276 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20277 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20278 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20279 break 2 20280 fi 20281 done 20282 done 20283 IFS=$as_save_IFS 20284 20285 ;; 20286 esac 20287 fi 20288 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20289 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20291 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20292 else 20293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20294 $as_echo "no" >&6; } 20295 fi 20296 20297 20298 test -n "$CHECK_TOOLSDIR_MAKE" && break 20299 done 20300 20301 20302 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20303 DESCRIPTION="make in tools-dir" 20304 20305 # On Cygwin, we require a newer version of make than on other platforms 20306 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20307 MAKE_VERSION_EXPR="-e 4\." 20308 MAKE_REQUIRED_VERSION="4.0" 20309 else 20310 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20311 MAKE_REQUIRED_VERSION="3.81" 20312 fi 20313 20314 if test "x$MAKE_CANDIDATE" != x; then 20315 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20316 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20317 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20318 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20319 if test "x$IS_GNU_MAKE" = x; then 20320 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20321 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20322 else 20323 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20324 if test "x$IS_MODERN_MAKE" = x; then 20325 { $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 20326 $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;} 20327 else 20328 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20329 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20330 MAKE_EXPECTED_ENV='cygwin' 20331 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20332 MAKE_EXPECTED_ENV='msys' 20333 else 20334 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20335 fi 20336 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20337 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20338 else 20339 # Not relevant for non-Windows 20340 IS_MAKE_CORRECT_ENV=true 20341 fi 20342 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20343 { $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 20344 $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;} 20345 else 20346 FOUND_MAKE=$MAKE_CANDIDATE 20347 20348 # Only process if variable expands to non-empty 20349 20350 if test "x$FOUND_MAKE" != x; then 20351 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20352 20353 # First separate the path from the arguments. This will split at the first 20354 # space. 20355 complete="$FOUND_MAKE" 20356 path="${complete%% *}" 20357 tmp="$complete EOL" 20358 arguments="${tmp#* }" 20359 20360 # Input might be given as Windows format, start by converting to 20361 # unix format. 20362 new_path=`$CYGPATH -u "$path"` 20363 20364 # Now try to locate executable using which 20365 new_path=`$WHICH "$new_path" 2> /dev/null` 20366 # bat and cmd files are not always considered executable in cygwin causing which 20367 # to not find them 20368 if test "x$new_path" = x \ 20369 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20370 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20371 new_path=`$CYGPATH -u "$path"` 20372 fi 20373 if test "x$new_path" = x; then 20374 # Oops. Which didn't find the executable. 20375 # The splitting of arguments from the executable at a space might have been incorrect, 20376 # since paths with space are more likely in Windows. Give it another try with the whole 20377 # argument. 20378 path="$complete" 20379 arguments="EOL" 20380 new_path=`$CYGPATH -u "$path"` 20381 new_path=`$WHICH "$new_path" 2> /dev/null` 20382 # bat and cmd files are not always considered executable in cygwin causing which 20383 # to not find them 20384 if test "x$new_path" = x \ 20385 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20386 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20387 new_path=`$CYGPATH -u "$path"` 20388 fi 20389 if test "x$new_path" = x; then 20390 # It's still not found. Now this is an unrecoverable error. 20391 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20392 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20393 has_space=`$ECHO "$complete" | $GREP " "` 20394 if test "x$has_space" != x; then 20395 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20396 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20397 fi 20398 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20399 fi 20400 fi 20401 20402 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20403 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20404 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20405 # "foo.exe" is OK but "foo" is an error. 20406 # 20407 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20408 # It is also a way to make sure we got the proper file name for the real test later on. 20409 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20410 if test "x$test_shortpath" = x; then 20411 # Short path failed, file does not exist as specified. 20412 # Try adding .exe or .cmd 20413 if test -f "${new_path}.exe"; then 20414 input_to_shortpath="${new_path}.exe" 20415 elif test -f "${new_path}.cmd"; then 20416 input_to_shortpath="${new_path}.cmd" 20417 else 20418 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20419 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20420 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20421 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20422 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20423 fi 20424 else 20425 input_to_shortpath="$new_path" 20426 fi 20427 20428 # Call helper function which possibly converts this using DOS-style short mode. 20429 # If so, the updated path is stored in $new_path. 20430 new_path="$input_to_shortpath" 20431 20432 input_path="$input_to_shortpath" 20433 # Check if we need to convert this using DOS-style short mode. If the path 20434 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20435 # take no chances and rewrite it. 20436 # Note: m4 eats our [], so we need to use [ and ] instead. 20437 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20438 if test "x$has_forbidden_chars" != x; then 20439 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20440 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20441 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20442 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20443 # Going to short mode and back again did indeed matter. Since short mode is 20444 # case insensitive, let's make it lowercase to improve readability. 20445 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20446 # Now convert it back to Unix-style (cygpath) 20447 input_path=`$CYGPATH -u "$shortmode_path"` 20448 new_path="$input_path" 20449 fi 20450 fi 20451 20452 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20453 if test "x$test_cygdrive_prefix" = x; then 20454 # As a simple fix, exclude /usr/bin since it's not a real path. 20455 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20456 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20457 # a path prefixed by /cygdrive for fixpath to work. 20458 new_path="$CYGWIN_ROOT_PATH$input_path" 20459 fi 20460 fi 20461 20462 # remove trailing .exe if any 20463 new_path="${new_path/%.exe/}" 20464 20465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20466 20467 # First separate the path from the arguments. This will split at the first 20468 # space. 20469 complete="$FOUND_MAKE" 20470 path="${complete%% *}" 20471 tmp="$complete EOL" 20472 arguments="${tmp#* }" 20473 20474 # Input might be given as Windows format, start by converting to 20475 # unix format. 20476 new_path="$path" 20477 20478 windows_path="$new_path" 20479 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20480 unix_path=`$CYGPATH -u "$windows_path"` 20481 new_path="$unix_path" 20482 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20483 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20484 new_path="$unix_path" 20485 fi 20486 20487 20488 # Now try to locate executable using which 20489 new_path=`$WHICH "$new_path" 2> /dev/null` 20490 20491 if test "x$new_path" = x; then 20492 # Oops. Which didn't find the executable. 20493 # The splitting of arguments from the executable at a space might have been incorrect, 20494 # since paths with space are more likely in Windows. Give it another try with the whole 20495 # argument. 20496 path="$complete" 20497 arguments="EOL" 20498 new_path="$path" 20499 20500 windows_path="$new_path" 20501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20502 unix_path=`$CYGPATH -u "$windows_path"` 20503 new_path="$unix_path" 20504 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20505 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20506 new_path="$unix_path" 20507 fi 20508 20509 20510 new_path=`$WHICH "$new_path" 2> /dev/null` 20511 # bat and cmd files are not always considered executable in MSYS causing which 20512 # to not find them 20513 if test "x$new_path" = x \ 20514 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20515 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20516 new_path="$path" 20517 20518 windows_path="$new_path" 20519 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20520 unix_path=`$CYGPATH -u "$windows_path"` 20521 new_path="$unix_path" 20522 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20523 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20524 new_path="$unix_path" 20525 fi 20526 20527 fi 20528 20529 if test "x$new_path" = x; then 20530 # It's still not found. Now this is an unrecoverable error. 20531 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20532 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20533 has_space=`$ECHO "$complete" | $GREP " "` 20534 if test "x$has_space" != x; then 20535 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20536 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20537 fi 20538 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20539 fi 20540 fi 20541 20542 # Now new_path has a complete unix path to the binary 20543 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20544 # Keep paths in /bin as-is, but remove trailing .exe if any 20545 new_path="${new_path/%.exe/}" 20546 # Do not save /bin paths to all_fixpath_prefixes! 20547 else 20548 # Not in mixed or Windows style, start by that. 20549 new_path=`cmd //c echo $new_path` 20550 20551 input_path="$new_path" 20552 # Check if we need to convert this using DOS-style short mode. If the path 20553 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20554 # take no chances and rewrite it. 20555 # Note: m4 eats our [], so we need to use [ and ] instead. 20556 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20557 if test "x$has_forbidden_chars" != x; then 20558 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20559 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20560 fi 20561 20562 # Output is in $new_path 20563 20564 windows_path="$new_path" 20565 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20566 unix_path=`$CYGPATH -u "$windows_path"` 20567 new_path="$unix_path" 20568 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20569 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20570 new_path="$unix_path" 20571 fi 20572 20573 # remove trailing .exe if any 20574 new_path="${new_path/%.exe/}" 20575 20576 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20577 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20578 fi 20579 20580 else 20581 # We're on a unix platform. Hooray! :) 20582 # First separate the path from the arguments. This will split at the first 20583 # space. 20584 complete="$FOUND_MAKE" 20585 path="${complete%% *}" 20586 tmp="$complete EOL" 20587 arguments="${tmp#* }" 20588 20589 # Cannot rely on the command "which" here since it doesn't always work. 20590 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20591 if test -z "$is_absolute_path"; then 20592 # Path to executable is not absolute. Find it. 20593 IFS_save="$IFS" 20594 IFS=: 20595 for p in $PATH; do 20596 if test -f "$p/$path" && test -x "$p/$path"; then 20597 new_path="$p/$path" 20598 break 20599 fi 20600 done 20601 IFS="$IFS_save" 20602 else 20603 # This is an absolute path, we can use it without further modifications. 20604 new_path="$path" 20605 fi 20606 20607 if test "x$new_path" = x; then 20608 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20609 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20610 has_space=`$ECHO "$complete" | $GREP " "` 20611 if test "x$has_space" != x; then 20612 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20613 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20614 fi 20615 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20616 fi 20617 fi 20618 20619 # Now join together the path and the arguments once again 20620 if test "x$arguments" != xEOL; then 20621 new_complete="$new_path ${arguments% *}" 20622 else 20623 new_complete="$new_path" 20624 fi 20625 20626 if test "x$complete" != "x$new_complete"; then 20627 FOUND_MAKE="$new_complete" 20628 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20629 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20630 fi 20631 fi 20632 20633 fi 20634 fi 20635 fi 20636 fi 20637 20638 fi 20639 PATH=$OLD_PATH 20640 fi 20641 fi 20642 20643 if test "x$FOUND_MAKE" = x; then 20644 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 20645 fi 20646 20647 else 20648 # If it succeeded, then it was overridden by the user. We will use it 20649 # for the tool. 20650 20651 # First remove it from the list of overridden variables, so we can test 20652 # for unknown variables in the end. 20653 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20654 20655 # Check if we try to supply an empty value 20656 if test "x$MAKE" = x; then 20657 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20658 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20660 $as_echo_n "checking for MAKE... " >&6; } 20661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20662 $as_echo "disabled" >&6; } 20663 else 20664 # Check if the provided tool contains a complete path. 20665 tool_specified="$MAKE" 20666 tool_basename="${tool_specified##*/}" 20667 if test "x$tool_basename" = "x$tool_specified"; then 20668 # A command without a complete path is provided, search $PATH. 20669 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20670 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20671 # Extract the first word of "$tool_basename", so it can be a program name with args. 20672 set dummy $tool_basename; ac_word=$2 20673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20674 $as_echo_n "checking for $ac_word... " >&6; } 20675 if ${ac_cv_path_MAKE+:} false; then : 20676 $as_echo_n "(cached) " >&6 20677 else 20678 case $MAKE in 20679 [\\/]* | ?:[\\/]*) 20680 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 20681 ;; 20682 *) 20683 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20684 for as_dir in $PATH 20685 do 20686 IFS=$as_save_IFS 20687 test -z "$as_dir" && as_dir=. 20688 for ac_exec_ext in '' $ac_executable_extensions; do 20689 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20690 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 20691 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20692 break 2 20693 fi 20694 done 20695 done 20696 IFS=$as_save_IFS 20697 20698 ;; 20699 esac 20700 fi 20701 MAKE=$ac_cv_path_MAKE 20702 if test -n "$MAKE"; then 20703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 20704 $as_echo "$MAKE" >&6; } 20705 else 20706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20707 $as_echo "no" >&6; } 20708 fi 20709 20710 20711 if test "x$MAKE" = x; then 20712 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20713 fi 20714 else 20715 # Otherwise we believe it is a complete path. Use it as it is. 20716 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 20717 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 20718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20719 $as_echo_n "checking for MAKE... " >&6; } 20720 if test ! -x "$tool_specified"; then 20721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20722 $as_echo "not found" >&6; } 20723 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 20724 fi 20725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20726 $as_echo "$tool_specified" >&6; } 20727 fi 20728 fi 20729 fi 20730 20731 # If MAKE was set by user, verify the version 20732 20733 MAKE_CANDIDATE=""$MAKE"" 20734 DESCRIPTION="user supplied MAKE=$MAKE" 20735 20736 # On Cygwin, we require a newer version of make than on other platforms 20737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20738 MAKE_VERSION_EXPR="-e 4\." 20739 MAKE_REQUIRED_VERSION="4.0" 20740 else 20741 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20742 MAKE_REQUIRED_VERSION="3.81" 20743 fi 20744 20745 if test "x$MAKE_CANDIDATE" != x; then 20746 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20747 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20748 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20749 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20750 if test "x$IS_GNU_MAKE" = x; then 20751 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20752 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20753 else 20754 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20755 if test "x$IS_MODERN_MAKE" = x; then 20756 { $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 20757 $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;} 20758 else 20759 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20760 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20761 MAKE_EXPECTED_ENV='cygwin' 20762 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20763 MAKE_EXPECTED_ENV='msys' 20764 else 20765 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20766 fi 20767 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20768 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20769 else 20770 # Not relevant for non-Windows 20771 IS_MAKE_CORRECT_ENV=true 20772 fi 20773 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20774 { $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 20775 $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;} 20776 else 20777 FOUND_MAKE=$MAKE_CANDIDATE 20778 20779 # Only process if variable expands to non-empty 20780 20781 if test "x$FOUND_MAKE" != x; then 20782 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20783 20784 # First separate the path from the arguments. This will split at the first 20785 # space. 20786 complete="$FOUND_MAKE" 20787 path="${complete%% *}" 20788 tmp="$complete EOL" 20789 arguments="${tmp#* }" 20790 20791 # Input might be given as Windows format, start by converting to 20792 # unix format. 20793 new_path=`$CYGPATH -u "$path"` 20794 20795 # Now try to locate executable using which 20796 new_path=`$WHICH "$new_path" 2> /dev/null` 20797 # bat and cmd files are not always considered executable in cygwin causing which 20798 # to not find them 20799 if test "x$new_path" = x \ 20800 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20801 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20802 new_path=`$CYGPATH -u "$path"` 20803 fi 20804 if test "x$new_path" = x; then 20805 # Oops. Which didn't find the executable. 20806 # The splitting of arguments from the executable at a space might have been incorrect, 20807 # since paths with space are more likely in Windows. Give it another try with the whole 20808 # argument. 20809 path="$complete" 20810 arguments="EOL" 20811 new_path=`$CYGPATH -u "$path"` 20812 new_path=`$WHICH "$new_path" 2> /dev/null` 20813 # bat and cmd files are not always considered executable in cygwin causing which 20814 # to not find them 20815 if test "x$new_path" = x \ 20816 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20817 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20818 new_path=`$CYGPATH -u "$path"` 20819 fi 20820 if test "x$new_path" = x; then 20821 # It's still not found. Now this is an unrecoverable error. 20822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20823 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20824 has_space=`$ECHO "$complete" | $GREP " "` 20825 if test "x$has_space" != x; then 20826 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20827 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20828 fi 20829 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20830 fi 20831 fi 20832 20833 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20834 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20835 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20836 # "foo.exe" is OK but "foo" is an error. 20837 # 20838 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20839 # It is also a way to make sure we got the proper file name for the real test later on. 20840 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20841 if test "x$test_shortpath" = x; then 20842 # Short path failed, file does not exist as specified. 20843 # Try adding .exe or .cmd 20844 if test -f "${new_path}.exe"; then 20845 input_to_shortpath="${new_path}.exe" 20846 elif test -f "${new_path}.cmd"; then 20847 input_to_shortpath="${new_path}.cmd" 20848 else 20849 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20850 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20851 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20852 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20853 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20854 fi 20855 else 20856 input_to_shortpath="$new_path" 20857 fi 20858 20859 # Call helper function which possibly converts this using DOS-style short mode. 20860 # If so, the updated path is stored in $new_path. 20861 new_path="$input_to_shortpath" 20862 20863 input_path="$input_to_shortpath" 20864 # Check if we need to convert this using DOS-style short mode. If the path 20865 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20866 # take no chances and rewrite it. 20867 # Note: m4 eats our [], so we need to use [ and ] instead. 20868 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20869 if test "x$has_forbidden_chars" != x; then 20870 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20871 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20872 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20873 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20874 # Going to short mode and back again did indeed matter. Since short mode is 20875 # case insensitive, let's make it lowercase to improve readability. 20876 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20877 # Now convert it back to Unix-style (cygpath) 20878 input_path=`$CYGPATH -u "$shortmode_path"` 20879 new_path="$input_path" 20880 fi 20881 fi 20882 20883 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20884 if test "x$test_cygdrive_prefix" = x; then 20885 # As a simple fix, exclude /usr/bin since it's not a real path. 20886 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20887 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20888 # a path prefixed by /cygdrive for fixpath to work. 20889 new_path="$CYGWIN_ROOT_PATH$input_path" 20890 fi 20891 fi 20892 20893 # remove trailing .exe if any 20894 new_path="${new_path/%.exe/}" 20895 20896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20897 20898 # First separate the path from the arguments. This will split at the first 20899 # space. 20900 complete="$FOUND_MAKE" 20901 path="${complete%% *}" 20902 tmp="$complete EOL" 20903 arguments="${tmp#* }" 20904 20905 # Input might be given as Windows format, start by converting to 20906 # unix format. 20907 new_path="$path" 20908 20909 windows_path="$new_path" 20910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20911 unix_path=`$CYGPATH -u "$windows_path"` 20912 new_path="$unix_path" 20913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20914 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20915 new_path="$unix_path" 20916 fi 20917 20918 20919 # Now try to locate executable using which 20920 new_path=`$WHICH "$new_path" 2> /dev/null` 20921 20922 if test "x$new_path" = x; then 20923 # Oops. Which didn't find the executable. 20924 # The splitting of arguments from the executable at a space might have been incorrect, 20925 # since paths with space are more likely in Windows. Give it another try with the whole 20926 # argument. 20927 path="$complete" 20928 arguments="EOL" 20929 new_path="$path" 20930 20931 windows_path="$new_path" 20932 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20933 unix_path=`$CYGPATH -u "$windows_path"` 20934 new_path="$unix_path" 20935 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20936 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20937 new_path="$unix_path" 20938 fi 20939 20940 20941 new_path=`$WHICH "$new_path" 2> /dev/null` 20942 # bat and cmd files are not always considered executable in MSYS causing which 20943 # to not find them 20944 if test "x$new_path" = x \ 20945 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20946 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20947 new_path="$path" 20948 20949 windows_path="$new_path" 20950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20951 unix_path=`$CYGPATH -u "$windows_path"` 20952 new_path="$unix_path" 20953 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20954 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20955 new_path="$unix_path" 20956 fi 20957 20958 fi 20959 20960 if test "x$new_path" = x; then 20961 # It's still not found. Now this is an unrecoverable error. 20962 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20963 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20964 has_space=`$ECHO "$complete" | $GREP " "` 20965 if test "x$has_space" != x; then 20966 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20967 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20968 fi 20969 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20970 fi 20971 fi 20972 20973 # Now new_path has a complete unix path to the binary 20974 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20975 # Keep paths in /bin as-is, but remove trailing .exe if any 20976 new_path="${new_path/%.exe/}" 20977 # Do not save /bin paths to all_fixpath_prefixes! 20978 else 20979 # Not in mixed or Windows style, start by that. 20980 new_path=`cmd //c echo $new_path` 20981 20982 input_path="$new_path" 20983 # Check if we need to convert this using DOS-style short mode. If the path 20984 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20985 # take no chances and rewrite it. 20986 # Note: m4 eats our [], so we need to use [ and ] instead. 20987 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20988 if test "x$has_forbidden_chars" != x; then 20989 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20990 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20991 fi 20992 20993 # Output is in $new_path 20994 20995 windows_path="$new_path" 20996 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20997 unix_path=`$CYGPATH -u "$windows_path"` 20998 new_path="$unix_path" 20999 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21000 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21001 new_path="$unix_path" 21002 fi 21003 21004 # remove trailing .exe if any 21005 new_path="${new_path/%.exe/}" 21006 21007 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21008 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21009 fi 21010 21011 else 21012 # We're on a unix platform. Hooray! :) 21013 # First separate the path from the arguments. This will split at the first 21014 # space. 21015 complete="$FOUND_MAKE" 21016 path="${complete%% *}" 21017 tmp="$complete EOL" 21018 arguments="${tmp#* }" 21019 21020 # Cannot rely on the command "which" here since it doesn't always work. 21021 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21022 if test -z "$is_absolute_path"; then 21023 # Path to executable is not absolute. Find it. 21024 IFS_save="$IFS" 21025 IFS=: 21026 for p in $PATH; do 21027 if test -f "$p/$path" && test -x "$p/$path"; then 21028 new_path="$p/$path" 21029 break 21030 fi 21031 done 21032 IFS="$IFS_save" 21033 else 21034 # This is an absolute path, we can use it without further modifications. 21035 new_path="$path" 21036 fi 21037 21038 if test "x$new_path" = x; then 21039 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21040 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21041 has_space=`$ECHO "$complete" | $GREP " "` 21042 if test "x$has_space" != x; then 21043 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21044 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21045 fi 21046 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21047 fi 21048 fi 21049 21050 # Now join together the path and the arguments once again 21051 if test "x$arguments" != xEOL; then 21052 new_complete="$new_path ${arguments% *}" 21053 else 21054 new_complete="$new_path" 21055 fi 21056 21057 if test "x$complete" != "x$new_complete"; then 21058 FOUND_MAKE="$new_complete" 21059 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21060 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21061 fi 21062 fi 21063 21064 fi 21065 fi 21066 fi 21067 fi 21068 21069 if test "x$FOUND_MAKE" = x; then 21070 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21071 fi 21072 21073 fi 21074 21075 21076 MAKE=$FOUND_MAKE 21077 21078 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21079 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21080 21081 21082 # Check if make supports the output sync option and if so, setup using it. 21083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21084 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21085 if $MAKE --version -O > /dev/null 2>&1; then 21086 OUTPUT_SYNC_SUPPORTED=true 21087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21088 $as_echo "yes" >&6; } 21089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21090 $as_echo_n "checking for output-sync value... " >&6; } 21091 21092 # Check whether --with-output-sync was given. 21093 if test "${with_output_sync+set}" = set; then : 21094 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21095 fi 21096 21097 if test "x$OUTPUT_SYNC" = "x"; then 21098 OUTPUT_SYNC=none 21099 fi 21100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21101 $as_echo "$OUTPUT_SYNC" >&6; } 21102 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21103 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21104 fi 21105 else 21106 OUTPUT_SYNC_SUPPORTED=false 21107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21108 $as_echo "no" >&6; } 21109 fi 21110 21111 21112 21113 21114 21115 21116 # Test if find supports -delete 21117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21118 $as_echo_n "checking if find supports -delete... " >&6; } 21119 FIND_DELETE="-delete" 21120 21121 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21122 21123 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21124 21125 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21126 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21127 # No, it does not. 21128 $RM $DELETEDIR/TestIfFindSupportsDelete 21129 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21130 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21131 FIND_DELETE="-print | $XARGS $RM" 21132 else 21133 FIND_DELETE="-exec $RM \{\} \+" 21134 fi 21135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21136 $as_echo "no" >&6; } 21137 else 21138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21139 $as_echo "yes" >&6; } 21140 fi 21141 $RMDIR $DELETEDIR 21142 21143 21144 21145 # Test which kind of tar was found 21146 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21147 TAR_TYPE="gnu" 21148 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21149 TAR_TYPE="bsd" 21150 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21151 TAR_TYPE="solaris" 21152 fi 21153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21154 $as_echo_n "checking what type of tar was found... " >&6; } 21155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21156 $as_echo "$TAR_TYPE" >&6; } 21157 21158 TAR_CREATE_FILE_PARAM="" 21159 21160 if test "x$TAR_TYPE" = "xgnu"; then 21161 TAR_INCLUDE_PARAM="T" 21162 TAR_SUPPORTS_TRANSFORM="true" 21163 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21164 # When using gnu tar for Solaris targets, need to use compatibility mode 21165 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21166 fi 21167 else 21168 TAR_INCLUDE_PARAM="I" 21169 TAR_SUPPORTS_TRANSFORM="false" 21170 fi 21171 21172 21173 21174 21175 21176 21177 # These tools might not be installed by default, 21178 # need hint on how to install them. 21179 21180 21181 21182 # Publish this variable in the help. 21183 21184 21185 if [ -z "${UNZIP+x}" ]; then 21186 # The variable is not set by user, try to locate tool using the code snippet 21187 for ac_prog in unzip 21188 do 21189 # Extract the first word of "$ac_prog", so it can be a program name with args. 21190 set dummy $ac_prog; ac_word=$2 21191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21192 $as_echo_n "checking for $ac_word... " >&6; } 21193 if ${ac_cv_path_UNZIP+:} false; then : 21194 $as_echo_n "(cached) " >&6 21195 else 21196 case $UNZIP in 21197 [\\/]* | ?:[\\/]*) 21198 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21199 ;; 21200 *) 21201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21202 for as_dir in $PATH 21203 do 21204 IFS=$as_save_IFS 21205 test -z "$as_dir" && as_dir=. 21206 for ac_exec_ext in '' $ac_executable_extensions; do 21207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21208 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21210 break 2 21211 fi 21212 done 21213 done 21214 IFS=$as_save_IFS 21215 21216 ;; 21217 esac 21218 fi 21219 UNZIP=$ac_cv_path_UNZIP 21220 if test -n "$UNZIP"; then 21221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21222 $as_echo "$UNZIP" >&6; } 21223 else 21224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21225 $as_echo "no" >&6; } 21226 fi 21227 21228 21229 test -n "$UNZIP" && break 21230 done 21231 21232 else 21233 # The variable is set, but is it from the command line or the environment? 21234 21235 # Try to remove the string !UNZIP! from our list. 21236 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21237 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21238 # If it failed, the variable was not from the command line. Ignore it, 21239 # but warn the user (except for BASH, which is always set by the calling BASH). 21240 if test "xUNZIP" != xBASH; then 21241 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21242 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21243 fi 21244 # Try to locate tool using the code snippet 21245 for ac_prog in unzip 21246 do 21247 # Extract the first word of "$ac_prog", so it can be a program name with args. 21248 set dummy $ac_prog; ac_word=$2 21249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21250 $as_echo_n "checking for $ac_word... " >&6; } 21251 if ${ac_cv_path_UNZIP+:} false; then : 21252 $as_echo_n "(cached) " >&6 21253 else 21254 case $UNZIP in 21255 [\\/]* | ?:[\\/]*) 21256 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21257 ;; 21258 *) 21259 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21260 for as_dir in $PATH 21261 do 21262 IFS=$as_save_IFS 21263 test -z "$as_dir" && as_dir=. 21264 for ac_exec_ext in '' $ac_executable_extensions; do 21265 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21266 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21267 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21268 break 2 21269 fi 21270 done 21271 done 21272 IFS=$as_save_IFS 21273 21274 ;; 21275 esac 21276 fi 21277 UNZIP=$ac_cv_path_UNZIP 21278 if test -n "$UNZIP"; then 21279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21280 $as_echo "$UNZIP" >&6; } 21281 else 21282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21283 $as_echo "no" >&6; } 21284 fi 21285 21286 21287 test -n "$UNZIP" && break 21288 done 21289 21290 else 21291 # If it succeeded, then it was overridden by the user. We will use it 21292 # for the tool. 21293 21294 # First remove it from the list of overridden variables, so we can test 21295 # for unknown variables in the end. 21296 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21297 21298 # Check if we try to supply an empty value 21299 if test "x$UNZIP" = x; then 21300 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21301 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21303 $as_echo_n "checking for UNZIP... " >&6; } 21304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21305 $as_echo "disabled" >&6; } 21306 else 21307 # Check if the provided tool contains a complete path. 21308 tool_specified="$UNZIP" 21309 tool_basename="${tool_specified##*/}" 21310 if test "x$tool_basename" = "x$tool_specified"; then 21311 # A command without a complete path is provided, search $PATH. 21312 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21313 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21314 # Extract the first word of "$tool_basename", so it can be a program name with args. 21315 set dummy $tool_basename; ac_word=$2 21316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21317 $as_echo_n "checking for $ac_word... " >&6; } 21318 if ${ac_cv_path_UNZIP+:} false; then : 21319 $as_echo_n "(cached) " >&6 21320 else 21321 case $UNZIP in 21322 [\\/]* | ?:[\\/]*) 21323 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21324 ;; 21325 *) 21326 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21327 for as_dir in $PATH 21328 do 21329 IFS=$as_save_IFS 21330 test -z "$as_dir" && as_dir=. 21331 for ac_exec_ext in '' $ac_executable_extensions; do 21332 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21333 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21334 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21335 break 2 21336 fi 21337 done 21338 done 21339 IFS=$as_save_IFS 21340 21341 ;; 21342 esac 21343 fi 21344 UNZIP=$ac_cv_path_UNZIP 21345 if test -n "$UNZIP"; then 21346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21347 $as_echo "$UNZIP" >&6; } 21348 else 21349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21350 $as_echo "no" >&6; } 21351 fi 21352 21353 21354 if test "x$UNZIP" = x; then 21355 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21356 fi 21357 else 21358 # Otherwise we believe it is a complete path. Use it as it is. 21359 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21360 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21362 $as_echo_n "checking for UNZIP... " >&6; } 21363 if test ! -x "$tool_specified"; then 21364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21365 $as_echo "not found" >&6; } 21366 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21367 fi 21368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21369 $as_echo "$tool_specified" >&6; } 21370 fi 21371 fi 21372 fi 21373 21374 fi 21375 21376 21377 21378 if test "x$UNZIP" = x; then 21379 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21380 fi 21381 21382 21383 21384 21385 21386 # Publish this variable in the help. 21387 21388 21389 if [ -z "${ZIP+x}" ]; then 21390 # The variable is not set by user, try to locate tool using the code snippet 21391 for ac_prog in zip 21392 do 21393 # Extract the first word of "$ac_prog", so it can be a program name with args. 21394 set dummy $ac_prog; ac_word=$2 21395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21396 $as_echo_n "checking for $ac_word... " >&6; } 21397 if ${ac_cv_path_ZIP+:} false; then : 21398 $as_echo_n "(cached) " >&6 21399 else 21400 case $ZIP in 21401 [\\/]* | ?:[\\/]*) 21402 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21403 ;; 21404 *) 21405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21406 for as_dir in $PATH 21407 do 21408 IFS=$as_save_IFS 21409 test -z "$as_dir" && as_dir=. 21410 for ac_exec_ext in '' $ac_executable_extensions; do 21411 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21412 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21413 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21414 break 2 21415 fi 21416 done 21417 done 21418 IFS=$as_save_IFS 21419 21420 ;; 21421 esac 21422 fi 21423 ZIP=$ac_cv_path_ZIP 21424 if test -n "$ZIP"; then 21425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21426 $as_echo "$ZIP" >&6; } 21427 else 21428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21429 $as_echo "no" >&6; } 21430 fi 21431 21432 21433 test -n "$ZIP" && break 21434 done 21435 21436 else 21437 # The variable is set, but is it from the command line or the environment? 21438 21439 # Try to remove the string !ZIP! from our list. 21440 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/} 21441 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21442 # If it failed, the variable was not from the command line. Ignore it, 21443 # but warn the user (except for BASH, which is always set by the calling BASH). 21444 if test "xZIP" != xBASH; then 21445 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5 21446 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;} 21447 fi 21448 # Try to locate tool using the code snippet 21449 for ac_prog in zip 21450 do 21451 # Extract the first word of "$ac_prog", so it can be a program name with args. 21452 set dummy $ac_prog; ac_word=$2 21453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21454 $as_echo_n "checking for $ac_word... " >&6; } 21455 if ${ac_cv_path_ZIP+:} false; then : 21456 $as_echo_n "(cached) " >&6 21457 else 21458 case $ZIP in 21459 [\\/]* | ?:[\\/]*) 21460 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21461 ;; 21462 *) 21463 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21464 for as_dir in $PATH 21465 do 21466 IFS=$as_save_IFS 21467 test -z "$as_dir" && as_dir=. 21468 for ac_exec_ext in '' $ac_executable_extensions; do 21469 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21470 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21471 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21472 break 2 21473 fi 21474 done 21475 done 21476 IFS=$as_save_IFS 21477 21478 ;; 21479 esac 21480 fi 21481 ZIP=$ac_cv_path_ZIP 21482 if test -n "$ZIP"; then 21483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21484 $as_echo "$ZIP" >&6; } 21485 else 21486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21487 $as_echo "no" >&6; } 21488 fi 21489 21490 21491 test -n "$ZIP" && break 21492 done 21493 21494 else 21495 # If it succeeded, then it was overridden by the user. We will use it 21496 # for the tool. 21497 21498 # First remove it from the list of overridden variables, so we can test 21499 # for unknown variables in the end. 21500 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21501 21502 # Check if we try to supply an empty value 21503 if test "x$ZIP" = x; then 21504 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIP= (no value)" >&5 21505 $as_echo "$as_me: Setting user supplied tool ZIP= (no value)" >&6;} 21506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 21507 $as_echo_n "checking for ZIP... " >&6; } 21508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21509 $as_echo "disabled" >&6; } 21510 else 21511 # Check if the provided tool contains a complete path. 21512 tool_specified="$ZIP" 21513 tool_basename="${tool_specified##*/}" 21514 if test "x$tool_basename" = "x$tool_specified"; then 21515 # A command without a complete path is provided, search $PATH. 21516 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5 21517 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;} 21518 # Extract the first word of "$tool_basename", so it can be a program name with args. 21519 set dummy $tool_basename; ac_word=$2 21520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21521 $as_echo_n "checking for $ac_word... " >&6; } 21522 if ${ac_cv_path_ZIP+:} false; then : 21523 $as_echo_n "(cached) " >&6 21524 else 21525 case $ZIP in 21526 [\\/]* | ?:[\\/]*) 21527 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21528 ;; 21529 *) 21530 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21531 for as_dir in $PATH 21532 do 21533 IFS=$as_save_IFS 21534 test -z "$as_dir" && as_dir=. 21535 for ac_exec_ext in '' $ac_executable_extensions; do 21536 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21537 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21538 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21539 break 2 21540 fi 21541 done 21542 done 21543 IFS=$as_save_IFS 21544 21545 ;; 21546 esac 21547 fi 21548 ZIP=$ac_cv_path_ZIP 21549 if test -n "$ZIP"; then 21550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21551 $as_echo "$ZIP" >&6; } 21552 else 21553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21554 $as_echo "no" >&6; } 21555 fi 21556 21557 21558 if test "x$ZIP" = x; then 21559 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21560 fi 21561 else 21562 # Otherwise we believe it is a complete path. Use it as it is. 21563 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5 21564 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;} 21565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 21566 $as_echo_n "checking for ZIP... " >&6; } 21567 if test ! -x "$tool_specified"; then 21568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21569 $as_echo "not found" >&6; } 21570 as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21571 fi 21572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21573 $as_echo "$tool_specified" >&6; } 21574 fi 21575 fi 21576 fi 21577 21578 fi 21579 21580 21581 21582 if test "x$ZIP" = x; then 21583 as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5 21584 fi 21585 21586 21587 21588 # Non-required basic tools 21589 21590 21591 21592 # Publish this variable in the help. 21593 21594 21595 if [ -z "${LDD+x}" ]; then 21596 # The variable is not set by user, try to locate tool using the code snippet 21597 for ac_prog in ldd 21598 do 21599 # Extract the first word of "$ac_prog", so it can be a program name with args. 21600 set dummy $ac_prog; ac_word=$2 21601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21602 $as_echo_n "checking for $ac_word... " >&6; } 21603 if ${ac_cv_path_LDD+:} false; then : 21604 $as_echo_n "(cached) " >&6 21605 else 21606 case $LDD in 21607 [\\/]* | ?:[\\/]*) 21608 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21609 ;; 21610 *) 21611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21612 for as_dir in $PATH 21613 do 21614 IFS=$as_save_IFS 21615 test -z "$as_dir" && as_dir=. 21616 for ac_exec_ext in '' $ac_executable_extensions; do 21617 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21618 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21619 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21620 break 2 21621 fi 21622 done 21623 done 21624 IFS=$as_save_IFS 21625 21626 ;; 21627 esac 21628 fi 21629 LDD=$ac_cv_path_LDD 21630 if test -n "$LDD"; then 21631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21632 $as_echo "$LDD" >&6; } 21633 else 21634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21635 $as_echo "no" >&6; } 21636 fi 21637 21638 21639 test -n "$LDD" && break 21640 done 21641 21642 else 21643 # The variable is set, but is it from the command line or the environment? 21644 21645 # Try to remove the string !LDD! from our list. 21646 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 21647 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21648 # If it failed, the variable was not from the command line. Ignore it, 21649 # but warn the user (except for BASH, which is always set by the calling BASH). 21650 if test "xLDD" != xBASH; then 21651 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 21652 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 21653 fi 21654 # Try to locate tool using the code snippet 21655 for ac_prog in ldd 21656 do 21657 # Extract the first word of "$ac_prog", so it can be a program name with args. 21658 set dummy $ac_prog; 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_LDD+:} false; then : 21662 $as_echo_n "(cached) " >&6 21663 else 21664 case $LDD in 21665 [\\/]* | ?:[\\/]*) 21666 ac_cv_path_LDD="$LDD" # 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_LDD="$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 LDD=$ac_cv_path_LDD 21688 if test -n "$LDD"; then 21689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21690 $as_echo "$LDD" >&6; } 21691 else 21692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21693 $as_echo "no" >&6; } 21694 fi 21695 21696 21697 test -n "$LDD" && break 21698 done 21699 21700 else 21701 # If it succeeded, then it was overridden by the user. We will use it 21702 # for the tool. 21703 21704 # First remove it from the list of overridden variables, so we can test 21705 # for unknown variables in the end. 21706 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21707 21708 # Check if we try to supply an empty value 21709 if test "x$LDD" = x; then 21710 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 21711 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 21712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21713 $as_echo_n "checking for LDD... " >&6; } 21714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21715 $as_echo "disabled" >&6; } 21716 else 21717 # Check if the provided tool contains a complete path. 21718 tool_specified="$LDD" 21719 tool_basename="${tool_specified##*/}" 21720 if test "x$tool_basename" = "x$tool_specified"; then 21721 # A command without a complete path is provided, search $PATH. 21722 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 21723 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 21724 # Extract the first word of "$tool_basename", so it can be a program name with args. 21725 set dummy $tool_basename; ac_word=$2 21726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21727 $as_echo_n "checking for $ac_word... " >&6; } 21728 if ${ac_cv_path_LDD+:} false; then : 21729 $as_echo_n "(cached) " >&6 21730 else 21731 case $LDD in 21732 [\\/]* | ?:[\\/]*) 21733 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21734 ;; 21735 *) 21736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21737 for as_dir in $PATH 21738 do 21739 IFS=$as_save_IFS 21740 test -z "$as_dir" && as_dir=. 21741 for ac_exec_ext in '' $ac_executable_extensions; do 21742 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21743 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21745 break 2 21746 fi 21747 done 21748 done 21749 IFS=$as_save_IFS 21750 21751 ;; 21752 esac 21753 fi 21754 LDD=$ac_cv_path_LDD 21755 if test -n "$LDD"; then 21756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21757 $as_echo "$LDD" >&6; } 21758 else 21759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21760 $as_echo "no" >&6; } 21761 fi 21762 21763 21764 if test "x$LDD" = x; then 21765 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21766 fi 21767 else 21768 # Otherwise we believe it is a complete path. Use it as it is. 21769 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 21770 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 21771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21772 $as_echo_n "checking for LDD... " >&6; } 21773 if test ! -x "$tool_specified"; then 21774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21775 $as_echo "not found" >&6; } 21776 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 21777 fi 21778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21779 $as_echo "$tool_specified" >&6; } 21780 fi 21781 fi 21782 fi 21783 21784 fi 21785 21786 21787 if test "x$LDD" = "x"; then 21788 # List shared lib dependencies is used for 21789 # debug output and checking for forbidden dependencies. 21790 # We can build without it. 21791 LDD="true" 21792 fi 21793 21794 21795 # Publish this variable in the help. 21796 21797 21798 if [ -z "${OTOOL+x}" ]; then 21799 # The variable is not set by user, try to locate tool using the code snippet 21800 for ac_prog in otool 21801 do 21802 # Extract the first word of "$ac_prog", so it can be a program name with args. 21803 set dummy $ac_prog; ac_word=$2 21804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21805 $as_echo_n "checking for $ac_word... " >&6; } 21806 if ${ac_cv_path_OTOOL+:} false; then : 21807 $as_echo_n "(cached) " >&6 21808 else 21809 case $OTOOL in 21810 [\\/]* | ?:[\\/]*) 21811 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21812 ;; 21813 *) 21814 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21815 for as_dir in $PATH 21816 do 21817 IFS=$as_save_IFS 21818 test -z "$as_dir" && as_dir=. 21819 for ac_exec_ext in '' $ac_executable_extensions; do 21820 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21821 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21822 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21823 break 2 21824 fi 21825 done 21826 done 21827 IFS=$as_save_IFS 21828 21829 ;; 21830 esac 21831 fi 21832 OTOOL=$ac_cv_path_OTOOL 21833 if test -n "$OTOOL"; then 21834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21835 $as_echo "$OTOOL" >&6; } 21836 else 21837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21838 $as_echo "no" >&6; } 21839 fi 21840 21841 21842 test -n "$OTOOL" && break 21843 done 21844 21845 else 21846 # The variable is set, but is it from the command line or the environment? 21847 21848 # Try to remove the string !OTOOL! from our list. 21849 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 21850 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21851 # If it failed, the variable was not from the command line. Ignore it, 21852 # but warn the user (except for BASH, which is always set by the calling BASH). 21853 if test "xOTOOL" != xBASH; then 21854 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 21855 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 21856 fi 21857 # Try to locate tool using the code snippet 21858 for ac_prog in otool 21859 do 21860 # Extract the first word of "$ac_prog", so it can be a program name with args. 21861 set dummy $ac_prog; ac_word=$2 21862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21863 $as_echo_n "checking for $ac_word... " >&6; } 21864 if ${ac_cv_path_OTOOL+:} false; then : 21865 $as_echo_n "(cached) " >&6 21866 else 21867 case $OTOOL in 21868 [\\/]* | ?:[\\/]*) 21869 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21870 ;; 21871 *) 21872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21873 for as_dir in $PATH 21874 do 21875 IFS=$as_save_IFS 21876 test -z "$as_dir" && as_dir=. 21877 for ac_exec_ext in '' $ac_executable_extensions; do 21878 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21879 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21880 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21881 break 2 21882 fi 21883 done 21884 done 21885 IFS=$as_save_IFS 21886 21887 ;; 21888 esac 21889 fi 21890 OTOOL=$ac_cv_path_OTOOL 21891 if test -n "$OTOOL"; then 21892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21893 $as_echo "$OTOOL" >&6; } 21894 else 21895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21896 $as_echo "no" >&6; } 21897 fi 21898 21899 21900 test -n "$OTOOL" && break 21901 done 21902 21903 else 21904 # If it succeeded, then it was overridden by the user. We will use it 21905 # for the tool. 21906 21907 # First remove it from the list of overridden variables, so we can test 21908 # for unknown variables in the end. 21909 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21910 21911 # Check if we try to supply an empty value 21912 if test "x$OTOOL" = x; then 21913 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 21914 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 21915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21916 $as_echo_n "checking for OTOOL... " >&6; } 21917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21918 $as_echo "disabled" >&6; } 21919 else 21920 # Check if the provided tool contains a complete path. 21921 tool_specified="$OTOOL" 21922 tool_basename="${tool_specified##*/}" 21923 if test "x$tool_basename" = "x$tool_specified"; then 21924 # A command without a complete path is provided, search $PATH. 21925 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 21926 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 21927 # Extract the first word of "$tool_basename", so it can be a program name with args. 21928 set dummy $tool_basename; ac_word=$2 21929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21930 $as_echo_n "checking for $ac_word... " >&6; } 21931 if ${ac_cv_path_OTOOL+:} false; then : 21932 $as_echo_n "(cached) " >&6 21933 else 21934 case $OTOOL in 21935 [\\/]* | ?:[\\/]*) 21936 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21937 ;; 21938 *) 21939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21940 for as_dir in $PATH 21941 do 21942 IFS=$as_save_IFS 21943 test -z "$as_dir" && as_dir=. 21944 for ac_exec_ext in '' $ac_executable_extensions; do 21945 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21946 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21947 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21948 break 2 21949 fi 21950 done 21951 done 21952 IFS=$as_save_IFS 21953 21954 ;; 21955 esac 21956 fi 21957 OTOOL=$ac_cv_path_OTOOL 21958 if test -n "$OTOOL"; then 21959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21960 $as_echo "$OTOOL" >&6; } 21961 else 21962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21963 $as_echo "no" >&6; } 21964 fi 21965 21966 21967 if test "x$OTOOL" = x; then 21968 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21969 fi 21970 else 21971 # Otherwise we believe it is a complete path. Use it as it is. 21972 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 21973 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 21974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21975 $as_echo_n "checking for OTOOL... " >&6; } 21976 if test ! -x "$tool_specified"; then 21977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21978 $as_echo "not found" >&6; } 21979 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 21980 fi 21981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21982 $as_echo "$tool_specified" >&6; } 21983 fi 21984 fi 21985 fi 21986 21987 fi 21988 21989 21990 if test "x$OTOOL" = "x"; then 21991 OTOOL="true" 21992 fi 21993 21994 21995 # Publish this variable in the help. 21996 21997 21998 if [ -z "${READELF+x}" ]; then 21999 # The variable is not set by user, try to locate tool using the code snippet 22000 for ac_prog in greadelf readelf 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_READELF+:} false; then : 22007 $as_echo_n "(cached) " >&6 22008 else 22009 case $READELF in 22010 [\\/]* | ?:[\\/]*) 22011 ac_cv_path_READELF="$READELF" # 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_READELF="$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 READELF=$ac_cv_path_READELF 22033 if test -n "$READELF"; then 22034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22035 $as_echo "$READELF" >&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 "$READELF" && break 22043 done 22044 22045 else 22046 # The variable is set, but is it from the command line or the environment? 22047 22048 # Try to remove the string !READELF! from our list. 22049 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22050 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22051 # If it failed, the variable was not from the command line. Ignore it, 22052 # but warn the user (except for BASH, which is always set by the calling BASH). 22053 if test "xREADELF" != xBASH; then 22054 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22055 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22056 fi 22057 # Try to locate tool using the code snippet 22058 for ac_prog in greadelf readelf 22059 do 22060 # Extract the first word of "$ac_prog", so it can be a program name with args. 22061 set dummy $ac_prog; ac_word=$2 22062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22063 $as_echo_n "checking for $ac_word... " >&6; } 22064 if ${ac_cv_path_READELF+:} false; then : 22065 $as_echo_n "(cached) " >&6 22066 else 22067 case $READELF in 22068 [\\/]* | ?:[\\/]*) 22069 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22070 ;; 22071 *) 22072 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22073 for as_dir in $PATH 22074 do 22075 IFS=$as_save_IFS 22076 test -z "$as_dir" && as_dir=. 22077 for ac_exec_ext in '' $ac_executable_extensions; do 22078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22079 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22081 break 2 22082 fi 22083 done 22084 done 22085 IFS=$as_save_IFS 22086 22087 ;; 22088 esac 22089 fi 22090 READELF=$ac_cv_path_READELF 22091 if test -n "$READELF"; then 22092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22093 $as_echo "$READELF" >&6; } 22094 else 22095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22096 $as_echo "no" >&6; } 22097 fi 22098 22099 22100 test -n "$READELF" && break 22101 done 22102 22103 else 22104 # If it succeeded, then it was overridden by the user. We will use it 22105 # for the tool. 22106 22107 # First remove it from the list of overridden variables, so we can test 22108 # for unknown variables in the end. 22109 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22110 22111 # Check if we try to supply an empty value 22112 if test "x$READELF" = x; then 22113 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22114 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22116 $as_echo_n "checking for READELF... " >&6; } 22117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22118 $as_echo "disabled" >&6; } 22119 else 22120 # Check if the provided tool contains a complete path. 22121 tool_specified="$READELF" 22122 tool_basename="${tool_specified##*/}" 22123 if test "x$tool_basename" = "x$tool_specified"; then 22124 # A command without a complete path is provided, search $PATH. 22125 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22126 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22127 # Extract the first word of "$tool_basename", so it can be a program name with args. 22128 set dummy $tool_basename; ac_word=$2 22129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22130 $as_echo_n "checking for $ac_word... " >&6; } 22131 if ${ac_cv_path_READELF+:} false; then : 22132 $as_echo_n "(cached) " >&6 22133 else 22134 case $READELF in 22135 [\\/]* | ?:[\\/]*) 22136 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22137 ;; 22138 *) 22139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22140 for as_dir in $PATH 22141 do 22142 IFS=$as_save_IFS 22143 test -z "$as_dir" && as_dir=. 22144 for ac_exec_ext in '' $ac_executable_extensions; do 22145 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22146 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22147 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22148 break 2 22149 fi 22150 done 22151 done 22152 IFS=$as_save_IFS 22153 22154 ;; 22155 esac 22156 fi 22157 READELF=$ac_cv_path_READELF 22158 if test -n "$READELF"; then 22159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22160 $as_echo "$READELF" >&6; } 22161 else 22162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22163 $as_echo "no" >&6; } 22164 fi 22165 22166 22167 if test "x$READELF" = x; then 22168 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22169 fi 22170 else 22171 # Otherwise we believe it is a complete path. Use it as it is. 22172 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22173 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22175 $as_echo_n "checking for READELF... " >&6; } 22176 if test ! -x "$tool_specified"; then 22177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22178 $as_echo "not found" >&6; } 22179 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22180 fi 22181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22182 $as_echo "$tool_specified" >&6; } 22183 fi 22184 fi 22185 fi 22186 22187 fi 22188 22189 22190 22191 22192 # Publish this variable in the help. 22193 22194 22195 if [ -z "${HG+x}" ]; then 22196 # The variable is not set by user, try to locate tool using the code snippet 22197 for ac_prog in hg 22198 do 22199 # Extract the first word of "$ac_prog", so it can be a program name with args. 22200 set dummy $ac_prog; ac_word=$2 22201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22202 $as_echo_n "checking for $ac_word... " >&6; } 22203 if ${ac_cv_path_HG+:} false; then : 22204 $as_echo_n "(cached) " >&6 22205 else 22206 case $HG in 22207 [\\/]* | ?:[\\/]*) 22208 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22209 ;; 22210 *) 22211 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22212 for as_dir in $PATH 22213 do 22214 IFS=$as_save_IFS 22215 test -z "$as_dir" && as_dir=. 22216 for ac_exec_ext in '' $ac_executable_extensions; do 22217 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22218 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22220 break 2 22221 fi 22222 done 22223 done 22224 IFS=$as_save_IFS 22225 22226 ;; 22227 esac 22228 fi 22229 HG=$ac_cv_path_HG 22230 if test -n "$HG"; then 22231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22232 $as_echo "$HG" >&6; } 22233 else 22234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22235 $as_echo "no" >&6; } 22236 fi 22237 22238 22239 test -n "$HG" && break 22240 done 22241 22242 else 22243 # The variable is set, but is it from the command line or the environment? 22244 22245 # Try to remove the string !HG! from our list. 22246 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22247 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22248 # If it failed, the variable was not from the command line. Ignore it, 22249 # but warn the user (except for BASH, which is always set by the calling BASH). 22250 if test "xHG" != xBASH; then 22251 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22252 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22253 fi 22254 # Try to locate tool using the code snippet 22255 for ac_prog in hg 22256 do 22257 # Extract the first word of "$ac_prog", so it can be a program name with args. 22258 set dummy $ac_prog; ac_word=$2 22259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22260 $as_echo_n "checking for $ac_word... " >&6; } 22261 if ${ac_cv_path_HG+:} false; then : 22262 $as_echo_n "(cached) " >&6 22263 else 22264 case $HG in 22265 [\\/]* | ?:[\\/]*) 22266 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22267 ;; 22268 *) 22269 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22270 for as_dir in $PATH 22271 do 22272 IFS=$as_save_IFS 22273 test -z "$as_dir" && as_dir=. 22274 for ac_exec_ext in '' $ac_executable_extensions; do 22275 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22276 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22277 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22278 break 2 22279 fi 22280 done 22281 done 22282 IFS=$as_save_IFS 22283 22284 ;; 22285 esac 22286 fi 22287 HG=$ac_cv_path_HG 22288 if test -n "$HG"; then 22289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22290 $as_echo "$HG" >&6; } 22291 else 22292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22293 $as_echo "no" >&6; } 22294 fi 22295 22296 22297 test -n "$HG" && break 22298 done 22299 22300 else 22301 # If it succeeded, then it was overridden by the user. We will use it 22302 # for the tool. 22303 22304 # First remove it from the list of overridden variables, so we can test 22305 # for unknown variables in the end. 22306 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22307 22308 # Check if we try to supply an empty value 22309 if test "x$HG" = x; then 22310 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22311 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22313 $as_echo_n "checking for HG... " >&6; } 22314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22315 $as_echo "disabled" >&6; } 22316 else 22317 # Check if the provided tool contains a complete path. 22318 tool_specified="$HG" 22319 tool_basename="${tool_specified##*/}" 22320 if test "x$tool_basename" = "x$tool_specified"; then 22321 # A command without a complete path is provided, search $PATH. 22322 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22323 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22324 # Extract the first word of "$tool_basename", so it can be a program name with args. 22325 set dummy $tool_basename; ac_word=$2 22326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22327 $as_echo_n "checking for $ac_word... " >&6; } 22328 if ${ac_cv_path_HG+:} false; then : 22329 $as_echo_n "(cached) " >&6 22330 else 22331 case $HG in 22332 [\\/]* | ?:[\\/]*) 22333 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22334 ;; 22335 *) 22336 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22337 for as_dir in $PATH 22338 do 22339 IFS=$as_save_IFS 22340 test -z "$as_dir" && as_dir=. 22341 for ac_exec_ext in '' $ac_executable_extensions; do 22342 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22343 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22344 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22345 break 2 22346 fi 22347 done 22348 done 22349 IFS=$as_save_IFS 22350 22351 ;; 22352 esac 22353 fi 22354 HG=$ac_cv_path_HG 22355 if test -n "$HG"; then 22356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22357 $as_echo "$HG" >&6; } 22358 else 22359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22360 $as_echo "no" >&6; } 22361 fi 22362 22363 22364 if test "x$HG" = x; then 22365 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22366 fi 22367 else 22368 # Otherwise we believe it is a complete path. Use it as it is. 22369 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22370 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22372 $as_echo_n "checking for HG... " >&6; } 22373 if test ! -x "$tool_specified"; then 22374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22375 $as_echo "not found" >&6; } 22376 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22377 fi 22378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22379 $as_echo "$tool_specified" >&6; } 22380 fi 22381 fi 22382 fi 22383 22384 fi 22385 22386 22387 22388 22389 # Publish this variable in the help. 22390 22391 22392 if [ -z "${STAT+x}" ]; then 22393 # The variable is not set by user, try to locate tool using the code snippet 22394 for ac_prog in stat 22395 do 22396 # Extract the first word of "$ac_prog", so it can be a program name with args. 22397 set dummy $ac_prog; ac_word=$2 22398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22399 $as_echo_n "checking for $ac_word... " >&6; } 22400 if ${ac_cv_path_STAT+:} false; then : 22401 $as_echo_n "(cached) " >&6 22402 else 22403 case $STAT in 22404 [\\/]* | ?:[\\/]*) 22405 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22406 ;; 22407 *) 22408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22409 for as_dir in $PATH 22410 do 22411 IFS=$as_save_IFS 22412 test -z "$as_dir" && as_dir=. 22413 for ac_exec_ext in '' $ac_executable_extensions; do 22414 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22415 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22416 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22417 break 2 22418 fi 22419 done 22420 done 22421 IFS=$as_save_IFS 22422 22423 ;; 22424 esac 22425 fi 22426 STAT=$ac_cv_path_STAT 22427 if test -n "$STAT"; then 22428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22429 $as_echo "$STAT" >&6; } 22430 else 22431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22432 $as_echo "no" >&6; } 22433 fi 22434 22435 22436 test -n "$STAT" && break 22437 done 22438 22439 else 22440 # The variable is set, but is it from the command line or the environment? 22441 22442 # Try to remove the string !STAT! from our list. 22443 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22444 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22445 # If it failed, the variable was not from the command line. Ignore it, 22446 # but warn the user (except for BASH, which is always set by the calling BASH). 22447 if test "xSTAT" != xBASH; then 22448 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22449 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22450 fi 22451 # Try to locate tool using the code snippet 22452 for ac_prog in stat 22453 do 22454 # Extract the first word of "$ac_prog", so it can be a program name with args. 22455 set dummy $ac_prog; ac_word=$2 22456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22457 $as_echo_n "checking for $ac_word... " >&6; } 22458 if ${ac_cv_path_STAT+:} false; then : 22459 $as_echo_n "(cached) " >&6 22460 else 22461 case $STAT in 22462 [\\/]* | ?:[\\/]*) 22463 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22464 ;; 22465 *) 22466 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22467 for as_dir in $PATH 22468 do 22469 IFS=$as_save_IFS 22470 test -z "$as_dir" && as_dir=. 22471 for ac_exec_ext in '' $ac_executable_extensions; do 22472 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22473 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22474 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22475 break 2 22476 fi 22477 done 22478 done 22479 IFS=$as_save_IFS 22480 22481 ;; 22482 esac 22483 fi 22484 STAT=$ac_cv_path_STAT 22485 if test -n "$STAT"; then 22486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22487 $as_echo "$STAT" >&6; } 22488 else 22489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22490 $as_echo "no" >&6; } 22491 fi 22492 22493 22494 test -n "$STAT" && break 22495 done 22496 22497 else 22498 # If it succeeded, then it was overridden by the user. We will use it 22499 # for the tool. 22500 22501 # First remove it from the list of overridden variables, so we can test 22502 # for unknown variables in the end. 22503 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22504 22505 # Check if we try to supply an empty value 22506 if test "x$STAT" = x; then 22507 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 22508 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 22509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22510 $as_echo_n "checking for STAT... " >&6; } 22511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22512 $as_echo "disabled" >&6; } 22513 else 22514 # Check if the provided tool contains a complete path. 22515 tool_specified="$STAT" 22516 tool_basename="${tool_specified##*/}" 22517 if test "x$tool_basename" = "x$tool_specified"; then 22518 # A command without a complete path is provided, search $PATH. 22519 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 22520 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 22521 # Extract the first word of "$tool_basename", so it can be a program name with args. 22522 set dummy $tool_basename; ac_word=$2 22523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22524 $as_echo_n "checking for $ac_word... " >&6; } 22525 if ${ac_cv_path_STAT+:} false; then : 22526 $as_echo_n "(cached) " >&6 22527 else 22528 case $STAT in 22529 [\\/]* | ?:[\\/]*) 22530 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22531 ;; 22532 *) 22533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22534 for as_dir in $PATH 22535 do 22536 IFS=$as_save_IFS 22537 test -z "$as_dir" && as_dir=. 22538 for ac_exec_ext in '' $ac_executable_extensions; do 22539 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22540 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22541 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22542 break 2 22543 fi 22544 done 22545 done 22546 IFS=$as_save_IFS 22547 22548 ;; 22549 esac 22550 fi 22551 STAT=$ac_cv_path_STAT 22552 if test -n "$STAT"; then 22553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22554 $as_echo "$STAT" >&6; } 22555 else 22556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22557 $as_echo "no" >&6; } 22558 fi 22559 22560 22561 if test "x$STAT" = x; then 22562 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22563 fi 22564 else 22565 # Otherwise we believe it is a complete path. Use it as it is. 22566 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 22567 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 22568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22569 $as_echo_n "checking for STAT... " >&6; } 22570 if test ! -x "$tool_specified"; then 22571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22572 $as_echo "not found" >&6; } 22573 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 22574 fi 22575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22576 $as_echo "$tool_specified" >&6; } 22577 fi 22578 fi 22579 fi 22580 22581 fi 22582 22583 22584 22585 22586 # Publish this variable in the help. 22587 22588 22589 if [ -z "${TIME+x}" ]; then 22590 # The variable is not set by user, try to locate tool using the code snippet 22591 for ac_prog in time 22592 do 22593 # Extract the first word of "$ac_prog", so it can be a program name with args. 22594 set dummy $ac_prog; ac_word=$2 22595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22596 $as_echo_n "checking for $ac_word... " >&6; } 22597 if ${ac_cv_path_TIME+:} false; then : 22598 $as_echo_n "(cached) " >&6 22599 else 22600 case $TIME in 22601 [\\/]* | ?:[\\/]*) 22602 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22603 ;; 22604 *) 22605 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22606 for as_dir in $PATH 22607 do 22608 IFS=$as_save_IFS 22609 test -z "$as_dir" && as_dir=. 22610 for ac_exec_ext in '' $ac_executable_extensions; do 22611 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22612 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22613 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22614 break 2 22615 fi 22616 done 22617 done 22618 IFS=$as_save_IFS 22619 22620 ;; 22621 esac 22622 fi 22623 TIME=$ac_cv_path_TIME 22624 if test -n "$TIME"; then 22625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22626 $as_echo "$TIME" >&6; } 22627 else 22628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22629 $as_echo "no" >&6; } 22630 fi 22631 22632 22633 test -n "$TIME" && break 22634 done 22635 22636 else 22637 # The variable is set, but is it from the command line or the environment? 22638 22639 # Try to remove the string !TIME! from our list. 22640 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 22641 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22642 # If it failed, the variable was not from the command line. Ignore it, 22643 # but warn the user (except for BASH, which is always set by the calling BASH). 22644 if test "xTIME" != xBASH; then 22645 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 22646 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 22647 fi 22648 # Try to locate tool using the code snippet 22649 for ac_prog in time 22650 do 22651 # Extract the first word of "$ac_prog", so it can be a program name with args. 22652 set dummy $ac_prog; ac_word=$2 22653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22654 $as_echo_n "checking for $ac_word... " >&6; } 22655 if ${ac_cv_path_TIME+:} false; then : 22656 $as_echo_n "(cached) " >&6 22657 else 22658 case $TIME in 22659 [\\/]* | ?:[\\/]*) 22660 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22661 ;; 22662 *) 22663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22664 for as_dir in $PATH 22665 do 22666 IFS=$as_save_IFS 22667 test -z "$as_dir" && as_dir=. 22668 for ac_exec_ext in '' $ac_executable_extensions; do 22669 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22670 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22671 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22672 break 2 22673 fi 22674 done 22675 done 22676 IFS=$as_save_IFS 22677 22678 ;; 22679 esac 22680 fi 22681 TIME=$ac_cv_path_TIME 22682 if test -n "$TIME"; then 22683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22684 $as_echo "$TIME" >&6; } 22685 else 22686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22687 $as_echo "no" >&6; } 22688 fi 22689 22690 22691 test -n "$TIME" && break 22692 done 22693 22694 else 22695 # If it succeeded, then it was overridden by the user. We will use it 22696 # for the tool. 22697 22698 # First remove it from the list of overridden variables, so we can test 22699 # for unknown variables in the end. 22700 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22701 22702 # Check if we try to supply an empty value 22703 if test "x$TIME" = x; then 22704 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 22705 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 22706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22707 $as_echo_n "checking for TIME... " >&6; } 22708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22709 $as_echo "disabled" >&6; } 22710 else 22711 # Check if the provided tool contains a complete path. 22712 tool_specified="$TIME" 22713 tool_basename="${tool_specified##*/}" 22714 if test "x$tool_basename" = "x$tool_specified"; then 22715 # A command without a complete path is provided, search $PATH. 22716 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 22717 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 22718 # Extract the first word of "$tool_basename", so it can be a program name with args. 22719 set dummy $tool_basename; ac_word=$2 22720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22721 $as_echo_n "checking for $ac_word... " >&6; } 22722 if ${ac_cv_path_TIME+:} false; then : 22723 $as_echo_n "(cached) " >&6 22724 else 22725 case $TIME in 22726 [\\/]* | ?:[\\/]*) 22727 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22728 ;; 22729 *) 22730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22731 for as_dir in $PATH 22732 do 22733 IFS=$as_save_IFS 22734 test -z "$as_dir" && as_dir=. 22735 for ac_exec_ext in '' $ac_executable_extensions; do 22736 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22737 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22738 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22739 break 2 22740 fi 22741 done 22742 done 22743 IFS=$as_save_IFS 22744 22745 ;; 22746 esac 22747 fi 22748 TIME=$ac_cv_path_TIME 22749 if test -n "$TIME"; then 22750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22751 $as_echo "$TIME" >&6; } 22752 else 22753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22754 $as_echo "no" >&6; } 22755 fi 22756 22757 22758 if test "x$TIME" = x; then 22759 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22760 fi 22761 else 22762 # Otherwise we believe it is a complete path. Use it as it is. 22763 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 22764 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 22765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22766 $as_echo_n "checking for TIME... " >&6; } 22767 if test ! -x "$tool_specified"; then 22768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22769 $as_echo "not found" >&6; } 22770 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 22771 fi 22772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22773 $as_echo "$tool_specified" >&6; } 22774 fi 22775 fi 22776 fi 22777 22778 fi 22779 22780 22781 22782 22783 # Publish this variable in the help. 22784 22785 22786 if [ -z "${DTRACE+x}" ]; then 22787 # The variable is not set by user, try to locate tool using the code snippet 22788 for ac_prog in dtrace 22789 do 22790 # Extract the first word of "$ac_prog", so it can be a program name with args. 22791 set dummy $ac_prog; ac_word=$2 22792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22793 $as_echo_n "checking for $ac_word... " >&6; } 22794 if ${ac_cv_path_DTRACE+:} false; then : 22795 $as_echo_n "(cached) " >&6 22796 else 22797 case $DTRACE in 22798 [\\/]* | ?:[\\/]*) 22799 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22800 ;; 22801 *) 22802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22803 for as_dir in $PATH 22804 do 22805 IFS=$as_save_IFS 22806 test -z "$as_dir" && as_dir=. 22807 for ac_exec_ext in '' $ac_executable_extensions; do 22808 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22809 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22811 break 2 22812 fi 22813 done 22814 done 22815 IFS=$as_save_IFS 22816 22817 ;; 22818 esac 22819 fi 22820 DTRACE=$ac_cv_path_DTRACE 22821 if test -n "$DTRACE"; then 22822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22823 $as_echo "$DTRACE" >&6; } 22824 else 22825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22826 $as_echo "no" >&6; } 22827 fi 22828 22829 22830 test -n "$DTRACE" && break 22831 done 22832 22833 else 22834 # The variable is set, but is it from the command line or the environment? 22835 22836 # Try to remove the string !DTRACE! from our list. 22837 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 22838 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22839 # If it failed, the variable was not from the command line. Ignore it, 22840 # but warn the user (except for BASH, which is always set by the calling BASH). 22841 if test "xDTRACE" != xBASH; then 22842 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 22843 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 22844 fi 22845 # Try to locate tool using the code snippet 22846 for ac_prog in dtrace 22847 do 22848 # Extract the first word of "$ac_prog", so it can be a program name with args. 22849 set dummy $ac_prog; ac_word=$2 22850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22851 $as_echo_n "checking for $ac_word... " >&6; } 22852 if ${ac_cv_path_DTRACE+:} false; then : 22853 $as_echo_n "(cached) " >&6 22854 else 22855 case $DTRACE in 22856 [\\/]* | ?:[\\/]*) 22857 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22858 ;; 22859 *) 22860 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22861 for as_dir in $PATH 22862 do 22863 IFS=$as_save_IFS 22864 test -z "$as_dir" && as_dir=. 22865 for ac_exec_ext in '' $ac_executable_extensions; do 22866 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22867 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22868 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22869 break 2 22870 fi 22871 done 22872 done 22873 IFS=$as_save_IFS 22874 22875 ;; 22876 esac 22877 fi 22878 DTRACE=$ac_cv_path_DTRACE 22879 if test -n "$DTRACE"; then 22880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22881 $as_echo "$DTRACE" >&6; } 22882 else 22883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22884 $as_echo "no" >&6; } 22885 fi 22886 22887 22888 test -n "$DTRACE" && break 22889 done 22890 22891 else 22892 # If it succeeded, then it was overridden by the user. We will use it 22893 # for the tool. 22894 22895 # First remove it from the list of overridden variables, so we can test 22896 # for unknown variables in the end. 22897 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22898 22899 # Check if we try to supply an empty value 22900 if test "x$DTRACE" = x; then 22901 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 22902 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 22903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 22904 $as_echo_n "checking for DTRACE... " >&6; } 22905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22906 $as_echo "disabled" >&6; } 22907 else 22908 # Check if the provided tool contains a complete path. 22909 tool_specified="$DTRACE" 22910 tool_basename="${tool_specified##*/}" 22911 if test "x$tool_basename" = "x$tool_specified"; then 22912 # A command without a complete path is provided, search $PATH. 22913 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 22914 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 22915 # Extract the first word of "$tool_basename", so it can be a program name with args. 22916 set dummy $tool_basename; ac_word=$2 22917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22918 $as_echo_n "checking for $ac_word... " >&6; } 22919 if ${ac_cv_path_DTRACE+:} false; then : 22920 $as_echo_n "(cached) " >&6 22921 else 22922 case $DTRACE in 22923 [\\/]* | ?:[\\/]*) 22924 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22925 ;; 22926 *) 22927 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22928 for as_dir in $PATH 22929 do 22930 IFS=$as_save_IFS 22931 test -z "$as_dir" && as_dir=. 22932 for ac_exec_ext in '' $ac_executable_extensions; do 22933 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22934 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22935 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22936 break 2 22937 fi 22938 done 22939 done 22940 IFS=$as_save_IFS 22941 22942 ;; 22943 esac 22944 fi 22945 DTRACE=$ac_cv_path_DTRACE 22946 if test -n "$DTRACE"; then 22947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22948 $as_echo "$DTRACE" >&6; } 22949 else 22950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22951 $as_echo "no" >&6; } 22952 fi 22953 22954 22955 if test "x$DTRACE" = x; then 22956 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22957 fi 22958 else 22959 # Otherwise we believe it is a complete path. Use it as it is. 22960 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 22961 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 22962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 22963 $as_echo_n "checking for DTRACE... " >&6; } 22964 if test ! -x "$tool_specified"; then 22965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22966 $as_echo "not found" >&6; } 22967 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 22968 fi 22969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22970 $as_echo "$tool_specified" >&6; } 22971 fi 22972 fi 22973 fi 22974 22975 fi 22976 22977 22978 22979 22980 # Publish this variable in the help. 22981 22982 22983 if [ -z "${PATCH+x}" ]; then 22984 # The variable is not set by user, try to locate tool using the code snippet 22985 for ac_prog in gpatch patch 22986 do 22987 # Extract the first word of "$ac_prog", so it can be a program name with args. 22988 set dummy $ac_prog; ac_word=$2 22989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22990 $as_echo_n "checking for $ac_word... " >&6; } 22991 if ${ac_cv_path_PATCH+:} false; then : 22992 $as_echo_n "(cached) " >&6 22993 else 22994 case $PATCH in 22995 [\\/]* | ?:[\\/]*) 22996 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 22997 ;; 22998 *) 22999 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23000 for as_dir in $PATH 23001 do 23002 IFS=$as_save_IFS 23003 test -z "$as_dir" && as_dir=. 23004 for ac_exec_ext in '' $ac_executable_extensions; do 23005 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23006 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23007 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23008 break 2 23009 fi 23010 done 23011 done 23012 IFS=$as_save_IFS 23013 23014 ;; 23015 esac 23016 fi 23017 PATCH=$ac_cv_path_PATCH 23018 if test -n "$PATCH"; then 23019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23020 $as_echo "$PATCH" >&6; } 23021 else 23022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23023 $as_echo "no" >&6; } 23024 fi 23025 23026 23027 test -n "$PATCH" && break 23028 done 23029 23030 else 23031 # The variable is set, but is it from the command line or the environment? 23032 23033 # Try to remove the string !PATCH! from our list. 23034 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23035 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23036 # If it failed, the variable was not from the command line. Ignore it, 23037 # but warn the user (except for BASH, which is always set by the calling BASH). 23038 if test "xPATCH" != xBASH; then 23039 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23040 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23041 fi 23042 # Try to locate tool using the code snippet 23043 for ac_prog in gpatch patch 23044 do 23045 # Extract the first word of "$ac_prog", so it can be a program name with args. 23046 set dummy $ac_prog; ac_word=$2 23047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23048 $as_echo_n "checking for $ac_word... " >&6; } 23049 if ${ac_cv_path_PATCH+:} false; then : 23050 $as_echo_n "(cached) " >&6 23051 else 23052 case $PATCH in 23053 [\\/]* | ?:[\\/]*) 23054 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23055 ;; 23056 *) 23057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23058 for as_dir in $PATH 23059 do 23060 IFS=$as_save_IFS 23061 test -z "$as_dir" && as_dir=. 23062 for ac_exec_ext in '' $ac_executable_extensions; do 23063 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23064 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23065 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23066 break 2 23067 fi 23068 done 23069 done 23070 IFS=$as_save_IFS 23071 23072 ;; 23073 esac 23074 fi 23075 PATCH=$ac_cv_path_PATCH 23076 if test -n "$PATCH"; then 23077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23078 $as_echo "$PATCH" >&6; } 23079 else 23080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23081 $as_echo "no" >&6; } 23082 fi 23083 23084 23085 test -n "$PATCH" && break 23086 done 23087 23088 else 23089 # If it succeeded, then it was overridden by the user. We will use it 23090 # for the tool. 23091 23092 # First remove it from the list of overridden variables, so we can test 23093 # for unknown variables in the end. 23094 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23095 23096 # Check if we try to supply an empty value 23097 if test "x$PATCH" = x; then 23098 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23099 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23101 $as_echo_n "checking for PATCH... " >&6; } 23102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23103 $as_echo "disabled" >&6; } 23104 else 23105 # Check if the provided tool contains a complete path. 23106 tool_specified="$PATCH" 23107 tool_basename="${tool_specified##*/}" 23108 if test "x$tool_basename" = "x$tool_specified"; then 23109 # A command without a complete path is provided, search $PATH. 23110 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23111 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23112 # Extract the first word of "$tool_basename", so it can be a program name with args. 23113 set dummy $tool_basename; ac_word=$2 23114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23115 $as_echo_n "checking for $ac_word... " >&6; } 23116 if ${ac_cv_path_PATCH+:} false; then : 23117 $as_echo_n "(cached) " >&6 23118 else 23119 case $PATCH in 23120 [\\/]* | ?:[\\/]*) 23121 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23122 ;; 23123 *) 23124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23125 for as_dir in $PATH 23126 do 23127 IFS=$as_save_IFS 23128 test -z "$as_dir" && as_dir=. 23129 for ac_exec_ext in '' $ac_executable_extensions; do 23130 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23131 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23132 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23133 break 2 23134 fi 23135 done 23136 done 23137 IFS=$as_save_IFS 23138 23139 ;; 23140 esac 23141 fi 23142 PATCH=$ac_cv_path_PATCH 23143 if test -n "$PATCH"; then 23144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23145 $as_echo "$PATCH" >&6; } 23146 else 23147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23148 $as_echo "no" >&6; } 23149 fi 23150 23151 23152 if test "x$PATCH" = x; then 23153 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23154 fi 23155 else 23156 # Otherwise we believe it is a complete path. Use it as it is. 23157 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23158 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23160 $as_echo_n "checking for PATCH... " >&6; } 23161 if test ! -x "$tool_specified"; then 23162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23163 $as_echo "not found" >&6; } 23164 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23165 fi 23166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23167 $as_echo "$tool_specified" >&6; } 23168 fi 23169 fi 23170 fi 23171 23172 fi 23173 23174 23175 # Check if it's GNU time 23176 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23177 if test "x$IS_GNU_TIME" != x; then 23178 IS_GNU_TIME=yes 23179 else 23180 IS_GNU_TIME=no 23181 fi 23182 23183 23184 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23185 23186 23187 23188 # Publish this variable in the help. 23189 23190 23191 if [ -z "${DSYMUTIL+x}" ]; then 23192 # The variable is not set by user, try to locate tool using the code snippet 23193 for ac_prog in dsymutil 23194 do 23195 # Extract the first word of "$ac_prog", so it can be a program name with args. 23196 set dummy $ac_prog; ac_word=$2 23197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23198 $as_echo_n "checking for $ac_word... " >&6; } 23199 if ${ac_cv_path_DSYMUTIL+:} false; then : 23200 $as_echo_n "(cached) " >&6 23201 else 23202 case $DSYMUTIL in 23203 [\\/]* | ?:[\\/]*) 23204 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23205 ;; 23206 *) 23207 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23208 for as_dir in $PATH 23209 do 23210 IFS=$as_save_IFS 23211 test -z "$as_dir" && as_dir=. 23212 for ac_exec_ext in '' $ac_executable_extensions; do 23213 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23214 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23215 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23216 break 2 23217 fi 23218 done 23219 done 23220 IFS=$as_save_IFS 23221 23222 ;; 23223 esac 23224 fi 23225 DSYMUTIL=$ac_cv_path_DSYMUTIL 23226 if test -n "$DSYMUTIL"; then 23227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23228 $as_echo "$DSYMUTIL" >&6; } 23229 else 23230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23231 $as_echo "no" >&6; } 23232 fi 23233 23234 23235 test -n "$DSYMUTIL" && break 23236 done 23237 23238 else 23239 # The variable is set, but is it from the command line or the environment? 23240 23241 # Try to remove the string !DSYMUTIL! from our list. 23242 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23243 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23244 # If it failed, the variable was not from the command line. Ignore it, 23245 # but warn the user (except for BASH, which is always set by the calling BASH). 23246 if test "xDSYMUTIL" != xBASH; then 23247 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23248 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23249 fi 23250 # Try to locate tool using the code snippet 23251 for ac_prog in dsymutil 23252 do 23253 # Extract the first word of "$ac_prog", so it can be a program name with args. 23254 set dummy $ac_prog; ac_word=$2 23255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23256 $as_echo_n "checking for $ac_word... " >&6; } 23257 if ${ac_cv_path_DSYMUTIL+:} false; then : 23258 $as_echo_n "(cached) " >&6 23259 else 23260 case $DSYMUTIL in 23261 [\\/]* | ?:[\\/]*) 23262 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23263 ;; 23264 *) 23265 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23266 for as_dir in $PATH 23267 do 23268 IFS=$as_save_IFS 23269 test -z "$as_dir" && as_dir=. 23270 for ac_exec_ext in '' $ac_executable_extensions; do 23271 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23272 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23273 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23274 break 2 23275 fi 23276 done 23277 done 23278 IFS=$as_save_IFS 23279 23280 ;; 23281 esac 23282 fi 23283 DSYMUTIL=$ac_cv_path_DSYMUTIL 23284 if test -n "$DSYMUTIL"; then 23285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23286 $as_echo "$DSYMUTIL" >&6; } 23287 else 23288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23289 $as_echo "no" >&6; } 23290 fi 23291 23292 23293 test -n "$DSYMUTIL" && break 23294 done 23295 23296 else 23297 # If it succeeded, then it was overridden by the user. We will use it 23298 # for the tool. 23299 23300 # First remove it from the list of overridden variables, so we can test 23301 # for unknown variables in the end. 23302 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23303 23304 # Check if we try to supply an empty value 23305 if test "x$DSYMUTIL" = x; then 23306 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 23307 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 23308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23309 $as_echo_n "checking for DSYMUTIL... " >&6; } 23310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23311 $as_echo "disabled" >&6; } 23312 else 23313 # Check if the provided tool contains a complete path. 23314 tool_specified="$DSYMUTIL" 23315 tool_basename="${tool_specified##*/}" 23316 if test "x$tool_basename" = "x$tool_specified"; then 23317 # A command without a complete path is provided, search $PATH. 23318 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 23319 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 23320 # Extract the first word of "$tool_basename", so it can be a program name with args. 23321 set dummy $tool_basename; ac_word=$2 23322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23323 $as_echo_n "checking for $ac_word... " >&6; } 23324 if ${ac_cv_path_DSYMUTIL+:} false; then : 23325 $as_echo_n "(cached) " >&6 23326 else 23327 case $DSYMUTIL in 23328 [\\/]* | ?:[\\/]*) 23329 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23330 ;; 23331 *) 23332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23333 for as_dir in $PATH 23334 do 23335 IFS=$as_save_IFS 23336 test -z "$as_dir" && as_dir=. 23337 for ac_exec_ext in '' $ac_executable_extensions; do 23338 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23339 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23341 break 2 23342 fi 23343 done 23344 done 23345 IFS=$as_save_IFS 23346 23347 ;; 23348 esac 23349 fi 23350 DSYMUTIL=$ac_cv_path_DSYMUTIL 23351 if test -n "$DSYMUTIL"; then 23352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23353 $as_echo "$DSYMUTIL" >&6; } 23354 else 23355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23356 $as_echo "no" >&6; } 23357 fi 23358 23359 23360 if test "x$DSYMUTIL" = x; then 23361 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23362 fi 23363 else 23364 # Otherwise we believe it is a complete path. Use it as it is. 23365 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 23366 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 23367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23368 $as_echo_n "checking for DSYMUTIL... " >&6; } 23369 if test ! -x "$tool_specified"; then 23370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23371 $as_echo "not found" >&6; } 23372 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 23373 fi 23374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23375 $as_echo "$tool_specified" >&6; } 23376 fi 23377 fi 23378 fi 23379 23380 fi 23381 23382 23383 23384 if test "x$DSYMUTIL" = x; then 23385 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 23386 fi 23387 23388 23389 23390 23391 23392 # Publish this variable in the help. 23393 23394 23395 if [ -z "${XATTR+x}" ]; then 23396 # The variable is not set by user, try to locate tool using the code snippet 23397 for ac_prog in xattr 23398 do 23399 # Extract the first word of "$ac_prog", so it can be a program name with args. 23400 set dummy $ac_prog; ac_word=$2 23401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23402 $as_echo_n "checking for $ac_word... " >&6; } 23403 if ${ac_cv_path_XATTR+:} false; then : 23404 $as_echo_n "(cached) " >&6 23405 else 23406 case $XATTR in 23407 [\\/]* | ?:[\\/]*) 23408 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23409 ;; 23410 *) 23411 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23412 for as_dir in $PATH 23413 do 23414 IFS=$as_save_IFS 23415 test -z "$as_dir" && as_dir=. 23416 for ac_exec_ext in '' $ac_executable_extensions; do 23417 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23418 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23419 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23420 break 2 23421 fi 23422 done 23423 done 23424 IFS=$as_save_IFS 23425 23426 ;; 23427 esac 23428 fi 23429 XATTR=$ac_cv_path_XATTR 23430 if test -n "$XATTR"; then 23431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23432 $as_echo "$XATTR" >&6; } 23433 else 23434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23435 $as_echo "no" >&6; } 23436 fi 23437 23438 23439 test -n "$XATTR" && break 23440 done 23441 23442 else 23443 # The variable is set, but is it from the command line or the environment? 23444 23445 # Try to remove the string !XATTR! from our list. 23446 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 23447 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23448 # If it failed, the variable was not from the command line. Ignore it, 23449 # but warn the user (except for BASH, which is always set by the calling BASH). 23450 if test "xXATTR" != xBASH; then 23451 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 23452 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 23453 fi 23454 # Try to locate tool using the code snippet 23455 for ac_prog in xattr 23456 do 23457 # Extract the first word of "$ac_prog", so it can be a program name with args. 23458 set dummy $ac_prog; 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_XATTR+:} false; then : 23462 $as_echo_n "(cached) " >&6 23463 else 23464 case $XATTR in 23465 [\\/]* | ?:[\\/]*) 23466 ac_cv_path_XATTR="$XATTR" # 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_XATTR="$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 XATTR=$ac_cv_path_XATTR 23488 if test -n "$XATTR"; then 23489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23490 $as_echo "$XATTR" >&6; } 23491 else 23492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23493 $as_echo "no" >&6; } 23494 fi 23495 23496 23497 test -n "$XATTR" && break 23498 done 23499 23500 else 23501 # If it succeeded, then it was overridden by the user. We will use it 23502 # for the tool. 23503 23504 # First remove it from the list of overridden variables, so we can test 23505 # for unknown variables in the end. 23506 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23507 23508 # Check if we try to supply an empty value 23509 if test "x$XATTR" = x; then 23510 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 23511 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 23512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23513 $as_echo_n "checking for XATTR... " >&6; } 23514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23515 $as_echo "disabled" >&6; } 23516 else 23517 # Check if the provided tool contains a complete path. 23518 tool_specified="$XATTR" 23519 tool_basename="${tool_specified##*/}" 23520 if test "x$tool_basename" = "x$tool_specified"; then 23521 # A command without a complete path is provided, search $PATH. 23522 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 23523 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 23524 # Extract the first word of "$tool_basename", so it can be a program name with args. 23525 set dummy $tool_basename; ac_word=$2 23526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23527 $as_echo_n "checking for $ac_word... " >&6; } 23528 if ${ac_cv_path_XATTR+:} false; then : 23529 $as_echo_n "(cached) " >&6 23530 else 23531 case $XATTR in 23532 [\\/]* | ?:[\\/]*) 23533 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23534 ;; 23535 *) 23536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23537 for as_dir in $PATH 23538 do 23539 IFS=$as_save_IFS 23540 test -z "$as_dir" && as_dir=. 23541 for ac_exec_ext in '' $ac_executable_extensions; do 23542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23543 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23545 break 2 23546 fi 23547 done 23548 done 23549 IFS=$as_save_IFS 23550 23551 ;; 23552 esac 23553 fi 23554 XATTR=$ac_cv_path_XATTR 23555 if test -n "$XATTR"; then 23556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23557 $as_echo "$XATTR" >&6; } 23558 else 23559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23560 $as_echo "no" >&6; } 23561 fi 23562 23563 23564 if test "x$XATTR" = x; then 23565 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23566 fi 23567 else 23568 # Otherwise we believe it is a complete path. Use it as it is. 23569 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 23570 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 23571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23572 $as_echo_n "checking for XATTR... " >&6; } 23573 if test ! -x "$tool_specified"; then 23574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23575 $as_echo "not found" >&6; } 23576 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 23577 fi 23578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23579 $as_echo "$tool_specified" >&6; } 23580 fi 23581 fi 23582 fi 23583 23584 fi 23585 23586 23587 23588 if test "x$XATTR" = x; then 23589 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 23590 fi 23591 23592 23593 23594 23595 # Publish this variable in the help. 23596 23597 23598 if [ -z "${CODESIGN+x}" ]; then 23599 # The variable is not set by user, try to locate tool using the code snippet 23600 for ac_prog in codesign 23601 do 23602 # Extract the first word of "$ac_prog", so it can be a program name with args. 23603 set dummy $ac_prog; ac_word=$2 23604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23605 $as_echo_n "checking for $ac_word... " >&6; } 23606 if ${ac_cv_path_CODESIGN+:} false; then : 23607 $as_echo_n "(cached) " >&6 23608 else 23609 case $CODESIGN in 23610 [\\/]* | ?:[\\/]*) 23611 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23612 ;; 23613 *) 23614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23615 for as_dir in $PATH 23616 do 23617 IFS=$as_save_IFS 23618 test -z "$as_dir" && as_dir=. 23619 for ac_exec_ext in '' $ac_executable_extensions; do 23620 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23621 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23622 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23623 break 2 23624 fi 23625 done 23626 done 23627 IFS=$as_save_IFS 23628 23629 ;; 23630 esac 23631 fi 23632 CODESIGN=$ac_cv_path_CODESIGN 23633 if test -n "$CODESIGN"; then 23634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23635 $as_echo "$CODESIGN" >&6; } 23636 else 23637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23638 $as_echo "no" >&6; } 23639 fi 23640 23641 23642 test -n "$CODESIGN" && break 23643 done 23644 23645 else 23646 # The variable is set, but is it from the command line or the environment? 23647 23648 # Try to remove the string !CODESIGN! from our list. 23649 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 23650 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23651 # If it failed, the variable was not from the command line. Ignore it, 23652 # but warn the user (except for BASH, which is always set by the calling BASH). 23653 if test "xCODESIGN" != xBASH; then 23654 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 23655 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 23656 fi 23657 # Try to locate tool using the code snippet 23658 for ac_prog in codesign 23659 do 23660 # Extract the first word of "$ac_prog", so it can be a program name with args. 23661 set dummy $ac_prog; ac_word=$2 23662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23663 $as_echo_n "checking for $ac_word... " >&6; } 23664 if ${ac_cv_path_CODESIGN+:} false; then : 23665 $as_echo_n "(cached) " >&6 23666 else 23667 case $CODESIGN in 23668 [\\/]* | ?:[\\/]*) 23669 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23670 ;; 23671 *) 23672 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23673 for as_dir in $PATH 23674 do 23675 IFS=$as_save_IFS 23676 test -z "$as_dir" && as_dir=. 23677 for ac_exec_ext in '' $ac_executable_extensions; do 23678 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23679 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23680 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23681 break 2 23682 fi 23683 done 23684 done 23685 IFS=$as_save_IFS 23686 23687 ;; 23688 esac 23689 fi 23690 CODESIGN=$ac_cv_path_CODESIGN 23691 if test -n "$CODESIGN"; then 23692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23693 $as_echo "$CODESIGN" >&6; } 23694 else 23695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23696 $as_echo "no" >&6; } 23697 fi 23698 23699 23700 test -n "$CODESIGN" && break 23701 done 23702 23703 else 23704 # If it succeeded, then it was overridden by the user. We will use it 23705 # for the tool. 23706 23707 # First remove it from the list of overridden variables, so we can test 23708 # for unknown variables in the end. 23709 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23710 23711 # Check if we try to supply an empty value 23712 if test "x$CODESIGN" = x; then 23713 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 23714 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 23715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23716 $as_echo_n "checking for CODESIGN... " >&6; } 23717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23718 $as_echo "disabled" >&6; } 23719 else 23720 # Check if the provided tool contains a complete path. 23721 tool_specified="$CODESIGN" 23722 tool_basename="${tool_specified##*/}" 23723 if test "x$tool_basename" = "x$tool_specified"; then 23724 # A command without a complete path is provided, search $PATH. 23725 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 23726 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 23727 # Extract the first word of "$tool_basename", so it can be a program name with args. 23728 set dummy $tool_basename; ac_word=$2 23729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23730 $as_echo_n "checking for $ac_word... " >&6; } 23731 if ${ac_cv_path_CODESIGN+:} false; then : 23732 $as_echo_n "(cached) " >&6 23733 else 23734 case $CODESIGN in 23735 [\\/]* | ?:[\\/]*) 23736 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23737 ;; 23738 *) 23739 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23740 for as_dir in $PATH 23741 do 23742 IFS=$as_save_IFS 23743 test -z "$as_dir" && as_dir=. 23744 for ac_exec_ext in '' $ac_executable_extensions; do 23745 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23746 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23748 break 2 23749 fi 23750 done 23751 done 23752 IFS=$as_save_IFS 23753 23754 ;; 23755 esac 23756 fi 23757 CODESIGN=$ac_cv_path_CODESIGN 23758 if test -n "$CODESIGN"; then 23759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23760 $as_echo "$CODESIGN" >&6; } 23761 else 23762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23763 $as_echo "no" >&6; } 23764 fi 23765 23766 23767 if test "x$CODESIGN" = x; then 23768 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23769 fi 23770 else 23771 # Otherwise we believe it is a complete path. Use it as it is. 23772 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 23773 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 23774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23775 $as_echo_n "checking for CODESIGN... " >&6; } 23776 if test ! -x "$tool_specified"; then 23777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23778 $as_echo "not found" >&6; } 23779 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 23780 fi 23781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23782 $as_echo "$tool_specified" >&6; } 23783 fi 23784 fi 23785 fi 23786 23787 fi 23788 23789 23790 if test "x$CODESIGN" != "x"; then 23791 # Verify that the openjdk_codesign certificate is present 23792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 23793 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 23794 $RM codesign-testfile 23795 $TOUCH codesign-testfile 23796 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 23797 $RM codesign-testfile 23798 if test "x$CODESIGN" = x; then 23799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23800 $as_echo "no" >&6; } 23801 else 23802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23803 $as_echo "yes" >&6; } 23804 fi 23805 fi 23806 23807 23808 23809 # Publish this variable in the help. 23810 23811 23812 if [ -z "${SETFILE+x}" ]; then 23813 # The variable is not set by user, try to locate tool using the code snippet 23814 for ac_prog in SetFile 23815 do 23816 # Extract the first word of "$ac_prog", so it can be a program name with args. 23817 set dummy $ac_prog; ac_word=$2 23818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23819 $as_echo_n "checking for $ac_word... " >&6; } 23820 if ${ac_cv_path_SETFILE+:} false; then : 23821 $as_echo_n "(cached) " >&6 23822 else 23823 case $SETFILE in 23824 [\\/]* | ?:[\\/]*) 23825 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23826 ;; 23827 *) 23828 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23829 for as_dir in $PATH 23830 do 23831 IFS=$as_save_IFS 23832 test -z "$as_dir" && as_dir=. 23833 for ac_exec_ext in '' $ac_executable_extensions; do 23834 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23835 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23836 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23837 break 2 23838 fi 23839 done 23840 done 23841 IFS=$as_save_IFS 23842 23843 ;; 23844 esac 23845 fi 23846 SETFILE=$ac_cv_path_SETFILE 23847 if test -n "$SETFILE"; then 23848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23849 $as_echo "$SETFILE" >&6; } 23850 else 23851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23852 $as_echo "no" >&6; } 23853 fi 23854 23855 23856 test -n "$SETFILE" && break 23857 done 23858 23859 else 23860 # The variable is set, but is it from the command line or the environment? 23861 23862 # Try to remove the string !SETFILE! from our list. 23863 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 23864 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23865 # If it failed, the variable was not from the command line. Ignore it, 23866 # but warn the user (except for BASH, which is always set by the calling BASH). 23867 if test "xSETFILE" != xBASH; then 23868 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 23869 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 23870 fi 23871 # Try to locate tool using the code snippet 23872 for ac_prog in SetFile 23873 do 23874 # Extract the first word of "$ac_prog", so it can be a program name with args. 23875 set dummy $ac_prog; ac_word=$2 23876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23877 $as_echo_n "checking for $ac_word... " >&6; } 23878 if ${ac_cv_path_SETFILE+:} false; then : 23879 $as_echo_n "(cached) " >&6 23880 else 23881 case $SETFILE in 23882 [\\/]* | ?:[\\/]*) 23883 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23884 ;; 23885 *) 23886 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23887 for as_dir in $PATH 23888 do 23889 IFS=$as_save_IFS 23890 test -z "$as_dir" && as_dir=. 23891 for ac_exec_ext in '' $ac_executable_extensions; do 23892 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23893 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23894 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23895 break 2 23896 fi 23897 done 23898 done 23899 IFS=$as_save_IFS 23900 23901 ;; 23902 esac 23903 fi 23904 SETFILE=$ac_cv_path_SETFILE 23905 if test -n "$SETFILE"; then 23906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23907 $as_echo "$SETFILE" >&6; } 23908 else 23909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23910 $as_echo "no" >&6; } 23911 fi 23912 23913 23914 test -n "$SETFILE" && break 23915 done 23916 23917 else 23918 # If it succeeded, then it was overridden by the user. We will use it 23919 # for the tool. 23920 23921 # First remove it from the list of overridden variables, so we can test 23922 # for unknown variables in the end. 23923 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23924 23925 # Check if we try to supply an empty value 23926 if test "x$SETFILE" = x; then 23927 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 23928 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 23929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 23930 $as_echo_n "checking for SETFILE... " >&6; } 23931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23932 $as_echo "disabled" >&6; } 23933 else 23934 # Check if the provided tool contains a complete path. 23935 tool_specified="$SETFILE" 23936 tool_basename="${tool_specified##*/}" 23937 if test "x$tool_basename" = "x$tool_specified"; then 23938 # A command without a complete path is provided, search $PATH. 23939 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 23940 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 23941 # Extract the first word of "$tool_basename", so it can be a program name with args. 23942 set dummy $tool_basename; ac_word=$2 23943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23944 $as_echo_n "checking for $ac_word... " >&6; } 23945 if ${ac_cv_path_SETFILE+:} false; then : 23946 $as_echo_n "(cached) " >&6 23947 else 23948 case $SETFILE in 23949 [\\/]* | ?:[\\/]*) 23950 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23951 ;; 23952 *) 23953 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23954 for as_dir in $PATH 23955 do 23956 IFS=$as_save_IFS 23957 test -z "$as_dir" && as_dir=. 23958 for ac_exec_ext in '' $ac_executable_extensions; do 23959 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23960 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23961 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23962 break 2 23963 fi 23964 done 23965 done 23966 IFS=$as_save_IFS 23967 23968 ;; 23969 esac 23970 fi 23971 SETFILE=$ac_cv_path_SETFILE 23972 if test -n "$SETFILE"; then 23973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23974 $as_echo "$SETFILE" >&6; } 23975 else 23976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23977 $as_echo "no" >&6; } 23978 fi 23979 23980 23981 if test "x$SETFILE" = x; then 23982 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23983 fi 23984 else 23985 # Otherwise we believe it is a complete path. Use it as it is. 23986 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 23987 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 23988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 23989 $as_echo_n "checking for SETFILE... " >&6; } 23990 if test ! -x "$tool_specified"; then 23991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23992 $as_echo "not found" >&6; } 23993 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 23994 fi 23995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23996 $as_echo "$tool_specified" >&6; } 23997 fi 23998 fi 23999 fi 24000 24001 fi 24002 24003 24004 24005 if test "x$SETFILE" = x; then 24006 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 24007 fi 24008 24009 24010 fi 24011 24012 24013 # Test if bash supports pipefail. 24014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24015 $as_echo_n "checking if bash supports pipefail... " >&6; } 24016 if ${BASH} -c 'set -o pipefail'; then 24017 BASH_ARGS="$BASH_ARGS -o pipefail" 24018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24019 $as_echo "yes" >&6; } 24020 else 24021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24022 $as_echo "no" >&6; } 24023 fi 24024 24025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24026 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24027 if ${BASH} -e -c 'true'; then 24028 BASH_ARGS="$BASH_ARGS -e" 24029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24030 $as_echo "yes" >&6; } 24031 else 24032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24033 $as_echo "no" >&6; } 24034 fi 24035 24036 24037 24038 24039 # Check if pkg-config is available. 24040 24041 24042 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24043 if test -n "$ac_tool_prefix"; then 24044 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24045 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24047 $as_echo_n "checking for $ac_word... " >&6; } 24048 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24049 $as_echo_n "(cached) " >&6 24050 else 24051 case $PKG_CONFIG in 24052 [\\/]* | ?:[\\/]*) 24053 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24054 ;; 24055 *) 24056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24057 for as_dir in $PATH 24058 do 24059 IFS=$as_save_IFS 24060 test -z "$as_dir" && as_dir=. 24061 for ac_exec_ext in '' $ac_executable_extensions; do 24062 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24063 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24064 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24065 break 2 24066 fi 24067 done 24068 done 24069 IFS=$as_save_IFS 24070 24071 ;; 24072 esac 24073 fi 24074 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24075 if test -n "$PKG_CONFIG"; then 24076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24077 $as_echo "$PKG_CONFIG" >&6; } 24078 else 24079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24080 $as_echo "no" >&6; } 24081 fi 24082 24083 24084 fi 24085 if test -z "$ac_cv_path_PKG_CONFIG"; then 24086 ac_pt_PKG_CONFIG=$PKG_CONFIG 24087 # Extract the first word of "pkg-config", so it can be a program name with args. 24088 set dummy pkg-config; ac_word=$2 24089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24090 $as_echo_n "checking for $ac_word... " >&6; } 24091 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24092 $as_echo_n "(cached) " >&6 24093 else 24094 case $ac_pt_PKG_CONFIG in 24095 [\\/]* | ?:[\\/]*) 24096 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24097 ;; 24098 *) 24099 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24100 for as_dir in $PATH 24101 do 24102 IFS=$as_save_IFS 24103 test -z "$as_dir" && as_dir=. 24104 for ac_exec_ext in '' $ac_executable_extensions; do 24105 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24106 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24107 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24108 break 2 24109 fi 24110 done 24111 done 24112 IFS=$as_save_IFS 24113 24114 ;; 24115 esac 24116 fi 24117 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24118 if test -n "$ac_pt_PKG_CONFIG"; then 24119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24120 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24121 else 24122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24123 $as_echo "no" >&6; } 24124 fi 24125 24126 if test "x$ac_pt_PKG_CONFIG" = x; then 24127 PKG_CONFIG="" 24128 else 24129 case $cross_compiling:$ac_tool_warned in 24130 yes:) 24131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24132 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24133 ac_tool_warned=yes ;; 24134 esac 24135 PKG_CONFIG=$ac_pt_PKG_CONFIG 24136 fi 24137 else 24138 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24139 fi 24140 24141 fi 24142 if test -n "$PKG_CONFIG"; then 24143 _pkg_min_version=0.9.0 24144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24145 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24146 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24148 $as_echo "yes" >&6; } 24149 else 24150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24151 $as_echo "no" >&6; } 24152 PKG_CONFIG="" 24153 fi 24154 24155 fi 24156 24157 # After basic tools have been setup, we can check build os specific details. 24158 24159 ############################################################################### 24160 24161 # Note that this is the build platform OS version! 24162 24163 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24164 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24165 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24166 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24167 24168 24169 24170 24171 24172 # Misc basic settings 24173 24174 24175 # Check whether --with-default-make-target was given. 24176 if test "${with_default_make_target+set}" = set; then : 24177 withval=$with_default_make_target; 24178 fi 24179 24180 if test "x$with_default_make_target" = "x" \ 24181 || test "x$with_default_make_target" = "xyes"; then 24182 DEFAULT_MAKE_TARGET="exploded-image" 24183 elif test "x$with_default_make_target" = "xno"; then 24184 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24185 else 24186 DEFAULT_MAKE_TARGET="$with_default_make_target" 24187 fi 24188 24189 24190 24191 24192 ############################################################################### 24193 # 24194 # Determine OpenJDK variants, options and version numbers. 24195 # 24196 ############################################################################### 24197 24198 # We need build & target for this. 24199 24200 # Should we build a JDK/JVM with headful support (ie a graphical ui)? 24201 # We always build headless support. 24202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5 24203 $as_echo_n "checking headful support... " >&6; } 24204 # Check whether --enable-headful was given. 24205 if test "${enable_headful+set}" = set; then : 24206 enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful} 24207 else 24208 SUPPORT_HEADFUL=yes 24209 fi 24210 24211 24212 SUPPORT_HEADLESS=yes 24213 BUILD_HEADLESS="BUILD_HEADLESS:=true" 24214 24215 if test "x$SUPPORT_HEADFUL" = xyes; then 24216 # We are building both headful and headless. 24217 headful_msg="include support for both headful and headless" 24218 fi 24219 24220 if test "x$SUPPORT_HEADFUL" = xno; then 24221 # Thus we are building headless only. 24222 BUILD_HEADLESS="BUILD_HEADLESS:=true" 24223 headful_msg="headless only" 24224 fi 24225 24226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5 24227 $as_echo "$headful_msg" >&6; } 24228 24229 24230 24231 24232 24233 # Choose cacerts source file 24234 24235 # Check whether --with-cacerts-file was given. 24236 if test "${with_cacerts_file+set}" = set; then : 24237 withval=$with_cacerts_file; 24238 fi 24239 24240 if test "x$with_cacerts_file" != x; then 24241 CACERTS_FILE=$with_cacerts_file 24242 fi 24243 24244 24245 # Enable or disable unlimited crypto 24246 # Check whether --enable-unlimited-crypto was given. 24247 if test "${enable_unlimited_crypto+set}" = set; then : 24248 enableval=$enable_unlimited_crypto; 24249 else 24250 enable_unlimited_crypto=no 24251 fi 24252 24253 if test "x$enable_unlimited_crypto" = "xyes"; then 24254 UNLIMITED_CRYPTO=true 24255 else 24256 UNLIMITED_CRYPTO=false 24257 fi 24258 24259 24260 # Should we build the serviceability agent (SA)? 24261 INCLUDE_SA=true 24262 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 24263 INCLUDE_SA=false 24264 fi 24265 if test "x$OPENJDK_TARGET_OS" = xaix ; then 24266 INCLUDE_SA=false 24267 fi 24268 24269 24270 # Compress jars 24271 COMPRESS_JARS=false 24272 24273 24274 24275 # Setup default copyright year. Mostly overridden when building close to a new year. 24276 24277 # Check whether --with-copyright-year was given. 24278 if test "${with_copyright_year+set}" = set; then : 24279 withval=$with_copyright_year; 24280 fi 24281 24282 if test "x$with_copyright_year" = xyes; then 24283 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 24284 elif test "x$with_copyright_year" != x; then 24285 COPYRIGHT_YEAR="$with_copyright_year" 24286 else 24287 COPYRIGHT_YEAR=`$DATE +'%Y'` 24288 fi 24289 24290 24291 24292 # Check whether --enable-keep-packaged-modules was given. 24293 if test "${enable_keep_packaged_modules+set}" = set; then : 24294 enableval=$enable_keep_packaged_modules; 24295 fi 24296 24297 24298 if test "x$enable_keep_packaged_modules" = "xyes"; then 24299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24300 $as_echo_n "checking if packaged modules are kept... " >&6; } 24301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24302 $as_echo "yes" >&6; } 24303 JLINK_KEEP_PACKAGED_MODULES=true 24304 elif test "x$enable_keep_packaged_modules" = "xno"; then 24305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24306 $as_echo_n "checking if packaged modules are kept... " >&6; } 24307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24308 $as_echo "no" >&6; } 24309 JLINK_KEEP_PACKAGED_MODULES=false 24310 elif test "x$enable_keep_packaged_modules" = "x"; then 24311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 24312 $as_echo "yes (default)" >&6; } 24313 JLINK_KEEP_PACKAGED_MODULES=true 24314 else 24315 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 24316 fi 24317 24318 24319 24320 24321 # Warn user that old version arguments are deprecated. 24322 24323 24324 # Check whether --with-milestone was given. 24325 if test "${with_milestone+set}" = set; then : 24326 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 24327 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 24328 fi 24329 24330 24331 24332 24333 # Check whether --with-update-version was given. 24334 if test "${with_update_version+set}" = set; then : 24335 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 24336 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 24337 fi 24338 24339 24340 24341 24342 # Check whether --with-user-release-suffix was given. 24343 if test "${with_user_release_suffix+set}" = set; then : 24344 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 24345 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 24346 fi 24347 24348 24349 24350 24351 # Check whether --with-build-number was given. 24352 if test "${with_build_number+set}" = set; then : 24353 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 24354 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 24355 fi 24356 24357 24358 24359 # Source the version numbers file 24360 . $AUTOCONF_DIR/version-numbers 24361 24362 # Some non-version number information is set in that file 24363 24364 24365 24366 24367 24368 24369 24370 24371 24372 # Override version from arguments 24373 24374 # If --with-version-string is set, process it first. It is possible to 24375 # override parts with more specific flags, since these are processed later. 24376 24377 # Check whether --with-version-string was given. 24378 if test "${with_version_string+set}" = set; then : 24379 withval=$with_version_string; 24380 fi 24381 24382 if test "x$with_version_string" = xyes; then 24383 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 24384 elif test "x$with_version_string" != x; then 24385 # Additional [] needed to keep m4 from mangling shell constructs. 24386 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 24387 VERSION_MAJOR=${BASH_REMATCH[1]} 24388 VERSION_MINOR=${BASH_REMATCH[3]} 24389 VERSION_SECURITY=${BASH_REMATCH[5]} 24390 VERSION_PATCH=${BASH_REMATCH[7]} 24391 VERSION_PRE=${BASH_REMATCH[9]} 24392 version_plus_separator=${BASH_REMATCH[11]} 24393 VERSION_BUILD=${BASH_REMATCH[12]} 24394 VERSION_OPT=${BASH_REMATCH[14]} 24395 # Unspecified numerical fields are interpreted as 0. 24396 if test "x$VERSION_MINOR" = x; then 24397 VERSION_MINOR=0 24398 fi 24399 if test "x$VERSION_SECURITY" = x; then 24400 VERSION_SECURITY=0 24401 fi 24402 if test "x$VERSION_PATCH" = x; then 24403 VERSION_PATCH=0 24404 fi 24405 if test "x$version_plus_separator" != x \ 24406 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 24407 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 24408 fi 24409 # Stop the version part process from setting default values. 24410 # We still allow them to explicitely override though. 24411 NO_DEFAULT_VERSION_PARTS=true 24412 else 24413 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 24414 fi 24415 fi 24416 24417 24418 # Check whether --with-version-pre was given. 24419 if test "${with_version_pre+set}" = set; then : 24420 withval=$with_version_pre; with_version_pre_present=true 24421 else 24422 with_version_pre_present=false 24423 fi 24424 24425 24426 if test "x$with_version_pre_present" = xtrue; then 24427 if test "x$with_version_pre" = xyes; then 24428 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 24429 elif test "x$with_version_pre" = xno; then 24430 # Interpret --without-* as empty string instead of the literal "no" 24431 VERSION_PRE= 24432 else 24433 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 24434 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 24435 if test "x$VERSION_PRE" != "x$with_version_pre"; then 24436 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 24437 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 24438 fi 24439 fi 24440 else 24441 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24442 # Default is to use "internal" as pre 24443 VERSION_PRE="internal" 24444 fi 24445 fi 24446 24447 24448 # Check whether --with-version-opt was given. 24449 if test "${with_version_opt+set}" = set; then : 24450 withval=$with_version_opt; with_version_opt_present=true 24451 else 24452 with_version_opt_present=false 24453 fi 24454 24455 24456 if test "x$with_version_opt_present" = xtrue; then 24457 if test "x$with_version_opt" = xyes; then 24458 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 24459 elif test "x$with_version_opt" = xno; then 24460 # Interpret --without-* as empty string instead of the literal "no" 24461 VERSION_OPT= 24462 else 24463 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 24464 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 24465 if test "x$VERSION_OPT" != "x$with_version_opt"; then 24466 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 24467 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 24468 fi 24469 fi 24470 else 24471 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24472 # Default is to calculate a string like this <timestamp>.<username>.<base dir name> 24473 timestamp=`$DATE '+%Y-%m-%d-%H%M%S'` 24474 # Outer [ ] to quote m4. 24475 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 24476 VERSION_OPT="$timestamp.$USERNAME.$basedirname" 24477 fi 24478 fi 24479 24480 24481 # Check whether --with-version-build was given. 24482 if test "${with_version_build+set}" = set; then : 24483 withval=$with_version_build; with_version_build_present=true 24484 else 24485 with_version_build_present=false 24486 fi 24487 24488 24489 if test "x$with_version_build_present" = xtrue; then 24490 if test "x$with_version_build" = xyes; then 24491 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 24492 elif test "x$with_version_build" = xno; then 24493 # Interpret --without-* as empty string instead of the literal "no" 24494 VERSION_BUILD= 24495 elif test "x$with_version_build" = x; then 24496 VERSION_BUILD= 24497 else 24498 24499 # Additional [] needed to keep m4 from mangling shell constructs. 24500 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24501 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 24502 fi 24503 # Extract the version number without leading zeros. 24504 cleaned_value=${BASH_REMATCH[1]} 24505 if test "x$cleaned_value" = x; then 24506 # Special case for zero 24507 cleaned_value=${BASH_REMATCH[2]} 24508 fi 24509 24510 if test $cleaned_value -gt 255; then 24511 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 24512 fi 24513 if test "x$cleaned_value" != "x$with_version_build"; then 24514 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 24515 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 24516 fi 24517 VERSION_BUILD=$cleaned_value 24518 24519 fi 24520 else 24521 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24522 # Default is to not have a build number. 24523 VERSION_BUILD="" 24524 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 24525 VERSION_BUILD=0 24526 fi 24527 fi 24528 24529 24530 # Check whether --with-version-major was given. 24531 if test "${with_version_major+set}" = set; then : 24532 withval=$with_version_major; with_version_major_present=true 24533 else 24534 with_version_major_present=false 24535 fi 24536 24537 24538 if test "x$with_version_major_present" = xtrue; then 24539 if test "x$with_version_major" = xyes; then 24540 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 24541 else 24542 24543 # Additional [] needed to keep m4 from mangling shell constructs. 24544 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24545 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 24546 fi 24547 # Extract the version number without leading zeros. 24548 cleaned_value=${BASH_REMATCH[1]} 24549 if test "x$cleaned_value" = x; then 24550 # Special case for zero 24551 cleaned_value=${BASH_REMATCH[2]} 24552 fi 24553 24554 if test $cleaned_value -gt 255; then 24555 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 24556 fi 24557 if test "x$cleaned_value" != "x$with_version_major"; then 24558 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 24559 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 24560 fi 24561 VERSION_MAJOR=$cleaned_value 24562 24563 fi 24564 else 24565 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24566 # Default is to get value from version-numbers 24567 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 24568 fi 24569 fi 24570 24571 24572 # Check whether --with-version-minor was given. 24573 if test "${with_version_minor+set}" = set; then : 24574 withval=$with_version_minor; with_version_minor_present=true 24575 else 24576 with_version_minor_present=false 24577 fi 24578 24579 24580 if test "x$with_version_minor_present" = xtrue; then 24581 if test "x$with_version_minor" = xyes; then 24582 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 24583 elif test "x$with_version_minor" = xno; then 24584 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24585 VERSION_MINOR=0 24586 elif test "x$with_version_minor" = x; then 24587 VERSION_MINOR=0 24588 else 24589 24590 # Additional [] needed to keep m4 from mangling shell constructs. 24591 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24592 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 24593 fi 24594 # Extract the version number without leading zeros. 24595 cleaned_value=${BASH_REMATCH[1]} 24596 if test "x$cleaned_value" = x; then 24597 # Special case for zero 24598 cleaned_value=${BASH_REMATCH[2]} 24599 fi 24600 24601 if test $cleaned_value -gt 255; then 24602 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 24603 fi 24604 if test "x$cleaned_value" != "x$with_version_minor"; then 24605 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 24606 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 24607 fi 24608 VERSION_MINOR=$cleaned_value 24609 24610 fi 24611 else 24612 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24613 # Default is 0, if unspecified 24614 VERSION_MINOR=0 24615 fi 24616 fi 24617 24618 24619 # Check whether --with-version-security was given. 24620 if test "${with_version_security+set}" = set; then : 24621 withval=$with_version_security; with_version_security_present=true 24622 else 24623 with_version_security_present=false 24624 fi 24625 24626 24627 if test "x$with_version_security_present" = xtrue; then 24628 if test "x$with_version_security" = xyes; then 24629 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 24630 elif test "x$with_version_security" = xno; then 24631 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24632 VERSION_SECURITY=0 24633 elif test "x$with_version_security" = x; then 24634 VERSION_SECURITY=0 24635 else 24636 24637 # Additional [] needed to keep m4 from mangling shell constructs. 24638 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24639 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 24640 fi 24641 # Extract the version number without leading zeros. 24642 cleaned_value=${BASH_REMATCH[1]} 24643 if test "x$cleaned_value" = x; then 24644 # Special case for zero 24645 cleaned_value=${BASH_REMATCH[2]} 24646 fi 24647 24648 if test $cleaned_value -gt 255; then 24649 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 24650 fi 24651 if test "x$cleaned_value" != "x$with_version_security"; then 24652 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 24653 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 24654 fi 24655 VERSION_SECURITY=$cleaned_value 24656 24657 fi 24658 else 24659 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24660 # Default is 0, if unspecified 24661 VERSION_SECURITY=0 24662 fi 24663 fi 24664 24665 24666 # Check whether --with-version-patch was given. 24667 if test "${with_version_patch+set}" = set; then : 24668 withval=$with_version_patch; with_version_patch_present=true 24669 else 24670 with_version_patch_present=false 24671 fi 24672 24673 24674 if test "x$with_version_patch_present" = xtrue; then 24675 if test "x$with_version_patch" = xyes; then 24676 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 24677 elif test "x$with_version_patch" = xno; then 24678 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24679 VERSION_PATCH=0 24680 elif test "x$with_version_patch" = x; then 24681 VERSION_PATCH=0 24682 else 24683 24684 # Additional [] needed to keep m4 from mangling shell constructs. 24685 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24686 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 24687 fi 24688 # Extract the version number without leading zeros. 24689 cleaned_value=${BASH_REMATCH[1]} 24690 if test "x$cleaned_value" = x; then 24691 # Special case for zero 24692 cleaned_value=${BASH_REMATCH[2]} 24693 fi 24694 24695 if test $cleaned_value -gt 255; then 24696 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 24697 fi 24698 if test "x$cleaned_value" != "x$with_version_patch"; then 24699 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 24700 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 24701 fi 24702 VERSION_PATCH=$cleaned_value 24703 24704 fi 24705 else 24706 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24707 # Default is 0, if unspecified 24708 VERSION_PATCH=0 24709 fi 24710 fi 24711 24712 # Calculate derived version properties 24713 24714 # Set VERSION_IS_GA based on if VERSION_PRE has a value 24715 if test "x$VERSION_PRE" = x; then 24716 VERSION_IS_GA=true 24717 else 24718 VERSION_IS_GA=false 24719 fi 24720 24721 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 24722 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 24723 24724 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 24725 # Strip trailing zeroes from stripped_version_number 24726 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 24727 VERSION_NUMBER=$stripped_version_number 24728 24729 # The complete version string, with additional build information 24730 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 24731 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 24732 else 24733 # If either build or opt is set, we need a + separator 24734 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 24735 fi 24736 24737 # The short version string, just VERSION_NUMBER and PRE, if present. 24738 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 24739 24740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 24741 $as_echo_n "checking for version string... " >&6; } 24742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 24743 $as_echo "$VERSION_STRING" >&6; } 24744 24745 24746 24747 24748 24749 24750 24751 24752 24753 24754 24755 24756 24757 24758 24759 ############################################################################### 24760 # 24761 # Setup BootJDK, used to bootstrap the build. 24762 # 24763 ############################################################################### 24764 24765 24766 BOOT_JDK_FOUND=no 24767 24768 # Check whether --with-boot-jdk was given. 24769 if test "${with_boot_jdk+set}" = set; then : 24770 withval=$with_boot_jdk; 24771 fi 24772 24773 24774 # We look for the Boot JDK through various means, going from more certain to 24775 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 24776 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 24777 # must check if this is indeed valid; otherwise we'll continue looking. 24778 24779 # Test: Is bootjdk explicitely set by command line arguments? 24780 24781 if test "x$BOOT_JDK_FOUND" = xno; then 24782 # Now execute the test 24783 24784 if test "x$with_boot_jdk" != x; then 24785 BOOT_JDK=$with_boot_jdk 24786 BOOT_JDK_FOUND=maybe 24787 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 24788 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 24789 fi 24790 24791 24792 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24793 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24794 # Do we have a bin/java? 24795 if test ! -x "$BOOT_JDK/bin/java"; then 24796 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24797 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24798 BOOT_JDK_FOUND=no 24799 else 24800 # Do we have a bin/javac? 24801 if test ! -x "$BOOT_JDK/bin/javac"; then 24802 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24803 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24804 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24805 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24806 BOOT_JDK_FOUND=no 24807 else 24808 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24809 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 24810 24811 # Extra M4 quote needed to protect [] in grep expression. 24812 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24813 if test "x$FOUND_CORRECT_VERSION" = x; then 24814 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24815 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24816 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24817 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24818 BOOT_JDK_FOUND=no 24819 else 24820 # We're done! :-) 24821 BOOT_JDK_FOUND=yes 24822 24823 # Only process if variable expands to non-empty 24824 24825 if test "x$BOOT_JDK" != x; then 24826 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24827 24828 # Input might be given as Windows format, start by converting to 24829 # unix format. 24830 path="$BOOT_JDK" 24831 new_path=`$CYGPATH -u "$path"` 24832 24833 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24834 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24835 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24836 # "foo.exe" is OK but "foo" is an error. 24837 # 24838 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24839 # It is also a way to make sure we got the proper file name for the real test later on. 24840 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24841 if test "x$test_shortpath" = x; then 24842 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24843 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24844 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24845 fi 24846 24847 # Call helper function which possibly converts this using DOS-style short mode. 24848 # If so, the updated path is stored in $new_path. 24849 24850 input_path="$new_path" 24851 # Check if we need to convert this using DOS-style short mode. If the path 24852 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24853 # take no chances and rewrite it. 24854 # Note: m4 eats our [], so we need to use [ and ] instead. 24855 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24856 if test "x$has_forbidden_chars" != x; then 24857 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24858 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24859 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24860 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24861 # Going to short mode and back again did indeed matter. Since short mode is 24862 # case insensitive, let's make it lowercase to improve readability. 24863 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24864 # Now convert it back to Unix-style (cygpath) 24865 input_path=`$CYGPATH -u "$shortmode_path"` 24866 new_path="$input_path" 24867 fi 24868 fi 24869 24870 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24871 if test "x$test_cygdrive_prefix" = x; then 24872 # As a simple fix, exclude /usr/bin since it's not a real path. 24873 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24874 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24875 # a path prefixed by /cygdrive for fixpath to work. 24876 new_path="$CYGWIN_ROOT_PATH$input_path" 24877 fi 24878 fi 24879 24880 24881 if test "x$path" != "x$new_path"; then 24882 BOOT_JDK="$new_path" 24883 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24884 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24885 fi 24886 24887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24888 24889 path="$BOOT_JDK" 24890 has_colon=`$ECHO $path | $GREP ^.:` 24891 new_path="$path" 24892 if test "x$has_colon" = x; then 24893 # Not in mixed or Windows style, start by that. 24894 new_path=`cmd //c echo $path` 24895 fi 24896 24897 24898 input_path="$new_path" 24899 # Check if we need to convert this using DOS-style short mode. If the path 24900 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24901 # take no chances and rewrite it. 24902 # Note: m4 eats our [], so we need to use [ and ] instead. 24903 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24904 if test "x$has_forbidden_chars" != x; then 24905 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24906 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24907 fi 24908 24909 24910 windows_path="$new_path" 24911 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24912 unix_path=`$CYGPATH -u "$windows_path"` 24913 new_path="$unix_path" 24914 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24915 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24916 new_path="$unix_path" 24917 fi 24918 24919 if test "x$path" != "x$new_path"; then 24920 BOOT_JDK="$new_path" 24921 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24922 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24923 fi 24924 24925 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24926 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24927 24928 else 24929 # We're on a unix platform. Hooray! :) 24930 path="$BOOT_JDK" 24931 has_space=`$ECHO "$path" | $GREP " "` 24932 if test "x$has_space" != x; then 24933 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24934 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24935 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24936 fi 24937 24938 # Use eval to expand a potential ~ 24939 eval path="$path" 24940 if test ! -f "$path" && test ! -d "$path"; then 24941 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24942 fi 24943 24944 if test -d "$path"; then 24945 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24946 else 24947 dir="`$DIRNAME "$path"`" 24948 base="`$BASENAME "$path"`" 24949 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24950 fi 24951 fi 24952 fi 24953 24954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24955 $as_echo_n "checking for Boot JDK... " >&6; } 24956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24957 $as_echo "$BOOT_JDK" >&6; } 24958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24959 $as_echo_n "checking Boot JDK version... " >&6; } 24960 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24962 $as_echo "$BOOT_JDK_VERSION" >&6; } 24963 fi # end check jdk version 24964 fi # end check javac 24965 fi # end check java 24966 fi # end check boot jdk found 24967 fi 24968 24969 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 24970 # Having specified an argument which is incorrect will produce an instant failure; 24971 # we should not go on looking 24972 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 24973 fi 24974 24975 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 24976 24977 if test "x$BOOT_JDK_FOUND" = xno; then 24978 # Now execute the test 24979 24980 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 24981 # First check at user selected default 24982 24983 if test "x$BOOT_JDK_FOUND" = xno; then 24984 # Now execute the test 24985 24986 if test -x /usr/libexec/java_home; then 24987 BOOT_JDK=`/usr/libexec/java_home ` 24988 BOOT_JDK_FOUND=maybe 24989 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 24990 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 24991 fi 24992 24993 24994 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24995 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24996 # Do we have a bin/java? 24997 if test ! -x "$BOOT_JDK/bin/java"; then 24998 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24999 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25000 BOOT_JDK_FOUND=no 25001 else 25002 # Do we have a bin/javac? 25003 if test ! -x "$BOOT_JDK/bin/javac"; then 25004 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25005 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25006 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25007 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25008 BOOT_JDK_FOUND=no 25009 else 25010 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25011 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25012 25013 # Extra M4 quote needed to protect [] in grep expression. 25014 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25015 if test "x$FOUND_CORRECT_VERSION" = x; then 25016 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25017 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25018 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25019 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25020 BOOT_JDK_FOUND=no 25021 else 25022 # We're done! :-) 25023 BOOT_JDK_FOUND=yes 25024 25025 # Only process if variable expands to non-empty 25026 25027 if test "x$BOOT_JDK" != x; then 25028 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25029 25030 # Input might be given as Windows format, start by converting to 25031 # unix format. 25032 path="$BOOT_JDK" 25033 new_path=`$CYGPATH -u "$path"` 25034 25035 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25036 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25037 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25038 # "foo.exe" is OK but "foo" is an error. 25039 # 25040 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25041 # It is also a way to make sure we got the proper file name for the real test later on. 25042 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25043 if test "x$test_shortpath" = x; then 25044 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25045 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25046 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25047 fi 25048 25049 # Call helper function which possibly converts this using DOS-style short mode. 25050 # If so, the updated path is stored in $new_path. 25051 25052 input_path="$new_path" 25053 # Check if we need to convert this using DOS-style short mode. If the path 25054 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25055 # take no chances and rewrite it. 25056 # Note: m4 eats our [], so we need to use [ and ] instead. 25057 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25058 if test "x$has_forbidden_chars" != x; then 25059 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25060 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25061 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25062 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25063 # Going to short mode and back again did indeed matter. Since short mode is 25064 # case insensitive, let's make it lowercase to improve readability. 25065 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25066 # Now convert it back to Unix-style (cygpath) 25067 input_path=`$CYGPATH -u "$shortmode_path"` 25068 new_path="$input_path" 25069 fi 25070 fi 25071 25072 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25073 if test "x$test_cygdrive_prefix" = x; then 25074 # As a simple fix, exclude /usr/bin since it's not a real path. 25075 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25076 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25077 # a path prefixed by /cygdrive for fixpath to work. 25078 new_path="$CYGWIN_ROOT_PATH$input_path" 25079 fi 25080 fi 25081 25082 25083 if test "x$path" != "x$new_path"; then 25084 BOOT_JDK="$new_path" 25085 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25086 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25087 fi 25088 25089 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25090 25091 path="$BOOT_JDK" 25092 has_colon=`$ECHO $path | $GREP ^.:` 25093 new_path="$path" 25094 if test "x$has_colon" = x; then 25095 # Not in mixed or Windows style, start by that. 25096 new_path=`cmd //c echo $path` 25097 fi 25098 25099 25100 input_path="$new_path" 25101 # Check if we need to convert this using DOS-style short mode. If the path 25102 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25103 # take no chances and rewrite it. 25104 # Note: m4 eats our [], so we need to use [ and ] instead. 25105 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25106 if test "x$has_forbidden_chars" != x; then 25107 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25108 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25109 fi 25110 25111 25112 windows_path="$new_path" 25113 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25114 unix_path=`$CYGPATH -u "$windows_path"` 25115 new_path="$unix_path" 25116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25117 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25118 new_path="$unix_path" 25119 fi 25120 25121 if test "x$path" != "x$new_path"; then 25122 BOOT_JDK="$new_path" 25123 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25124 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25125 fi 25126 25127 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25128 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25129 25130 else 25131 # We're on a unix platform. Hooray! :) 25132 path="$BOOT_JDK" 25133 has_space=`$ECHO "$path" | $GREP " "` 25134 if test "x$has_space" != x; then 25135 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25136 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25137 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25138 fi 25139 25140 # Use eval to expand a potential ~ 25141 eval path="$path" 25142 if test ! -f "$path" && test ! -d "$path"; then 25143 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25144 fi 25145 25146 if test -d "$path"; then 25147 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25148 else 25149 dir="`$DIRNAME "$path"`" 25150 base="`$BASENAME "$path"`" 25151 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25152 fi 25153 fi 25154 fi 25155 25156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25157 $as_echo_n "checking for Boot JDK... " >&6; } 25158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25159 $as_echo "$BOOT_JDK" >&6; } 25160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25161 $as_echo_n "checking Boot JDK version... " >&6; } 25162 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25164 $as_echo "$BOOT_JDK_VERSION" >&6; } 25165 fi # end check jdk version 25166 fi # end check javac 25167 fi # end check java 25168 fi # end check boot jdk found 25169 fi 25170 25171 # If that did not work out (e.g. too old), try explicit versions instead 25172 25173 if test "x$BOOT_JDK_FOUND" = xno; then 25174 # Now execute the test 25175 25176 if test -x /usr/libexec/java_home; then 25177 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 25178 BOOT_JDK_FOUND=maybe 25179 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 25180 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 25181 fi 25182 25183 25184 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25185 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25186 # Do we have a bin/java? 25187 if test ! -x "$BOOT_JDK/bin/java"; then 25188 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25189 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25190 BOOT_JDK_FOUND=no 25191 else 25192 # Do we have a bin/javac? 25193 if test ! -x "$BOOT_JDK/bin/javac"; then 25194 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25195 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25196 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25197 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25198 BOOT_JDK_FOUND=no 25199 else 25200 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25201 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25202 25203 # Extra M4 quote needed to protect [] in grep expression. 25204 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25205 if test "x$FOUND_CORRECT_VERSION" = x; then 25206 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25207 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25208 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25209 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25210 BOOT_JDK_FOUND=no 25211 else 25212 # We're done! :-) 25213 BOOT_JDK_FOUND=yes 25214 25215 # Only process if variable expands to non-empty 25216 25217 if test "x$BOOT_JDK" != x; then 25218 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25219 25220 # Input might be given as Windows format, start by converting to 25221 # unix format. 25222 path="$BOOT_JDK" 25223 new_path=`$CYGPATH -u "$path"` 25224 25225 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25226 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25227 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25228 # "foo.exe" is OK but "foo" is an error. 25229 # 25230 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25231 # It is also a way to make sure we got the proper file name for the real test later on. 25232 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25233 if test "x$test_shortpath" = x; then 25234 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25235 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25236 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25237 fi 25238 25239 # Call helper function which possibly converts this using DOS-style short mode. 25240 # If so, the updated path is stored in $new_path. 25241 25242 input_path="$new_path" 25243 # Check if we need to convert this using DOS-style short mode. If the path 25244 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25245 # take no chances and rewrite it. 25246 # Note: m4 eats our [], so we need to use [ and ] instead. 25247 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25248 if test "x$has_forbidden_chars" != x; then 25249 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25250 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25251 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25252 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25253 # Going to short mode and back again did indeed matter. Since short mode is 25254 # case insensitive, let's make it lowercase to improve readability. 25255 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25256 # Now convert it back to Unix-style (cygpath) 25257 input_path=`$CYGPATH -u "$shortmode_path"` 25258 new_path="$input_path" 25259 fi 25260 fi 25261 25262 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25263 if test "x$test_cygdrive_prefix" = x; then 25264 # As a simple fix, exclude /usr/bin since it's not a real path. 25265 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25266 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25267 # a path prefixed by /cygdrive for fixpath to work. 25268 new_path="$CYGWIN_ROOT_PATH$input_path" 25269 fi 25270 fi 25271 25272 25273 if test "x$path" != "x$new_path"; then 25274 BOOT_JDK="$new_path" 25275 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25276 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25277 fi 25278 25279 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25280 25281 path="$BOOT_JDK" 25282 has_colon=`$ECHO $path | $GREP ^.:` 25283 new_path="$path" 25284 if test "x$has_colon" = x; then 25285 # Not in mixed or Windows style, start by that. 25286 new_path=`cmd //c echo $path` 25287 fi 25288 25289 25290 input_path="$new_path" 25291 # Check if we need to convert this using DOS-style short mode. If the path 25292 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25293 # take no chances and rewrite it. 25294 # Note: m4 eats our [], so we need to use [ and ] instead. 25295 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25296 if test "x$has_forbidden_chars" != x; then 25297 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25298 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25299 fi 25300 25301 25302 windows_path="$new_path" 25303 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25304 unix_path=`$CYGPATH -u "$windows_path"` 25305 new_path="$unix_path" 25306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25307 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25308 new_path="$unix_path" 25309 fi 25310 25311 if test "x$path" != "x$new_path"; then 25312 BOOT_JDK="$new_path" 25313 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25314 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25315 fi 25316 25317 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25318 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25319 25320 else 25321 # We're on a unix platform. Hooray! :) 25322 path="$BOOT_JDK" 25323 has_space=`$ECHO "$path" | $GREP " "` 25324 if test "x$has_space" != x; then 25325 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25326 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25327 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25328 fi 25329 25330 # Use eval to expand a potential ~ 25331 eval path="$path" 25332 if test ! -f "$path" && test ! -d "$path"; then 25333 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25334 fi 25335 25336 if test -d "$path"; then 25337 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25338 else 25339 dir="`$DIRNAME "$path"`" 25340 base="`$BASENAME "$path"`" 25341 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25342 fi 25343 fi 25344 fi 25345 25346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25347 $as_echo_n "checking for Boot JDK... " >&6; } 25348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25349 $as_echo "$BOOT_JDK" >&6; } 25350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25351 $as_echo_n "checking Boot JDK version... " >&6; } 25352 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25354 $as_echo "$BOOT_JDK_VERSION" >&6; } 25355 fi # end check jdk version 25356 fi # end check javac 25357 fi # end check java 25358 fi # end check boot jdk found 25359 fi 25360 25361 25362 if test "x$BOOT_JDK_FOUND" = xno; then 25363 # Now execute the test 25364 25365 if test -x /usr/libexec/java_home; then 25366 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 25367 BOOT_JDK_FOUND=maybe 25368 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 25369 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 25370 fi 25371 25372 25373 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25374 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25375 # Do we have a bin/java? 25376 if test ! -x "$BOOT_JDK/bin/java"; then 25377 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25378 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25379 BOOT_JDK_FOUND=no 25380 else 25381 # Do we have a bin/javac? 25382 if test ! -x "$BOOT_JDK/bin/javac"; then 25383 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25384 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25385 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25386 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25387 BOOT_JDK_FOUND=no 25388 else 25389 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25390 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25391 25392 # Extra M4 quote needed to protect [] in grep expression. 25393 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25394 if test "x$FOUND_CORRECT_VERSION" = x; then 25395 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25396 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25397 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25398 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25399 BOOT_JDK_FOUND=no 25400 else 25401 # We're done! :-) 25402 BOOT_JDK_FOUND=yes 25403 25404 # Only process if variable expands to non-empty 25405 25406 if test "x$BOOT_JDK" != x; then 25407 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25408 25409 # Input might be given as Windows format, start by converting to 25410 # unix format. 25411 path="$BOOT_JDK" 25412 new_path=`$CYGPATH -u "$path"` 25413 25414 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25415 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25416 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25417 # "foo.exe" is OK but "foo" is an error. 25418 # 25419 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25420 # It is also a way to make sure we got the proper file name for the real test later on. 25421 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25422 if test "x$test_shortpath" = x; then 25423 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25424 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25425 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25426 fi 25427 25428 # Call helper function which possibly converts this using DOS-style short mode. 25429 # If so, the updated path is stored in $new_path. 25430 25431 input_path="$new_path" 25432 # Check if we need to convert this using DOS-style short mode. If the path 25433 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25434 # take no chances and rewrite it. 25435 # Note: m4 eats our [], so we need to use [ and ] instead. 25436 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25437 if test "x$has_forbidden_chars" != x; then 25438 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25439 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25440 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25441 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25442 # Going to short mode and back again did indeed matter. Since short mode is 25443 # case insensitive, let's make it lowercase to improve readability. 25444 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25445 # Now convert it back to Unix-style (cygpath) 25446 input_path=`$CYGPATH -u "$shortmode_path"` 25447 new_path="$input_path" 25448 fi 25449 fi 25450 25451 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25452 if test "x$test_cygdrive_prefix" = x; then 25453 # As a simple fix, exclude /usr/bin since it's not a real path. 25454 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25455 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25456 # a path prefixed by /cygdrive for fixpath to work. 25457 new_path="$CYGWIN_ROOT_PATH$input_path" 25458 fi 25459 fi 25460 25461 25462 if test "x$path" != "x$new_path"; then 25463 BOOT_JDK="$new_path" 25464 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25465 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25466 fi 25467 25468 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25469 25470 path="$BOOT_JDK" 25471 has_colon=`$ECHO $path | $GREP ^.:` 25472 new_path="$path" 25473 if test "x$has_colon" = x; then 25474 # Not in mixed or Windows style, start by that. 25475 new_path=`cmd //c echo $path` 25476 fi 25477 25478 25479 input_path="$new_path" 25480 # Check if we need to convert this using DOS-style short mode. If the path 25481 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25482 # take no chances and rewrite it. 25483 # Note: m4 eats our [], so we need to use [ and ] instead. 25484 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25485 if test "x$has_forbidden_chars" != x; then 25486 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25487 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25488 fi 25489 25490 25491 windows_path="$new_path" 25492 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25493 unix_path=`$CYGPATH -u "$windows_path"` 25494 new_path="$unix_path" 25495 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25496 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25497 new_path="$unix_path" 25498 fi 25499 25500 if test "x$path" != "x$new_path"; then 25501 BOOT_JDK="$new_path" 25502 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25503 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25504 fi 25505 25506 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25507 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25508 25509 else 25510 # We're on a unix platform. Hooray! :) 25511 path="$BOOT_JDK" 25512 has_space=`$ECHO "$path" | $GREP " "` 25513 if test "x$has_space" != x; then 25514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25515 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25516 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25517 fi 25518 25519 # Use eval to expand a potential ~ 25520 eval path="$path" 25521 if test ! -f "$path" && test ! -d "$path"; then 25522 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25523 fi 25524 25525 if test -d "$path"; then 25526 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25527 else 25528 dir="`$DIRNAME "$path"`" 25529 base="`$BASENAME "$path"`" 25530 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25531 fi 25532 fi 25533 fi 25534 25535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25536 $as_echo_n "checking for Boot JDK... " >&6; } 25537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25538 $as_echo "$BOOT_JDK" >&6; } 25539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25540 $as_echo_n "checking Boot JDK version... " >&6; } 25541 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25543 $as_echo "$BOOT_JDK_VERSION" >&6; } 25544 fi # end check jdk version 25545 fi # end check javac 25546 fi # end check java 25547 fi # end check boot jdk found 25548 fi 25549 25550 25551 if test "x$BOOT_JDK_FOUND" = xno; then 25552 # Now execute the test 25553 25554 if test -x /usr/libexec/java_home; then 25555 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 25556 BOOT_JDK_FOUND=maybe 25557 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 25558 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 25559 fi 25560 25561 25562 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25563 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25564 # Do we have a bin/java? 25565 if test ! -x "$BOOT_JDK/bin/java"; then 25566 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25567 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25568 BOOT_JDK_FOUND=no 25569 else 25570 # Do we have a bin/javac? 25571 if test ! -x "$BOOT_JDK/bin/javac"; then 25572 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25573 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25574 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25575 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25576 BOOT_JDK_FOUND=no 25577 else 25578 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25579 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25580 25581 # Extra M4 quote needed to protect [] in grep expression. 25582 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25583 if test "x$FOUND_CORRECT_VERSION" = x; then 25584 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25585 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25586 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25587 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25588 BOOT_JDK_FOUND=no 25589 else 25590 # We're done! :-) 25591 BOOT_JDK_FOUND=yes 25592 25593 # Only process if variable expands to non-empty 25594 25595 if test "x$BOOT_JDK" != x; then 25596 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25597 25598 # Input might be given as Windows format, start by converting to 25599 # unix format. 25600 path="$BOOT_JDK" 25601 new_path=`$CYGPATH -u "$path"` 25602 25603 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25604 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25605 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25606 # "foo.exe" is OK but "foo" is an error. 25607 # 25608 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25609 # It is also a way to make sure we got the proper file name for the real test later on. 25610 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25611 if test "x$test_shortpath" = x; then 25612 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25613 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25614 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25615 fi 25616 25617 # Call helper function which possibly converts this using DOS-style short mode. 25618 # If so, the updated path is stored in $new_path. 25619 25620 input_path="$new_path" 25621 # Check if we need to convert this using DOS-style short mode. If the path 25622 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25623 # take no chances and rewrite it. 25624 # Note: m4 eats our [], so we need to use [ and ] instead. 25625 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25626 if test "x$has_forbidden_chars" != x; then 25627 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25628 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25629 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25630 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25631 # Going to short mode and back again did indeed matter. Since short mode is 25632 # case insensitive, let's make it lowercase to improve readability. 25633 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25634 # Now convert it back to Unix-style (cygpath) 25635 input_path=`$CYGPATH -u "$shortmode_path"` 25636 new_path="$input_path" 25637 fi 25638 fi 25639 25640 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25641 if test "x$test_cygdrive_prefix" = x; then 25642 # As a simple fix, exclude /usr/bin since it's not a real path. 25643 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25644 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25645 # a path prefixed by /cygdrive for fixpath to work. 25646 new_path="$CYGWIN_ROOT_PATH$input_path" 25647 fi 25648 fi 25649 25650 25651 if test "x$path" != "x$new_path"; then 25652 BOOT_JDK="$new_path" 25653 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25654 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25655 fi 25656 25657 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25658 25659 path="$BOOT_JDK" 25660 has_colon=`$ECHO $path | $GREP ^.:` 25661 new_path="$path" 25662 if test "x$has_colon" = x; then 25663 # Not in mixed or Windows style, start by that. 25664 new_path=`cmd //c echo $path` 25665 fi 25666 25667 25668 input_path="$new_path" 25669 # Check if we need to convert this using DOS-style short mode. If the path 25670 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25671 # take no chances and rewrite it. 25672 # Note: m4 eats our [], so we need to use [ and ] instead. 25673 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25674 if test "x$has_forbidden_chars" != x; then 25675 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25676 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25677 fi 25678 25679 25680 windows_path="$new_path" 25681 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25682 unix_path=`$CYGPATH -u "$windows_path"` 25683 new_path="$unix_path" 25684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25685 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25686 new_path="$unix_path" 25687 fi 25688 25689 if test "x$path" != "x$new_path"; then 25690 BOOT_JDK="$new_path" 25691 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25692 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25693 fi 25694 25695 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25696 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25697 25698 else 25699 # We're on a unix platform. Hooray! :) 25700 path="$BOOT_JDK" 25701 has_space=`$ECHO "$path" | $GREP " "` 25702 if test "x$has_space" != x; then 25703 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25704 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25705 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25706 fi 25707 25708 # Use eval to expand a potential ~ 25709 eval path="$path" 25710 if test ! -f "$path" && test ! -d "$path"; then 25711 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25712 fi 25713 25714 if test -d "$path"; then 25715 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25716 else 25717 dir="`$DIRNAME "$path"`" 25718 base="`$BASENAME "$path"`" 25719 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25720 fi 25721 fi 25722 fi 25723 25724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25725 $as_echo_n "checking for Boot JDK... " >&6; } 25726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25727 $as_echo "$BOOT_JDK" >&6; } 25728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25729 $as_echo_n "checking Boot JDK version... " >&6; } 25730 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25732 $as_echo "$BOOT_JDK_VERSION" >&6; } 25733 fi # end check jdk version 25734 fi # end check javac 25735 fi # end check java 25736 fi # end check boot jdk found 25737 fi 25738 25739 fi 25740 25741 25742 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25743 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25744 # Do we have a bin/java? 25745 if test ! -x "$BOOT_JDK/bin/java"; then 25746 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25747 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25748 BOOT_JDK_FOUND=no 25749 else 25750 # Do we have a bin/javac? 25751 if test ! -x "$BOOT_JDK/bin/javac"; then 25752 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25753 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25754 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25755 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25756 BOOT_JDK_FOUND=no 25757 else 25758 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25759 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25760 25761 # Extra M4 quote needed to protect [] in grep expression. 25762 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25763 if test "x$FOUND_CORRECT_VERSION" = x; then 25764 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25765 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25766 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25767 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25768 BOOT_JDK_FOUND=no 25769 else 25770 # We're done! :-) 25771 BOOT_JDK_FOUND=yes 25772 25773 # Only process if variable expands to non-empty 25774 25775 if test "x$BOOT_JDK" != x; then 25776 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25777 25778 # Input might be given as Windows format, start by converting to 25779 # unix format. 25780 path="$BOOT_JDK" 25781 new_path=`$CYGPATH -u "$path"` 25782 25783 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25784 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25785 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25786 # "foo.exe" is OK but "foo" is an error. 25787 # 25788 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25789 # It is also a way to make sure we got the proper file name for the real test later on. 25790 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25791 if test "x$test_shortpath" = x; then 25792 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25793 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25794 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25795 fi 25796 25797 # Call helper function which possibly converts this using DOS-style short mode. 25798 # If so, the updated path is stored in $new_path. 25799 25800 input_path="$new_path" 25801 # Check if we need to convert this using DOS-style short mode. If the path 25802 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25803 # take no chances and rewrite it. 25804 # Note: m4 eats our [], so we need to use [ and ] instead. 25805 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25806 if test "x$has_forbidden_chars" != x; then 25807 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25808 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25809 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25810 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25811 # Going to short mode and back again did indeed matter. Since short mode is 25812 # case insensitive, let's make it lowercase to improve readability. 25813 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25814 # Now convert it back to Unix-style (cygpath) 25815 input_path=`$CYGPATH -u "$shortmode_path"` 25816 new_path="$input_path" 25817 fi 25818 fi 25819 25820 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25821 if test "x$test_cygdrive_prefix" = x; then 25822 # As a simple fix, exclude /usr/bin since it's not a real path. 25823 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25824 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25825 # a path prefixed by /cygdrive for fixpath to work. 25826 new_path="$CYGWIN_ROOT_PATH$input_path" 25827 fi 25828 fi 25829 25830 25831 if test "x$path" != "x$new_path"; then 25832 BOOT_JDK="$new_path" 25833 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25834 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25835 fi 25836 25837 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25838 25839 path="$BOOT_JDK" 25840 has_colon=`$ECHO $path | $GREP ^.:` 25841 new_path="$path" 25842 if test "x$has_colon" = x; then 25843 # Not in mixed or Windows style, start by that. 25844 new_path=`cmd //c echo $path` 25845 fi 25846 25847 25848 input_path="$new_path" 25849 # Check if we need to convert this using DOS-style short mode. If the path 25850 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25851 # take no chances and rewrite it. 25852 # Note: m4 eats our [], so we need to use [ and ] instead. 25853 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25854 if test "x$has_forbidden_chars" != x; then 25855 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25856 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25857 fi 25858 25859 25860 windows_path="$new_path" 25861 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25862 unix_path=`$CYGPATH -u "$windows_path"` 25863 new_path="$unix_path" 25864 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25865 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25866 new_path="$unix_path" 25867 fi 25868 25869 if test "x$path" != "x$new_path"; then 25870 BOOT_JDK="$new_path" 25871 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25872 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25873 fi 25874 25875 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25876 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25877 25878 else 25879 # We're on a unix platform. Hooray! :) 25880 path="$BOOT_JDK" 25881 has_space=`$ECHO "$path" | $GREP " "` 25882 if test "x$has_space" != x; then 25883 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25884 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25885 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25886 fi 25887 25888 # Use eval to expand a potential ~ 25889 eval path="$path" 25890 if test ! -f "$path" && test ! -d "$path"; then 25891 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25892 fi 25893 25894 if test -d "$path"; then 25895 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25896 else 25897 dir="`$DIRNAME "$path"`" 25898 base="`$BASENAME "$path"`" 25899 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25900 fi 25901 fi 25902 fi 25903 25904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25905 $as_echo_n "checking for Boot JDK... " >&6; } 25906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25907 $as_echo "$BOOT_JDK" >&6; } 25908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25909 $as_echo_n "checking Boot JDK version... " >&6; } 25910 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25912 $as_echo "$BOOT_JDK_VERSION" >&6; } 25913 fi # end check jdk version 25914 fi # end check javac 25915 fi # end check java 25916 fi # end check boot jdk found 25917 fi 25918 25919 25920 # Test: Is $JAVA_HOME set? 25921 25922 if test "x$BOOT_JDK_FOUND" = xno; then 25923 # Now execute the test 25924 25925 if test "x$JAVA_HOME" != x; then 25926 JAVA_HOME_PROCESSED="$JAVA_HOME" 25927 25928 # Only process if variable expands to non-empty 25929 25930 if test "x$JAVA_HOME_PROCESSED" != x; then 25931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25932 25933 # Input might be given as Windows format, start by converting to 25934 # unix format. 25935 path="$JAVA_HOME_PROCESSED" 25936 new_path=`$CYGPATH -u "$path"` 25937 25938 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25939 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25940 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25941 # "foo.exe" is OK but "foo" is an error. 25942 # 25943 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25944 # It is also a way to make sure we got the proper file name for the real test later on. 25945 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25946 if test "x$test_shortpath" = x; then 25947 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 25948 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 25949 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 25950 fi 25951 25952 # Call helper function which possibly converts this using DOS-style short mode. 25953 # If so, the updated path is stored in $new_path. 25954 25955 input_path="$new_path" 25956 # Check if we need to convert this using DOS-style short mode. If the path 25957 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25958 # take no chances and rewrite it. 25959 # Note: m4 eats our [], so we need to use [ and ] instead. 25960 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25961 if test "x$has_forbidden_chars" != x; then 25962 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25963 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25964 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25965 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25966 # Going to short mode and back again did indeed matter. Since short mode is 25967 # case insensitive, let's make it lowercase to improve readability. 25968 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25969 # Now convert it back to Unix-style (cygpath) 25970 input_path=`$CYGPATH -u "$shortmode_path"` 25971 new_path="$input_path" 25972 fi 25973 fi 25974 25975 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25976 if test "x$test_cygdrive_prefix" = x; then 25977 # As a simple fix, exclude /usr/bin since it's not a real path. 25978 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25979 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25980 # a path prefixed by /cygdrive for fixpath to work. 25981 new_path="$CYGWIN_ROOT_PATH$input_path" 25982 fi 25983 fi 25984 25985 25986 if test "x$path" != "x$new_path"; then 25987 JAVA_HOME_PROCESSED="$new_path" 25988 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 25989 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 25990 fi 25991 25992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25993 25994 path="$JAVA_HOME_PROCESSED" 25995 has_colon=`$ECHO $path | $GREP ^.:` 25996 new_path="$path" 25997 if test "x$has_colon" = x; then 25998 # Not in mixed or Windows style, start by that. 25999 new_path=`cmd //c echo $path` 26000 fi 26001 26002 26003 input_path="$new_path" 26004 # Check if we need to convert this using DOS-style short mode. If the path 26005 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26006 # take no chances and rewrite it. 26007 # Note: m4 eats our [], so we need to use [ and ] instead. 26008 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26009 if test "x$has_forbidden_chars" != x; then 26010 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26011 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26012 fi 26013 26014 26015 windows_path="$new_path" 26016 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26017 unix_path=`$CYGPATH -u "$windows_path"` 26018 new_path="$unix_path" 26019 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26020 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26021 new_path="$unix_path" 26022 fi 26023 26024 if test "x$path" != "x$new_path"; then 26025 JAVA_HOME_PROCESSED="$new_path" 26026 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26027 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26028 fi 26029 26030 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26031 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26032 26033 else 26034 # We're on a unix platform. Hooray! :) 26035 path="$JAVA_HOME_PROCESSED" 26036 has_space=`$ECHO "$path" | $GREP " "` 26037 if test "x$has_space" != x; then 26038 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26039 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26040 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26041 fi 26042 26043 # Use eval to expand a potential ~ 26044 eval path="$path" 26045 if test ! -f "$path" && test ! -d "$path"; then 26046 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26047 fi 26048 26049 if test -d "$path"; then 26050 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26051 else 26052 dir="`$DIRNAME "$path"`" 26053 base="`$BASENAME "$path"`" 26054 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26055 fi 26056 fi 26057 fi 26058 26059 if test ! -d "$JAVA_HOME_PROCESSED"; then 26060 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26061 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26062 else 26063 # Aha, the user has set a JAVA_HOME 26064 # let us use that as the Boot JDK. 26065 BOOT_JDK="$JAVA_HOME_PROCESSED" 26066 BOOT_JDK_FOUND=maybe 26067 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26068 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26069 fi 26070 fi 26071 26072 26073 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26074 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26075 # Do we have a bin/java? 26076 if test ! -x "$BOOT_JDK/bin/java"; then 26077 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26078 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26079 BOOT_JDK_FOUND=no 26080 else 26081 # Do we have a bin/javac? 26082 if test ! -x "$BOOT_JDK/bin/javac"; then 26083 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26084 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26085 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26086 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26087 BOOT_JDK_FOUND=no 26088 else 26089 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26090 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26091 26092 # Extra M4 quote needed to protect [] in grep expression. 26093 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26094 if test "x$FOUND_CORRECT_VERSION" = x; then 26095 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26096 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26097 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26098 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26099 BOOT_JDK_FOUND=no 26100 else 26101 # We're done! :-) 26102 BOOT_JDK_FOUND=yes 26103 26104 # Only process if variable expands to non-empty 26105 26106 if test "x$BOOT_JDK" != x; then 26107 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26108 26109 # Input might be given as Windows format, start by converting to 26110 # unix format. 26111 path="$BOOT_JDK" 26112 new_path=`$CYGPATH -u "$path"` 26113 26114 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26115 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26116 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26117 # "foo.exe" is OK but "foo" is an error. 26118 # 26119 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26120 # It is also a way to make sure we got the proper file name for the real test later on. 26121 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26122 if test "x$test_shortpath" = x; then 26123 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26124 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26125 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26126 fi 26127 26128 # Call helper function which possibly converts this using DOS-style short mode. 26129 # If so, the updated path is stored in $new_path. 26130 26131 input_path="$new_path" 26132 # Check if we need to convert this using DOS-style short mode. If the path 26133 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26134 # take no chances and rewrite it. 26135 # Note: m4 eats our [], so we need to use [ and ] instead. 26136 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26137 if test "x$has_forbidden_chars" != x; then 26138 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26139 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26140 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26141 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26142 # Going to short mode and back again did indeed matter. Since short mode is 26143 # case insensitive, let's make it lowercase to improve readability. 26144 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26145 # Now convert it back to Unix-style (cygpath) 26146 input_path=`$CYGPATH -u "$shortmode_path"` 26147 new_path="$input_path" 26148 fi 26149 fi 26150 26151 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26152 if test "x$test_cygdrive_prefix" = x; then 26153 # As a simple fix, exclude /usr/bin since it's not a real path. 26154 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26155 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26156 # a path prefixed by /cygdrive for fixpath to work. 26157 new_path="$CYGWIN_ROOT_PATH$input_path" 26158 fi 26159 fi 26160 26161 26162 if test "x$path" != "x$new_path"; then 26163 BOOT_JDK="$new_path" 26164 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26165 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26166 fi 26167 26168 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26169 26170 path="$BOOT_JDK" 26171 has_colon=`$ECHO $path | $GREP ^.:` 26172 new_path="$path" 26173 if test "x$has_colon" = x; then 26174 # Not in mixed or Windows style, start by that. 26175 new_path=`cmd //c echo $path` 26176 fi 26177 26178 26179 input_path="$new_path" 26180 # Check if we need to convert this using DOS-style short mode. If the path 26181 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26182 # take no chances and rewrite it. 26183 # Note: m4 eats our [], so we need to use [ and ] instead. 26184 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26185 if test "x$has_forbidden_chars" != x; then 26186 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26187 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26188 fi 26189 26190 26191 windows_path="$new_path" 26192 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26193 unix_path=`$CYGPATH -u "$windows_path"` 26194 new_path="$unix_path" 26195 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26196 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26197 new_path="$unix_path" 26198 fi 26199 26200 if test "x$path" != "x$new_path"; then 26201 BOOT_JDK="$new_path" 26202 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26203 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26204 fi 26205 26206 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26207 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26208 26209 else 26210 # We're on a unix platform. Hooray! :) 26211 path="$BOOT_JDK" 26212 has_space=`$ECHO "$path" | $GREP " "` 26213 if test "x$has_space" != x; then 26214 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26215 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26216 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26217 fi 26218 26219 # Use eval to expand a potential ~ 26220 eval path="$path" 26221 if test ! -f "$path" && test ! -d "$path"; then 26222 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26223 fi 26224 26225 if test -d "$path"; then 26226 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26227 else 26228 dir="`$DIRNAME "$path"`" 26229 base="`$BASENAME "$path"`" 26230 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26231 fi 26232 fi 26233 fi 26234 26235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26236 $as_echo_n "checking for Boot JDK... " >&6; } 26237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26238 $as_echo "$BOOT_JDK" >&6; } 26239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26240 $as_echo_n "checking Boot JDK version... " >&6; } 26241 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26243 $as_echo "$BOOT_JDK_VERSION" >&6; } 26244 fi # end check jdk version 26245 fi # end check javac 26246 fi # end check java 26247 fi # end check boot jdk found 26248 fi 26249 26250 26251 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 26252 26253 if test "x$BOOT_JDK_FOUND" = xno; then 26254 # Now execute the test 26255 26256 # Extract the first word of "javac", so it can be a program name with args. 26257 set dummy javac; ac_word=$2 26258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26259 $as_echo_n "checking for $ac_word... " >&6; } 26260 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 26261 $as_echo_n "(cached) " >&6 26262 else 26263 case $JAVAC_CHECK in 26264 [\\/]* | ?:[\\/]*) 26265 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 26266 ;; 26267 *) 26268 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26269 for as_dir in $PATH 26270 do 26271 IFS=$as_save_IFS 26272 test -z "$as_dir" && as_dir=. 26273 for ac_exec_ext in '' $ac_executable_extensions; do 26274 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26275 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 26276 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26277 break 2 26278 fi 26279 done 26280 done 26281 IFS=$as_save_IFS 26282 26283 ;; 26284 esac 26285 fi 26286 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 26287 if test -n "$JAVAC_CHECK"; then 26288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 26289 $as_echo "$JAVAC_CHECK" >&6; } 26290 else 26291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26292 $as_echo "no" >&6; } 26293 fi 26294 26295 26296 # Extract the first word of "java", so it can be a program name with args. 26297 set dummy java; ac_word=$2 26298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26299 $as_echo_n "checking for $ac_word... " >&6; } 26300 if ${ac_cv_path_JAVA_CHECK+:} false; then : 26301 $as_echo_n "(cached) " >&6 26302 else 26303 case $JAVA_CHECK in 26304 [\\/]* | ?:[\\/]*) 26305 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 26306 ;; 26307 *) 26308 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26309 for as_dir in $PATH 26310 do 26311 IFS=$as_save_IFS 26312 test -z "$as_dir" && as_dir=. 26313 for ac_exec_ext in '' $ac_executable_extensions; do 26314 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26315 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 26316 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26317 break 2 26318 fi 26319 done 26320 done 26321 IFS=$as_save_IFS 26322 26323 ;; 26324 esac 26325 fi 26326 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 26327 if test -n "$JAVA_CHECK"; then 26328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 26329 $as_echo "$JAVA_CHECK" >&6; } 26330 else 26331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26332 $as_echo "no" >&6; } 26333 fi 26334 26335 26336 BINARY="$JAVAC_CHECK" 26337 if test "x$JAVAC_CHECK" = x; then 26338 BINARY="$JAVA_CHECK" 26339 fi 26340 if test "x$BINARY" != x; then 26341 # So there is a java(c) binary, it might be part of a JDK. 26342 # Lets find the JDK/JRE directory by following symbolic links. 26343 # Linux/GNU systems often have links from /usr/bin/java to 26344 # /etc/alternatives/java to the real JDK binary. 26345 26346 if test "x$OPENJDK_BUILD_OS" != xwindows; then 26347 # Follow a chain of symbolic links. Use readlink 26348 # where it exists, else fall back to horribly 26349 # complicated shell code. 26350 if test "x$READLINK_TESTED" != yes; then 26351 # On MacOSX there is a readlink tool with a different 26352 # purpose than the GNU readlink tool. Check the found readlink. 26353 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 26354 if test "x$ISGNU" = x; then 26355 # A readlink that we do not know how to use. 26356 # Are there other non-GNU readlinks out there? 26357 READLINK_TESTED=yes 26358 READLINK= 26359 fi 26360 fi 26361 26362 if test "x$READLINK" != x; then 26363 BINARY=`$READLINK -f $BINARY` 26364 else 26365 # Save the current directory for restoring afterwards 26366 STARTDIR=$PWD 26367 COUNTER=0 26368 sym_link_dir=`$DIRNAME $BINARY` 26369 sym_link_file=`$BASENAME $BINARY` 26370 cd $sym_link_dir 26371 # Use -P flag to resolve symlinks in directories. 26372 cd `$THEPWDCMD -P` 26373 sym_link_dir=`$THEPWDCMD -P` 26374 # Resolve file symlinks 26375 while test $COUNTER -lt 20; do 26376 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 26377 if test "x$ISLINK" == x; then 26378 # This is not a symbolic link! We are done! 26379 break 26380 fi 26381 # Again resolve directory symlinks since the target of the just found 26382 # link could be in a different directory 26383 cd `$DIRNAME $ISLINK` 26384 sym_link_dir=`$THEPWDCMD -P` 26385 sym_link_file=`$BASENAME $ISLINK` 26386 let COUNTER=COUNTER+1 26387 done 26388 cd $STARTDIR 26389 BINARY=$sym_link_dir/$sym_link_file 26390 fi 26391 fi 26392 26393 BOOT_JDK=`dirname "$BINARY"` 26394 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 26395 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 26396 # Looks like we found ourselves an JDK 26397 BOOT_JDK_FOUND=maybe 26398 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 26399 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 26400 fi 26401 fi 26402 26403 26404 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26405 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26406 # Do we have a bin/java? 26407 if test ! -x "$BOOT_JDK/bin/java"; then 26408 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26409 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26410 BOOT_JDK_FOUND=no 26411 else 26412 # Do we have a bin/javac? 26413 if test ! -x "$BOOT_JDK/bin/javac"; then 26414 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26415 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26416 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26417 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26418 BOOT_JDK_FOUND=no 26419 else 26420 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26421 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26422 26423 # Extra M4 quote needed to protect [] in grep expression. 26424 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26425 if test "x$FOUND_CORRECT_VERSION" = x; then 26426 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26427 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26428 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26429 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26430 BOOT_JDK_FOUND=no 26431 else 26432 # We're done! :-) 26433 BOOT_JDK_FOUND=yes 26434 26435 # Only process if variable expands to non-empty 26436 26437 if test "x$BOOT_JDK" != x; then 26438 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26439 26440 # Input might be given as Windows format, start by converting to 26441 # unix format. 26442 path="$BOOT_JDK" 26443 new_path=`$CYGPATH -u "$path"` 26444 26445 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26446 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26447 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26448 # "foo.exe" is OK but "foo" is an error. 26449 # 26450 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26451 # It is also a way to make sure we got the proper file name for the real test later on. 26452 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26453 if test "x$test_shortpath" = x; then 26454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26455 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26456 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26457 fi 26458 26459 # Call helper function which possibly converts this using DOS-style short mode. 26460 # If so, the updated path is stored in $new_path. 26461 26462 input_path="$new_path" 26463 # Check if we need to convert this using DOS-style short mode. If the path 26464 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26465 # take no chances and rewrite it. 26466 # Note: m4 eats our [], so we need to use [ and ] instead. 26467 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26468 if test "x$has_forbidden_chars" != x; then 26469 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26470 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26471 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26472 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26473 # Going to short mode and back again did indeed matter. Since short mode is 26474 # case insensitive, let's make it lowercase to improve readability. 26475 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26476 # Now convert it back to Unix-style (cygpath) 26477 input_path=`$CYGPATH -u "$shortmode_path"` 26478 new_path="$input_path" 26479 fi 26480 fi 26481 26482 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26483 if test "x$test_cygdrive_prefix" = x; then 26484 # As a simple fix, exclude /usr/bin since it's not a real path. 26485 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26486 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26487 # a path prefixed by /cygdrive for fixpath to work. 26488 new_path="$CYGWIN_ROOT_PATH$input_path" 26489 fi 26490 fi 26491 26492 26493 if test "x$path" != "x$new_path"; then 26494 BOOT_JDK="$new_path" 26495 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26496 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26497 fi 26498 26499 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26500 26501 path="$BOOT_JDK" 26502 has_colon=`$ECHO $path | $GREP ^.:` 26503 new_path="$path" 26504 if test "x$has_colon" = x; then 26505 # Not in mixed or Windows style, start by that. 26506 new_path=`cmd //c echo $path` 26507 fi 26508 26509 26510 input_path="$new_path" 26511 # Check if we need to convert this using DOS-style short mode. If the path 26512 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26513 # take no chances and rewrite it. 26514 # Note: m4 eats our [], so we need to use [ and ] instead. 26515 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26516 if test "x$has_forbidden_chars" != x; then 26517 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26518 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26519 fi 26520 26521 26522 windows_path="$new_path" 26523 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26524 unix_path=`$CYGPATH -u "$windows_path"` 26525 new_path="$unix_path" 26526 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26527 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26528 new_path="$unix_path" 26529 fi 26530 26531 if test "x$path" != "x$new_path"; then 26532 BOOT_JDK="$new_path" 26533 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26534 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26535 fi 26536 26537 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26538 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26539 26540 else 26541 # We're on a unix platform. Hooray! :) 26542 path="$BOOT_JDK" 26543 has_space=`$ECHO "$path" | $GREP " "` 26544 if test "x$has_space" != x; then 26545 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26546 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26547 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26548 fi 26549 26550 # Use eval to expand a potential ~ 26551 eval path="$path" 26552 if test ! -f "$path" && test ! -d "$path"; then 26553 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26554 fi 26555 26556 if test -d "$path"; then 26557 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26558 else 26559 dir="`$DIRNAME "$path"`" 26560 base="`$BASENAME "$path"`" 26561 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26562 fi 26563 fi 26564 fi 26565 26566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26567 $as_echo_n "checking for Boot JDK... " >&6; } 26568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26569 $as_echo "$BOOT_JDK" >&6; } 26570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26571 $as_echo_n "checking Boot JDK version... " >&6; } 26572 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26574 $as_echo "$BOOT_JDK_VERSION" >&6; } 26575 fi # end check jdk version 26576 fi # end check javac 26577 fi # end check java 26578 fi # end check boot jdk found 26579 fi 26580 26581 26582 # Test: Is there a JDK installed in default, well-known locations? 26583 26584 if test "x$BOOT_JDK_FOUND" = xno; then 26585 # Now execute the test 26586 26587 if test "x$OPENJDK_TARGET_OS" = xwindows; then 26588 26589 if test "x$BOOT_JDK_FOUND" = xno; then 26590 # Now execute the test 26591 26592 if test "x$ProgramW6432" != x; then 26593 VIRTUAL_DIR="$ProgramW6432/Java" 26594 26595 windows_path="$VIRTUAL_DIR" 26596 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26597 unix_path=`$CYGPATH -u "$windows_path"` 26598 VIRTUAL_DIR="$unix_path" 26599 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26600 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26601 VIRTUAL_DIR="$unix_path" 26602 fi 26603 26604 26605 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26606 BOOT_JDK_SUFFIX="" 26607 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26608 if test "x$ALL_JDKS_FOUND" != x; then 26609 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26610 26611 if test "x$BOOT_JDK_FOUND" = xno; then 26612 # Now execute the test 26613 26614 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26615 if test -d "$BOOT_JDK"; then 26616 BOOT_JDK_FOUND=maybe 26617 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26618 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26619 fi 26620 26621 26622 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26623 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26624 # Do we have a bin/java? 26625 if test ! -x "$BOOT_JDK/bin/java"; then 26626 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26627 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26628 BOOT_JDK_FOUND=no 26629 else 26630 # Do we have a bin/javac? 26631 if test ! -x "$BOOT_JDK/bin/javac"; then 26632 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26633 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26634 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26635 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26636 BOOT_JDK_FOUND=no 26637 else 26638 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26639 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26640 26641 # Extra M4 quote needed to protect [] in grep expression. 26642 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26643 if test "x$FOUND_CORRECT_VERSION" = x; then 26644 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26645 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26646 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26647 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26648 BOOT_JDK_FOUND=no 26649 else 26650 # We're done! :-) 26651 BOOT_JDK_FOUND=yes 26652 26653 # Only process if variable expands to non-empty 26654 26655 if test "x$BOOT_JDK" != x; then 26656 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26657 26658 # Input might be given as Windows format, start by converting to 26659 # unix format. 26660 path="$BOOT_JDK" 26661 new_path=`$CYGPATH -u "$path"` 26662 26663 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26664 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26665 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26666 # "foo.exe" is OK but "foo" is an error. 26667 # 26668 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26669 # It is also a way to make sure we got the proper file name for the real test later on. 26670 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26671 if test "x$test_shortpath" = x; then 26672 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26673 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26674 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26675 fi 26676 26677 # Call helper function which possibly converts this using DOS-style short mode. 26678 # If so, the updated path is stored in $new_path. 26679 26680 input_path="$new_path" 26681 # Check if we need to convert this using DOS-style short mode. If the path 26682 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26683 # take no chances and rewrite it. 26684 # Note: m4 eats our [], so we need to use [ and ] instead. 26685 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26686 if test "x$has_forbidden_chars" != x; then 26687 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26688 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26689 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26690 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26691 # Going to short mode and back again did indeed matter. Since short mode is 26692 # case insensitive, let's make it lowercase to improve readability. 26693 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26694 # Now convert it back to Unix-style (cygpath) 26695 input_path=`$CYGPATH -u "$shortmode_path"` 26696 new_path="$input_path" 26697 fi 26698 fi 26699 26700 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26701 if test "x$test_cygdrive_prefix" = x; then 26702 # As a simple fix, exclude /usr/bin since it's not a real path. 26703 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26704 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26705 # a path prefixed by /cygdrive for fixpath to work. 26706 new_path="$CYGWIN_ROOT_PATH$input_path" 26707 fi 26708 fi 26709 26710 26711 if test "x$path" != "x$new_path"; then 26712 BOOT_JDK="$new_path" 26713 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26714 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26715 fi 26716 26717 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26718 26719 path="$BOOT_JDK" 26720 has_colon=`$ECHO $path | $GREP ^.:` 26721 new_path="$path" 26722 if test "x$has_colon" = x; then 26723 # Not in mixed or Windows style, start by that. 26724 new_path=`cmd //c echo $path` 26725 fi 26726 26727 26728 input_path="$new_path" 26729 # Check if we need to convert this using DOS-style short mode. If the path 26730 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26731 # take no chances and rewrite it. 26732 # Note: m4 eats our [], so we need to use [ and ] instead. 26733 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26734 if test "x$has_forbidden_chars" != x; then 26735 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26736 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26737 fi 26738 26739 26740 windows_path="$new_path" 26741 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26742 unix_path=`$CYGPATH -u "$windows_path"` 26743 new_path="$unix_path" 26744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26745 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26746 new_path="$unix_path" 26747 fi 26748 26749 if test "x$path" != "x$new_path"; then 26750 BOOT_JDK="$new_path" 26751 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26752 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26753 fi 26754 26755 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26756 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26757 26758 else 26759 # We're on a unix platform. Hooray! :) 26760 path="$BOOT_JDK" 26761 has_space=`$ECHO "$path" | $GREP " "` 26762 if test "x$has_space" != x; then 26763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26764 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26765 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26766 fi 26767 26768 # Use eval to expand a potential ~ 26769 eval path="$path" 26770 if test ! -f "$path" && test ! -d "$path"; then 26771 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26772 fi 26773 26774 if test -d "$path"; then 26775 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26776 else 26777 dir="`$DIRNAME "$path"`" 26778 base="`$BASENAME "$path"`" 26779 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26780 fi 26781 fi 26782 fi 26783 26784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26785 $as_echo_n "checking for Boot JDK... " >&6; } 26786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26787 $as_echo "$BOOT_JDK" >&6; } 26788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26789 $as_echo_n "checking Boot JDK version... " >&6; } 26790 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26792 $as_echo "$BOOT_JDK_VERSION" >&6; } 26793 fi # end check jdk version 26794 fi # end check javac 26795 fi # end check java 26796 fi # end check boot jdk found 26797 fi 26798 26799 done 26800 fi 26801 26802 fi 26803 26804 26805 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26806 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26807 # Do we have a bin/java? 26808 if test ! -x "$BOOT_JDK/bin/java"; then 26809 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26810 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26811 BOOT_JDK_FOUND=no 26812 else 26813 # Do we have a bin/javac? 26814 if test ! -x "$BOOT_JDK/bin/javac"; then 26815 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26816 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26817 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26818 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26819 BOOT_JDK_FOUND=no 26820 else 26821 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26822 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26823 26824 # Extra M4 quote needed to protect [] in grep expression. 26825 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26826 if test "x$FOUND_CORRECT_VERSION" = x; then 26827 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26828 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26829 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26830 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26831 BOOT_JDK_FOUND=no 26832 else 26833 # We're done! :-) 26834 BOOT_JDK_FOUND=yes 26835 26836 # Only process if variable expands to non-empty 26837 26838 if test "x$BOOT_JDK" != x; then 26839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26840 26841 # Input might be given as Windows format, start by converting to 26842 # unix format. 26843 path="$BOOT_JDK" 26844 new_path=`$CYGPATH -u "$path"` 26845 26846 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26847 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26848 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26849 # "foo.exe" is OK but "foo" is an error. 26850 # 26851 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26852 # It is also a way to make sure we got the proper file name for the real test later on. 26853 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26854 if test "x$test_shortpath" = x; then 26855 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26856 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26857 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26858 fi 26859 26860 # Call helper function which possibly converts this using DOS-style short mode. 26861 # If so, the updated path is stored in $new_path. 26862 26863 input_path="$new_path" 26864 # Check if we need to convert this using DOS-style short mode. If the path 26865 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26866 # take no chances and rewrite it. 26867 # Note: m4 eats our [], so we need to use [ and ] instead. 26868 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26869 if test "x$has_forbidden_chars" != x; then 26870 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26871 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26872 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26873 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26874 # Going to short mode and back again did indeed matter. Since short mode is 26875 # case insensitive, let's make it lowercase to improve readability. 26876 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26877 # Now convert it back to Unix-style (cygpath) 26878 input_path=`$CYGPATH -u "$shortmode_path"` 26879 new_path="$input_path" 26880 fi 26881 fi 26882 26883 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26884 if test "x$test_cygdrive_prefix" = x; then 26885 # As a simple fix, exclude /usr/bin since it's not a real path. 26886 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26887 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26888 # a path prefixed by /cygdrive for fixpath to work. 26889 new_path="$CYGWIN_ROOT_PATH$input_path" 26890 fi 26891 fi 26892 26893 26894 if test "x$path" != "x$new_path"; then 26895 BOOT_JDK="$new_path" 26896 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26897 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26898 fi 26899 26900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26901 26902 path="$BOOT_JDK" 26903 has_colon=`$ECHO $path | $GREP ^.:` 26904 new_path="$path" 26905 if test "x$has_colon" = x; then 26906 # Not in mixed or Windows style, start by that. 26907 new_path=`cmd //c echo $path` 26908 fi 26909 26910 26911 input_path="$new_path" 26912 # Check if we need to convert this using DOS-style short mode. If the path 26913 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26914 # take no chances and rewrite it. 26915 # Note: m4 eats our [], so we need to use [ and ] instead. 26916 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26917 if test "x$has_forbidden_chars" != x; then 26918 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26919 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26920 fi 26921 26922 26923 windows_path="$new_path" 26924 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26925 unix_path=`$CYGPATH -u "$windows_path"` 26926 new_path="$unix_path" 26927 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26928 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26929 new_path="$unix_path" 26930 fi 26931 26932 if test "x$path" != "x$new_path"; then 26933 BOOT_JDK="$new_path" 26934 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26935 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26936 fi 26937 26938 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26939 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26940 26941 else 26942 # We're on a unix platform. Hooray! :) 26943 path="$BOOT_JDK" 26944 has_space=`$ECHO "$path" | $GREP " "` 26945 if test "x$has_space" != x; then 26946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26947 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26948 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26949 fi 26950 26951 # Use eval to expand a potential ~ 26952 eval path="$path" 26953 if test ! -f "$path" && test ! -d "$path"; then 26954 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26955 fi 26956 26957 if test -d "$path"; then 26958 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26959 else 26960 dir="`$DIRNAME "$path"`" 26961 base="`$BASENAME "$path"`" 26962 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26963 fi 26964 fi 26965 fi 26966 26967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26968 $as_echo_n "checking for Boot JDK... " >&6; } 26969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26970 $as_echo "$BOOT_JDK" >&6; } 26971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26972 $as_echo_n "checking Boot JDK version... " >&6; } 26973 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26975 $as_echo "$BOOT_JDK_VERSION" >&6; } 26976 fi # end check jdk version 26977 fi # end check javac 26978 fi # end check java 26979 fi # end check boot jdk found 26980 fi 26981 26982 26983 if test "x$BOOT_JDK_FOUND" = xno; then 26984 # Now execute the test 26985 26986 if test "x$PROGRAMW6432" != x; then 26987 VIRTUAL_DIR="$PROGRAMW6432/Java" 26988 26989 windows_path="$VIRTUAL_DIR" 26990 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26991 unix_path=`$CYGPATH -u "$windows_path"` 26992 VIRTUAL_DIR="$unix_path" 26993 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26994 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26995 VIRTUAL_DIR="$unix_path" 26996 fi 26997 26998 26999 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27000 BOOT_JDK_SUFFIX="" 27001 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27002 if test "x$ALL_JDKS_FOUND" != x; then 27003 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27004 27005 if test "x$BOOT_JDK_FOUND" = xno; then 27006 # Now execute the test 27007 27008 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27009 if test -d "$BOOT_JDK"; then 27010 BOOT_JDK_FOUND=maybe 27011 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27012 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27013 fi 27014 27015 27016 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27017 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27018 # Do we have a bin/java? 27019 if test ! -x "$BOOT_JDK/bin/java"; then 27020 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27021 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27022 BOOT_JDK_FOUND=no 27023 else 27024 # Do we have a bin/javac? 27025 if test ! -x "$BOOT_JDK/bin/javac"; then 27026 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27027 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27028 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27029 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27030 BOOT_JDK_FOUND=no 27031 else 27032 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27033 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27034 27035 # Extra M4 quote needed to protect [] in grep expression. 27036 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27037 if test "x$FOUND_CORRECT_VERSION" = x; then 27038 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27039 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27040 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27041 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27042 BOOT_JDK_FOUND=no 27043 else 27044 # We're done! :-) 27045 BOOT_JDK_FOUND=yes 27046 27047 # Only process if variable expands to non-empty 27048 27049 if test "x$BOOT_JDK" != x; then 27050 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27051 27052 # Input might be given as Windows format, start by converting to 27053 # unix format. 27054 path="$BOOT_JDK" 27055 new_path=`$CYGPATH -u "$path"` 27056 27057 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27058 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27059 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27060 # "foo.exe" is OK but "foo" is an error. 27061 # 27062 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27063 # It is also a way to make sure we got the proper file name for the real test later on. 27064 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27065 if test "x$test_shortpath" = x; then 27066 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27067 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27068 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27069 fi 27070 27071 # Call helper function which possibly converts this using DOS-style short mode. 27072 # If so, the updated path is stored in $new_path. 27073 27074 input_path="$new_path" 27075 # Check if we need to convert this using DOS-style short mode. If the path 27076 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27077 # take no chances and rewrite it. 27078 # Note: m4 eats our [], so we need to use [ and ] instead. 27079 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27080 if test "x$has_forbidden_chars" != x; then 27081 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27082 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27083 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27084 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27085 # Going to short mode and back again did indeed matter. Since short mode is 27086 # case insensitive, let's make it lowercase to improve readability. 27087 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27088 # Now convert it back to Unix-style (cygpath) 27089 input_path=`$CYGPATH -u "$shortmode_path"` 27090 new_path="$input_path" 27091 fi 27092 fi 27093 27094 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27095 if test "x$test_cygdrive_prefix" = x; then 27096 # As a simple fix, exclude /usr/bin since it's not a real path. 27097 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27098 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27099 # a path prefixed by /cygdrive for fixpath to work. 27100 new_path="$CYGWIN_ROOT_PATH$input_path" 27101 fi 27102 fi 27103 27104 27105 if test "x$path" != "x$new_path"; then 27106 BOOT_JDK="$new_path" 27107 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27108 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27109 fi 27110 27111 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27112 27113 path="$BOOT_JDK" 27114 has_colon=`$ECHO $path | $GREP ^.:` 27115 new_path="$path" 27116 if test "x$has_colon" = x; then 27117 # Not in mixed or Windows style, start by that. 27118 new_path=`cmd //c echo $path` 27119 fi 27120 27121 27122 input_path="$new_path" 27123 # Check if we need to convert this using DOS-style short mode. If the path 27124 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27125 # take no chances and rewrite it. 27126 # Note: m4 eats our [], so we need to use [ and ] instead. 27127 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27128 if test "x$has_forbidden_chars" != x; then 27129 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27130 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27131 fi 27132 27133 27134 windows_path="$new_path" 27135 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27136 unix_path=`$CYGPATH -u "$windows_path"` 27137 new_path="$unix_path" 27138 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27139 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27140 new_path="$unix_path" 27141 fi 27142 27143 if test "x$path" != "x$new_path"; then 27144 BOOT_JDK="$new_path" 27145 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27146 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27147 fi 27148 27149 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27150 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27151 27152 else 27153 # We're on a unix platform. Hooray! :) 27154 path="$BOOT_JDK" 27155 has_space=`$ECHO "$path" | $GREP " "` 27156 if test "x$has_space" != x; then 27157 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27158 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27159 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27160 fi 27161 27162 # Use eval to expand a potential ~ 27163 eval path="$path" 27164 if test ! -f "$path" && test ! -d "$path"; then 27165 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27166 fi 27167 27168 if test -d "$path"; then 27169 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27170 else 27171 dir="`$DIRNAME "$path"`" 27172 base="`$BASENAME "$path"`" 27173 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27174 fi 27175 fi 27176 fi 27177 27178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27179 $as_echo_n "checking for Boot JDK... " >&6; } 27180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27181 $as_echo "$BOOT_JDK" >&6; } 27182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27183 $as_echo_n "checking Boot JDK version... " >&6; } 27184 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27186 $as_echo "$BOOT_JDK_VERSION" >&6; } 27187 fi # end check jdk version 27188 fi # end check javac 27189 fi # end check java 27190 fi # end check boot jdk found 27191 fi 27192 27193 done 27194 fi 27195 27196 fi 27197 27198 27199 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27200 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27201 # Do we have a bin/java? 27202 if test ! -x "$BOOT_JDK/bin/java"; then 27203 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27204 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27205 BOOT_JDK_FOUND=no 27206 else 27207 # Do we have a bin/javac? 27208 if test ! -x "$BOOT_JDK/bin/javac"; then 27209 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27210 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27211 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27212 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27213 BOOT_JDK_FOUND=no 27214 else 27215 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27216 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27217 27218 # Extra M4 quote needed to protect [] in grep expression. 27219 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27220 if test "x$FOUND_CORRECT_VERSION" = x; then 27221 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27222 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27223 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27224 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27225 BOOT_JDK_FOUND=no 27226 else 27227 # We're done! :-) 27228 BOOT_JDK_FOUND=yes 27229 27230 # Only process if variable expands to non-empty 27231 27232 if test "x$BOOT_JDK" != x; then 27233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27234 27235 # Input might be given as Windows format, start by converting to 27236 # unix format. 27237 path="$BOOT_JDK" 27238 new_path=`$CYGPATH -u "$path"` 27239 27240 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27241 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27242 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27243 # "foo.exe" is OK but "foo" is an error. 27244 # 27245 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27246 # It is also a way to make sure we got the proper file name for the real test later on. 27247 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27248 if test "x$test_shortpath" = x; then 27249 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27250 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27251 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27252 fi 27253 27254 # Call helper function which possibly converts this using DOS-style short mode. 27255 # If so, the updated path is stored in $new_path. 27256 27257 input_path="$new_path" 27258 # Check if we need to convert this using DOS-style short mode. If the path 27259 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27260 # take no chances and rewrite it. 27261 # Note: m4 eats our [], so we need to use [ and ] instead. 27262 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27263 if test "x$has_forbidden_chars" != x; then 27264 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27265 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27266 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27267 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27268 # Going to short mode and back again did indeed matter. Since short mode is 27269 # case insensitive, let's make it lowercase to improve readability. 27270 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27271 # Now convert it back to Unix-style (cygpath) 27272 input_path=`$CYGPATH -u "$shortmode_path"` 27273 new_path="$input_path" 27274 fi 27275 fi 27276 27277 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27278 if test "x$test_cygdrive_prefix" = x; then 27279 # As a simple fix, exclude /usr/bin since it's not a real path. 27280 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27281 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27282 # a path prefixed by /cygdrive for fixpath to work. 27283 new_path="$CYGWIN_ROOT_PATH$input_path" 27284 fi 27285 fi 27286 27287 27288 if test "x$path" != "x$new_path"; then 27289 BOOT_JDK="$new_path" 27290 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27291 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27292 fi 27293 27294 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27295 27296 path="$BOOT_JDK" 27297 has_colon=`$ECHO $path | $GREP ^.:` 27298 new_path="$path" 27299 if test "x$has_colon" = x; then 27300 # Not in mixed or Windows style, start by that. 27301 new_path=`cmd //c echo $path` 27302 fi 27303 27304 27305 input_path="$new_path" 27306 # Check if we need to convert this using DOS-style short mode. If the path 27307 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27308 # take no chances and rewrite it. 27309 # Note: m4 eats our [], so we need to use [ and ] instead. 27310 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27311 if test "x$has_forbidden_chars" != x; then 27312 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27313 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27314 fi 27315 27316 27317 windows_path="$new_path" 27318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27319 unix_path=`$CYGPATH -u "$windows_path"` 27320 new_path="$unix_path" 27321 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27322 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27323 new_path="$unix_path" 27324 fi 27325 27326 if test "x$path" != "x$new_path"; then 27327 BOOT_JDK="$new_path" 27328 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27329 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27330 fi 27331 27332 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27333 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27334 27335 else 27336 # We're on a unix platform. Hooray! :) 27337 path="$BOOT_JDK" 27338 has_space=`$ECHO "$path" | $GREP " "` 27339 if test "x$has_space" != x; then 27340 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27341 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27342 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27343 fi 27344 27345 # Use eval to expand a potential ~ 27346 eval path="$path" 27347 if test ! -f "$path" && test ! -d "$path"; then 27348 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27349 fi 27350 27351 if test -d "$path"; then 27352 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27353 else 27354 dir="`$DIRNAME "$path"`" 27355 base="`$BASENAME "$path"`" 27356 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27357 fi 27358 fi 27359 fi 27360 27361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27362 $as_echo_n "checking for Boot JDK... " >&6; } 27363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27364 $as_echo "$BOOT_JDK" >&6; } 27365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27366 $as_echo_n "checking Boot JDK version... " >&6; } 27367 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27369 $as_echo "$BOOT_JDK_VERSION" >&6; } 27370 fi # end check jdk version 27371 fi # end check javac 27372 fi # end check java 27373 fi # end check boot jdk found 27374 fi 27375 27376 27377 if test "x$BOOT_JDK_FOUND" = xno; then 27378 # Now execute the test 27379 27380 if test "x$PROGRAMFILES" != x; then 27381 VIRTUAL_DIR="$PROGRAMFILES/Java" 27382 27383 windows_path="$VIRTUAL_DIR" 27384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27385 unix_path=`$CYGPATH -u "$windows_path"` 27386 VIRTUAL_DIR="$unix_path" 27387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27388 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27389 VIRTUAL_DIR="$unix_path" 27390 fi 27391 27392 27393 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27394 BOOT_JDK_SUFFIX="" 27395 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27396 if test "x$ALL_JDKS_FOUND" != x; then 27397 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27398 27399 if test "x$BOOT_JDK_FOUND" = xno; then 27400 # Now execute the test 27401 27402 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27403 if test -d "$BOOT_JDK"; then 27404 BOOT_JDK_FOUND=maybe 27405 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27406 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27407 fi 27408 27409 27410 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27411 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27412 # Do we have a bin/java? 27413 if test ! -x "$BOOT_JDK/bin/java"; then 27414 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27415 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27416 BOOT_JDK_FOUND=no 27417 else 27418 # Do we have a bin/javac? 27419 if test ! -x "$BOOT_JDK/bin/javac"; then 27420 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27421 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27422 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27423 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27424 BOOT_JDK_FOUND=no 27425 else 27426 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27427 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27428 27429 # Extra M4 quote needed to protect [] in grep expression. 27430 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27431 if test "x$FOUND_CORRECT_VERSION" = x; then 27432 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27433 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27434 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27435 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27436 BOOT_JDK_FOUND=no 27437 else 27438 # We're done! :-) 27439 BOOT_JDK_FOUND=yes 27440 27441 # Only process if variable expands to non-empty 27442 27443 if test "x$BOOT_JDK" != x; then 27444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27445 27446 # Input might be given as Windows format, start by converting to 27447 # unix format. 27448 path="$BOOT_JDK" 27449 new_path=`$CYGPATH -u "$path"` 27450 27451 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27452 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27453 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27454 # "foo.exe" is OK but "foo" is an error. 27455 # 27456 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27457 # It is also a way to make sure we got the proper file name for the real test later on. 27458 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27459 if test "x$test_shortpath" = x; then 27460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27461 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27462 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27463 fi 27464 27465 # Call helper function which possibly converts this using DOS-style short mode. 27466 # If so, the updated path is stored in $new_path. 27467 27468 input_path="$new_path" 27469 # Check if we need to convert this using DOS-style short mode. If the path 27470 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27471 # take no chances and rewrite it. 27472 # Note: m4 eats our [], so we need to use [ and ] instead. 27473 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27474 if test "x$has_forbidden_chars" != x; then 27475 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27476 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27477 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27478 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27479 # Going to short mode and back again did indeed matter. Since short mode is 27480 # case insensitive, let's make it lowercase to improve readability. 27481 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27482 # Now convert it back to Unix-style (cygpath) 27483 input_path=`$CYGPATH -u "$shortmode_path"` 27484 new_path="$input_path" 27485 fi 27486 fi 27487 27488 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27489 if test "x$test_cygdrive_prefix" = x; then 27490 # As a simple fix, exclude /usr/bin since it's not a real path. 27491 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27492 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27493 # a path prefixed by /cygdrive for fixpath to work. 27494 new_path="$CYGWIN_ROOT_PATH$input_path" 27495 fi 27496 fi 27497 27498 27499 if test "x$path" != "x$new_path"; then 27500 BOOT_JDK="$new_path" 27501 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27502 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27503 fi 27504 27505 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27506 27507 path="$BOOT_JDK" 27508 has_colon=`$ECHO $path | $GREP ^.:` 27509 new_path="$path" 27510 if test "x$has_colon" = x; then 27511 # Not in mixed or Windows style, start by that. 27512 new_path=`cmd //c echo $path` 27513 fi 27514 27515 27516 input_path="$new_path" 27517 # Check if we need to convert this using DOS-style short mode. If the path 27518 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27519 # take no chances and rewrite it. 27520 # Note: m4 eats our [], so we need to use [ and ] instead. 27521 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27522 if test "x$has_forbidden_chars" != x; then 27523 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27524 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27525 fi 27526 27527 27528 windows_path="$new_path" 27529 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27530 unix_path=`$CYGPATH -u "$windows_path"` 27531 new_path="$unix_path" 27532 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27533 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27534 new_path="$unix_path" 27535 fi 27536 27537 if test "x$path" != "x$new_path"; then 27538 BOOT_JDK="$new_path" 27539 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27540 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27541 fi 27542 27543 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27544 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27545 27546 else 27547 # We're on a unix platform. Hooray! :) 27548 path="$BOOT_JDK" 27549 has_space=`$ECHO "$path" | $GREP " "` 27550 if test "x$has_space" != x; then 27551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27552 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27553 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27554 fi 27555 27556 # Use eval to expand a potential ~ 27557 eval path="$path" 27558 if test ! -f "$path" && test ! -d "$path"; then 27559 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27560 fi 27561 27562 if test -d "$path"; then 27563 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27564 else 27565 dir="`$DIRNAME "$path"`" 27566 base="`$BASENAME "$path"`" 27567 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27568 fi 27569 fi 27570 fi 27571 27572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27573 $as_echo_n "checking for Boot JDK... " >&6; } 27574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27575 $as_echo "$BOOT_JDK" >&6; } 27576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27577 $as_echo_n "checking Boot JDK version... " >&6; } 27578 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27580 $as_echo "$BOOT_JDK_VERSION" >&6; } 27581 fi # end check jdk version 27582 fi # end check javac 27583 fi # end check java 27584 fi # end check boot jdk found 27585 fi 27586 27587 done 27588 fi 27589 27590 fi 27591 27592 27593 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27594 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27595 # Do we have a bin/java? 27596 if test ! -x "$BOOT_JDK/bin/java"; then 27597 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27598 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27599 BOOT_JDK_FOUND=no 27600 else 27601 # Do we have a bin/javac? 27602 if test ! -x "$BOOT_JDK/bin/javac"; then 27603 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27604 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27605 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27606 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27607 BOOT_JDK_FOUND=no 27608 else 27609 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27610 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27611 27612 # Extra M4 quote needed to protect [] in grep expression. 27613 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27614 if test "x$FOUND_CORRECT_VERSION" = x; then 27615 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27616 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27617 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27618 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27619 BOOT_JDK_FOUND=no 27620 else 27621 # We're done! :-) 27622 BOOT_JDK_FOUND=yes 27623 27624 # Only process if variable expands to non-empty 27625 27626 if test "x$BOOT_JDK" != x; then 27627 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27628 27629 # Input might be given as Windows format, start by converting to 27630 # unix format. 27631 path="$BOOT_JDK" 27632 new_path=`$CYGPATH -u "$path"` 27633 27634 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27635 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27636 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27637 # "foo.exe" is OK but "foo" is an error. 27638 # 27639 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27640 # It is also a way to make sure we got the proper file name for the real test later on. 27641 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27642 if test "x$test_shortpath" = x; then 27643 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27644 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27645 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27646 fi 27647 27648 # Call helper function which possibly converts this using DOS-style short mode. 27649 # If so, the updated path is stored in $new_path. 27650 27651 input_path="$new_path" 27652 # Check if we need to convert this using DOS-style short mode. If the path 27653 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27654 # take no chances and rewrite it. 27655 # Note: m4 eats our [], so we need to use [ and ] instead. 27656 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27657 if test "x$has_forbidden_chars" != x; then 27658 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27659 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27660 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27661 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27662 # Going to short mode and back again did indeed matter. Since short mode is 27663 # case insensitive, let's make it lowercase to improve readability. 27664 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27665 # Now convert it back to Unix-style (cygpath) 27666 input_path=`$CYGPATH -u "$shortmode_path"` 27667 new_path="$input_path" 27668 fi 27669 fi 27670 27671 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27672 if test "x$test_cygdrive_prefix" = x; then 27673 # As a simple fix, exclude /usr/bin since it's not a real path. 27674 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27675 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27676 # a path prefixed by /cygdrive for fixpath to work. 27677 new_path="$CYGWIN_ROOT_PATH$input_path" 27678 fi 27679 fi 27680 27681 27682 if test "x$path" != "x$new_path"; then 27683 BOOT_JDK="$new_path" 27684 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27685 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27686 fi 27687 27688 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27689 27690 path="$BOOT_JDK" 27691 has_colon=`$ECHO $path | $GREP ^.:` 27692 new_path="$path" 27693 if test "x$has_colon" = x; then 27694 # Not in mixed or Windows style, start by that. 27695 new_path=`cmd //c echo $path` 27696 fi 27697 27698 27699 input_path="$new_path" 27700 # Check if we need to convert this using DOS-style short mode. If the path 27701 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27702 # take no chances and rewrite it. 27703 # Note: m4 eats our [], so we need to use [ and ] instead. 27704 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27705 if test "x$has_forbidden_chars" != x; then 27706 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27707 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27708 fi 27709 27710 27711 windows_path="$new_path" 27712 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27713 unix_path=`$CYGPATH -u "$windows_path"` 27714 new_path="$unix_path" 27715 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27716 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27717 new_path="$unix_path" 27718 fi 27719 27720 if test "x$path" != "x$new_path"; then 27721 BOOT_JDK="$new_path" 27722 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27723 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27724 fi 27725 27726 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27727 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27728 27729 else 27730 # We're on a unix platform. Hooray! :) 27731 path="$BOOT_JDK" 27732 has_space=`$ECHO "$path" | $GREP " "` 27733 if test "x$has_space" != x; then 27734 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27735 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27736 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27737 fi 27738 27739 # Use eval to expand a potential ~ 27740 eval path="$path" 27741 if test ! -f "$path" && test ! -d "$path"; then 27742 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27743 fi 27744 27745 if test -d "$path"; then 27746 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27747 else 27748 dir="`$DIRNAME "$path"`" 27749 base="`$BASENAME "$path"`" 27750 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27751 fi 27752 fi 27753 fi 27754 27755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27756 $as_echo_n "checking for Boot JDK... " >&6; } 27757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27758 $as_echo "$BOOT_JDK" >&6; } 27759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27760 $as_echo_n "checking Boot JDK version... " >&6; } 27761 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27763 $as_echo "$BOOT_JDK_VERSION" >&6; } 27764 fi # end check jdk version 27765 fi # end check javac 27766 fi # end check java 27767 fi # end check boot jdk found 27768 fi 27769 27770 27771 if test "x$BOOT_JDK_FOUND" = xno; then 27772 # Now execute the test 27773 27774 if test "x$ProgramFiles" != x; then 27775 VIRTUAL_DIR="$ProgramFiles/Java" 27776 27777 windows_path="$VIRTUAL_DIR" 27778 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27779 unix_path=`$CYGPATH -u "$windows_path"` 27780 VIRTUAL_DIR="$unix_path" 27781 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27782 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27783 VIRTUAL_DIR="$unix_path" 27784 fi 27785 27786 27787 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27788 BOOT_JDK_SUFFIX="" 27789 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27790 if test "x$ALL_JDKS_FOUND" != x; then 27791 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27792 27793 if test "x$BOOT_JDK_FOUND" = xno; then 27794 # Now execute the test 27795 27796 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27797 if test -d "$BOOT_JDK"; then 27798 BOOT_JDK_FOUND=maybe 27799 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27800 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27801 fi 27802 27803 27804 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27805 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27806 # Do we have a bin/java? 27807 if test ! -x "$BOOT_JDK/bin/java"; then 27808 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27809 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27810 BOOT_JDK_FOUND=no 27811 else 27812 # Do we have a bin/javac? 27813 if test ! -x "$BOOT_JDK/bin/javac"; then 27814 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27815 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27816 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27817 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27818 BOOT_JDK_FOUND=no 27819 else 27820 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27821 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27822 27823 # Extra M4 quote needed to protect [] in grep expression. 27824 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27825 if test "x$FOUND_CORRECT_VERSION" = x; then 27826 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27827 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27828 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27829 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27830 BOOT_JDK_FOUND=no 27831 else 27832 # We're done! :-) 27833 BOOT_JDK_FOUND=yes 27834 27835 # Only process if variable expands to non-empty 27836 27837 if test "x$BOOT_JDK" != x; then 27838 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27839 27840 # Input might be given as Windows format, start by converting to 27841 # unix format. 27842 path="$BOOT_JDK" 27843 new_path=`$CYGPATH -u "$path"` 27844 27845 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27846 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27847 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27848 # "foo.exe" is OK but "foo" is an error. 27849 # 27850 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27851 # It is also a way to make sure we got the proper file name for the real test later on. 27852 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27853 if test "x$test_shortpath" = x; then 27854 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27855 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27856 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27857 fi 27858 27859 # Call helper function which possibly converts this using DOS-style short mode. 27860 # If so, the updated path is stored in $new_path. 27861 27862 input_path="$new_path" 27863 # Check if we need to convert this using DOS-style short mode. If the path 27864 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27865 # take no chances and rewrite it. 27866 # Note: m4 eats our [], so we need to use [ and ] instead. 27867 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27868 if test "x$has_forbidden_chars" != x; then 27869 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27870 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27871 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27872 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27873 # Going to short mode and back again did indeed matter. Since short mode is 27874 # case insensitive, let's make it lowercase to improve readability. 27875 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27876 # Now convert it back to Unix-style (cygpath) 27877 input_path=`$CYGPATH -u "$shortmode_path"` 27878 new_path="$input_path" 27879 fi 27880 fi 27881 27882 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27883 if test "x$test_cygdrive_prefix" = x; then 27884 # As a simple fix, exclude /usr/bin since it's not a real path. 27885 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27886 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27887 # a path prefixed by /cygdrive for fixpath to work. 27888 new_path="$CYGWIN_ROOT_PATH$input_path" 27889 fi 27890 fi 27891 27892 27893 if test "x$path" != "x$new_path"; then 27894 BOOT_JDK="$new_path" 27895 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27896 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27897 fi 27898 27899 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27900 27901 path="$BOOT_JDK" 27902 has_colon=`$ECHO $path | $GREP ^.:` 27903 new_path="$path" 27904 if test "x$has_colon" = x; then 27905 # Not in mixed or Windows style, start by that. 27906 new_path=`cmd //c echo $path` 27907 fi 27908 27909 27910 input_path="$new_path" 27911 # Check if we need to convert this using DOS-style short mode. If the path 27912 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27913 # take no chances and rewrite it. 27914 # Note: m4 eats our [], so we need to use [ and ] instead. 27915 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27916 if test "x$has_forbidden_chars" != x; then 27917 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27918 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27919 fi 27920 27921 27922 windows_path="$new_path" 27923 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27924 unix_path=`$CYGPATH -u "$windows_path"` 27925 new_path="$unix_path" 27926 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27927 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27928 new_path="$unix_path" 27929 fi 27930 27931 if test "x$path" != "x$new_path"; then 27932 BOOT_JDK="$new_path" 27933 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27934 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27935 fi 27936 27937 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27938 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27939 27940 else 27941 # We're on a unix platform. Hooray! :) 27942 path="$BOOT_JDK" 27943 has_space=`$ECHO "$path" | $GREP " "` 27944 if test "x$has_space" != x; then 27945 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27946 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27947 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27948 fi 27949 27950 # Use eval to expand a potential ~ 27951 eval path="$path" 27952 if test ! -f "$path" && test ! -d "$path"; then 27953 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27954 fi 27955 27956 if test -d "$path"; then 27957 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27958 else 27959 dir="`$DIRNAME "$path"`" 27960 base="`$BASENAME "$path"`" 27961 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27962 fi 27963 fi 27964 fi 27965 27966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27967 $as_echo_n "checking for Boot JDK... " >&6; } 27968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27969 $as_echo "$BOOT_JDK" >&6; } 27970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27971 $as_echo_n "checking Boot JDK version... " >&6; } 27972 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27974 $as_echo "$BOOT_JDK_VERSION" >&6; } 27975 fi # end check jdk version 27976 fi # end check javac 27977 fi # end check java 27978 fi # end check boot jdk found 27979 fi 27980 27981 done 27982 fi 27983 27984 fi 27985 27986 27987 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27988 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27989 # Do we have a bin/java? 27990 if test ! -x "$BOOT_JDK/bin/java"; then 27991 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27992 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27993 BOOT_JDK_FOUND=no 27994 else 27995 # Do we have a bin/javac? 27996 if test ! -x "$BOOT_JDK/bin/javac"; then 27997 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27998 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27999 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28000 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28001 BOOT_JDK_FOUND=no 28002 else 28003 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28004 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28005 28006 # Extra M4 quote needed to protect [] in grep expression. 28007 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28008 if test "x$FOUND_CORRECT_VERSION" = x; then 28009 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28010 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28011 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28012 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28013 BOOT_JDK_FOUND=no 28014 else 28015 # We're done! :-) 28016 BOOT_JDK_FOUND=yes 28017 28018 # Only process if variable expands to non-empty 28019 28020 if test "x$BOOT_JDK" != x; then 28021 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28022 28023 # Input might be given as Windows format, start by converting to 28024 # unix format. 28025 path="$BOOT_JDK" 28026 new_path=`$CYGPATH -u "$path"` 28027 28028 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28029 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28030 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28031 # "foo.exe" is OK but "foo" is an error. 28032 # 28033 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28034 # It is also a way to make sure we got the proper file name for the real test later on. 28035 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28036 if test "x$test_shortpath" = x; then 28037 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28038 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28039 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28040 fi 28041 28042 # Call helper function which possibly converts this using DOS-style short mode. 28043 # If so, the updated path is stored in $new_path. 28044 28045 input_path="$new_path" 28046 # Check if we need to convert this using DOS-style short mode. If the path 28047 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28048 # take no chances and rewrite it. 28049 # Note: m4 eats our [], so we need to use [ and ] instead. 28050 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28051 if test "x$has_forbidden_chars" != x; then 28052 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28053 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28054 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28055 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28056 # Going to short mode and back again did indeed matter. Since short mode is 28057 # case insensitive, let's make it lowercase to improve readability. 28058 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28059 # Now convert it back to Unix-style (cygpath) 28060 input_path=`$CYGPATH -u "$shortmode_path"` 28061 new_path="$input_path" 28062 fi 28063 fi 28064 28065 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28066 if test "x$test_cygdrive_prefix" = x; then 28067 # As a simple fix, exclude /usr/bin since it's not a real path. 28068 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28069 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28070 # a path prefixed by /cygdrive for fixpath to work. 28071 new_path="$CYGWIN_ROOT_PATH$input_path" 28072 fi 28073 fi 28074 28075 28076 if test "x$path" != "x$new_path"; then 28077 BOOT_JDK="$new_path" 28078 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28079 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28080 fi 28081 28082 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28083 28084 path="$BOOT_JDK" 28085 has_colon=`$ECHO $path | $GREP ^.:` 28086 new_path="$path" 28087 if test "x$has_colon" = x; then 28088 # Not in mixed or Windows style, start by that. 28089 new_path=`cmd //c echo $path` 28090 fi 28091 28092 28093 input_path="$new_path" 28094 # Check if we need to convert this using DOS-style short mode. If the path 28095 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28096 # take no chances and rewrite it. 28097 # Note: m4 eats our [], so we need to use [ and ] instead. 28098 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28099 if test "x$has_forbidden_chars" != x; then 28100 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28101 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28102 fi 28103 28104 28105 windows_path="$new_path" 28106 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28107 unix_path=`$CYGPATH -u "$windows_path"` 28108 new_path="$unix_path" 28109 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28110 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28111 new_path="$unix_path" 28112 fi 28113 28114 if test "x$path" != "x$new_path"; then 28115 BOOT_JDK="$new_path" 28116 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28117 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28118 fi 28119 28120 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28121 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28122 28123 else 28124 # We're on a unix platform. Hooray! :) 28125 path="$BOOT_JDK" 28126 has_space=`$ECHO "$path" | $GREP " "` 28127 if test "x$has_space" != x; then 28128 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28129 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28130 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28131 fi 28132 28133 # Use eval to expand a potential ~ 28134 eval path="$path" 28135 if test ! -f "$path" && test ! -d "$path"; then 28136 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28137 fi 28138 28139 if test -d "$path"; then 28140 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28141 else 28142 dir="`$DIRNAME "$path"`" 28143 base="`$BASENAME "$path"`" 28144 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28145 fi 28146 fi 28147 fi 28148 28149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28150 $as_echo_n "checking for Boot JDK... " >&6; } 28151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28152 $as_echo "$BOOT_JDK" >&6; } 28153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28154 $as_echo_n "checking Boot JDK version... " >&6; } 28155 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28157 $as_echo "$BOOT_JDK_VERSION" >&6; } 28158 fi # end check jdk version 28159 fi # end check javac 28160 fi # end check java 28161 fi # end check boot jdk found 28162 fi 28163 28164 28165 if test "x$BOOT_JDK_FOUND" = xno; then 28166 # Now execute the test 28167 28168 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 28169 BOOT_JDK_SUFFIX="" 28170 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28171 if test "x$ALL_JDKS_FOUND" != x; then 28172 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28173 28174 if test "x$BOOT_JDK_FOUND" = xno; then 28175 # Now execute the test 28176 28177 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28178 if test -d "$BOOT_JDK"; then 28179 BOOT_JDK_FOUND=maybe 28180 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28181 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28182 fi 28183 28184 28185 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28186 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28187 # Do we have a bin/java? 28188 if test ! -x "$BOOT_JDK/bin/java"; then 28189 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28190 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28191 BOOT_JDK_FOUND=no 28192 else 28193 # Do we have a bin/javac? 28194 if test ! -x "$BOOT_JDK/bin/javac"; then 28195 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28196 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28197 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28198 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28199 BOOT_JDK_FOUND=no 28200 else 28201 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28202 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28203 28204 # Extra M4 quote needed to protect [] in grep expression. 28205 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28206 if test "x$FOUND_CORRECT_VERSION" = x; then 28207 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28208 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28209 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28210 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28211 BOOT_JDK_FOUND=no 28212 else 28213 # We're done! :-) 28214 BOOT_JDK_FOUND=yes 28215 28216 # Only process if variable expands to non-empty 28217 28218 if test "x$BOOT_JDK" != x; then 28219 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28220 28221 # Input might be given as Windows format, start by converting to 28222 # unix format. 28223 path="$BOOT_JDK" 28224 new_path=`$CYGPATH -u "$path"` 28225 28226 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28227 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28228 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28229 # "foo.exe" is OK but "foo" is an error. 28230 # 28231 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28232 # It is also a way to make sure we got the proper file name for the real test later on. 28233 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28234 if test "x$test_shortpath" = x; then 28235 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28236 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28237 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28238 fi 28239 28240 # Call helper function which possibly converts this using DOS-style short mode. 28241 # If so, the updated path is stored in $new_path. 28242 28243 input_path="$new_path" 28244 # Check if we need to convert this using DOS-style short mode. If the path 28245 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28246 # take no chances and rewrite it. 28247 # Note: m4 eats our [], so we need to use [ and ] instead. 28248 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28249 if test "x$has_forbidden_chars" != x; then 28250 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28251 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28252 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28253 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28254 # Going to short mode and back again did indeed matter. Since short mode is 28255 # case insensitive, let's make it lowercase to improve readability. 28256 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28257 # Now convert it back to Unix-style (cygpath) 28258 input_path=`$CYGPATH -u "$shortmode_path"` 28259 new_path="$input_path" 28260 fi 28261 fi 28262 28263 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28264 if test "x$test_cygdrive_prefix" = x; then 28265 # As a simple fix, exclude /usr/bin since it's not a real path. 28266 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28267 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28268 # a path prefixed by /cygdrive for fixpath to work. 28269 new_path="$CYGWIN_ROOT_PATH$input_path" 28270 fi 28271 fi 28272 28273 28274 if test "x$path" != "x$new_path"; then 28275 BOOT_JDK="$new_path" 28276 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28277 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28278 fi 28279 28280 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28281 28282 path="$BOOT_JDK" 28283 has_colon=`$ECHO $path | $GREP ^.:` 28284 new_path="$path" 28285 if test "x$has_colon" = x; then 28286 # Not in mixed or Windows style, start by that. 28287 new_path=`cmd //c echo $path` 28288 fi 28289 28290 28291 input_path="$new_path" 28292 # Check if we need to convert this using DOS-style short mode. If the path 28293 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28294 # take no chances and rewrite it. 28295 # Note: m4 eats our [], so we need to use [ and ] instead. 28296 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28297 if test "x$has_forbidden_chars" != x; then 28298 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28299 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28300 fi 28301 28302 28303 windows_path="$new_path" 28304 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28305 unix_path=`$CYGPATH -u "$windows_path"` 28306 new_path="$unix_path" 28307 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28308 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28309 new_path="$unix_path" 28310 fi 28311 28312 if test "x$path" != "x$new_path"; then 28313 BOOT_JDK="$new_path" 28314 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28315 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28316 fi 28317 28318 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28319 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28320 28321 else 28322 # We're on a unix platform. Hooray! :) 28323 path="$BOOT_JDK" 28324 has_space=`$ECHO "$path" | $GREP " "` 28325 if test "x$has_space" != x; then 28326 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28327 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28328 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28329 fi 28330 28331 # Use eval to expand a potential ~ 28332 eval path="$path" 28333 if test ! -f "$path" && test ! -d "$path"; then 28334 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28335 fi 28336 28337 if test -d "$path"; then 28338 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28339 else 28340 dir="`$DIRNAME "$path"`" 28341 base="`$BASENAME "$path"`" 28342 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28343 fi 28344 fi 28345 fi 28346 28347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28348 $as_echo_n "checking for Boot JDK... " >&6; } 28349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28350 $as_echo "$BOOT_JDK" >&6; } 28351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28352 $as_echo_n "checking Boot JDK version... " >&6; } 28353 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28355 $as_echo "$BOOT_JDK_VERSION" >&6; } 28356 fi # end check jdk version 28357 fi # end check javac 28358 fi # end check java 28359 fi # end check boot jdk found 28360 fi 28361 28362 done 28363 fi 28364 28365 28366 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28367 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28368 # Do we have a bin/java? 28369 if test ! -x "$BOOT_JDK/bin/java"; then 28370 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28371 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28372 BOOT_JDK_FOUND=no 28373 else 28374 # Do we have a bin/javac? 28375 if test ! -x "$BOOT_JDK/bin/javac"; then 28376 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28377 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28378 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28379 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28380 BOOT_JDK_FOUND=no 28381 else 28382 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28383 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28384 28385 # Extra M4 quote needed to protect [] in grep expression. 28386 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28387 if test "x$FOUND_CORRECT_VERSION" = x; then 28388 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28389 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28390 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28391 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28392 BOOT_JDK_FOUND=no 28393 else 28394 # We're done! :-) 28395 BOOT_JDK_FOUND=yes 28396 28397 # Only process if variable expands to non-empty 28398 28399 if test "x$BOOT_JDK" != x; then 28400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28401 28402 # Input might be given as Windows format, start by converting to 28403 # unix format. 28404 path="$BOOT_JDK" 28405 new_path=`$CYGPATH -u "$path"` 28406 28407 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28408 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28409 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28410 # "foo.exe" is OK but "foo" is an error. 28411 # 28412 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28413 # It is also a way to make sure we got the proper file name for the real test later on. 28414 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28415 if test "x$test_shortpath" = x; then 28416 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28417 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28418 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28419 fi 28420 28421 # Call helper function which possibly converts this using DOS-style short mode. 28422 # If so, the updated path is stored in $new_path. 28423 28424 input_path="$new_path" 28425 # Check if we need to convert this using DOS-style short mode. If the path 28426 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28427 # take no chances and rewrite it. 28428 # Note: m4 eats our [], so we need to use [ and ] instead. 28429 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28430 if test "x$has_forbidden_chars" != x; then 28431 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28432 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28433 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28434 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28435 # Going to short mode and back again did indeed matter. Since short mode is 28436 # case insensitive, let's make it lowercase to improve readability. 28437 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28438 # Now convert it back to Unix-style (cygpath) 28439 input_path=`$CYGPATH -u "$shortmode_path"` 28440 new_path="$input_path" 28441 fi 28442 fi 28443 28444 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28445 if test "x$test_cygdrive_prefix" = x; then 28446 # As a simple fix, exclude /usr/bin since it's not a real path. 28447 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28448 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28449 # a path prefixed by /cygdrive for fixpath to work. 28450 new_path="$CYGWIN_ROOT_PATH$input_path" 28451 fi 28452 fi 28453 28454 28455 if test "x$path" != "x$new_path"; then 28456 BOOT_JDK="$new_path" 28457 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28458 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28459 fi 28460 28461 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28462 28463 path="$BOOT_JDK" 28464 has_colon=`$ECHO $path | $GREP ^.:` 28465 new_path="$path" 28466 if test "x$has_colon" = x; then 28467 # Not in mixed or Windows style, start by that. 28468 new_path=`cmd //c echo $path` 28469 fi 28470 28471 28472 input_path="$new_path" 28473 # Check if we need to convert this using DOS-style short mode. If the path 28474 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28475 # take no chances and rewrite it. 28476 # Note: m4 eats our [], so we need to use [ and ] instead. 28477 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28478 if test "x$has_forbidden_chars" != x; then 28479 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28480 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28481 fi 28482 28483 28484 windows_path="$new_path" 28485 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28486 unix_path=`$CYGPATH -u "$windows_path"` 28487 new_path="$unix_path" 28488 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28489 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28490 new_path="$unix_path" 28491 fi 28492 28493 if test "x$path" != "x$new_path"; then 28494 BOOT_JDK="$new_path" 28495 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28496 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28497 fi 28498 28499 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28500 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28501 28502 else 28503 # We're on a unix platform. Hooray! :) 28504 path="$BOOT_JDK" 28505 has_space=`$ECHO "$path" | $GREP " "` 28506 if test "x$has_space" != x; then 28507 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28508 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28509 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28510 fi 28511 28512 # Use eval to expand a potential ~ 28513 eval path="$path" 28514 if test ! -f "$path" && test ! -d "$path"; then 28515 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28516 fi 28517 28518 if test -d "$path"; then 28519 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28520 else 28521 dir="`$DIRNAME "$path"`" 28522 base="`$BASENAME "$path"`" 28523 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28524 fi 28525 fi 28526 fi 28527 28528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28529 $as_echo_n "checking for Boot JDK... " >&6; } 28530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28531 $as_echo "$BOOT_JDK" >&6; } 28532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28533 $as_echo_n "checking Boot JDK version... " >&6; } 28534 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28536 $as_echo "$BOOT_JDK_VERSION" >&6; } 28537 fi # end check jdk version 28538 fi # end check javac 28539 fi # end check java 28540 fi # end check boot jdk found 28541 fi 28542 28543 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 28544 28545 if test "x$BOOT_JDK_FOUND" = xno; then 28546 # Now execute the test 28547 28548 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 28549 BOOT_JDK_SUFFIX="/Contents/Home" 28550 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28551 if test "x$ALL_JDKS_FOUND" != x; then 28552 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28553 28554 if test "x$BOOT_JDK_FOUND" = xno; then 28555 # Now execute the test 28556 28557 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28558 if test -d "$BOOT_JDK"; then 28559 BOOT_JDK_FOUND=maybe 28560 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28561 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28562 fi 28563 28564 28565 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28566 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28567 # Do we have a bin/java? 28568 if test ! -x "$BOOT_JDK/bin/java"; then 28569 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28570 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28571 BOOT_JDK_FOUND=no 28572 else 28573 # Do we have a bin/javac? 28574 if test ! -x "$BOOT_JDK/bin/javac"; then 28575 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28576 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28577 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28578 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28579 BOOT_JDK_FOUND=no 28580 else 28581 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28582 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28583 28584 # Extra M4 quote needed to protect [] in grep expression. 28585 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28586 if test "x$FOUND_CORRECT_VERSION" = x; then 28587 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28588 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28589 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28590 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28591 BOOT_JDK_FOUND=no 28592 else 28593 # We're done! :-) 28594 BOOT_JDK_FOUND=yes 28595 28596 # Only process if variable expands to non-empty 28597 28598 if test "x$BOOT_JDK" != x; then 28599 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28600 28601 # Input might be given as Windows format, start by converting to 28602 # unix format. 28603 path="$BOOT_JDK" 28604 new_path=`$CYGPATH -u "$path"` 28605 28606 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28607 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28608 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28609 # "foo.exe" is OK but "foo" is an error. 28610 # 28611 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28612 # It is also a way to make sure we got the proper file name for the real test later on. 28613 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28614 if test "x$test_shortpath" = x; then 28615 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28616 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28617 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28618 fi 28619 28620 # Call helper function which possibly converts this using DOS-style short mode. 28621 # If so, the updated path is stored in $new_path. 28622 28623 input_path="$new_path" 28624 # Check if we need to convert this using DOS-style short mode. If the path 28625 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28626 # take no chances and rewrite it. 28627 # Note: m4 eats our [], so we need to use [ and ] instead. 28628 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28629 if test "x$has_forbidden_chars" != x; then 28630 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28631 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28632 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28633 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28634 # Going to short mode and back again did indeed matter. Since short mode is 28635 # case insensitive, let's make it lowercase to improve readability. 28636 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28637 # Now convert it back to Unix-style (cygpath) 28638 input_path=`$CYGPATH -u "$shortmode_path"` 28639 new_path="$input_path" 28640 fi 28641 fi 28642 28643 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28644 if test "x$test_cygdrive_prefix" = x; then 28645 # As a simple fix, exclude /usr/bin since it's not a real path. 28646 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28647 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28648 # a path prefixed by /cygdrive for fixpath to work. 28649 new_path="$CYGWIN_ROOT_PATH$input_path" 28650 fi 28651 fi 28652 28653 28654 if test "x$path" != "x$new_path"; then 28655 BOOT_JDK="$new_path" 28656 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28657 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28658 fi 28659 28660 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28661 28662 path="$BOOT_JDK" 28663 has_colon=`$ECHO $path | $GREP ^.:` 28664 new_path="$path" 28665 if test "x$has_colon" = x; then 28666 # Not in mixed or Windows style, start by that. 28667 new_path=`cmd //c echo $path` 28668 fi 28669 28670 28671 input_path="$new_path" 28672 # Check if we need to convert this using DOS-style short mode. If the path 28673 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28674 # take no chances and rewrite it. 28675 # Note: m4 eats our [], so we need to use [ and ] instead. 28676 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28677 if test "x$has_forbidden_chars" != x; then 28678 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28679 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28680 fi 28681 28682 28683 windows_path="$new_path" 28684 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28685 unix_path=`$CYGPATH -u "$windows_path"` 28686 new_path="$unix_path" 28687 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28688 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28689 new_path="$unix_path" 28690 fi 28691 28692 if test "x$path" != "x$new_path"; then 28693 BOOT_JDK="$new_path" 28694 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28695 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28696 fi 28697 28698 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28699 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28700 28701 else 28702 # We're on a unix platform. Hooray! :) 28703 path="$BOOT_JDK" 28704 has_space=`$ECHO "$path" | $GREP " "` 28705 if test "x$has_space" != x; then 28706 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28707 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28708 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28709 fi 28710 28711 # Use eval to expand a potential ~ 28712 eval path="$path" 28713 if test ! -f "$path" && test ! -d "$path"; then 28714 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28715 fi 28716 28717 if test -d "$path"; then 28718 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28719 else 28720 dir="`$DIRNAME "$path"`" 28721 base="`$BASENAME "$path"`" 28722 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28723 fi 28724 fi 28725 fi 28726 28727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28728 $as_echo_n "checking for Boot JDK... " >&6; } 28729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28730 $as_echo "$BOOT_JDK" >&6; } 28731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28732 $as_echo_n "checking Boot JDK version... " >&6; } 28733 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28735 $as_echo "$BOOT_JDK_VERSION" >&6; } 28736 fi # end check jdk version 28737 fi # end check javac 28738 fi # end check java 28739 fi # end check boot jdk found 28740 fi 28741 28742 done 28743 fi 28744 28745 28746 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28747 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28748 # Do we have a bin/java? 28749 if test ! -x "$BOOT_JDK/bin/java"; then 28750 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28751 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28752 BOOT_JDK_FOUND=no 28753 else 28754 # Do we have a bin/javac? 28755 if test ! -x "$BOOT_JDK/bin/javac"; then 28756 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28757 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28758 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28759 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28760 BOOT_JDK_FOUND=no 28761 else 28762 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28763 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28764 28765 # Extra M4 quote needed to protect [] in grep expression. 28766 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28767 if test "x$FOUND_CORRECT_VERSION" = x; then 28768 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28769 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28770 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28771 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28772 BOOT_JDK_FOUND=no 28773 else 28774 # We're done! :-) 28775 BOOT_JDK_FOUND=yes 28776 28777 # Only process if variable expands to non-empty 28778 28779 if test "x$BOOT_JDK" != x; then 28780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28781 28782 # Input might be given as Windows format, start by converting to 28783 # unix format. 28784 path="$BOOT_JDK" 28785 new_path=`$CYGPATH -u "$path"` 28786 28787 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28788 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28789 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28790 # "foo.exe" is OK but "foo" is an error. 28791 # 28792 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28793 # It is also a way to make sure we got the proper file name for the real test later on. 28794 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28795 if test "x$test_shortpath" = x; then 28796 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28797 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28798 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28799 fi 28800 28801 # Call helper function which possibly converts this using DOS-style short mode. 28802 # If so, the updated path is stored in $new_path. 28803 28804 input_path="$new_path" 28805 # Check if we need to convert this using DOS-style short mode. If the path 28806 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28807 # take no chances and rewrite it. 28808 # Note: m4 eats our [], so we need to use [ and ] instead. 28809 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28810 if test "x$has_forbidden_chars" != x; then 28811 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28812 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28813 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28814 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28815 # Going to short mode and back again did indeed matter. Since short mode is 28816 # case insensitive, let's make it lowercase to improve readability. 28817 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28818 # Now convert it back to Unix-style (cygpath) 28819 input_path=`$CYGPATH -u "$shortmode_path"` 28820 new_path="$input_path" 28821 fi 28822 fi 28823 28824 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28825 if test "x$test_cygdrive_prefix" = x; then 28826 # As a simple fix, exclude /usr/bin since it's not a real path. 28827 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28828 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28829 # a path prefixed by /cygdrive for fixpath to work. 28830 new_path="$CYGWIN_ROOT_PATH$input_path" 28831 fi 28832 fi 28833 28834 28835 if test "x$path" != "x$new_path"; then 28836 BOOT_JDK="$new_path" 28837 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28838 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28839 fi 28840 28841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28842 28843 path="$BOOT_JDK" 28844 has_colon=`$ECHO $path | $GREP ^.:` 28845 new_path="$path" 28846 if test "x$has_colon" = x; then 28847 # Not in mixed or Windows style, start by that. 28848 new_path=`cmd //c echo $path` 28849 fi 28850 28851 28852 input_path="$new_path" 28853 # Check if we need to convert this using DOS-style short mode. If the path 28854 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28855 # take no chances and rewrite it. 28856 # Note: m4 eats our [], so we need to use [ and ] instead. 28857 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28858 if test "x$has_forbidden_chars" != x; then 28859 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28860 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28861 fi 28862 28863 28864 windows_path="$new_path" 28865 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28866 unix_path=`$CYGPATH -u "$windows_path"` 28867 new_path="$unix_path" 28868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28869 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28870 new_path="$unix_path" 28871 fi 28872 28873 if test "x$path" != "x$new_path"; then 28874 BOOT_JDK="$new_path" 28875 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28876 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28877 fi 28878 28879 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28880 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28881 28882 else 28883 # We're on a unix platform. Hooray! :) 28884 path="$BOOT_JDK" 28885 has_space=`$ECHO "$path" | $GREP " "` 28886 if test "x$has_space" != x; then 28887 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28888 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28889 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28890 fi 28891 28892 # Use eval to expand a potential ~ 28893 eval path="$path" 28894 if test ! -f "$path" && test ! -d "$path"; then 28895 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28896 fi 28897 28898 if test -d "$path"; then 28899 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28900 else 28901 dir="`$DIRNAME "$path"`" 28902 base="`$BASENAME "$path"`" 28903 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28904 fi 28905 fi 28906 fi 28907 28908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28909 $as_echo_n "checking for Boot JDK... " >&6; } 28910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28911 $as_echo "$BOOT_JDK" >&6; } 28912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28913 $as_echo_n "checking Boot JDK version... " >&6; } 28914 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28916 $as_echo "$BOOT_JDK_VERSION" >&6; } 28917 fi # end check jdk version 28918 fi # end check javac 28919 fi # end check java 28920 fi # end check boot jdk found 28921 fi 28922 28923 28924 if test "x$BOOT_JDK_FOUND" = xno; then 28925 # Now execute the test 28926 28927 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 28928 BOOT_JDK_SUFFIX="/Contents/Home" 28929 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28930 if test "x$ALL_JDKS_FOUND" != x; then 28931 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28932 28933 if test "x$BOOT_JDK_FOUND" = xno; then 28934 # Now execute the test 28935 28936 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28937 if test -d "$BOOT_JDK"; then 28938 BOOT_JDK_FOUND=maybe 28939 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28940 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28941 fi 28942 28943 28944 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28945 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28946 # Do we have a bin/java? 28947 if test ! -x "$BOOT_JDK/bin/java"; then 28948 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28949 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28950 BOOT_JDK_FOUND=no 28951 else 28952 # Do we have a bin/javac? 28953 if test ! -x "$BOOT_JDK/bin/javac"; then 28954 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28955 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28956 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28957 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28958 BOOT_JDK_FOUND=no 28959 else 28960 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28961 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28962 28963 # Extra M4 quote needed to protect [] in grep expression. 28964 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28965 if test "x$FOUND_CORRECT_VERSION" = x; then 28966 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28967 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28968 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28969 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28970 BOOT_JDK_FOUND=no 28971 else 28972 # We're done! :-) 28973 BOOT_JDK_FOUND=yes 28974 28975 # Only process if variable expands to non-empty 28976 28977 if test "x$BOOT_JDK" != x; then 28978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28979 28980 # Input might be given as Windows format, start by converting to 28981 # unix format. 28982 path="$BOOT_JDK" 28983 new_path=`$CYGPATH -u "$path"` 28984 28985 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28986 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28987 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28988 # "foo.exe" is OK but "foo" is an error. 28989 # 28990 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28991 # It is also a way to make sure we got the proper file name for the real test later on. 28992 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28993 if test "x$test_shortpath" = x; then 28994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28995 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28996 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28997 fi 28998 28999 # Call helper function which possibly converts this using DOS-style short mode. 29000 # If so, the updated path is stored in $new_path. 29001 29002 input_path="$new_path" 29003 # Check if we need to convert this using DOS-style short mode. If the path 29004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29005 # take no chances and rewrite it. 29006 # Note: m4 eats our [], so we need to use [ and ] instead. 29007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29008 if test "x$has_forbidden_chars" != x; then 29009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29010 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29011 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29012 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29013 # Going to short mode and back again did indeed matter. Since short mode is 29014 # case insensitive, let's make it lowercase to improve readability. 29015 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29016 # Now convert it back to Unix-style (cygpath) 29017 input_path=`$CYGPATH -u "$shortmode_path"` 29018 new_path="$input_path" 29019 fi 29020 fi 29021 29022 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29023 if test "x$test_cygdrive_prefix" = x; then 29024 # As a simple fix, exclude /usr/bin since it's not a real path. 29025 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29026 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29027 # a path prefixed by /cygdrive for fixpath to work. 29028 new_path="$CYGWIN_ROOT_PATH$input_path" 29029 fi 29030 fi 29031 29032 29033 if test "x$path" != "x$new_path"; then 29034 BOOT_JDK="$new_path" 29035 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29036 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29037 fi 29038 29039 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29040 29041 path="$BOOT_JDK" 29042 has_colon=`$ECHO $path | $GREP ^.:` 29043 new_path="$path" 29044 if test "x$has_colon" = x; then 29045 # Not in mixed or Windows style, start by that. 29046 new_path=`cmd //c echo $path` 29047 fi 29048 29049 29050 input_path="$new_path" 29051 # Check if we need to convert this using DOS-style short mode. If the path 29052 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29053 # take no chances and rewrite it. 29054 # Note: m4 eats our [], so we need to use [ and ] instead. 29055 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29056 if test "x$has_forbidden_chars" != x; then 29057 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29058 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29059 fi 29060 29061 29062 windows_path="$new_path" 29063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29064 unix_path=`$CYGPATH -u "$windows_path"` 29065 new_path="$unix_path" 29066 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29067 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29068 new_path="$unix_path" 29069 fi 29070 29071 if test "x$path" != "x$new_path"; then 29072 BOOT_JDK="$new_path" 29073 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29074 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29075 fi 29076 29077 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29078 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29079 29080 else 29081 # We're on a unix platform. Hooray! :) 29082 path="$BOOT_JDK" 29083 has_space=`$ECHO "$path" | $GREP " "` 29084 if test "x$has_space" != x; then 29085 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29086 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29087 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29088 fi 29089 29090 # Use eval to expand a potential ~ 29091 eval path="$path" 29092 if test ! -f "$path" && test ! -d "$path"; then 29093 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29094 fi 29095 29096 if test -d "$path"; then 29097 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29098 else 29099 dir="`$DIRNAME "$path"`" 29100 base="`$BASENAME "$path"`" 29101 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29102 fi 29103 fi 29104 fi 29105 29106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29107 $as_echo_n "checking for Boot JDK... " >&6; } 29108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29109 $as_echo "$BOOT_JDK" >&6; } 29110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29111 $as_echo_n "checking Boot JDK version... " >&6; } 29112 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29114 $as_echo "$BOOT_JDK_VERSION" >&6; } 29115 fi # end check jdk version 29116 fi # end check javac 29117 fi # end check java 29118 fi # end check boot jdk found 29119 fi 29120 29121 done 29122 fi 29123 29124 29125 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29126 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29127 # Do we have a bin/java? 29128 if test ! -x "$BOOT_JDK/bin/java"; then 29129 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29130 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29131 BOOT_JDK_FOUND=no 29132 else 29133 # Do we have a bin/javac? 29134 if test ! -x "$BOOT_JDK/bin/javac"; then 29135 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29136 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29137 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29138 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29139 BOOT_JDK_FOUND=no 29140 else 29141 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29142 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29143 29144 # Extra M4 quote needed to protect [] in grep expression. 29145 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29146 if test "x$FOUND_CORRECT_VERSION" = x; then 29147 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29148 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29149 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29150 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29151 BOOT_JDK_FOUND=no 29152 else 29153 # We're done! :-) 29154 BOOT_JDK_FOUND=yes 29155 29156 # Only process if variable expands to non-empty 29157 29158 if test "x$BOOT_JDK" != x; then 29159 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29160 29161 # Input might be given as Windows format, start by converting to 29162 # unix format. 29163 path="$BOOT_JDK" 29164 new_path=`$CYGPATH -u "$path"` 29165 29166 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29167 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29168 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29169 # "foo.exe" is OK but "foo" is an error. 29170 # 29171 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29172 # It is also a way to make sure we got the proper file name for the real test later on. 29173 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29174 if test "x$test_shortpath" = x; then 29175 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29176 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29177 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29178 fi 29179 29180 # Call helper function which possibly converts this using DOS-style short mode. 29181 # If so, the updated path is stored in $new_path. 29182 29183 input_path="$new_path" 29184 # Check if we need to convert this using DOS-style short mode. If the path 29185 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29186 # take no chances and rewrite it. 29187 # Note: m4 eats our [], so we need to use [ and ] instead. 29188 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29189 if test "x$has_forbidden_chars" != x; then 29190 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29191 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29192 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29193 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29194 # Going to short mode and back again did indeed matter. Since short mode is 29195 # case insensitive, let's make it lowercase to improve readability. 29196 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29197 # Now convert it back to Unix-style (cygpath) 29198 input_path=`$CYGPATH -u "$shortmode_path"` 29199 new_path="$input_path" 29200 fi 29201 fi 29202 29203 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29204 if test "x$test_cygdrive_prefix" = x; then 29205 # As a simple fix, exclude /usr/bin since it's not a real path. 29206 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29207 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29208 # a path prefixed by /cygdrive for fixpath to work. 29209 new_path="$CYGWIN_ROOT_PATH$input_path" 29210 fi 29211 fi 29212 29213 29214 if test "x$path" != "x$new_path"; then 29215 BOOT_JDK="$new_path" 29216 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29217 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29218 fi 29219 29220 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29221 29222 path="$BOOT_JDK" 29223 has_colon=`$ECHO $path | $GREP ^.:` 29224 new_path="$path" 29225 if test "x$has_colon" = x; then 29226 # Not in mixed or Windows style, start by that. 29227 new_path=`cmd //c echo $path` 29228 fi 29229 29230 29231 input_path="$new_path" 29232 # Check if we need to convert this using DOS-style short mode. If the path 29233 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29234 # take no chances and rewrite it. 29235 # Note: m4 eats our [], so we need to use [ and ] instead. 29236 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29237 if test "x$has_forbidden_chars" != x; then 29238 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29239 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29240 fi 29241 29242 29243 windows_path="$new_path" 29244 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29245 unix_path=`$CYGPATH -u "$windows_path"` 29246 new_path="$unix_path" 29247 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29248 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29249 new_path="$unix_path" 29250 fi 29251 29252 if test "x$path" != "x$new_path"; then 29253 BOOT_JDK="$new_path" 29254 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29255 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29256 fi 29257 29258 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29259 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29260 29261 else 29262 # We're on a unix platform. Hooray! :) 29263 path="$BOOT_JDK" 29264 has_space=`$ECHO "$path" | $GREP " "` 29265 if test "x$has_space" != x; then 29266 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29267 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29268 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29269 fi 29270 29271 # Use eval to expand a potential ~ 29272 eval path="$path" 29273 if test ! -f "$path" && test ! -d "$path"; then 29274 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29275 fi 29276 29277 if test -d "$path"; then 29278 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29279 else 29280 dir="`$DIRNAME "$path"`" 29281 base="`$BASENAME "$path"`" 29282 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29283 fi 29284 fi 29285 fi 29286 29287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29288 $as_echo_n "checking for Boot JDK... " >&6; } 29289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29290 $as_echo "$BOOT_JDK" >&6; } 29291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29292 $as_echo_n "checking Boot JDK version... " >&6; } 29293 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29295 $as_echo "$BOOT_JDK_VERSION" >&6; } 29296 fi # end check jdk version 29297 fi # end check javac 29298 fi # end check java 29299 fi # end check boot jdk found 29300 fi 29301 29302 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 29303 29304 if test "x$BOOT_JDK_FOUND" = xno; then 29305 # Now execute the test 29306 29307 BOOT_JDK_PREFIX="/usr/lib/jvm" 29308 BOOT_JDK_SUFFIX="" 29309 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29310 if test "x$ALL_JDKS_FOUND" != x; then 29311 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29312 29313 if test "x$BOOT_JDK_FOUND" = xno; then 29314 # Now execute the test 29315 29316 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29317 if test -d "$BOOT_JDK"; then 29318 BOOT_JDK_FOUND=maybe 29319 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29320 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29321 fi 29322 29323 29324 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29325 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29326 # Do we have a bin/java? 29327 if test ! -x "$BOOT_JDK/bin/java"; then 29328 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29329 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29330 BOOT_JDK_FOUND=no 29331 else 29332 # Do we have a bin/javac? 29333 if test ! -x "$BOOT_JDK/bin/javac"; then 29334 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29335 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29336 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29337 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29338 BOOT_JDK_FOUND=no 29339 else 29340 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29341 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29342 29343 # Extra M4 quote needed to protect [] in grep expression. 29344 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29345 if test "x$FOUND_CORRECT_VERSION" = x; then 29346 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29347 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29348 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29349 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29350 BOOT_JDK_FOUND=no 29351 else 29352 # We're done! :-) 29353 BOOT_JDK_FOUND=yes 29354 29355 # Only process if variable expands to non-empty 29356 29357 if test "x$BOOT_JDK" != x; then 29358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29359 29360 # Input might be given as Windows format, start by converting to 29361 # unix format. 29362 path="$BOOT_JDK" 29363 new_path=`$CYGPATH -u "$path"` 29364 29365 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29366 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29367 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29368 # "foo.exe" is OK but "foo" is an error. 29369 # 29370 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29371 # It is also a way to make sure we got the proper file name for the real test later on. 29372 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29373 if test "x$test_shortpath" = x; then 29374 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29375 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29376 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29377 fi 29378 29379 # Call helper function which possibly converts this using DOS-style short mode. 29380 # If so, the updated path is stored in $new_path. 29381 29382 input_path="$new_path" 29383 # Check if we need to convert this using DOS-style short mode. If the path 29384 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29385 # take no chances and rewrite it. 29386 # Note: m4 eats our [], so we need to use [ and ] instead. 29387 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29388 if test "x$has_forbidden_chars" != x; then 29389 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29390 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29391 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29392 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29393 # Going to short mode and back again did indeed matter. Since short mode is 29394 # case insensitive, let's make it lowercase to improve readability. 29395 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29396 # Now convert it back to Unix-style (cygpath) 29397 input_path=`$CYGPATH -u "$shortmode_path"` 29398 new_path="$input_path" 29399 fi 29400 fi 29401 29402 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29403 if test "x$test_cygdrive_prefix" = x; then 29404 # As a simple fix, exclude /usr/bin since it's not a real path. 29405 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29406 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29407 # a path prefixed by /cygdrive for fixpath to work. 29408 new_path="$CYGWIN_ROOT_PATH$input_path" 29409 fi 29410 fi 29411 29412 29413 if test "x$path" != "x$new_path"; then 29414 BOOT_JDK="$new_path" 29415 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29416 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29417 fi 29418 29419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29420 29421 path="$BOOT_JDK" 29422 has_colon=`$ECHO $path | $GREP ^.:` 29423 new_path="$path" 29424 if test "x$has_colon" = x; then 29425 # Not in mixed or Windows style, start by that. 29426 new_path=`cmd //c echo $path` 29427 fi 29428 29429 29430 input_path="$new_path" 29431 # Check if we need to convert this using DOS-style short mode. If the path 29432 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29433 # take no chances and rewrite it. 29434 # Note: m4 eats our [], so we need to use [ and ] instead. 29435 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29436 if test "x$has_forbidden_chars" != x; then 29437 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29438 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29439 fi 29440 29441 29442 windows_path="$new_path" 29443 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29444 unix_path=`$CYGPATH -u "$windows_path"` 29445 new_path="$unix_path" 29446 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29447 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29448 new_path="$unix_path" 29449 fi 29450 29451 if test "x$path" != "x$new_path"; then 29452 BOOT_JDK="$new_path" 29453 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29454 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29455 fi 29456 29457 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29458 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29459 29460 else 29461 # We're on a unix platform. Hooray! :) 29462 path="$BOOT_JDK" 29463 has_space=`$ECHO "$path" | $GREP " "` 29464 if test "x$has_space" != x; then 29465 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29466 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29467 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29468 fi 29469 29470 # Use eval to expand a potential ~ 29471 eval path="$path" 29472 if test ! -f "$path" && test ! -d "$path"; then 29473 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29474 fi 29475 29476 if test -d "$path"; then 29477 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29478 else 29479 dir="`$DIRNAME "$path"`" 29480 base="`$BASENAME "$path"`" 29481 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29482 fi 29483 fi 29484 fi 29485 29486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29487 $as_echo_n "checking for Boot JDK... " >&6; } 29488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29489 $as_echo "$BOOT_JDK" >&6; } 29490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29491 $as_echo_n "checking Boot JDK version... " >&6; } 29492 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29494 $as_echo "$BOOT_JDK_VERSION" >&6; } 29495 fi # end check jdk version 29496 fi # end check javac 29497 fi # end check java 29498 fi # end check boot jdk found 29499 fi 29500 29501 done 29502 fi 29503 29504 29505 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29506 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29507 # Do we have a bin/java? 29508 if test ! -x "$BOOT_JDK/bin/java"; then 29509 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29510 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29511 BOOT_JDK_FOUND=no 29512 else 29513 # Do we have a bin/javac? 29514 if test ! -x "$BOOT_JDK/bin/javac"; then 29515 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29516 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29517 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29518 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29519 BOOT_JDK_FOUND=no 29520 else 29521 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29522 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29523 29524 # Extra M4 quote needed to protect [] in grep expression. 29525 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29526 if test "x$FOUND_CORRECT_VERSION" = x; then 29527 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29528 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29529 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29530 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29531 BOOT_JDK_FOUND=no 29532 else 29533 # We're done! :-) 29534 BOOT_JDK_FOUND=yes 29535 29536 # Only process if variable expands to non-empty 29537 29538 if test "x$BOOT_JDK" != x; then 29539 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29540 29541 # Input might be given as Windows format, start by converting to 29542 # unix format. 29543 path="$BOOT_JDK" 29544 new_path=`$CYGPATH -u "$path"` 29545 29546 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29547 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29548 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29549 # "foo.exe" is OK but "foo" is an error. 29550 # 29551 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29552 # It is also a way to make sure we got the proper file name for the real test later on. 29553 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29554 if test "x$test_shortpath" = x; then 29555 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29556 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29557 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29558 fi 29559 29560 # Call helper function which possibly converts this using DOS-style short mode. 29561 # If so, the updated path is stored in $new_path. 29562 29563 input_path="$new_path" 29564 # Check if we need to convert this using DOS-style short mode. If the path 29565 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29566 # take no chances and rewrite it. 29567 # Note: m4 eats our [], so we need to use [ and ] instead. 29568 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29569 if test "x$has_forbidden_chars" != x; then 29570 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29571 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29572 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29573 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29574 # Going to short mode and back again did indeed matter. Since short mode is 29575 # case insensitive, let's make it lowercase to improve readability. 29576 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29577 # Now convert it back to Unix-style (cygpath) 29578 input_path=`$CYGPATH -u "$shortmode_path"` 29579 new_path="$input_path" 29580 fi 29581 fi 29582 29583 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29584 if test "x$test_cygdrive_prefix" = x; then 29585 # As a simple fix, exclude /usr/bin since it's not a real path. 29586 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29587 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29588 # a path prefixed by /cygdrive for fixpath to work. 29589 new_path="$CYGWIN_ROOT_PATH$input_path" 29590 fi 29591 fi 29592 29593 29594 if test "x$path" != "x$new_path"; then 29595 BOOT_JDK="$new_path" 29596 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29597 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29598 fi 29599 29600 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29601 29602 path="$BOOT_JDK" 29603 has_colon=`$ECHO $path | $GREP ^.:` 29604 new_path="$path" 29605 if test "x$has_colon" = x; then 29606 # Not in mixed or Windows style, start by that. 29607 new_path=`cmd //c echo $path` 29608 fi 29609 29610 29611 input_path="$new_path" 29612 # Check if we need to convert this using DOS-style short mode. If the path 29613 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29614 # take no chances and rewrite it. 29615 # Note: m4 eats our [], so we need to use [ and ] instead. 29616 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29617 if test "x$has_forbidden_chars" != x; then 29618 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29619 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29620 fi 29621 29622 29623 windows_path="$new_path" 29624 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29625 unix_path=`$CYGPATH -u "$windows_path"` 29626 new_path="$unix_path" 29627 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29628 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29629 new_path="$unix_path" 29630 fi 29631 29632 if test "x$path" != "x$new_path"; then 29633 BOOT_JDK="$new_path" 29634 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29635 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29636 fi 29637 29638 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29639 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29640 29641 else 29642 # We're on a unix platform. Hooray! :) 29643 path="$BOOT_JDK" 29644 has_space=`$ECHO "$path" | $GREP " "` 29645 if test "x$has_space" != x; then 29646 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29647 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29648 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29649 fi 29650 29651 # Use eval to expand a potential ~ 29652 eval path="$path" 29653 if test ! -f "$path" && test ! -d "$path"; then 29654 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29655 fi 29656 29657 if test -d "$path"; then 29658 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29659 else 29660 dir="`$DIRNAME "$path"`" 29661 base="`$BASENAME "$path"`" 29662 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29663 fi 29664 fi 29665 fi 29666 29667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29668 $as_echo_n "checking for Boot JDK... " >&6; } 29669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29670 $as_echo "$BOOT_JDK" >&6; } 29671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29672 $as_echo_n "checking Boot JDK version... " >&6; } 29673 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29675 $as_echo "$BOOT_JDK_VERSION" >&6; } 29676 fi # end check jdk version 29677 fi # end check javac 29678 fi # end check java 29679 fi # end check boot jdk found 29680 fi 29681 29682 fi 29683 29684 29685 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29686 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29687 # Do we have a bin/java? 29688 if test ! -x "$BOOT_JDK/bin/java"; then 29689 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29690 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29691 BOOT_JDK_FOUND=no 29692 else 29693 # Do we have a bin/javac? 29694 if test ! -x "$BOOT_JDK/bin/javac"; then 29695 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29696 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29697 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29698 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29699 BOOT_JDK_FOUND=no 29700 else 29701 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29702 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29703 29704 # Extra M4 quote needed to protect [] in grep expression. 29705 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29706 if test "x$FOUND_CORRECT_VERSION" = x; then 29707 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29708 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29709 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29710 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29711 BOOT_JDK_FOUND=no 29712 else 29713 # We're done! :-) 29714 BOOT_JDK_FOUND=yes 29715 29716 # Only process if variable expands to non-empty 29717 29718 if test "x$BOOT_JDK" != x; then 29719 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29720 29721 # Input might be given as Windows format, start by converting to 29722 # unix format. 29723 path="$BOOT_JDK" 29724 new_path=`$CYGPATH -u "$path"` 29725 29726 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29727 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29728 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29729 # "foo.exe" is OK but "foo" is an error. 29730 # 29731 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29732 # It is also a way to make sure we got the proper file name for the real test later on. 29733 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29734 if test "x$test_shortpath" = x; then 29735 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29736 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29737 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29738 fi 29739 29740 # Call helper function which possibly converts this using DOS-style short mode. 29741 # If so, the updated path is stored in $new_path. 29742 29743 input_path="$new_path" 29744 # Check if we need to convert this using DOS-style short mode. If the path 29745 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29746 # take no chances and rewrite it. 29747 # Note: m4 eats our [], so we need to use [ and ] instead. 29748 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29749 if test "x$has_forbidden_chars" != x; then 29750 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29751 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29752 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29753 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29754 # Going to short mode and back again did indeed matter. Since short mode is 29755 # case insensitive, let's make it lowercase to improve readability. 29756 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29757 # Now convert it back to Unix-style (cygpath) 29758 input_path=`$CYGPATH -u "$shortmode_path"` 29759 new_path="$input_path" 29760 fi 29761 fi 29762 29763 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29764 if test "x$test_cygdrive_prefix" = x; then 29765 # As a simple fix, exclude /usr/bin since it's not a real path. 29766 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29767 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29768 # a path prefixed by /cygdrive for fixpath to work. 29769 new_path="$CYGWIN_ROOT_PATH$input_path" 29770 fi 29771 fi 29772 29773 29774 if test "x$path" != "x$new_path"; then 29775 BOOT_JDK="$new_path" 29776 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29777 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29778 fi 29779 29780 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29781 29782 path="$BOOT_JDK" 29783 has_colon=`$ECHO $path | $GREP ^.:` 29784 new_path="$path" 29785 if test "x$has_colon" = x; then 29786 # Not in mixed or Windows style, start by that. 29787 new_path=`cmd //c echo $path` 29788 fi 29789 29790 29791 input_path="$new_path" 29792 # Check if we need to convert this using DOS-style short mode. If the path 29793 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29794 # take no chances and rewrite it. 29795 # Note: m4 eats our [], so we need to use [ and ] instead. 29796 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29797 if test "x$has_forbidden_chars" != x; then 29798 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29799 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29800 fi 29801 29802 29803 windows_path="$new_path" 29804 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29805 unix_path=`$CYGPATH -u "$windows_path"` 29806 new_path="$unix_path" 29807 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29808 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29809 new_path="$unix_path" 29810 fi 29811 29812 if test "x$path" != "x$new_path"; then 29813 BOOT_JDK="$new_path" 29814 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29815 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29816 fi 29817 29818 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29819 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29820 29821 else 29822 # We're on a unix platform. Hooray! :) 29823 path="$BOOT_JDK" 29824 has_space=`$ECHO "$path" | $GREP " "` 29825 if test "x$has_space" != x; then 29826 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29827 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29828 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29829 fi 29830 29831 # Use eval to expand a potential ~ 29832 eval path="$path" 29833 if test ! -f "$path" && test ! -d "$path"; then 29834 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29835 fi 29836 29837 if test -d "$path"; then 29838 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29839 else 29840 dir="`$DIRNAME "$path"`" 29841 base="`$BASENAME "$path"`" 29842 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29843 fi 29844 fi 29845 fi 29846 29847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29848 $as_echo_n "checking for Boot JDK... " >&6; } 29849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29850 $as_echo "$BOOT_JDK" >&6; } 29851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29852 $as_echo_n "checking Boot JDK version... " >&6; } 29853 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29855 $as_echo "$BOOT_JDK_VERSION" >&6; } 29856 fi # end check jdk version 29857 fi # end check javac 29858 fi # end check java 29859 fi # end check boot jdk found 29860 fi 29861 29862 29863 # If we haven't found anything yet, we've truly lost. Give up. 29864 if test "x$BOOT_JDK_FOUND" = xno; then 29865 29866 # Print a helpful message on how to acquire the necessary build dependency. 29867 # openjdk is the help tag: freetype, cups, alsa etc 29868 MISSING_DEPENDENCY=openjdk 29869 29870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29871 cygwin_help $MISSING_DEPENDENCY 29872 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29873 msys_help $MISSING_DEPENDENCY 29874 else 29875 PKGHANDLER_COMMAND= 29876 29877 case $PKGHANDLER in 29878 apt-get) 29879 apt_help $MISSING_DEPENDENCY ;; 29880 yum) 29881 yum_help $MISSING_DEPENDENCY ;; 29882 port) 29883 port_help $MISSING_DEPENDENCY ;; 29884 pkgutil) 29885 pkgutil_help $MISSING_DEPENDENCY ;; 29886 pkgadd) 29887 pkgadd_help $MISSING_DEPENDENCY ;; 29888 esac 29889 29890 if test "x$PKGHANDLER_COMMAND" != x; then 29891 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 29892 fi 29893 fi 29894 29895 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 29896 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 29897 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5 29898 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29899 as_fn_error $? "Cannot continue" "$LINENO" 5 29900 fi 29901 29902 29903 29904 # Setup tools from the Boot JDK. 29905 29906 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 29907 29908 # Publish this variable in the help. 29909 29910 29911 if [ -z "${JAVA+x}" ]; then 29912 # The variable is not set by user, try to locate tool using the code snippet 29913 29914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 29915 $as_echo_n "checking for java in Boot JDK... " >&6; } 29916 JAVA=$BOOT_JDK/bin/java 29917 if test ! -x $JAVA; then 29918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29919 $as_echo "not found" >&6; } 29920 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29921 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29922 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 29923 fi 29924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29925 $as_echo "ok" >&6; } 29926 29927 29928 else 29929 # The variable is set, but is it from the command line or the environment? 29930 29931 # Try to remove the string !JAVA! from our list. 29932 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 29933 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29934 # If it failed, the variable was not from the command line. Ignore it, 29935 # but warn the user (except for BASH, which is always set by the calling BASH). 29936 if test "xJAVA" != xBASH; then 29937 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 29938 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 29939 fi 29940 # Try to locate tool using the code snippet 29941 29942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 29943 $as_echo_n "checking for java in Boot JDK... " >&6; } 29944 JAVA=$BOOT_JDK/bin/java 29945 if test ! -x $JAVA; then 29946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29947 $as_echo "not found" >&6; } 29948 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29949 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29950 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 29951 fi 29952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29953 $as_echo "ok" >&6; } 29954 29955 29956 else 29957 # If it succeeded, then it was overridden by the user. We will use it 29958 # for the tool. 29959 29960 # First remove it from the list of overridden variables, so we can test 29961 # for unknown variables in the end. 29962 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29963 29964 # Check if we try to supply an empty value 29965 if test "x$JAVA" = x; then 29966 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 29967 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 29968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 29969 $as_echo_n "checking for JAVA... " >&6; } 29970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29971 $as_echo "disabled" >&6; } 29972 else 29973 # Check if the provided tool contains a complete path. 29974 tool_specified="$JAVA" 29975 tool_basename="${tool_specified##*/}" 29976 if test "x$tool_basename" = "x$tool_specified"; then 29977 # A command without a complete path is provided, search $PATH. 29978 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 29979 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 29980 # Extract the first word of "$tool_basename", so it can be a program name with args. 29981 set dummy $tool_basename; ac_word=$2 29982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29983 $as_echo_n "checking for $ac_word... " >&6; } 29984 if ${ac_cv_path_JAVA+:} false; then : 29985 $as_echo_n "(cached) " >&6 29986 else 29987 case $JAVA in 29988 [\\/]* | ?:[\\/]*) 29989 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 29990 ;; 29991 *) 29992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29993 for as_dir in $PATH 29994 do 29995 IFS=$as_save_IFS 29996 test -z "$as_dir" && as_dir=. 29997 for ac_exec_ext in '' $ac_executable_extensions; do 29998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29999 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 30000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30001 break 2 30002 fi 30003 done 30004 done 30005 IFS=$as_save_IFS 30006 30007 ;; 30008 esac 30009 fi 30010 JAVA=$ac_cv_path_JAVA 30011 if test -n "$JAVA"; then 30012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 30013 $as_echo "$JAVA" >&6; } 30014 else 30015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30016 $as_echo "no" >&6; } 30017 fi 30018 30019 30020 if test "x$JAVA" = x; then 30021 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30022 fi 30023 else 30024 # Otherwise we believe it is a complete path. Use it as it is. 30025 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30026 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30028 $as_echo_n "checking for JAVA... " >&6; } 30029 if test ! -x "$tool_specified"; then 30030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30031 $as_echo "not found" >&6; } 30032 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30033 fi 30034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30035 $as_echo "$tool_specified" >&6; } 30036 fi 30037 fi 30038 fi 30039 30040 fi 30041 30042 30043 30044 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30045 30046 # Publish this variable in the help. 30047 30048 30049 if [ -z "${JAVAC+x}" ]; then 30050 # The variable is not set by user, try to locate tool using the code snippet 30051 30052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30053 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30054 JAVAC=$BOOT_JDK/bin/javac 30055 if test ! -x $JAVAC; then 30056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30057 $as_echo "not found" >&6; } 30058 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30059 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30060 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30061 fi 30062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30063 $as_echo "ok" >&6; } 30064 30065 30066 else 30067 # The variable is set, but is it from the command line or the environment? 30068 30069 # Try to remove the string !JAVAC! from our list. 30070 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30071 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30072 # If it failed, the variable was not from the command line. Ignore it, 30073 # but warn the user (except for BASH, which is always set by the calling BASH). 30074 if test "xJAVAC" != xBASH; then 30075 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30076 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30077 fi 30078 # Try to locate tool using the code snippet 30079 30080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30081 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30082 JAVAC=$BOOT_JDK/bin/javac 30083 if test ! -x $JAVAC; then 30084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30085 $as_echo "not found" >&6; } 30086 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30087 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30088 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30089 fi 30090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30091 $as_echo "ok" >&6; } 30092 30093 30094 else 30095 # If it succeeded, then it was overridden by the user. We will use it 30096 # for the tool. 30097 30098 # First remove it from the list of overridden variables, so we can test 30099 # for unknown variables in the end. 30100 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30101 30102 # Check if we try to supply an empty value 30103 if test "x$JAVAC" = x; then 30104 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30105 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30107 $as_echo_n "checking for JAVAC... " >&6; } 30108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30109 $as_echo "disabled" >&6; } 30110 else 30111 # Check if the provided tool contains a complete path. 30112 tool_specified="$JAVAC" 30113 tool_basename="${tool_specified##*/}" 30114 if test "x$tool_basename" = "x$tool_specified"; then 30115 # A command without a complete path is provided, search $PATH. 30116 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30117 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30118 # Extract the first word of "$tool_basename", so it can be a program name with args. 30119 set dummy $tool_basename; ac_word=$2 30120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30121 $as_echo_n "checking for $ac_word... " >&6; } 30122 if ${ac_cv_path_JAVAC+:} false; then : 30123 $as_echo_n "(cached) " >&6 30124 else 30125 case $JAVAC in 30126 [\\/]* | ?:[\\/]*) 30127 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30128 ;; 30129 *) 30130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30131 for as_dir in $PATH 30132 do 30133 IFS=$as_save_IFS 30134 test -z "$as_dir" && as_dir=. 30135 for ac_exec_ext in '' $ac_executable_extensions; do 30136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30137 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30139 break 2 30140 fi 30141 done 30142 done 30143 IFS=$as_save_IFS 30144 30145 ;; 30146 esac 30147 fi 30148 JAVAC=$ac_cv_path_JAVAC 30149 if test -n "$JAVAC"; then 30150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 30151 $as_echo "$JAVAC" >&6; } 30152 else 30153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30154 $as_echo "no" >&6; } 30155 fi 30156 30157 30158 if test "x$JAVAC" = x; then 30159 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30160 fi 30161 else 30162 # Otherwise we believe it is a complete path. Use it as it is. 30163 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 30164 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 30165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30166 $as_echo_n "checking for JAVAC... " >&6; } 30167 if test ! -x "$tool_specified"; then 30168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30169 $as_echo "not found" >&6; } 30170 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 30171 fi 30172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30173 $as_echo "$tool_specified" >&6; } 30174 fi 30175 fi 30176 fi 30177 30178 fi 30179 30180 30181 30182 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30183 30184 # Publish this variable in the help. 30185 30186 30187 if [ -z "${JAVAH+x}" ]; then 30188 # The variable is not set by user, try to locate tool using the code snippet 30189 30190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30191 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30192 JAVAH=$BOOT_JDK/bin/javah 30193 if test ! -x $JAVAH; then 30194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30195 $as_echo "not found" >&6; } 30196 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30197 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30198 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30199 fi 30200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30201 $as_echo "ok" >&6; } 30202 30203 30204 else 30205 # The variable is set, but is it from the command line or the environment? 30206 30207 # Try to remove the string !JAVAH! from our list. 30208 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 30209 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30210 # If it failed, the variable was not from the command line. Ignore it, 30211 # but warn the user (except for BASH, which is always set by the calling BASH). 30212 if test "xJAVAH" != xBASH; then 30213 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 30214 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 30215 fi 30216 # Try to locate tool using the code snippet 30217 30218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30219 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30220 JAVAH=$BOOT_JDK/bin/javah 30221 if test ! -x $JAVAH; then 30222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30223 $as_echo "not found" >&6; } 30224 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30225 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30226 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30227 fi 30228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30229 $as_echo "ok" >&6; } 30230 30231 30232 else 30233 # If it succeeded, then it was overridden by the user. We will use it 30234 # for the tool. 30235 30236 # First remove it from the list of overridden variables, so we can test 30237 # for unknown variables in the end. 30238 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30239 30240 # Check if we try to supply an empty value 30241 if test "x$JAVAH" = x; then 30242 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 30243 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 30244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30245 $as_echo_n "checking for JAVAH... " >&6; } 30246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30247 $as_echo "disabled" >&6; } 30248 else 30249 # Check if the provided tool contains a complete path. 30250 tool_specified="$JAVAH" 30251 tool_basename="${tool_specified##*/}" 30252 if test "x$tool_basename" = "x$tool_specified"; then 30253 # A command without a complete path is provided, search $PATH. 30254 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 30255 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 30256 # Extract the first word of "$tool_basename", so it can be a program name with args. 30257 set dummy $tool_basename; ac_word=$2 30258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30259 $as_echo_n "checking for $ac_word... " >&6; } 30260 if ${ac_cv_path_JAVAH+:} false; then : 30261 $as_echo_n "(cached) " >&6 30262 else 30263 case $JAVAH in 30264 [\\/]* | ?:[\\/]*) 30265 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 30266 ;; 30267 *) 30268 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30269 for as_dir in $PATH 30270 do 30271 IFS=$as_save_IFS 30272 test -z "$as_dir" && as_dir=. 30273 for ac_exec_ext in '' $ac_executable_extensions; do 30274 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30275 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 30276 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30277 break 2 30278 fi 30279 done 30280 done 30281 IFS=$as_save_IFS 30282 30283 ;; 30284 esac 30285 fi 30286 JAVAH=$ac_cv_path_JAVAH 30287 if test -n "$JAVAH"; then 30288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 30289 $as_echo "$JAVAH" >&6; } 30290 else 30291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30292 $as_echo "no" >&6; } 30293 fi 30294 30295 30296 if test "x$JAVAH" = x; then 30297 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30298 fi 30299 else 30300 # Otherwise we believe it is a complete path. Use it as it is. 30301 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 30302 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 30303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30304 $as_echo_n "checking for JAVAH... " >&6; } 30305 if test ! -x "$tool_specified"; then 30306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30307 $as_echo "not found" >&6; } 30308 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 30309 fi 30310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30311 $as_echo "$tool_specified" >&6; } 30312 fi 30313 fi 30314 fi 30315 30316 fi 30317 30318 30319 30320 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30321 30322 # Publish this variable in the help. 30323 30324 30325 if [ -z "${JAR+x}" ]; then 30326 # The variable is not set by user, try to locate tool using the code snippet 30327 30328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30329 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30330 JAR=$BOOT_JDK/bin/jar 30331 if test ! -x $JAR; then 30332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30333 $as_echo "not found" >&6; } 30334 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30335 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30336 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30337 fi 30338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30339 $as_echo "ok" >&6; } 30340 30341 30342 else 30343 # The variable is set, but is it from the command line or the environment? 30344 30345 # Try to remove the string !JAR! from our list. 30346 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 30347 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30348 # If it failed, the variable was not from the command line. Ignore it, 30349 # but warn the user (except for BASH, which is always set by the calling BASH). 30350 if test "xJAR" != xBASH; then 30351 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 30352 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 30353 fi 30354 # Try to locate tool using the code snippet 30355 30356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30357 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30358 JAR=$BOOT_JDK/bin/jar 30359 if test ! -x $JAR; then 30360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30361 $as_echo "not found" >&6; } 30362 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30363 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30364 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30365 fi 30366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30367 $as_echo "ok" >&6; } 30368 30369 30370 else 30371 # If it succeeded, then it was overridden by the user. We will use it 30372 # for the tool. 30373 30374 # First remove it from the list of overridden variables, so we can test 30375 # for unknown variables in the end. 30376 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30377 30378 # Check if we try to supply an empty value 30379 if test "x$JAR" = x; then 30380 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 30381 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 30382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30383 $as_echo_n "checking for JAR... " >&6; } 30384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30385 $as_echo "disabled" >&6; } 30386 else 30387 # Check if the provided tool contains a complete path. 30388 tool_specified="$JAR" 30389 tool_basename="${tool_specified##*/}" 30390 if test "x$tool_basename" = "x$tool_specified"; then 30391 # A command without a complete path is provided, search $PATH. 30392 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 30393 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 30394 # Extract the first word of "$tool_basename", so it can be a program name with args. 30395 set dummy $tool_basename; ac_word=$2 30396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30397 $as_echo_n "checking for $ac_word... " >&6; } 30398 if ${ac_cv_path_JAR+:} false; then : 30399 $as_echo_n "(cached) " >&6 30400 else 30401 case $JAR in 30402 [\\/]* | ?:[\\/]*) 30403 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 30404 ;; 30405 *) 30406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30407 for as_dir in $PATH 30408 do 30409 IFS=$as_save_IFS 30410 test -z "$as_dir" && as_dir=. 30411 for ac_exec_ext in '' $ac_executable_extensions; do 30412 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30413 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 30414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30415 break 2 30416 fi 30417 done 30418 done 30419 IFS=$as_save_IFS 30420 30421 ;; 30422 esac 30423 fi 30424 JAR=$ac_cv_path_JAR 30425 if test -n "$JAR"; then 30426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 30427 $as_echo "$JAR" >&6; } 30428 else 30429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30430 $as_echo "no" >&6; } 30431 fi 30432 30433 30434 if test "x$JAR" = x; then 30435 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30436 fi 30437 else 30438 # Otherwise we believe it is a complete path. Use it as it is. 30439 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 30440 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 30441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30442 $as_echo_n "checking for JAR... " >&6; } 30443 if test ! -x "$tool_specified"; then 30444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30445 $as_echo "not found" >&6; } 30446 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 30447 fi 30448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30449 $as_echo "$tool_specified" >&6; } 30450 fi 30451 fi 30452 fi 30453 30454 fi 30455 30456 30457 30458 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30459 30460 # Publish this variable in the help. 30461 30462 30463 if [ -z "${JARSIGNER+x}" ]; then 30464 # The variable is not set by user, try to locate tool using the code snippet 30465 30466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30467 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30468 JARSIGNER=$BOOT_JDK/bin/jarsigner 30469 if test ! -x $JARSIGNER; then 30470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30471 $as_echo "not found" >&6; } 30472 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30473 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30474 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30475 fi 30476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30477 $as_echo "ok" >&6; } 30478 30479 30480 else 30481 # The variable is set, but is it from the command line or the environment? 30482 30483 # Try to remove the string !JARSIGNER! from our list. 30484 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 30485 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30486 # If it failed, the variable was not from the command line. Ignore it, 30487 # but warn the user (except for BASH, which is always set by the calling BASH). 30488 if test "xJARSIGNER" != xBASH; then 30489 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 30490 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 30491 fi 30492 # Try to locate tool using the code snippet 30493 30494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30495 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30496 JARSIGNER=$BOOT_JDK/bin/jarsigner 30497 if test ! -x $JARSIGNER; then 30498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30499 $as_echo "not found" >&6; } 30500 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30501 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30502 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30503 fi 30504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30505 $as_echo "ok" >&6; } 30506 30507 30508 else 30509 # If it succeeded, then it was overridden by the user. We will use it 30510 # for the tool. 30511 30512 # First remove it from the list of overridden variables, so we can test 30513 # for unknown variables in the end. 30514 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30515 30516 # Check if we try to supply an empty value 30517 if test "x$JARSIGNER" = x; then 30518 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 30519 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 30520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30521 $as_echo_n "checking for JARSIGNER... " >&6; } 30522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30523 $as_echo "disabled" >&6; } 30524 else 30525 # Check if the provided tool contains a complete path. 30526 tool_specified="$JARSIGNER" 30527 tool_basename="${tool_specified##*/}" 30528 if test "x$tool_basename" = "x$tool_specified"; then 30529 # A command without a complete path is provided, search $PATH. 30530 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 30531 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 30532 # Extract the first word of "$tool_basename", so it can be a program name with args. 30533 set dummy $tool_basename; ac_word=$2 30534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30535 $as_echo_n "checking for $ac_word... " >&6; } 30536 if ${ac_cv_path_JARSIGNER+:} false; then : 30537 $as_echo_n "(cached) " >&6 30538 else 30539 case $JARSIGNER in 30540 [\\/]* | ?:[\\/]*) 30541 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 30542 ;; 30543 *) 30544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30545 for as_dir in $PATH 30546 do 30547 IFS=$as_save_IFS 30548 test -z "$as_dir" && as_dir=. 30549 for ac_exec_ext in '' $ac_executable_extensions; do 30550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30551 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 30552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30553 break 2 30554 fi 30555 done 30556 done 30557 IFS=$as_save_IFS 30558 30559 ;; 30560 esac 30561 fi 30562 JARSIGNER=$ac_cv_path_JARSIGNER 30563 if test -n "$JARSIGNER"; then 30564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 30565 $as_echo "$JARSIGNER" >&6; } 30566 else 30567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30568 $as_echo "no" >&6; } 30569 fi 30570 30571 30572 if test "x$JARSIGNER" = x; then 30573 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30574 fi 30575 else 30576 # Otherwise we believe it is a complete path. Use it as it is. 30577 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 30578 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 30579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30580 $as_echo_n "checking for JARSIGNER... " >&6; } 30581 if test ! -x "$tool_specified"; then 30582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30583 $as_echo "not found" >&6; } 30584 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 30585 fi 30586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30587 $as_echo "$tool_specified" >&6; } 30588 fi 30589 fi 30590 fi 30591 30592 fi 30593 30594 30595 30596 # Finally, set some other options... 30597 30598 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 30599 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 30600 30601 30602 30603 $ECHO "Check if jvm arg is ok: --patch-module foo=bar" >&5 30604 $ECHO "Command: $JAVA --patch-module foo=bar -version" >&5 30605 OUTPUT=`$JAVA --patch-module foo=bar -version 2>&1` 30606 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 30607 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 30608 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 30609 dummy="$dummy --patch-module foo=bar" 30610 JVM_ARG_OK=true 30611 else 30612 $ECHO "Arg failed:" >&5 30613 $ECHO "$OUTPUT" >&5 30614 JVM_ARG_OK=false 30615 fi 30616 30617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK supports modules" >&5 30618 $as_echo_n "checking if Boot JDK supports modules... " >&6; } 30619 if test "x$JVM_ARG_OK" = "xtrue"; then 30620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30621 $as_echo "yes" >&6; } 30622 BOOT_JDK_MODULAR="true" 30623 else 30624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30625 $as_echo "no" >&6; } 30626 BOOT_JDK_MODULAR="false" 30627 fi 30628 30629 30630 30631 30632 # Check if the boot jdk is 32 or 64 bit 30633 if "$JAVA" -d64 -version > /dev/null 2>&1; then 30634 BOOT_JDK_BITS="64" 30635 else 30636 BOOT_JDK_BITS="32" 30637 fi 30638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 30639 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 30640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 30641 $as_echo "$BOOT_JDK_BITS" >&6; } 30642 30643 30644 30645 30646 # Check whether --with-build-jdk was given. 30647 if test "${with_build_jdk+set}" = set; then : 30648 withval=$with_build_jdk; 30649 fi 30650 30651 30652 CREATE_BUILDJDK=false 30653 EXTERNAL_BUILDJDK=false 30654 BUILD_JDK_FOUND="no" 30655 if test "x$with_build_jdk" != "x"; then 30656 30657 if test "x$BUILD_JDK_FOUND" = xno; then 30658 # Execute the test 30659 30660 if test "x$with_build_jdk" != x; then 30661 BUILD_JDK=$with_build_jdk 30662 BUILD_JDK_FOUND=maybe 30663 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 30664 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 30665 fi 30666 30667 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30668 if test "x$BUILD_JDK_FOUND" = xmaybe; then 30669 # Do we have a bin/java? 30670 if test ! -x "$BUILD_JDK/bin/java"; then 30671 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 30672 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 30673 BUILD_JDK_FOUND=no 30674 elif test ! -x "$BUILD_JDK/bin/jlink"; then 30675 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 30676 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 30677 BUILD_JDK_FOUND=no 30678 elif test ! -x "$BUILD_JDK/bin/jmod"; then 30679 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 30680 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 30681 BUILD_JDK_FOUND=no 30682 elif test ! -x "$BUILD_JDK/bin/javac"; then 30683 # Do we have a bin/javac? 30684 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 30685 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 30686 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 30687 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 30688 BUILD_JDK_FOUND=no 30689 else 30690 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30691 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30692 30693 # Extra M4 quote needed to protect [] in grep expression. 30694 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"'` 30695 if test "x$FOUND_CORRECT_VERSION" = x; then 30696 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 30697 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 30698 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 9)" >&5 30699 $as_echo "$as_me: (Your Build JDK must be version 9)" >&6;} 30700 BUILD_JDK_FOUND=no 30701 else 30702 # We're done! 30703 BUILD_JDK_FOUND=yes 30704 30705 # Only process if variable expands to non-empty 30706 30707 if test "x$BUILD_JDK" != x; then 30708 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30709 30710 # Input might be given as Windows format, start by converting to 30711 # unix format. 30712 path="$BUILD_JDK" 30713 new_path=`$CYGPATH -u "$path"` 30714 30715 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30716 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30717 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30718 # "foo.exe" is OK but "foo" is an error. 30719 # 30720 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30721 # It is also a way to make sure we got the proper file name for the real test later on. 30722 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30723 if test "x$test_shortpath" = x; then 30724 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30725 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30726 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 30727 fi 30728 30729 # Call helper function which possibly converts this using DOS-style short mode. 30730 # If so, the updated path is stored in $new_path. 30731 30732 input_path="$new_path" 30733 # Check if we need to convert this using DOS-style short mode. If the path 30734 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30735 # take no chances and rewrite it. 30736 # Note: m4 eats our [], so we need to use [ and ] instead. 30737 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30738 if test "x$has_forbidden_chars" != x; then 30739 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30740 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30741 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30742 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30743 # Going to short mode and back again did indeed matter. Since short mode is 30744 # case insensitive, let's make it lowercase to improve readability. 30745 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30746 # Now convert it back to Unix-style (cygpath) 30747 input_path=`$CYGPATH -u "$shortmode_path"` 30748 new_path="$input_path" 30749 fi 30750 fi 30751 30752 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30753 if test "x$test_cygdrive_prefix" = x; then 30754 # As a simple fix, exclude /usr/bin since it's not a real path. 30755 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30756 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30757 # a path prefixed by /cygdrive for fixpath to work. 30758 new_path="$CYGWIN_ROOT_PATH$input_path" 30759 fi 30760 fi 30761 30762 30763 if test "x$path" != "x$new_path"; then 30764 BUILD_JDK="$new_path" 30765 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 30766 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 30767 fi 30768 30769 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30770 30771 path="$BUILD_JDK" 30772 has_colon=`$ECHO $path | $GREP ^.:` 30773 new_path="$path" 30774 if test "x$has_colon" = x; then 30775 # Not in mixed or Windows style, start by that. 30776 new_path=`cmd //c echo $path` 30777 fi 30778 30779 30780 input_path="$new_path" 30781 # Check if we need to convert this using DOS-style short mode. If the path 30782 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30783 # take no chances and rewrite it. 30784 # Note: m4 eats our [], so we need to use [ and ] instead. 30785 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30786 if test "x$has_forbidden_chars" != x; then 30787 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30788 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30789 fi 30790 30791 30792 windows_path="$new_path" 30793 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30794 unix_path=`$CYGPATH -u "$windows_path"` 30795 new_path="$unix_path" 30796 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30797 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30798 new_path="$unix_path" 30799 fi 30800 30801 if test "x$path" != "x$new_path"; then 30802 BUILD_JDK="$new_path" 30803 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 30804 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 30805 fi 30806 30807 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30808 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30809 30810 else 30811 # We're on a unix platform. Hooray! :) 30812 path="$BUILD_JDK" 30813 has_space=`$ECHO "$path" | $GREP " "` 30814 if test "x$has_space" != x; then 30815 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30816 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30817 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30818 fi 30819 30820 # Use eval to expand a potential ~ 30821 eval path="$path" 30822 if test ! -f "$path" && test ! -d "$path"; then 30823 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30824 fi 30825 30826 if test -d "$path"; then 30827 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 30828 else 30829 dir="`$DIRNAME "$path"`" 30830 base="`$BASENAME "$path"`" 30831 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30832 fi 30833 fi 30834 fi 30835 30836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30837 $as_echo_n "checking for Build JDK... " >&6; } 30838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 30839 $as_echo "$BUILD_JDK" >&6; } 30840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 30841 $as_echo_n "checking Build JDK version... " >&6; } 30842 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 30844 $as_echo "$BUILD_JDK_VERSION" >&6; } 30845 fi # end check jdk version 30846 fi # end check java 30847 fi # end check build jdk found 30848 fi 30849 30850 EXTERNAL_BUILDJDK=true 30851 else 30852 if test "x$COMPILE_TYPE" = "xcross"; then 30853 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 30854 BUILD_JDK_FOUND=yes 30855 CREATE_BUILDJDK=true 30856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30857 $as_echo_n "checking for Build JDK... " >&6; } 30858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 30859 $as_echo "yes, will build it for the host platform" >&6; } 30860 else 30861 BUILD_JDK="\$(JDK_OUTPUTDIR)" 30862 BUILD_JDK_FOUND=yes 30863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30864 $as_echo_n "checking for Build JDK... " >&6; } 30865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 30866 $as_echo "yes, will use output dir" >&6; } 30867 fi 30868 fi 30869 30870 JMOD="$BUILD_JDK/bin/jmod" 30871 JLINK="$BUILD_JDK/bin/jlink" 30872 30873 30874 30875 if test "x$BUILD_JDK_FOUND" != "xyes"; then 30876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30877 $as_echo_n "checking for Build JDK... " >&6; } 30878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30879 $as_echo "no" >&6; } 30880 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 30881 fi 30882 30883 30884 30885 30886 30887 30888 ############################################################################### 30889 # 30890 # Configure the sources to use. We can add or override individual directories. 30891 # 30892 ############################################################################### 30893 30894 30895 # Where are the sources. 30896 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 30897 CORBA_TOPDIR="$SRC_ROOT/corba" 30898 JAXP_TOPDIR="$SRC_ROOT/jaxp" 30899 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 30900 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 30901 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 30902 JDK_TOPDIR="$SRC_ROOT/jdk" 30903 30904 30905 30906 30907 30908 30909 30910 30911 30912 # This feature is no longer supported. 30913 30914 30915 30916 # Check whether --with-add-source-root was given. 30917 if test "${with_add_source_root+set}" = set; then : 30918 withval=$with_add_source_root; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&5 30919 $as_echo "$as_me: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&2;} 30920 fi 30921 30922 30923 30924 30925 # Check whether --with-override-source-root was given. 30926 if test "${with_override_source_root+set}" = set; then : 30927 withval=$with_override_source_root; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&5 30928 $as_echo "$as_me: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&2;} 30929 fi 30930 30931 30932 30933 30934 # Check whether --with-adds-and-overrides was given. 30935 if test "${with_adds_and_overrides+set}" = set; then : 30936 withval=$with_adds_and_overrides; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&5 30937 $as_echo "$as_me: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&2;} 30938 fi 30939 30940 30941 30942 30943 # Check whether --with-override-langtools was given. 30944 if test "${with_override_langtools+set}" = set; then : 30945 withval=$with_override_langtools; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&5 30946 $as_echo "$as_me: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&2;} 30947 fi 30948 30949 30950 30951 30952 # Check whether --with-override-corba was given. 30953 if test "${with_override_corba+set}" = set; then : 30954 withval=$with_override_corba; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-corba is deprecated and will be ignored." >&5 30955 $as_echo "$as_me: WARNING: Option --with-override-corba is deprecated and will be ignored." >&2;} 30956 fi 30957 30958 30959 30960 30961 # Check whether --with-override-jaxp was given. 30962 if test "${with_override_jaxp+set}" = set; then : 30963 withval=$with_override_jaxp; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&5 30964 $as_echo "$as_me: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&2;} 30965 fi 30966 30967 30968 30969 30970 # Check whether --with-override-jaxws was given. 30971 if test "${with_override_jaxws+set}" = set; then : 30972 withval=$with_override_jaxws; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&5 30973 $as_echo "$as_me: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&2;} 30974 fi 30975 30976 30977 30978 30979 # Check whether --with-override-hotspot was given. 30980 if test "${with_override_hotspot+set}" = set; then : 30981 withval=$with_override_hotspot; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&5 30982 $as_echo "$as_me: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&2;} 30983 fi 30984 30985 30986 30987 30988 # Check whether --with-override-nashorn was given. 30989 if test "${with_override_nashorn+set}" = set; then : 30990 withval=$with_override_nashorn; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&5 30991 $as_echo "$as_me: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&2;} 30992 fi 30993 30994 30995 30996 30997 # Check whether --with-override-jdk was given. 30998 if test "${with_override_jdk+set}" = set; then : 30999 withval=$with_override_jdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&5 31000 $as_echo "$as_me: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&2;} 31001 fi 31002 31003 31004 31005 31006 BUILD_OUTPUT="$OUTPUT_ROOT" 31007 31008 31009 HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist" 31010 BUILD_HOTSPOT=true 31011 31012 31013 31014 # Check whether --with-import-hotspot was given. 31015 if test "${with_import_hotspot+set}" = set; then : 31016 withval=$with_import_hotspot; 31017 fi 31018 31019 if test "x$with_import_hotspot" != x; then 31020 CURDIR="$PWD" 31021 cd "$with_import_hotspot" 31022 HOTSPOT_DIST="`pwd`" 31023 cd "$CURDIR" 31024 if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then 31025 as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5 31026 fi 31027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5 31028 $as_echo_n "checking if hotspot should be imported... " >&6; } 31029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5 31030 $as_echo "yes from $HOTSPOT_DIST" >&6; } 31031 BUILD_HOTSPOT=false 31032 fi 31033 31034 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 31035 31036 31037 31038 31039 # Check whether --with-import-modules was given. 31040 if test "${with_import_modules+set}" = set; then : 31041 withval=$with_import_modules; 31042 fi 31043 31044 31045 if test "x$with_import_modules" != x \ 31046 && test "x$with_import_modules" != "xno"; then 31047 if test -d "$with_import_modules"; then 31048 IMPORT_MODULES_TOPDIR="$with_import_modules" 31049 31050 # Only process if variable expands to non-empty 31051 31052 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31053 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31054 31055 # Input might be given as Windows format, start by converting to 31056 # unix format. 31057 path="$IMPORT_MODULES_TOPDIR" 31058 new_path=`$CYGPATH -u "$path"` 31059 31060 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31061 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31062 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31063 # "foo.exe" is OK but "foo" is an error. 31064 # 31065 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31066 # It is also a way to make sure we got the proper file name for the real test later on. 31067 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31068 if test "x$test_shortpath" = x; then 31069 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31070 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31071 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31072 fi 31073 31074 # Call helper function which possibly converts this using DOS-style short mode. 31075 # If so, the updated path is stored in $new_path. 31076 31077 input_path="$new_path" 31078 # Check if we need to convert this using DOS-style short mode. If the path 31079 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31080 # take no chances and rewrite it. 31081 # Note: m4 eats our [], so we need to use [ and ] instead. 31082 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31083 if test "x$has_forbidden_chars" != x; then 31084 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31085 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31086 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31087 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31088 # Going to short mode and back again did indeed matter. Since short mode is 31089 # case insensitive, let's make it lowercase to improve readability. 31090 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31091 # Now convert it back to Unix-style (cygpath) 31092 input_path=`$CYGPATH -u "$shortmode_path"` 31093 new_path="$input_path" 31094 fi 31095 fi 31096 31097 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31098 if test "x$test_cygdrive_prefix" = x; then 31099 # As a simple fix, exclude /usr/bin since it's not a real path. 31100 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31101 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31102 # a path prefixed by /cygdrive for fixpath to work. 31103 new_path="$CYGWIN_ROOT_PATH$input_path" 31104 fi 31105 fi 31106 31107 31108 if test "x$path" != "x$new_path"; then 31109 IMPORT_MODULES_TOPDIR="$new_path" 31110 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31111 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31112 fi 31113 31114 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31115 31116 path="$IMPORT_MODULES_TOPDIR" 31117 has_colon=`$ECHO $path | $GREP ^.:` 31118 new_path="$path" 31119 if test "x$has_colon" = x; then 31120 # Not in mixed or Windows style, start by that. 31121 new_path=`cmd //c echo $path` 31122 fi 31123 31124 31125 input_path="$new_path" 31126 # Check if we need to convert this using DOS-style short mode. If the path 31127 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31128 # take no chances and rewrite it. 31129 # Note: m4 eats our [], so we need to use [ and ] instead. 31130 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31131 if test "x$has_forbidden_chars" != x; then 31132 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31133 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31134 fi 31135 31136 31137 windows_path="$new_path" 31138 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31139 unix_path=`$CYGPATH -u "$windows_path"` 31140 new_path="$unix_path" 31141 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31142 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31143 new_path="$unix_path" 31144 fi 31145 31146 if test "x$path" != "x$new_path"; then 31147 IMPORT_MODULES_TOPDIR="$new_path" 31148 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31149 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31150 fi 31151 31152 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31153 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31154 31155 else 31156 # We're on a unix platform. Hooray! :) 31157 path="$IMPORT_MODULES_TOPDIR" 31158 has_space=`$ECHO "$path" | $GREP " "` 31159 if test "x$has_space" != x; then 31160 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31161 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31162 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31163 fi 31164 31165 # Use eval to expand a potential ~ 31166 eval path="$path" 31167 if test ! -f "$path" && test ! -d "$path"; then 31168 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31169 fi 31170 31171 if test -d "$path"; then 31172 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31173 else 31174 dir="`$DIRNAME "$path"`" 31175 base="`$BASENAME "$path"`" 31176 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31177 fi 31178 fi 31179 fi 31180 31181 elif test -e "$with_import_modules"; then 31182 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31183 $RM -rf "$IMPORT_MODULES_TOPDIR" 31184 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31185 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31186 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31187 fi 31188 else 31189 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31190 fi 31191 fi 31192 31193 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31194 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31195 fi 31196 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31197 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31198 fi 31199 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31200 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31201 fi 31202 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31203 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31204 fi 31205 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31206 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31207 fi 31208 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31209 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31210 fi 31211 31212 31213 31214 31215 31216 31217 31218 31219 31220 ############################################################################### 31221 # 31222 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31223 # native code. 31224 # 31225 ############################################################################### 31226 31227 # See if we are doing a complete static build or not 31228 31229 # Check whether --enable-static-build was given. 31230 if test "${enable_static_build+set}" = set; then : 31231 enableval=$enable_static_build; 31232 fi 31233 31234 STATIC_BUILD=false 31235 if test "x$enable_static_build" = "xyes"; then 31236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31237 $as_echo_n "checking if static build is enabled... " >&6; } 31238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31239 $as_echo "yes" >&6; } 31240 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 31241 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 31242 fi 31243 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 31244 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $STATIC_BUILD_CFLAGS" 31245 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $STATIC_BUILD_CFLAGS" 31246 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31247 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31248 STATIC_BUILD=true 31249 elif test "x$enable_static_build" = "xno"; then 31250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31251 $as_echo_n "checking if static build is enabled... " >&6; } 31252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31253 $as_echo "no" >&6; } 31254 elif test "x$enable_static_build" != "x"; then 31255 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 31256 fi 31257 31258 31259 31260 31261 # First determine the toolchain type (compiler family) 31262 31263 31264 # Check whether --with-toolchain-type was given. 31265 if test "${with_toolchain_type+set}" = set; then : 31266 withval=$with_toolchain_type; 31267 fi 31268 31269 31270 # Use indirect variable referencing 31271 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 31272 VALID_TOOLCHAINS=${!toolchain_var_name} 31273 31274 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31275 if test -n "$XCODEBUILD"; then 31276 # On Mac OS X, default toolchain to clang after Xcode 5 31277 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 31278 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 31279 if test $? -ne 0; then 31280 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 31281 fi 31282 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 31283 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 31284 $CUT -f 1 -d .` 31285 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 31286 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 31287 if test $XCODE_MAJOR_VERSION -ge 5; then 31288 DEFAULT_TOOLCHAIN="clang" 31289 else 31290 DEFAULT_TOOLCHAIN="gcc" 31291 fi 31292 else 31293 # If Xcode is not installed, but the command line tools are 31294 # then we can't run xcodebuild. On these systems we should 31295 # default to clang 31296 DEFAULT_TOOLCHAIN="clang" 31297 fi 31298 else 31299 # First toolchain type in the list is the default 31300 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 31301 fi 31302 31303 if test "x$with_toolchain_type" = xlist; then 31304 # List all toolchains 31305 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 31306 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 31307 for toolchain in $VALID_TOOLCHAINS; do 31308 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 31309 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31310 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 31311 done 31312 31313 exit 0 31314 elif test "x$with_toolchain_type" != x; then 31315 # User override; check that it is valid 31316 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 31317 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 31318 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 31319 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 31320 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 31321 as_fn_error $? "Cannot continue." "$LINENO" 5 31322 fi 31323 TOOLCHAIN_TYPE=$with_toolchain_type 31324 else 31325 # No flag given, use default 31326 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 31327 fi 31328 31329 31330 TOOLCHAIN_CC_BINARY_clang="clang" 31331 TOOLCHAIN_CC_BINARY_gcc="gcc" 31332 TOOLCHAIN_CC_BINARY_microsoft="cl" 31333 TOOLCHAIN_CC_BINARY_solstudio="cc" 31334 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 31335 31336 TOOLCHAIN_CXX_BINARY_clang="clang++" 31337 TOOLCHAIN_CXX_BINARY_gcc="g++" 31338 TOOLCHAIN_CXX_BINARY_microsoft="cl" 31339 TOOLCHAIN_CXX_BINARY_solstudio="CC" 31340 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 31341 31342 # Use indirect variable referencing 31343 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 31344 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31345 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 31346 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 31347 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 31348 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 31349 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 31350 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 31351 31352 31353 # Define filename patterns 31354 if test "x$OPENJDK_TARGET_OS" = xwindows; then 31355 LIBRARY_PREFIX= 31356 SHARED_LIBRARY_SUFFIX='.dll' 31357 STATIC_LIBRARY_SUFFIX='.lib' 31358 SHARED_LIBRARY='$1.dll' 31359 STATIC_LIBRARY='$1.lib' 31360 OBJ_SUFFIX='.obj' 31361 EXE_SUFFIX='.exe' 31362 else 31363 LIBRARY_PREFIX=lib 31364 SHARED_LIBRARY_SUFFIX='.so' 31365 STATIC_LIBRARY_SUFFIX='.a' 31366 SHARED_LIBRARY='lib$1.so' 31367 STATIC_LIBRARY='lib$1.a' 31368 OBJ_SUFFIX='.o' 31369 EXE_SUFFIX='' 31370 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31371 # For full static builds, we're overloading the SHARED_LIBRARY 31372 # variables in order to limit the amount of changes required. 31373 # It would be better to remove SHARED and just use LIBRARY and 31374 # LIBRARY_SUFFIX for libraries that can be built either 31375 # shared or static and use STATIC_* for libraries that are 31376 # always built statically. 31377 if test "x$STATIC_BUILD" = xtrue; then 31378 SHARED_LIBRARY='lib$1.a' 31379 SHARED_LIBRARY_SUFFIX='.a' 31380 else 31381 SHARED_LIBRARY='lib$1.dylib' 31382 SHARED_LIBRARY_SUFFIX='.dylib' 31383 fi 31384 fi 31385 fi 31386 31387 31388 31389 31390 31391 31392 31393 31394 31395 31396 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 31397 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 31398 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 31399 else 31400 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 31401 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 31402 fi 31403 31404 31405 # User supplied flags should be used when configure detects compilers 31406 31407 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 31408 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 31409 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 31410 fi 31411 31412 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 31413 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 31414 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 31415 fi 31416 31417 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 31418 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 31419 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 31420 fi 31421 31422 31423 # Check whether --with-extra-cflags was given. 31424 if test "${with_extra_cflags+set}" = set; then : 31425 withval=$with_extra_cflags; 31426 fi 31427 31428 31429 31430 # Check whether --with-extra-cxxflags was given. 31431 if test "${with_extra_cxxflags+set}" = set; then : 31432 withval=$with_extra_cxxflags; 31433 fi 31434 31435 31436 31437 # Check whether --with-extra-ldflags was given. 31438 if test "${with_extra_ldflags+set}" = set; then : 31439 withval=$with_extra_ldflags; 31440 fi 31441 31442 31443 EXTRA_CFLAGS="$with_extra_cflags" 31444 EXTRA_CXXFLAGS="$with_extra_cxxflags" 31445 EXTRA_LDFLAGS="$with_extra_ldflags" 31446 31447 # Hotspot needs these set in their legacy form 31448 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $EXTRA_CFLAGS" 31449 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $EXTRA_CXXFLAGS" 31450 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $EXTRA_LDFLAGS" 31451 31452 31453 31454 31455 31456 31457 31458 31459 31460 # The global CFLAGS and LDLAGS variables are used by configure tests and 31461 # should include the extra parameters 31462 CFLAGS="$EXTRA_CFLAGS" 31463 CXXFLAGS="$EXTRA_CXXFLAGS" 31464 LDFLAGS="$EXTRA_LDFLAGS" 31465 CPPFLAGS="" 31466 31467 # The sysroot cflags are needed for configure to be able to run the compilers 31468 31469 if test "x$SYSROOT" != "x"; then 31470 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 31471 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 31472 # Solaris Studio does not have a concept of sysroot. Instead we must 31473 # make sure the default include and lib dirs are appended to each 31474 # compile and link command line. Must also add -I-xbuiltin to enable 31475 # inlining of system functions and intrinsics. 31476 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 31477 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 31478 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \ 31479 -L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR" 31480 fi 31481 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 31482 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 31483 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 31484 elif test "x$TOOLCHAIN_TYPE" = xclang; then 31485 SYSROOT_CFLAGS="-isysroot $SYSROOT" 31486 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 31487 fi 31488 # Propagate the sysroot args to hotspot 31489 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS" 31490 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS" 31491 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS" 31492 # The global CFLAGS and LDFLAGS variables need these for configure to function 31493 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 31494 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 31495 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 31496 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 31497 fi 31498 31499 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31500 # We also need -iframework<path>/System/Library/Frameworks 31501 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31502 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31503 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 31504 # set this here so it doesn't have to be peppered throughout the forest 31505 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31506 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31507 fi 31508 31509 31510 31511 31512 31513 # Then detect the actual binaries needed 31514 31515 # FIXME: Is this needed? 31516 ac_ext=cpp 31517 ac_cpp='$CXXCPP $CPPFLAGS' 31518 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 31519 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 31520 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 31521 31522 31523 # Store the CFLAGS etc passed to the configure script. 31524 ORG_CFLAGS="$CFLAGS" 31525 ORG_CXXFLAGS="$CXXFLAGS" 31526 31527 # autoconf magic only relies on PATH, so update it if tools dir is specified 31528 OLD_PATH="$PATH" 31529 31530 # On Windows, we need to detect the visual studio installation first. 31531 # This will change the PATH, but we need to keep that new PATH even 31532 # after toolchain detection is done, since the compiler (on x86) uses 31533 # it for DLL resolution in runtime. 31534 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 31535 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 31536 31537 # Store path to cygwin link.exe to help excluding it when searching for 31538 # VS linker. This must be done before changing the PATH when looking for VS. 31539 # Extract the first word of "link", so it can be a program name with args. 31540 set dummy link; ac_word=$2 31541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31542 $as_echo_n "checking for $ac_word... " >&6; } 31543 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 31544 $as_echo_n "(cached) " >&6 31545 else 31546 case $CYGWIN_LINK in 31547 [\\/]* | ?:[\\/]*) 31548 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 31549 ;; 31550 *) 31551 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31552 for as_dir in $PATH 31553 do 31554 IFS=$as_save_IFS 31555 test -z "$as_dir" && as_dir=. 31556 for ac_exec_ext in '' $ac_executable_extensions; do 31557 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31558 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 31559 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31560 break 2 31561 fi 31562 done 31563 done 31564 IFS=$as_save_IFS 31565 31566 ;; 31567 esac 31568 fi 31569 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 31570 if test -n "$CYGWIN_LINK"; then 31571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 31572 $as_echo "$CYGWIN_LINK" >&6; } 31573 else 31574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31575 $as_echo "no" >&6; } 31576 fi 31577 31578 31579 if test "x$CYGWIN_LINK" != x; then 31580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 31581 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 31582 "$CYGWIN_LINK" --version > /dev/null 31583 if test $? -eq 0 ; then 31584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31585 $as_echo "yes" >&6; } 31586 else 31587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31588 $as_echo "no" >&6; } 31589 # This might be the VS linker. Don't exclude it later on. 31590 CYGWIN_LINK="" 31591 fi 31592 fi 31593 31594 # First-hand choice is to locate and run the vsvars bat file. 31595 31596 31597 # Check whether --with-toolchain-version was given. 31598 if test "${with_toolchain_version+set}" = set; then : 31599 withval=$with_toolchain_version; 31600 fi 31601 31602 31603 if test "x$with_toolchain_version" = xlist; then 31604 # List all toolchains 31605 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 31606 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 31607 for version in $VALID_VS_VERSIONS; do 31608 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 31609 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 31610 done 31611 31612 exit 0 31613 elif test "x$DEVKIT_VS_VERSION" != x; then 31614 VS_VERSION=$DEVKIT_VS_VERSION 31615 TOOLCHAIN_VERSION=$VS_VERSION 31616 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 31617 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 31618 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 31619 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 31620 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31621 VS_PATH="$TOOLCHAIN_PATH:$PATH" 31622 31623 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 31624 # can still be exported as INCLUDE for compiler invocations without 31625 # SYSROOT_CFLAGS 31626 OLDIFS="$IFS" 31627 IFS=";" 31628 for i in $DEVKIT_VS_INCLUDE; do 31629 ipath=$i 31630 31631 unix_path="$ipath" 31632 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31633 windows_path=`$CYGPATH -m "$unix_path"` 31634 ipath="$windows_path" 31635 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31636 windows_path=`cmd //c echo $unix_path` 31637 ipath="$windows_path" 31638 fi 31639 31640 VS_INCLUDE="$VS_INCLUDE;$ipath" 31641 done 31642 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 31643 # as LIB for compiler invocations without SYSROOT_LDFLAGS 31644 for i in $DEVKIT_VS_LIB; do 31645 libpath=$i 31646 31647 unix_path="$libpath" 31648 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31649 windows_path=`$CYGPATH -m "$unix_path"` 31650 libpath="$windows_path" 31651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31652 windows_path=`cmd //c echo $unix_path` 31653 libpath="$windows_path" 31654 fi 31655 31656 VS_LIB="$VS_LIB;$libpath" 31657 done 31658 IFS="$OLDIFS" 31659 31660 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 31661 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 31662 31663 elif test "x$with_toolchain_version" != x; then 31664 # User override; check that it is valid 31665 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 31666 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 31667 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 31668 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 31669 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 31670 as_fn_error $? "Cannot continue." "$LINENO" 5 31671 fi 31672 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 31673 else 31674 # No flag given, use default 31675 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 31676 fi 31677 31678 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 31679 31680 VS_VERSION="$VS_VERSION" 31681 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 31682 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 31683 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 31684 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 31685 31686 # When using --with-tools-dir, assume it points to the correct and default 31687 # version of Visual Studio or that --with-toolchain-version was also set. 31688 if test "x$with_tools_dir" != x; then 31689 31690 if test "x$VS_ENV_CMD" = x; then 31691 VS_VERSION="${VS_VERSION}" 31692 VS_BASE="$with_tools_dir/../.." 31693 METHOD="--with-tools-dir" 31694 31695 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31696 VCVARSFILE="vc/bin/vcvars32.bat" 31697 else 31698 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31699 fi 31700 31701 31702 windows_path="$VS_BASE" 31703 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31704 unix_path=`$CYGPATH -u "$windows_path"` 31705 VS_BASE="$unix_path" 31706 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31707 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31708 VS_BASE="$unix_path" 31709 fi 31710 31711 if test -d "$VS_BASE"; then 31712 if test -f "$VS_BASE/$VCVARSFILE"; then 31713 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31714 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31715 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31716 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31717 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31718 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31719 else 31720 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31721 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31722 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31723 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31724 fi 31725 fi 31726 fi 31727 31728 31729 if test "x$VS_ENV_CMD" = x; then 31730 VS_VERSION="${VS_VERSION}" 31731 VS_BASE="$with_tools_dir/../../.." 31732 METHOD="--with-tools-dir" 31733 31734 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31735 VCVARSFILE="vc/bin/vcvars32.bat" 31736 else 31737 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31738 fi 31739 31740 31741 windows_path="$VS_BASE" 31742 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31743 unix_path=`$CYGPATH -u "$windows_path"` 31744 VS_BASE="$unix_path" 31745 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31746 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31747 VS_BASE="$unix_path" 31748 fi 31749 31750 if test -d "$VS_BASE"; then 31751 if test -f "$VS_BASE/$VCVARSFILE"; then 31752 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31753 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31754 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31755 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31756 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31757 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31758 else 31759 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31760 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31761 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31762 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31763 fi 31764 fi 31765 fi 31766 31767 if test "x$VS_ENV_CMD" = x; then 31768 # Having specified an argument which is incorrect will produce an instant failure; 31769 # we should not go on looking 31770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 31771 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 31772 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 31773 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 31774 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 31775 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 31776 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 31777 fi 31778 fi 31779 31780 VS_ENV_CMD="" 31781 VS_ENV_ARGS="" 31782 31783 if test "x$VS_COMNTOOLS" != x; then 31784 31785 if test "x$VS_ENV_CMD" = x; then 31786 VS_VERSION="${VS_VERSION}" 31787 VS_BASE="$VS_COMNTOOLS/../.." 31788 METHOD="$VS_COMNTOOLS_VAR variable" 31789 31790 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31791 VCVARSFILE="vc/bin/vcvars32.bat" 31792 else 31793 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31794 fi 31795 31796 31797 windows_path="$VS_BASE" 31798 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31799 unix_path=`$CYGPATH -u "$windows_path"` 31800 VS_BASE="$unix_path" 31801 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31802 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31803 VS_BASE="$unix_path" 31804 fi 31805 31806 if test -d "$VS_BASE"; then 31807 if test -f "$VS_BASE/$VCVARSFILE"; then 31808 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31809 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31810 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31811 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31812 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31813 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31814 else 31815 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31816 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31817 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31818 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31819 fi 31820 fi 31821 fi 31822 31823 fi 31824 if test "x$PROGRAMFILES" != x; then 31825 31826 if test "x$VS_ENV_CMD" = x; then 31827 VS_VERSION="${VS_VERSION}" 31828 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 31829 METHOD="well-known name" 31830 31831 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31832 VCVARSFILE="vc/bin/vcvars32.bat" 31833 else 31834 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31835 fi 31836 31837 31838 windows_path="$VS_BASE" 31839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31840 unix_path=`$CYGPATH -u "$windows_path"` 31841 VS_BASE="$unix_path" 31842 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31843 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31844 VS_BASE="$unix_path" 31845 fi 31846 31847 if test -d "$VS_BASE"; then 31848 if test -f "$VS_BASE/$VCVARSFILE"; then 31849 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31850 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31851 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31852 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31853 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31854 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31855 else 31856 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31857 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31858 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31859 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31860 fi 31861 fi 31862 fi 31863 31864 fi 31865 # Work around the insanely named ProgramFiles(x86) env variable 31866 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 31867 if test "x$PROGRAMFILES_X86" != x; then 31868 31869 if test "x$VS_ENV_CMD" = x; then 31870 VS_VERSION="${VS_VERSION}" 31871 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 31872 METHOD="well-known name" 31873 31874 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31875 VCVARSFILE="vc/bin/vcvars32.bat" 31876 else 31877 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31878 fi 31879 31880 31881 windows_path="$VS_BASE" 31882 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31883 unix_path=`$CYGPATH -u "$windows_path"` 31884 VS_BASE="$unix_path" 31885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31886 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31887 VS_BASE="$unix_path" 31888 fi 31889 31890 if test -d "$VS_BASE"; then 31891 if test -f "$VS_BASE/$VCVARSFILE"; then 31892 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31893 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31894 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31895 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31896 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31897 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31898 else 31899 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31900 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31901 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31902 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31903 fi 31904 fi 31905 fi 31906 31907 fi 31908 31909 if test "x$VS_ENV_CMD" = x; then 31910 VS_VERSION="${VS_VERSION}" 31911 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 31912 METHOD="well-known name" 31913 31914 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31915 VCVARSFILE="vc/bin/vcvars32.bat" 31916 else 31917 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31918 fi 31919 31920 31921 windows_path="$VS_BASE" 31922 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31923 unix_path=`$CYGPATH -u "$windows_path"` 31924 VS_BASE="$unix_path" 31925 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31926 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31927 VS_BASE="$unix_path" 31928 fi 31929 31930 if test -d "$VS_BASE"; then 31931 if test -f "$VS_BASE/$VCVARSFILE"; then 31932 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31933 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31934 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31935 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31936 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31937 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31938 else 31939 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31940 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31941 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31942 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31943 fi 31944 fi 31945 fi 31946 31947 31948 if test "x$VS_ENV_CMD" = x; then 31949 VS_VERSION="${VS_VERSION}" 31950 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 31951 METHOD="well-known name" 31952 31953 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31954 VCVARSFILE="vc/bin/vcvars32.bat" 31955 else 31956 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31957 fi 31958 31959 31960 windows_path="$VS_BASE" 31961 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31962 unix_path=`$CYGPATH -u "$windows_path"` 31963 VS_BASE="$unix_path" 31964 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31965 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31966 VS_BASE="$unix_path" 31967 fi 31968 31969 if test -d "$VS_BASE"; then 31970 if test -f "$VS_BASE/$VCVARSFILE"; then 31971 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31972 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31973 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31974 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31975 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31976 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31977 else 31978 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31979 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31980 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31981 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31982 fi 31983 fi 31984 fi 31985 31986 31987 if test "x$SDK_INSTALL_DIR" != x; then 31988 if test "x$ProgramW6432" != x; then 31989 31990 if test "x$VS_ENV_CMD" = x; then 31991 VS_VERSION="${VS_VERSION}" 31992 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 31993 METHOD="well-known name" 31994 31995 windows_path="$WIN_SDK_BASE" 31996 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31997 unix_path=`$CYGPATH -u "$windows_path"` 31998 WIN_SDK_BASE="$unix_path" 31999 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32000 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32001 WIN_SDK_BASE="$unix_path" 32002 fi 32003 32004 if test -d "$WIN_SDK_BASE"; then 32005 # There have been cases of partial or broken SDK installations. A missing 32006 # lib dir is not going to work. 32007 if test ! -d "$WIN_SDK_BASE/lib"; then 32008 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32009 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32010 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32011 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32012 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32013 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32014 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32015 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32016 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32017 VS_ENV_ARGS="/x86" 32018 else 32019 VS_ENV_ARGS="/x64" 32020 fi 32021 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32022 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32023 # TODO: improve detection for other versions of SDK 32024 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32025 else 32026 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32027 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32028 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32029 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32030 fi 32031 fi 32032 fi 32033 32034 fi 32035 if test "x$PROGRAMW6432" != x; then 32036 32037 if test "x$VS_ENV_CMD" = x; then 32038 VS_VERSION="${VS_VERSION}" 32039 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32040 METHOD="well-known name" 32041 32042 windows_path="$WIN_SDK_BASE" 32043 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32044 unix_path=`$CYGPATH -u "$windows_path"` 32045 WIN_SDK_BASE="$unix_path" 32046 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32047 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32048 WIN_SDK_BASE="$unix_path" 32049 fi 32050 32051 if test -d "$WIN_SDK_BASE"; then 32052 # There have been cases of partial or broken SDK installations. A missing 32053 # lib dir is not going to work. 32054 if test ! -d "$WIN_SDK_BASE/lib"; then 32055 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32056 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32057 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32058 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32059 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32060 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32061 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32062 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32063 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32064 VS_ENV_ARGS="/x86" 32065 else 32066 VS_ENV_ARGS="/x64" 32067 fi 32068 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32069 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32070 # TODO: improve detection for other versions of SDK 32071 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32072 else 32073 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32074 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32075 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32076 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32077 fi 32078 fi 32079 fi 32080 32081 fi 32082 if test "x$PROGRAMFILES" != x; then 32083 32084 if test "x$VS_ENV_CMD" = x; then 32085 VS_VERSION="${VS_VERSION}" 32086 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32087 METHOD="well-known name" 32088 32089 windows_path="$WIN_SDK_BASE" 32090 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32091 unix_path=`$CYGPATH -u "$windows_path"` 32092 WIN_SDK_BASE="$unix_path" 32093 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32094 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32095 WIN_SDK_BASE="$unix_path" 32096 fi 32097 32098 if test -d "$WIN_SDK_BASE"; then 32099 # There have been cases of partial or broken SDK installations. A missing 32100 # lib dir is not going to work. 32101 if test ! -d "$WIN_SDK_BASE/lib"; then 32102 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32103 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32104 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32105 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32106 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32107 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32108 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32109 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32110 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32111 VS_ENV_ARGS="/x86" 32112 else 32113 VS_ENV_ARGS="/x64" 32114 fi 32115 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32116 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32117 # TODO: improve detection for other versions of SDK 32118 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32119 else 32120 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32121 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32122 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32123 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32124 fi 32125 fi 32126 fi 32127 32128 fi 32129 32130 if test "x$VS_ENV_CMD" = x; then 32131 VS_VERSION="${VS_VERSION}" 32132 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32133 METHOD="well-known name" 32134 32135 windows_path="$WIN_SDK_BASE" 32136 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32137 unix_path=`$CYGPATH -u "$windows_path"` 32138 WIN_SDK_BASE="$unix_path" 32139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32140 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32141 WIN_SDK_BASE="$unix_path" 32142 fi 32143 32144 if test -d "$WIN_SDK_BASE"; then 32145 # There have been cases of partial or broken SDK installations. A missing 32146 # lib dir is not going to work. 32147 if test ! -d "$WIN_SDK_BASE/lib"; then 32148 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32149 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32150 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32151 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32152 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32153 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32154 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32155 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32156 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32157 VS_ENV_ARGS="/x86" 32158 else 32159 VS_ENV_ARGS="/x64" 32160 fi 32161 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32162 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32163 # TODO: improve detection for other versions of SDK 32164 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32165 else 32166 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32167 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32168 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32169 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32170 fi 32171 fi 32172 fi 32173 32174 32175 if test "x$VS_ENV_CMD" = x; then 32176 VS_VERSION="${VS_VERSION}" 32177 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32178 METHOD="well-known name" 32179 32180 windows_path="$WIN_SDK_BASE" 32181 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32182 unix_path=`$CYGPATH -u "$windows_path"` 32183 WIN_SDK_BASE="$unix_path" 32184 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32185 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32186 WIN_SDK_BASE="$unix_path" 32187 fi 32188 32189 if test -d "$WIN_SDK_BASE"; then 32190 # There have been cases of partial or broken SDK installations. A missing 32191 # lib dir is not going to work. 32192 if test ! -d "$WIN_SDK_BASE/lib"; then 32193 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32194 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32195 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32196 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32197 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32198 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32199 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32200 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32201 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32202 VS_ENV_ARGS="/x86" 32203 else 32204 VS_ENV_ARGS="/x64" 32205 fi 32206 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32207 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32208 # TODO: improve detection for other versions of SDK 32209 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32210 else 32211 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32212 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32213 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32214 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32215 fi 32216 fi 32217 fi 32218 32219 fi 32220 32221 if test "x$VS_ENV_CMD" != x; then 32222 TOOLCHAIN_VERSION=$VS_VERSION 32223 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32224 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32225 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32226 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32227 # The rest of the variables are already evaled while probing 32228 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32229 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32230 break 32231 fi 32232 done 32233 32234 32235 # If we have a devkit, skip all of the below. 32236 if test "x$DEVKIT_VS_VERSION" = x; then 32237 if test "x$VS_ENV_CMD" != x; then 32238 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32239 32240 # Only process if variable expands to non-empty 32241 32242 if test "x$VS_ENV_CMD" != x; then 32243 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32244 32245 # First separate the path from the arguments. This will split at the first 32246 # space. 32247 complete="$VS_ENV_CMD" 32248 path="${complete%% *}" 32249 tmp="$complete EOL" 32250 arguments="${tmp#* }" 32251 32252 # Input might be given as Windows format, start by converting to 32253 # unix format. 32254 new_path=`$CYGPATH -u "$path"` 32255 32256 # Now try to locate executable using which 32257 new_path=`$WHICH "$new_path" 2> /dev/null` 32258 # bat and cmd files are not always considered executable in cygwin causing which 32259 # to not find them 32260 if test "x$new_path" = x \ 32261 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32262 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32263 new_path=`$CYGPATH -u "$path"` 32264 fi 32265 if test "x$new_path" = x; then 32266 # Oops. Which didn't find the executable. 32267 # The splitting of arguments from the executable at a space might have been incorrect, 32268 # since paths with space are more likely in Windows. Give it another try with the whole 32269 # argument. 32270 path="$complete" 32271 arguments="EOL" 32272 new_path=`$CYGPATH -u "$path"` 32273 new_path=`$WHICH "$new_path" 2> /dev/null` 32274 # bat and cmd files are not always considered executable in cygwin causing which 32275 # to not find them 32276 if test "x$new_path" = x \ 32277 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32278 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32279 new_path=`$CYGPATH -u "$path"` 32280 fi 32281 if test "x$new_path" = x; then 32282 # It's still not found. Now this is an unrecoverable error. 32283 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32284 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32285 has_space=`$ECHO "$complete" | $GREP " "` 32286 if test "x$has_space" != x; then 32287 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32288 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32289 fi 32290 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32291 fi 32292 fi 32293 32294 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32295 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32296 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32297 # "foo.exe" is OK but "foo" is an error. 32298 # 32299 # This test is therefore slightly more accurate than "test -f" to check for file presence. 32300 # It is also a way to make sure we got the proper file name for the real test later on. 32301 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32302 if test "x$test_shortpath" = x; then 32303 # Short path failed, file does not exist as specified. 32304 # Try adding .exe or .cmd 32305 if test -f "${new_path}.exe"; then 32306 input_to_shortpath="${new_path}.exe" 32307 elif test -f "${new_path}.cmd"; then 32308 input_to_shortpath="${new_path}.cmd" 32309 else 32310 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 32311 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 32312 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 32313 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 32314 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32315 fi 32316 else 32317 input_to_shortpath="$new_path" 32318 fi 32319 32320 # Call helper function which possibly converts this using DOS-style short mode. 32321 # If so, the updated path is stored in $new_path. 32322 new_path="$input_to_shortpath" 32323 32324 input_path="$input_to_shortpath" 32325 # Check if we need to convert this using DOS-style short mode. If the path 32326 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32327 # take no chances and rewrite it. 32328 # Note: m4 eats our [], so we need to use [ and ] instead. 32329 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32330 if test "x$has_forbidden_chars" != x; then 32331 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32332 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32333 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32334 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32335 # Going to short mode and back again did indeed matter. Since short mode is 32336 # case insensitive, let's make it lowercase to improve readability. 32337 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32338 # Now convert it back to Unix-style (cygpath) 32339 input_path=`$CYGPATH -u "$shortmode_path"` 32340 new_path="$input_path" 32341 fi 32342 fi 32343 32344 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32345 if test "x$test_cygdrive_prefix" = x; then 32346 # As a simple fix, exclude /usr/bin since it's not a real path. 32347 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 32348 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32349 # a path prefixed by /cygdrive for fixpath to work. 32350 new_path="$CYGWIN_ROOT_PATH$input_path" 32351 fi 32352 fi 32353 32354 # remove trailing .exe if any 32355 new_path="${new_path/%.exe/}" 32356 32357 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32358 32359 # First separate the path from the arguments. This will split at the first 32360 # space. 32361 complete="$VS_ENV_CMD" 32362 path="${complete%% *}" 32363 tmp="$complete EOL" 32364 arguments="${tmp#* }" 32365 32366 # Input might be given as Windows format, start by converting to 32367 # unix format. 32368 new_path="$path" 32369 32370 windows_path="$new_path" 32371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32372 unix_path=`$CYGPATH -u "$windows_path"` 32373 new_path="$unix_path" 32374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32375 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32376 new_path="$unix_path" 32377 fi 32378 32379 32380 # Now try to locate executable using which 32381 new_path=`$WHICH "$new_path" 2> /dev/null` 32382 32383 if test "x$new_path" = x; then 32384 # Oops. Which didn't find the executable. 32385 # The splitting of arguments from the executable at a space might have been incorrect, 32386 # since paths with space are more likely in Windows. Give it another try with the whole 32387 # argument. 32388 path="$complete" 32389 arguments="EOL" 32390 new_path="$path" 32391 32392 windows_path="$new_path" 32393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32394 unix_path=`$CYGPATH -u "$windows_path"` 32395 new_path="$unix_path" 32396 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32397 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32398 new_path="$unix_path" 32399 fi 32400 32401 32402 new_path=`$WHICH "$new_path" 2> /dev/null` 32403 # bat and cmd files are not always considered executable in MSYS causing which 32404 # to not find them 32405 if test "x$new_path" = x \ 32406 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32407 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32408 new_path="$path" 32409 32410 windows_path="$new_path" 32411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32412 unix_path=`$CYGPATH -u "$windows_path"` 32413 new_path="$unix_path" 32414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32416 new_path="$unix_path" 32417 fi 32418 32419 fi 32420 32421 if test "x$new_path" = x; then 32422 # It's still not found. Now this is an unrecoverable error. 32423 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32424 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32425 has_space=`$ECHO "$complete" | $GREP " "` 32426 if test "x$has_space" != x; then 32427 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32428 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32429 fi 32430 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32431 fi 32432 fi 32433 32434 # Now new_path has a complete unix path to the binary 32435 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 32436 # Keep paths in /bin as-is, but remove trailing .exe if any 32437 new_path="${new_path/%.exe/}" 32438 # Do not save /bin paths to all_fixpath_prefixes! 32439 else 32440 # Not in mixed or Windows style, start by that. 32441 new_path=`cmd //c echo $new_path` 32442 32443 input_path="$new_path" 32444 # Check if we need to convert this using DOS-style short mode. If the path 32445 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32446 # take no chances and rewrite it. 32447 # Note: m4 eats our [], so we need to use [ and ] instead. 32448 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32449 if test "x$has_forbidden_chars" != x; then 32450 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32451 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32452 fi 32453 32454 # Output is in $new_path 32455 32456 windows_path="$new_path" 32457 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32458 unix_path=`$CYGPATH -u "$windows_path"` 32459 new_path="$unix_path" 32460 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32461 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32462 new_path="$unix_path" 32463 fi 32464 32465 # remove trailing .exe if any 32466 new_path="${new_path/%.exe/}" 32467 32468 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32469 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32470 fi 32471 32472 else 32473 # We're on a unix platform. Hooray! :) 32474 # First separate the path from the arguments. This will split at the first 32475 # space. 32476 complete="$VS_ENV_CMD" 32477 path="${complete%% *}" 32478 tmp="$complete EOL" 32479 arguments="${tmp#* }" 32480 32481 # Cannot rely on the command "which" here since it doesn't always work. 32482 is_absolute_path=`$ECHO "$path" | $GREP ^/` 32483 if test -z "$is_absolute_path"; then 32484 # Path to executable is not absolute. Find it. 32485 IFS_save="$IFS" 32486 IFS=: 32487 for p in $PATH; do 32488 if test -f "$p/$path" && test -x "$p/$path"; then 32489 new_path="$p/$path" 32490 break 32491 fi 32492 done 32493 IFS="$IFS_save" 32494 else 32495 # This is an absolute path, we can use it without further modifications. 32496 new_path="$path" 32497 fi 32498 32499 if test "x$new_path" = x; then 32500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32501 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32502 has_space=`$ECHO "$complete" | $GREP " "` 32503 if test "x$has_space" != x; then 32504 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 32505 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 32506 fi 32507 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32508 fi 32509 fi 32510 32511 # Now join together the path and the arguments once again 32512 if test "x$arguments" != xEOL; then 32513 new_complete="$new_path ${arguments% *}" 32514 else 32515 new_complete="$new_path" 32516 fi 32517 32518 if test "x$complete" != "x$new_complete"; then 32519 VS_ENV_CMD="$new_complete" 32520 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 32521 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 32522 fi 32523 fi 32524 32525 32526 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 32527 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 32528 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 32529 32530 # We need to create a couple of temporary files. 32531 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 32532 $MKDIR -p $VS_ENV_TMP_DIR 32533 32534 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 32535 # Instead create a shell script which will set the relevant variables when run. 32536 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 32537 32538 unix_path="$WINPATH_VS_ENV_CMD" 32539 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32540 windows_path=`$CYGPATH -m "$unix_path"` 32541 WINPATH_VS_ENV_CMD="$windows_path" 32542 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32543 windows_path=`cmd //c echo $unix_path` 32544 WINPATH_VS_ENV_CMD="$windows_path" 32545 fi 32546 32547 WINPATH_BASH="$BASH" 32548 32549 unix_path="$WINPATH_BASH" 32550 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32551 windows_path=`$CYGPATH -m "$unix_path"` 32552 WINPATH_BASH="$windows_path" 32553 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32554 windows_path=`cmd //c echo $unix_path` 32555 WINPATH_BASH="$windows_path" 32556 fi 32557 32558 32559 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 32560 # script (executable by bash) that will setup the important variables. 32561 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 32562 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 32563 # This will end up something like: 32564 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 32565 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 32566 # These will end up something like: 32567 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 32568 # The trailing space for everyone except PATH is no typo, but is needed due 32569 # to trailing \ in the Windows paths. These will be stripped later. 32570 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 32571 >> $EXTRACT_VC_ENV_BAT_FILE 32572 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 32573 >> $EXTRACT_VC_ENV_BAT_FILE 32574 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 32575 >> $EXTRACT_VC_ENV_BAT_FILE 32576 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 32577 >> $EXTRACT_VC_ENV_BAT_FILE 32578 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 32579 >> $EXTRACT_VC_ENV_BAT_FILE 32580 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 32581 >> $EXTRACT_VC_ENV_BAT_FILE 32582 32583 # Now execute the newly created bat file. 32584 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 32585 # Change directory so we don't need to mess with Windows paths in redirects. 32586 cd $VS_ENV_TMP_DIR 32587 cmd /c extract-vs-env.bat | $CAT 32588 cd $CURDIR 32589 32590 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 32591 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 32592 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 32593 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32594 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32595 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32596 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32597 as_fn_error $? "Cannot continue" "$LINENO" 5 32598 fi 32599 32600 # Now set all paths and other env variables. This will allow the rest of 32601 # the configure script to find and run the compiler in the proper way. 32602 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 32603 $as_echo "$as_me: Setting extracted environment variables" >&6;} 32604 . $VS_ENV_TMP_DIR/set-vs-env.sh 32605 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 32606 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 32607 else 32608 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 32609 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 32610 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 32611 fi 32612 fi 32613 32614 # At this point, we should have correct variables in the environment, or we can't continue. 32615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 32616 $as_echo_n "checking for Visual Studio variables... " >&6; } 32617 32618 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 32619 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 32620 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 32621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 32622 $as_echo "present but broken" >&6; } 32623 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 32624 else 32625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 32626 $as_echo "ok" >&6; } 32627 # Remove any trailing "\" ";" and " " from the variables. 32628 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 32629 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 32630 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 32631 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 32632 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 32633 # Remove any paths containing # (typically F#) as that messes up make. This 32634 # is needed if visual studio was installed with F# support. 32635 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 32636 32637 32638 32639 32640 32641 # Convert VS_INCLUDE into SYSROOT_CFLAGS 32642 OLDIFS="$IFS" 32643 IFS=";" 32644 for i in $VS_INCLUDE; do 32645 ipath=$i 32646 # Only process non-empty elements 32647 if test "x$ipath" != x; then 32648 IFS="$OLDIFS" 32649 # Check that directory exists before calling fixup_path 32650 testpath=$ipath 32651 32652 windows_path="$testpath" 32653 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32654 unix_path=`$CYGPATH -u "$windows_path"` 32655 testpath="$unix_path" 32656 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32657 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32658 testpath="$unix_path" 32659 fi 32660 32661 if test -d "$testpath"; then 32662 32663 # Only process if variable expands to non-empty 32664 32665 if test "x$ipath" != x; then 32666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32667 32668 # Input might be given as Windows format, start by converting to 32669 # unix format. 32670 path="$ipath" 32671 new_path=`$CYGPATH -u "$path"` 32672 32673 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32674 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32675 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32676 # "foo.exe" is OK but "foo" is an error. 32677 # 32678 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32679 # It is also a way to make sure we got the proper file name for the real test later on. 32680 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32681 if test "x$test_shortpath" = x; then 32682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32683 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32684 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 32685 fi 32686 32687 # Call helper function which possibly converts this using DOS-style short mode. 32688 # If so, the updated path is stored in $new_path. 32689 32690 input_path="$new_path" 32691 # Check if we need to convert this using DOS-style short mode. If the path 32692 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32693 # take no chances and rewrite it. 32694 # Note: m4 eats our [], so we need to use [ and ] instead. 32695 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32696 if test "x$has_forbidden_chars" != x; then 32697 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32698 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32699 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32700 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32701 # Going to short mode and back again did indeed matter. Since short mode is 32702 # case insensitive, let's make it lowercase to improve readability. 32703 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32704 # Now convert it back to Unix-style (cygpath) 32705 input_path=`$CYGPATH -u "$shortmode_path"` 32706 new_path="$input_path" 32707 fi 32708 fi 32709 32710 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32711 if test "x$test_cygdrive_prefix" = x; then 32712 # As a simple fix, exclude /usr/bin since it's not a real path. 32713 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32714 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32715 # a path prefixed by /cygdrive for fixpath to work. 32716 new_path="$CYGWIN_ROOT_PATH$input_path" 32717 fi 32718 fi 32719 32720 32721 if test "x$path" != "x$new_path"; then 32722 ipath="$new_path" 32723 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32724 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32725 fi 32726 32727 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32728 32729 path="$ipath" 32730 has_colon=`$ECHO $path | $GREP ^.:` 32731 new_path="$path" 32732 if test "x$has_colon" = x; then 32733 # Not in mixed or Windows style, start by that. 32734 new_path=`cmd //c echo $path` 32735 fi 32736 32737 32738 input_path="$new_path" 32739 # Check if we need to convert this using DOS-style short mode. If the path 32740 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32741 # take no chances and rewrite it. 32742 # Note: m4 eats our [], so we need to use [ and ] instead. 32743 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32744 if test "x$has_forbidden_chars" != x; then 32745 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32746 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32747 fi 32748 32749 32750 windows_path="$new_path" 32751 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32752 unix_path=`$CYGPATH -u "$windows_path"` 32753 new_path="$unix_path" 32754 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32755 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32756 new_path="$unix_path" 32757 fi 32758 32759 if test "x$path" != "x$new_path"; then 32760 ipath="$new_path" 32761 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32762 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32763 fi 32764 32765 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32766 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32767 32768 else 32769 # We're on a unix platform. Hooray! :) 32770 path="$ipath" 32771 has_space=`$ECHO "$path" | $GREP " "` 32772 if test "x$has_space" != x; then 32773 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32774 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32775 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 32776 fi 32777 32778 # Use eval to expand a potential ~ 32779 eval path="$path" 32780 if test ! -f "$path" && test ! -d "$path"; then 32781 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 32782 fi 32783 32784 if test -d "$path"; then 32785 ipath="`cd "$path"; $THEPWDCMD -L`" 32786 else 32787 dir="`$DIRNAME "$path"`" 32788 base="`$BASENAME "$path"`" 32789 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 32790 fi 32791 fi 32792 fi 32793 32794 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 32795 fi 32796 IFS=";" 32797 fi 32798 done 32799 # Convert VS_LIB into SYSROOT_LDFLAGS 32800 for i in $VS_LIB; do 32801 libpath=$i 32802 # Only process non-empty elements 32803 if test "x$libpath" != x; then 32804 IFS="$OLDIFS" 32805 # Check that directory exists before calling fixup_path 32806 testpath=$libpath 32807 32808 windows_path="$testpath" 32809 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32810 unix_path=`$CYGPATH -u "$windows_path"` 32811 testpath="$unix_path" 32812 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32813 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32814 testpath="$unix_path" 32815 fi 32816 32817 if test -d "$testpath"; then 32818 32819 # Only process if variable expands to non-empty 32820 32821 if test "x$libpath" != x; then 32822 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32823 32824 # Input might be given as Windows format, start by converting to 32825 # unix format. 32826 path="$libpath" 32827 new_path=`$CYGPATH -u "$path"` 32828 32829 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32830 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32831 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32832 # "foo.exe" is OK but "foo" is an error. 32833 # 32834 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32835 # It is also a way to make sure we got the proper file name for the real test later on. 32836 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32837 if test "x$test_shortpath" = x; then 32838 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 32839 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 32840 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 32841 fi 32842 32843 # Call helper function which possibly converts this using DOS-style short mode. 32844 # If so, the updated path is stored in $new_path. 32845 32846 input_path="$new_path" 32847 # Check if we need to convert this using DOS-style short mode. If the path 32848 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32849 # take no chances and rewrite it. 32850 # Note: m4 eats our [], so we need to use [ and ] instead. 32851 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32852 if test "x$has_forbidden_chars" != x; then 32853 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32854 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32855 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32856 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32857 # Going to short mode and back again did indeed matter. Since short mode is 32858 # case insensitive, let's make it lowercase to improve readability. 32859 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32860 # Now convert it back to Unix-style (cygpath) 32861 input_path=`$CYGPATH -u "$shortmode_path"` 32862 new_path="$input_path" 32863 fi 32864 fi 32865 32866 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32867 if test "x$test_cygdrive_prefix" = x; then 32868 # As a simple fix, exclude /usr/bin since it's not a real path. 32869 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32870 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32871 # a path prefixed by /cygdrive for fixpath to work. 32872 new_path="$CYGWIN_ROOT_PATH$input_path" 32873 fi 32874 fi 32875 32876 32877 if test "x$path" != "x$new_path"; then 32878 libpath="$new_path" 32879 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 32880 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 32881 fi 32882 32883 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32884 32885 path="$libpath" 32886 has_colon=`$ECHO $path | $GREP ^.:` 32887 new_path="$path" 32888 if test "x$has_colon" = x; then 32889 # Not in mixed or Windows style, start by that. 32890 new_path=`cmd //c echo $path` 32891 fi 32892 32893 32894 input_path="$new_path" 32895 # Check if we need to convert this using DOS-style short mode. If the path 32896 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32897 # take no chances and rewrite it. 32898 # Note: m4 eats our [], so we need to use [ and ] instead. 32899 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32900 if test "x$has_forbidden_chars" != x; then 32901 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32902 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32903 fi 32904 32905 32906 windows_path="$new_path" 32907 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32908 unix_path=`$CYGPATH -u "$windows_path"` 32909 new_path="$unix_path" 32910 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32911 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32912 new_path="$unix_path" 32913 fi 32914 32915 if test "x$path" != "x$new_path"; then 32916 libpath="$new_path" 32917 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 32918 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 32919 fi 32920 32921 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32922 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32923 32924 else 32925 # We're on a unix platform. Hooray! :) 32926 path="$libpath" 32927 has_space=`$ECHO "$path" | $GREP " "` 32928 if test "x$has_space" != x; then 32929 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 32930 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 32931 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 32932 fi 32933 32934 # Use eval to expand a potential ~ 32935 eval path="$path" 32936 if test ! -f "$path" && test ! -d "$path"; then 32937 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 32938 fi 32939 32940 if test -d "$path"; then 32941 libpath="`cd "$path"; $THEPWDCMD -L`" 32942 else 32943 dir="`$DIRNAME "$path"`" 32944 base="`$BASENAME "$path"`" 32945 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 32946 fi 32947 fi 32948 fi 32949 32950 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 32951 fi 32952 IFS=";" 32953 fi 32954 done 32955 IFS="$OLDIFS" 32956 fi 32957 else 32958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 32959 $as_echo "not found" >&6; } 32960 32961 if test "x$VS_ENV_CMD" = x; then 32962 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 32963 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 32964 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 32965 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 32966 else 32967 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 32968 $as_echo "$as_me: Running the extraction script failed." >&6;} 32969 fi 32970 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32971 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32972 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32973 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32974 as_fn_error $? "Cannot continue" "$LINENO" 5 32975 fi 32976 32977 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 32978 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 32979 PATH="$VS_PATH" 32980 # The microsoft toolchain also requires INCLUDE and LIB to be set. 32981 export INCLUDE="$VS_INCLUDE" 32982 export LIB="$VS_LIB" 32983 else 32984 if test "x$XCODE_VERSION_OUTPUT" != x; then 32985 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 32986 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 32987 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 32988 else 32989 # Currently we do not define this for other toolchains. This might change as the need arise. 32990 TOOLCHAIN_VERSION= 32991 fi 32992 fi 32993 32994 32995 # For solaris we really need solaris tools, and not the GNU equivalent. 32996 # The build tools on Solaris reside in /usr/ccs (C Compilation System), 32997 # so add that to path before starting to probe. 32998 # FIXME: This was originally only done for AS,NM,GNM,STRIP,OBJCOPY,OBJDUMP. 32999 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 33000 PATH="/usr/ccs/bin:$PATH" 33001 fi 33002 33003 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 33004 # override all other locations. 33005 if test "x$TOOLCHAIN_PATH" != x; then 33006 PATH=$TOOLCHAIN_PATH:$PATH 33007 fi 33008 33009 33010 # 33011 # Setup the compilers (CC and CXX) 33012 # 33013 33014 COMPILER_NAME=C 33015 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 33016 33017 if test "x$CC" != x; then 33018 # User has supplied compiler name already, always let that override. 33019 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 33020 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 33021 if test "x`basename $CC`" = "x$CC"; then 33022 # A command without a complete path is provided, search $PATH. 33023 33024 for ac_prog in $CC 33025 do 33026 # Extract the first word of "$ac_prog", so it can be a program name with args. 33027 set dummy $ac_prog; ac_word=$2 33028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33029 $as_echo_n "checking for $ac_word... " >&6; } 33030 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33031 $as_echo_n "(cached) " >&6 33032 else 33033 case $POTENTIAL_CC in 33034 [\\/]* | ?:[\\/]*) 33035 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33036 ;; 33037 *) 33038 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33039 for as_dir in $PATH 33040 do 33041 IFS=$as_save_IFS 33042 test -z "$as_dir" && as_dir=. 33043 for ac_exec_ext in '' $ac_executable_extensions; do 33044 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33045 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33046 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33047 break 2 33048 fi 33049 done 33050 done 33051 IFS=$as_save_IFS 33052 33053 ;; 33054 esac 33055 fi 33056 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33057 if test -n "$POTENTIAL_CC"; then 33058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33059 $as_echo "$POTENTIAL_CC" >&6; } 33060 else 33061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33062 $as_echo "no" >&6; } 33063 fi 33064 33065 33066 test -n "$POTENTIAL_CC" && break 33067 done 33068 33069 if test "x$POTENTIAL_CC" != x; then 33070 CC=$POTENTIAL_CC 33071 else 33072 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33073 fi 33074 else 33075 # Otherwise it might already be a complete path 33076 if test ! -x "$CC"; then 33077 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33078 fi 33079 fi 33080 else 33081 # No user supplied value. Locate compiler ourselves. 33082 33083 # If we are cross compiling, assume cross compilation tools follows the 33084 # cross compilation standard where they are prefixed with the autoconf 33085 # standard name for the target. For example the binary 33086 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33087 # If we are not cross compiling, then the default compiler name will be 33088 # used. 33089 33090 CC= 33091 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33092 # before checking the rest of the PATH. 33093 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33094 # step, this should not be necessary. 33095 if test -n "$TOOLCHAIN_PATH"; then 33096 PATH_save="$PATH" 33097 PATH="$TOOLCHAIN_PATH" 33098 for ac_prog in $SEARCH_LIST 33099 do 33100 # Extract the first word of "$ac_prog", so it can be a program name with args. 33101 set dummy $ac_prog; ac_word=$2 33102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33103 $as_echo_n "checking for $ac_word... " >&6; } 33104 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33105 $as_echo_n "(cached) " >&6 33106 else 33107 case $TOOLCHAIN_PATH_CC in 33108 [\\/]* | ?:[\\/]*) 33109 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33110 ;; 33111 *) 33112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33113 for as_dir in $PATH 33114 do 33115 IFS=$as_save_IFS 33116 test -z "$as_dir" && as_dir=. 33117 for ac_exec_ext in '' $ac_executable_extensions; do 33118 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33119 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33121 break 2 33122 fi 33123 done 33124 done 33125 IFS=$as_save_IFS 33126 33127 ;; 33128 esac 33129 fi 33130 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33131 if test -n "$TOOLCHAIN_PATH_CC"; then 33132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33133 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33134 else 33135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33136 $as_echo "no" >&6; } 33137 fi 33138 33139 33140 test -n "$TOOLCHAIN_PATH_CC" && break 33141 done 33142 33143 CC=$TOOLCHAIN_PATH_CC 33144 PATH="$PATH_save" 33145 fi 33146 33147 # AC_PATH_PROGS can't be run multiple times with the same variable, 33148 # so create a new name for this run. 33149 if test "x$CC" = x; then 33150 for ac_prog in $SEARCH_LIST 33151 do 33152 # Extract the first word of "$ac_prog", so it can be a program name with args. 33153 set dummy $ac_prog; ac_word=$2 33154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33155 $as_echo_n "checking for $ac_word... " >&6; } 33156 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33157 $as_echo_n "(cached) " >&6 33158 else 33159 case $POTENTIAL_CC in 33160 [\\/]* | ?:[\\/]*) 33161 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33162 ;; 33163 *) 33164 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33165 for as_dir in $PATH 33166 do 33167 IFS=$as_save_IFS 33168 test -z "$as_dir" && as_dir=. 33169 for ac_exec_ext in '' $ac_executable_extensions; do 33170 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33171 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33172 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33173 break 2 33174 fi 33175 done 33176 done 33177 IFS=$as_save_IFS 33178 33179 ;; 33180 esac 33181 fi 33182 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33183 if test -n "$POTENTIAL_CC"; then 33184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33185 $as_echo "$POTENTIAL_CC" >&6; } 33186 else 33187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33188 $as_echo "no" >&6; } 33189 fi 33190 33191 33192 test -n "$POTENTIAL_CC" && break 33193 done 33194 33195 CC=$POTENTIAL_CC 33196 fi 33197 33198 if test "x$CC" = x; then 33199 33200 # Print a helpful message on how to acquire the necessary build dependency. 33201 # devkit is the help tag: freetype, cups, alsa etc 33202 MISSING_DEPENDENCY=devkit 33203 33204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33205 cygwin_help $MISSING_DEPENDENCY 33206 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33207 msys_help $MISSING_DEPENDENCY 33208 else 33209 PKGHANDLER_COMMAND= 33210 33211 case $PKGHANDLER in 33212 apt-get) 33213 apt_help $MISSING_DEPENDENCY ;; 33214 yum) 33215 yum_help $MISSING_DEPENDENCY ;; 33216 port) 33217 port_help $MISSING_DEPENDENCY ;; 33218 pkgutil) 33219 pkgutil_help $MISSING_DEPENDENCY ;; 33220 pkgadd) 33221 pkgadd_help $MISSING_DEPENDENCY ;; 33222 esac 33223 33224 if test "x$PKGHANDLER_COMMAND" != x; then 33225 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 33226 fi 33227 fi 33228 33229 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 33230 fi 33231 fi 33232 33233 # Now we have a compiler binary in CC. Make sure it's okay. 33234 33235 # Only process if variable expands to non-empty 33236 33237 if test "x$CC" != x; then 33238 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33239 33240 # First separate the path from the arguments. This will split at the first 33241 # space. 33242 complete="$CC" 33243 path="${complete%% *}" 33244 tmp="$complete EOL" 33245 arguments="${tmp#* }" 33246 33247 # Input might be given as Windows format, start by converting to 33248 # unix format. 33249 new_path=`$CYGPATH -u "$path"` 33250 33251 # Now try to locate executable using which 33252 new_path=`$WHICH "$new_path" 2> /dev/null` 33253 # bat and cmd files are not always considered executable in cygwin causing which 33254 # to not find them 33255 if test "x$new_path" = x \ 33256 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33257 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33258 new_path=`$CYGPATH -u "$path"` 33259 fi 33260 if test "x$new_path" = x; then 33261 # Oops. Which didn't find the executable. 33262 # The splitting of arguments from the executable at a space might have been incorrect, 33263 # since paths with space are more likely in Windows. Give it another try with the whole 33264 # argument. 33265 path="$complete" 33266 arguments="EOL" 33267 new_path=`$CYGPATH -u "$path"` 33268 new_path=`$WHICH "$new_path" 2> /dev/null` 33269 # bat and cmd files are not always considered executable in cygwin causing which 33270 # to not find them 33271 if test "x$new_path" = x \ 33272 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33273 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33274 new_path=`$CYGPATH -u "$path"` 33275 fi 33276 if test "x$new_path" = x; then 33277 # It's still not found. Now this is an unrecoverable error. 33278 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33279 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33280 has_space=`$ECHO "$complete" | $GREP " "` 33281 if test "x$has_space" != x; then 33282 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33283 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33284 fi 33285 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33286 fi 33287 fi 33288 33289 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33290 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33291 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33292 # "foo.exe" is OK but "foo" is an error. 33293 # 33294 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33295 # It is also a way to make sure we got the proper file name for the real test later on. 33296 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33297 if test "x$test_shortpath" = x; then 33298 # Short path failed, file does not exist as specified. 33299 # Try adding .exe or .cmd 33300 if test -f "${new_path}.exe"; then 33301 input_to_shortpath="${new_path}.exe" 33302 elif test -f "${new_path}.cmd"; then 33303 input_to_shortpath="${new_path}.cmd" 33304 else 33305 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 33306 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 33307 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33308 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33309 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33310 fi 33311 else 33312 input_to_shortpath="$new_path" 33313 fi 33314 33315 # Call helper function which possibly converts this using DOS-style short mode. 33316 # If so, the updated path is stored in $new_path. 33317 new_path="$input_to_shortpath" 33318 33319 input_path="$input_to_shortpath" 33320 # Check if we need to convert this using DOS-style short mode. If the path 33321 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33322 # take no chances and rewrite it. 33323 # Note: m4 eats our [], so we need to use [ and ] instead. 33324 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33325 if test "x$has_forbidden_chars" != x; then 33326 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33327 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33328 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33329 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33330 # Going to short mode and back again did indeed matter. Since short mode is 33331 # case insensitive, let's make it lowercase to improve readability. 33332 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33333 # Now convert it back to Unix-style (cygpath) 33334 input_path=`$CYGPATH -u "$shortmode_path"` 33335 new_path="$input_path" 33336 fi 33337 fi 33338 33339 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33340 if test "x$test_cygdrive_prefix" = x; then 33341 # As a simple fix, exclude /usr/bin since it's not a real path. 33342 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33343 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33344 # a path prefixed by /cygdrive for fixpath to work. 33345 new_path="$CYGWIN_ROOT_PATH$input_path" 33346 fi 33347 fi 33348 33349 # remove trailing .exe if any 33350 new_path="${new_path/%.exe/}" 33351 33352 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33353 33354 # First separate the path from the arguments. This will split at the first 33355 # space. 33356 complete="$CC" 33357 path="${complete%% *}" 33358 tmp="$complete EOL" 33359 arguments="${tmp#* }" 33360 33361 # Input might be given as Windows format, start by converting to 33362 # unix format. 33363 new_path="$path" 33364 33365 windows_path="$new_path" 33366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33367 unix_path=`$CYGPATH -u "$windows_path"` 33368 new_path="$unix_path" 33369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33370 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33371 new_path="$unix_path" 33372 fi 33373 33374 33375 # Now try to locate executable using which 33376 new_path=`$WHICH "$new_path" 2> /dev/null` 33377 33378 if test "x$new_path" = x; then 33379 # Oops. Which didn't find the executable. 33380 # The splitting of arguments from the executable at a space might have been incorrect, 33381 # since paths with space are more likely in Windows. Give it another try with the whole 33382 # argument. 33383 path="$complete" 33384 arguments="EOL" 33385 new_path="$path" 33386 33387 windows_path="$new_path" 33388 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33389 unix_path=`$CYGPATH -u "$windows_path"` 33390 new_path="$unix_path" 33391 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33392 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33393 new_path="$unix_path" 33394 fi 33395 33396 33397 new_path=`$WHICH "$new_path" 2> /dev/null` 33398 # bat and cmd files are not always considered executable in MSYS causing which 33399 # to not find them 33400 if test "x$new_path" = x \ 33401 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33402 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33403 new_path="$path" 33404 33405 windows_path="$new_path" 33406 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33407 unix_path=`$CYGPATH -u "$windows_path"` 33408 new_path="$unix_path" 33409 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33410 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33411 new_path="$unix_path" 33412 fi 33413 33414 fi 33415 33416 if test "x$new_path" = x; then 33417 # It's still not found. Now this is an unrecoverable error. 33418 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33419 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33420 has_space=`$ECHO "$complete" | $GREP " "` 33421 if test "x$has_space" != x; then 33422 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33423 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33424 fi 33425 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33426 fi 33427 fi 33428 33429 # Now new_path has a complete unix path to the binary 33430 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33431 # Keep paths in /bin as-is, but remove trailing .exe if any 33432 new_path="${new_path/%.exe/}" 33433 # Do not save /bin paths to all_fixpath_prefixes! 33434 else 33435 # Not in mixed or Windows style, start by that. 33436 new_path=`cmd //c echo $new_path` 33437 33438 input_path="$new_path" 33439 # Check if we need to convert this using DOS-style short mode. If the path 33440 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33441 # take no chances and rewrite it. 33442 # Note: m4 eats our [], so we need to use [ and ] instead. 33443 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33444 if test "x$has_forbidden_chars" != x; then 33445 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33446 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33447 fi 33448 33449 # Output is in $new_path 33450 33451 windows_path="$new_path" 33452 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33453 unix_path=`$CYGPATH -u "$windows_path"` 33454 new_path="$unix_path" 33455 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33456 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33457 new_path="$unix_path" 33458 fi 33459 33460 # remove trailing .exe if any 33461 new_path="${new_path/%.exe/}" 33462 33463 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33464 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33465 fi 33466 33467 else 33468 # We're on a unix platform. Hooray! :) 33469 # First separate the path from the arguments. This will split at the first 33470 # space. 33471 complete="$CC" 33472 path="${complete%% *}" 33473 tmp="$complete EOL" 33474 arguments="${tmp#* }" 33475 33476 # Cannot rely on the command "which" here since it doesn't always work. 33477 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33478 if test -z "$is_absolute_path"; then 33479 # Path to executable is not absolute. Find it. 33480 IFS_save="$IFS" 33481 IFS=: 33482 for p in $PATH; do 33483 if test -f "$p/$path" && test -x "$p/$path"; then 33484 new_path="$p/$path" 33485 break 33486 fi 33487 done 33488 IFS="$IFS_save" 33489 else 33490 # This is an absolute path, we can use it without further modifications. 33491 new_path="$path" 33492 fi 33493 33494 if test "x$new_path" = x; then 33495 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33496 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33497 has_space=`$ECHO "$complete" | $GREP " "` 33498 if test "x$has_space" != x; then 33499 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33500 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33501 fi 33502 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33503 fi 33504 fi 33505 33506 # Now join together the path and the arguments once again 33507 if test "x$arguments" != xEOL; then 33508 new_complete="$new_path ${arguments% *}" 33509 else 33510 new_complete="$new_path" 33511 fi 33512 33513 if test "x$complete" != "x$new_complete"; then 33514 CC="$new_complete" 33515 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 33516 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 33517 fi 33518 fi 33519 33520 TEST_COMPILER="$CC" 33521 33522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 33523 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 33524 SYMLINK_ORIGINAL="$TEST_COMPILER" 33525 33526 if test "x$OPENJDK_BUILD_OS" != xwindows; then 33527 # Follow a chain of symbolic links. Use readlink 33528 # where it exists, else fall back to horribly 33529 # complicated shell code. 33530 if test "x$READLINK_TESTED" != yes; then 33531 # On MacOSX there is a readlink tool with a different 33532 # purpose than the GNU readlink tool. Check the found readlink. 33533 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 33534 if test "x$ISGNU" = x; then 33535 # A readlink that we do not know how to use. 33536 # Are there other non-GNU readlinks out there? 33537 READLINK_TESTED=yes 33538 READLINK= 33539 fi 33540 fi 33541 33542 if test "x$READLINK" != x; then 33543 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 33544 else 33545 # Save the current directory for restoring afterwards 33546 STARTDIR=$PWD 33547 COUNTER=0 33548 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 33549 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 33550 cd $sym_link_dir 33551 # Use -P flag to resolve symlinks in directories. 33552 cd `$THEPWDCMD -P` 33553 sym_link_dir=`$THEPWDCMD -P` 33554 # Resolve file symlinks 33555 while test $COUNTER -lt 20; do 33556 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 33557 if test "x$ISLINK" == x; then 33558 # This is not a symbolic link! We are done! 33559 break 33560 fi 33561 # Again resolve directory symlinks since the target of the just found 33562 # link could be in a different directory 33563 cd `$DIRNAME $ISLINK` 33564 sym_link_dir=`$THEPWDCMD -P` 33565 sym_link_file=`$BASENAME $ISLINK` 33566 let COUNTER=COUNTER+1 33567 done 33568 cd $STARTDIR 33569 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 33570 fi 33571 fi 33572 33573 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 33574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 33575 $as_echo "no symlink" >&6; } 33576 else 33577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 33578 $as_echo "$SYMLINK_ORIGINAL" >&6; } 33579 33580 # We can't handle ccache by gcc wrappers, since we need to know if we're 33581 # using ccache. Instead ccache usage must be controlled by a configure option. 33582 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 33583 if test "x$COMPILER_BASENAME" = "xccache"; then 33584 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 33585 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 33586 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 33587 fi 33588 fi 33589 33590 33591 COMPILER=$CC 33592 COMPILER_NAME=$COMPILER_NAME 33593 33594 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 33595 # cc -V output typically looks like 33596 # cc: Sun C 5.12 Linux_i386 2011/11/16 33597 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 33598 # Check that this is likely to be the Solaris Studio cc. 33599 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 33600 if test $? -ne 0; then 33601 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33602 { $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 33603 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33604 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33605 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33606 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33607 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33608 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33609 fi 33610 # Remove usage instructions (if present), and 33611 # collapse compiler output into a single line 33612 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33613 $SED -e 's/ *[Uu]sage:.*//'` 33614 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33615 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 33616 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 33617 # xlc -qversion output typically looks like 33618 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 33619 # Version: 11.01.0000.0015 33620 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 33621 # Check that this is likely to be the IBM XL C compiler. 33622 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 33623 if test $? -ne 0; then 33624 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33625 { $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 33626 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33627 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33628 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33629 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33630 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33631 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33632 fi 33633 # Collapse compiler output into a single line 33634 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33635 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33636 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 33637 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 33638 # There is no specific version flag, but all output starts with a version string. 33639 # First line typically looks something like: 33640 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 33641 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 33642 # Check that this is likely to be Microsoft CL.EXE. 33643 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 33644 if test $? -ne 0; then 33645 { $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 33646 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33647 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33648 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33649 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33650 fi 33651 # Collapse compiler output into a single line 33652 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33653 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33654 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 33655 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 33656 # gcc --version output typically looks like 33657 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 33658 # Copyright (C) 2013 Free Software Foundation, Inc. 33659 # This is free software; see the source for copying conditions. There is NO 33660 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 33661 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33662 # Check that this is likely to be GCC. 33663 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 33664 if test $? -ne 0; then 33665 { $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 33666 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33667 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 33668 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 33669 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33670 fi 33671 # Remove Copyright and legalese from version string, and 33672 # collapse into a single line 33673 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33674 $SED -e 's/ *Copyright .*//'` 33675 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33676 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 33677 elif test "x$TOOLCHAIN_TYPE" = xclang; then 33678 # clang --version output typically looks like 33679 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 33680 # clang version 3.3 (tags/RELEASE_33/final) 33681 # or 33682 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 33683 # Target: x86_64-pc-linux-gnu 33684 # Thread model: posix 33685 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33686 # Check that this is likely to be clang 33687 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 33688 if test $? -ne 0; then 33689 { $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 33690 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33691 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33692 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33693 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33694 fi 33695 # Collapse compiler output into a single line 33696 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33697 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33698 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 33699 else 33700 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 33701 fi 33702 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 33703 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 33704 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 33705 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 33706 33707 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 33708 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 33709 33710 33711 # Now that we have resolved CC ourself, let autoconf have its go at it 33712 ac_ext=c 33713 ac_cpp='$CPP $CPPFLAGS' 33714 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 33715 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 33716 ac_compiler_gnu=$ac_cv_c_compiler_gnu 33717 if test -n "$ac_tool_prefix"; then 33718 for ac_prog in $CC 33719 do 33720 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 33721 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 33722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33723 $as_echo_n "checking for $ac_word... " >&6; } 33724 if ${ac_cv_prog_CC+:} false; then : 33725 $as_echo_n "(cached) " >&6 33726 else 33727 if test -n "$CC"; then 33728 ac_cv_prog_CC="$CC" # Let the user override the test. 33729 else 33730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33731 for as_dir in $PATH 33732 do 33733 IFS=$as_save_IFS 33734 test -z "$as_dir" && as_dir=. 33735 for ac_exec_ext in '' $ac_executable_extensions; do 33736 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33737 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 33738 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33739 break 2 33740 fi 33741 done 33742 done 33743 IFS=$as_save_IFS 33744 33745 fi 33746 fi 33747 CC=$ac_cv_prog_CC 33748 if test -n "$CC"; then 33749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 33750 $as_echo "$CC" >&6; } 33751 else 33752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33753 $as_echo "no" >&6; } 33754 fi 33755 33756 33757 test -n "$CC" && break 33758 done 33759 fi 33760 if test -z "$CC"; then 33761 ac_ct_CC=$CC 33762 for ac_prog in $CC 33763 do 33764 # Extract the first word of "$ac_prog", so it can be a program name with args. 33765 set dummy $ac_prog; ac_word=$2 33766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33767 $as_echo_n "checking for $ac_word... " >&6; } 33768 if ${ac_cv_prog_ac_ct_CC+:} false; then : 33769 $as_echo_n "(cached) " >&6 33770 else 33771 if test -n "$ac_ct_CC"; then 33772 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 33773 else 33774 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33775 for as_dir in $PATH 33776 do 33777 IFS=$as_save_IFS 33778 test -z "$as_dir" && as_dir=. 33779 for ac_exec_ext in '' $ac_executable_extensions; do 33780 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33781 ac_cv_prog_ac_ct_CC="$ac_prog" 33782 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33783 break 2 33784 fi 33785 done 33786 done 33787 IFS=$as_save_IFS 33788 33789 fi 33790 fi 33791 ac_ct_CC=$ac_cv_prog_ac_ct_CC 33792 if test -n "$ac_ct_CC"; then 33793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 33794 $as_echo "$ac_ct_CC" >&6; } 33795 else 33796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33797 $as_echo "no" >&6; } 33798 fi 33799 33800 33801 test -n "$ac_ct_CC" && break 33802 done 33803 33804 if test "x$ac_ct_CC" = x; then 33805 CC="" 33806 else 33807 case $cross_compiling:$ac_tool_warned in 33808 yes:) 33809 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33810 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33811 ac_tool_warned=yes ;; 33812 esac 33813 CC=$ac_ct_CC 33814 fi 33815 fi 33816 33817 33818 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33819 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33820 as_fn_error $? "no acceptable C compiler found in \$PATH 33821 See \`config.log' for more details" "$LINENO" 5; } 33822 33823 # Provide some information about the compiler. 33824 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 33825 set X $ac_compile 33826 ac_compiler=$2 33827 for ac_option in --version -v -V -qversion; do 33828 { { ac_try="$ac_compiler $ac_option >&5" 33829 case "(($ac_try" in 33830 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33831 *) ac_try_echo=$ac_try;; 33832 esac 33833 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33834 $as_echo "$ac_try_echo"; } >&5 33835 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 33836 ac_status=$? 33837 if test -s conftest.err; then 33838 sed '10a\ 33839 ... rest of stderr output deleted ... 33840 10q' conftest.err >conftest.er1 33841 cat conftest.er1 >&5 33842 fi 33843 rm -f conftest.er1 conftest.err 33844 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33845 test $ac_status = 0; } 33846 done 33847 33848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33849 /* end confdefs.h. */ 33850 33851 int 33852 main () 33853 { 33854 33855 ; 33856 return 0; 33857 } 33858 _ACEOF 33859 ac_clean_files_save=$ac_clean_files 33860 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 33861 # Try to create an executable without -o first, disregard a.out. 33862 # It will help us diagnose broken compilers, and finding out an intuition 33863 # of exeext. 33864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 33865 $as_echo_n "checking whether the C compiler works... " >&6; } 33866 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 33867 33868 # The possible output files: 33869 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 33870 33871 ac_rmfiles= 33872 for ac_file in $ac_files 33873 do 33874 case $ac_file in 33875 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 33876 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 33877 esac 33878 done 33879 rm -f $ac_rmfiles 33880 33881 if { { ac_try="$ac_link_default" 33882 case "(($ac_try" in 33883 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33884 *) ac_try_echo=$ac_try;; 33885 esac 33886 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33887 $as_echo "$ac_try_echo"; } >&5 33888 (eval "$ac_link_default") 2>&5 33889 ac_status=$? 33890 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33891 test $ac_status = 0; }; then : 33892 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 33893 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 33894 # in a Makefile. We should not override ac_cv_exeext if it was cached, 33895 # so that the user can short-circuit this test for compilers unknown to 33896 # Autoconf. 33897 for ac_file in $ac_files '' 33898 do 33899 test -f "$ac_file" || continue 33900 case $ac_file in 33901 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 33902 ;; 33903 [ab].out ) 33904 # We found the default executable, but exeext='' is most 33905 # certainly right. 33906 break;; 33907 *.* ) 33908 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 33909 then :; else 33910 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 33911 fi 33912 # We set ac_cv_exeext here because the later test for it is not 33913 # safe: cross compilers may not add the suffix if given an `-o' 33914 # argument, so we may need to know it at that point already. 33915 # Even if this section looks crufty: it has the advantage of 33916 # actually working. 33917 break;; 33918 * ) 33919 break;; 33920 esac 33921 done 33922 test "$ac_cv_exeext" = no && ac_cv_exeext= 33923 33924 else 33925 ac_file='' 33926 fi 33927 if test -z "$ac_file"; then : 33928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33929 $as_echo "no" >&6; } 33930 $as_echo "$as_me: failed program was:" >&5 33931 sed 's/^/| /' conftest.$ac_ext >&5 33932 33933 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33934 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33935 as_fn_error 77 "C compiler cannot create executables 33936 See \`config.log' for more details" "$LINENO" 5; } 33937 else 33938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33939 $as_echo "yes" >&6; } 33940 fi 33941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 33942 $as_echo_n "checking for C compiler default output file name... " >&6; } 33943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 33944 $as_echo "$ac_file" >&6; } 33945 ac_exeext=$ac_cv_exeext 33946 33947 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 33948 ac_clean_files=$ac_clean_files_save 33949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 33950 $as_echo_n "checking for suffix of executables... " >&6; } 33951 if { { ac_try="$ac_link" 33952 case "(($ac_try" in 33953 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33954 *) ac_try_echo=$ac_try;; 33955 esac 33956 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33957 $as_echo "$ac_try_echo"; } >&5 33958 (eval "$ac_link") 2>&5 33959 ac_status=$? 33960 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33961 test $ac_status = 0; }; then : 33962 # If both `conftest.exe' and `conftest' are `present' (well, observable) 33963 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 33964 # work properly (i.e., refer to `conftest.exe'), while it won't with 33965 # `rm'. 33966 for ac_file in conftest.exe conftest conftest.*; do 33967 test -f "$ac_file" || continue 33968 case $ac_file in 33969 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 33970 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 33971 break;; 33972 * ) break;; 33973 esac 33974 done 33975 else 33976 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33977 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33978 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 33979 See \`config.log' for more details" "$LINENO" 5; } 33980 fi 33981 rm -f conftest conftest$ac_cv_exeext 33982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 33983 $as_echo "$ac_cv_exeext" >&6; } 33984 33985 rm -f conftest.$ac_ext 33986 EXEEXT=$ac_cv_exeext 33987 ac_exeext=$EXEEXT 33988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33989 /* end confdefs.h. */ 33990 #include <stdio.h> 33991 int 33992 main () 33993 { 33994 FILE *f = fopen ("conftest.out", "w"); 33995 return ferror (f) || fclose (f) != 0; 33996 33997 ; 33998 return 0; 33999 } 34000 _ACEOF 34001 ac_clean_files="$ac_clean_files conftest.out" 34002 # Check that the compiler produces executables we can run. If not, either 34003 # the compiler is broken, or we cross compile. 34004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 34005 $as_echo_n "checking whether we are cross compiling... " >&6; } 34006 if test "$cross_compiling" != yes; then 34007 { { ac_try="$ac_link" 34008 case "(($ac_try" in 34009 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34010 *) ac_try_echo=$ac_try;; 34011 esac 34012 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34013 $as_echo "$ac_try_echo"; } >&5 34014 (eval "$ac_link") 2>&5 34015 ac_status=$? 34016 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34017 test $ac_status = 0; } 34018 if { ac_try='./conftest$ac_cv_exeext' 34019 { { case "(($ac_try" in 34020 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34021 *) ac_try_echo=$ac_try;; 34022 esac 34023 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34024 $as_echo "$ac_try_echo"; } >&5 34025 (eval "$ac_try") 2>&5 34026 ac_status=$? 34027 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34028 test $ac_status = 0; }; }; then 34029 cross_compiling=no 34030 else 34031 if test "$cross_compiling" = maybe; then 34032 cross_compiling=yes 34033 else 34034 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34035 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34036 as_fn_error $? "cannot run C compiled programs. 34037 If you meant to cross compile, use \`--host'. 34038 See \`config.log' for more details" "$LINENO" 5; } 34039 fi 34040 fi 34041 fi 34042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34043 $as_echo "$cross_compiling" >&6; } 34044 34045 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34046 ac_clean_files=$ac_clean_files_save 34047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34048 $as_echo_n "checking for suffix of object files... " >&6; } 34049 if ${ac_cv_objext+:} false; then : 34050 $as_echo_n "(cached) " >&6 34051 else 34052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34053 /* end confdefs.h. */ 34054 34055 int 34056 main () 34057 { 34058 34059 ; 34060 return 0; 34061 } 34062 _ACEOF 34063 rm -f conftest.o conftest.obj 34064 if { { ac_try="$ac_compile" 34065 case "(($ac_try" in 34066 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34067 *) ac_try_echo=$ac_try;; 34068 esac 34069 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34070 $as_echo "$ac_try_echo"; } >&5 34071 (eval "$ac_compile") 2>&5 34072 ac_status=$? 34073 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34074 test $ac_status = 0; }; then : 34075 for ac_file in conftest.o conftest.obj conftest.*; do 34076 test -f "$ac_file" || continue; 34077 case $ac_file in 34078 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34079 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34080 break;; 34081 esac 34082 done 34083 else 34084 $as_echo "$as_me: failed program was:" >&5 34085 sed 's/^/| /' conftest.$ac_ext >&5 34086 34087 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34088 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34089 as_fn_error $? "cannot compute suffix of object files: cannot compile 34090 See \`config.log' for more details" "$LINENO" 5; } 34091 fi 34092 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34093 fi 34094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34095 $as_echo "$ac_cv_objext" >&6; } 34096 OBJEXT=$ac_cv_objext 34097 ac_objext=$OBJEXT 34098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34099 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34100 if ${ac_cv_c_compiler_gnu+:} false; then : 34101 $as_echo_n "(cached) " >&6 34102 else 34103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34104 /* end confdefs.h. */ 34105 34106 int 34107 main () 34108 { 34109 #ifndef __GNUC__ 34110 choke me 34111 #endif 34112 34113 ; 34114 return 0; 34115 } 34116 _ACEOF 34117 if ac_fn_c_try_compile "$LINENO"; then : 34118 ac_compiler_gnu=yes 34119 else 34120 ac_compiler_gnu=no 34121 fi 34122 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34123 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34124 34125 fi 34126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34127 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34128 if test $ac_compiler_gnu = yes; then 34129 GCC=yes 34130 else 34131 GCC= 34132 fi 34133 ac_test_CFLAGS=${CFLAGS+set} 34134 ac_save_CFLAGS=$CFLAGS 34135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34136 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34137 if ${ac_cv_prog_cc_g+:} false; then : 34138 $as_echo_n "(cached) " >&6 34139 else 34140 ac_save_c_werror_flag=$ac_c_werror_flag 34141 ac_c_werror_flag=yes 34142 ac_cv_prog_cc_g=no 34143 CFLAGS="-g" 34144 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34145 /* end confdefs.h. */ 34146 34147 int 34148 main () 34149 { 34150 34151 ; 34152 return 0; 34153 } 34154 _ACEOF 34155 if ac_fn_c_try_compile "$LINENO"; then : 34156 ac_cv_prog_cc_g=yes 34157 else 34158 CFLAGS="" 34159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34160 /* end confdefs.h. */ 34161 34162 int 34163 main () 34164 { 34165 34166 ; 34167 return 0; 34168 } 34169 _ACEOF 34170 if ac_fn_c_try_compile "$LINENO"; then : 34171 34172 else 34173 ac_c_werror_flag=$ac_save_c_werror_flag 34174 CFLAGS="-g" 34175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34176 /* end confdefs.h. */ 34177 34178 int 34179 main () 34180 { 34181 34182 ; 34183 return 0; 34184 } 34185 _ACEOF 34186 if ac_fn_c_try_compile "$LINENO"; then : 34187 ac_cv_prog_cc_g=yes 34188 fi 34189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34190 fi 34191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34192 fi 34193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34194 ac_c_werror_flag=$ac_save_c_werror_flag 34195 fi 34196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 34197 $as_echo "$ac_cv_prog_cc_g" >&6; } 34198 if test "$ac_test_CFLAGS" = set; then 34199 CFLAGS=$ac_save_CFLAGS 34200 elif test $ac_cv_prog_cc_g = yes; then 34201 if test "$GCC" = yes; then 34202 CFLAGS="-g -O2" 34203 else 34204 CFLAGS="-g" 34205 fi 34206 else 34207 if test "$GCC" = yes; then 34208 CFLAGS="-O2" 34209 else 34210 CFLAGS= 34211 fi 34212 fi 34213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 34214 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 34215 if ${ac_cv_prog_cc_c89+:} false; then : 34216 $as_echo_n "(cached) " >&6 34217 else 34218 ac_cv_prog_cc_c89=no 34219 ac_save_CC=$CC 34220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34221 /* end confdefs.h. */ 34222 #include <stdarg.h> 34223 #include <stdio.h> 34224 struct stat; 34225 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 34226 struct buf { int x; }; 34227 FILE * (*rcsopen) (struct buf *, struct stat *, int); 34228 static char *e (p, i) 34229 char **p; 34230 int i; 34231 { 34232 return p[i]; 34233 } 34234 static char *f (char * (*g) (char **, int), char **p, ...) 34235 { 34236 char *s; 34237 va_list v; 34238 va_start (v,p); 34239 s = g (p, va_arg (v,int)); 34240 va_end (v); 34241 return s; 34242 } 34243 34244 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 34245 function prototypes and stuff, but not '\xHH' hex character constants. 34246 These don't provoke an error unfortunately, instead are silently treated 34247 as 'x'. The following induces an error, until -std is added to get 34248 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 34249 array size at least. It's necessary to write '\x00'==0 to get something 34250 that's true only with -std. */ 34251 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 34252 34253 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 34254 inside strings and character constants. */ 34255 #define FOO(x) 'x' 34256 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 34257 34258 int test (int i, double x); 34259 struct s1 {int (*f) (int a);}; 34260 struct s2 {int (*f) (double a);}; 34261 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 34262 int argc; 34263 char **argv; 34264 int 34265 main () 34266 { 34267 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 34268 ; 34269 return 0; 34270 } 34271 _ACEOF 34272 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 34273 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 34274 do 34275 CC="$ac_save_CC $ac_arg" 34276 if ac_fn_c_try_compile "$LINENO"; then : 34277 ac_cv_prog_cc_c89=$ac_arg 34278 fi 34279 rm -f core conftest.err conftest.$ac_objext 34280 test "x$ac_cv_prog_cc_c89" != "xno" && break 34281 done 34282 rm -f conftest.$ac_ext 34283 CC=$ac_save_CC 34284 34285 fi 34286 # AC_CACHE_VAL 34287 case "x$ac_cv_prog_cc_c89" in 34288 x) 34289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 34290 $as_echo "none needed" >&6; } ;; 34291 xno) 34292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 34293 $as_echo "unsupported" >&6; } ;; 34294 *) 34295 CC="$CC $ac_cv_prog_cc_c89" 34296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 34297 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 34298 esac 34299 if test "x$ac_cv_prog_cc_c89" != xno; then : 34300 34301 fi 34302 34303 ac_ext=cpp 34304 ac_cpp='$CXXCPP $CPPFLAGS' 34305 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34306 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34307 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34308 34309 34310 34311 COMPILER_NAME=C++ 34312 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 34313 34314 if test "x$CXX" != x; then 34315 # User has supplied compiler name already, always let that override. 34316 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 34317 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 34318 if test "x`basename $CXX`" = "x$CXX"; then 34319 # A command without a complete path is provided, search $PATH. 34320 34321 for ac_prog in $CXX 34322 do 34323 # Extract the first word of "$ac_prog", so it can be a program name with args. 34324 set dummy $ac_prog; ac_word=$2 34325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34326 $as_echo_n "checking for $ac_word... " >&6; } 34327 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34328 $as_echo_n "(cached) " >&6 34329 else 34330 case $POTENTIAL_CXX in 34331 [\\/]* | ?:[\\/]*) 34332 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34333 ;; 34334 *) 34335 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34336 for as_dir in $PATH 34337 do 34338 IFS=$as_save_IFS 34339 test -z "$as_dir" && as_dir=. 34340 for ac_exec_ext in '' $ac_executable_extensions; do 34341 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34342 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34343 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34344 break 2 34345 fi 34346 done 34347 done 34348 IFS=$as_save_IFS 34349 34350 ;; 34351 esac 34352 fi 34353 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34354 if test -n "$POTENTIAL_CXX"; then 34355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34356 $as_echo "$POTENTIAL_CXX" >&6; } 34357 else 34358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34359 $as_echo "no" >&6; } 34360 fi 34361 34362 34363 test -n "$POTENTIAL_CXX" && break 34364 done 34365 34366 if test "x$POTENTIAL_CXX" != x; then 34367 CXX=$POTENTIAL_CXX 34368 else 34369 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 34370 fi 34371 else 34372 # Otherwise it might already be a complete path 34373 if test ! -x "$CXX"; then 34374 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 34375 fi 34376 fi 34377 else 34378 # No user supplied value. Locate compiler ourselves. 34379 34380 # If we are cross compiling, assume cross compilation tools follows the 34381 # cross compilation standard where they are prefixed with the autoconf 34382 # standard name for the target. For example the binary 34383 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 34384 # If we are not cross compiling, then the default compiler name will be 34385 # used. 34386 34387 CXX= 34388 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 34389 # before checking the rest of the PATH. 34390 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 34391 # step, this should not be necessary. 34392 if test -n "$TOOLCHAIN_PATH"; then 34393 PATH_save="$PATH" 34394 PATH="$TOOLCHAIN_PATH" 34395 for ac_prog in $SEARCH_LIST 34396 do 34397 # Extract the first word of "$ac_prog", so it can be a program name with args. 34398 set dummy $ac_prog; ac_word=$2 34399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34400 $as_echo_n "checking for $ac_word... " >&6; } 34401 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 34402 $as_echo_n "(cached) " >&6 34403 else 34404 case $TOOLCHAIN_PATH_CXX in 34405 [\\/]* | ?:[\\/]*) 34406 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 34407 ;; 34408 *) 34409 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34410 for as_dir in $PATH 34411 do 34412 IFS=$as_save_IFS 34413 test -z "$as_dir" && as_dir=. 34414 for ac_exec_ext in '' $ac_executable_extensions; do 34415 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34416 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 34417 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34418 break 2 34419 fi 34420 done 34421 done 34422 IFS=$as_save_IFS 34423 34424 ;; 34425 esac 34426 fi 34427 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 34428 if test -n "$TOOLCHAIN_PATH_CXX"; then 34429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 34430 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 34431 else 34432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34433 $as_echo "no" >&6; } 34434 fi 34435 34436 34437 test -n "$TOOLCHAIN_PATH_CXX" && break 34438 done 34439 34440 CXX=$TOOLCHAIN_PATH_CXX 34441 PATH="$PATH_save" 34442 fi 34443 34444 # AC_PATH_PROGS can't be run multiple times with the same variable, 34445 # so create a new name for this run. 34446 if test "x$CXX" = x; then 34447 for ac_prog in $SEARCH_LIST 34448 do 34449 # Extract the first word of "$ac_prog", so it can be a program name with args. 34450 set dummy $ac_prog; ac_word=$2 34451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34452 $as_echo_n "checking for $ac_word... " >&6; } 34453 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34454 $as_echo_n "(cached) " >&6 34455 else 34456 case $POTENTIAL_CXX in 34457 [\\/]* | ?:[\\/]*) 34458 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34459 ;; 34460 *) 34461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34462 for as_dir in $PATH 34463 do 34464 IFS=$as_save_IFS 34465 test -z "$as_dir" && as_dir=. 34466 for ac_exec_ext in '' $ac_executable_extensions; do 34467 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34468 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34470 break 2 34471 fi 34472 done 34473 done 34474 IFS=$as_save_IFS 34475 34476 ;; 34477 esac 34478 fi 34479 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34480 if test -n "$POTENTIAL_CXX"; then 34481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34482 $as_echo "$POTENTIAL_CXX" >&6; } 34483 else 34484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34485 $as_echo "no" >&6; } 34486 fi 34487 34488 34489 test -n "$POTENTIAL_CXX" && break 34490 done 34491 34492 CXX=$POTENTIAL_CXX 34493 fi 34494 34495 if test "x$CXX" = x; then 34496 34497 # Print a helpful message on how to acquire the necessary build dependency. 34498 # devkit is the help tag: freetype, cups, alsa etc 34499 MISSING_DEPENDENCY=devkit 34500 34501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34502 cygwin_help $MISSING_DEPENDENCY 34503 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34504 msys_help $MISSING_DEPENDENCY 34505 else 34506 PKGHANDLER_COMMAND= 34507 34508 case $PKGHANDLER in 34509 apt-get) 34510 apt_help $MISSING_DEPENDENCY ;; 34511 yum) 34512 yum_help $MISSING_DEPENDENCY ;; 34513 port) 34514 port_help $MISSING_DEPENDENCY ;; 34515 pkgutil) 34516 pkgutil_help $MISSING_DEPENDENCY ;; 34517 pkgadd) 34518 pkgadd_help $MISSING_DEPENDENCY ;; 34519 esac 34520 34521 if test "x$PKGHANDLER_COMMAND" != x; then 34522 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34523 fi 34524 fi 34525 34526 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34527 fi 34528 fi 34529 34530 # Now we have a compiler binary in CXX. Make sure it's okay. 34531 34532 # Only process if variable expands to non-empty 34533 34534 if test "x$CXX" != x; then 34535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34536 34537 # First separate the path from the arguments. This will split at the first 34538 # space. 34539 complete="$CXX" 34540 path="${complete%% *}" 34541 tmp="$complete EOL" 34542 arguments="${tmp#* }" 34543 34544 # Input might be given as Windows format, start by converting to 34545 # unix format. 34546 new_path=`$CYGPATH -u "$path"` 34547 34548 # Now try to locate executable using which 34549 new_path=`$WHICH "$new_path" 2> /dev/null` 34550 # bat and cmd files are not always considered executable in cygwin causing which 34551 # to not find them 34552 if test "x$new_path" = x \ 34553 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34554 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34555 new_path=`$CYGPATH -u "$path"` 34556 fi 34557 if test "x$new_path" = x; then 34558 # Oops. Which didn't find the executable. 34559 # The splitting of arguments from the executable at a space might have been incorrect, 34560 # since paths with space are more likely in Windows. Give it another try with the whole 34561 # argument. 34562 path="$complete" 34563 arguments="EOL" 34564 new_path=`$CYGPATH -u "$path"` 34565 new_path=`$WHICH "$new_path" 2> /dev/null` 34566 # bat and cmd files are not always considered executable in cygwin causing which 34567 # to not find them 34568 if test "x$new_path" = x \ 34569 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34570 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34571 new_path=`$CYGPATH -u "$path"` 34572 fi 34573 if test "x$new_path" = x; then 34574 # It's still not found. Now this is an unrecoverable error. 34575 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34576 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34577 has_space=`$ECHO "$complete" | $GREP " "` 34578 if test "x$has_space" != x; then 34579 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34580 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34581 fi 34582 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34583 fi 34584 fi 34585 34586 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34587 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34588 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34589 # "foo.exe" is OK but "foo" is an error. 34590 # 34591 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34592 # It is also a way to make sure we got the proper file name for the real test later on. 34593 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34594 if test "x$test_shortpath" = x; then 34595 # Short path failed, file does not exist as specified. 34596 # Try adding .exe or .cmd 34597 if test -f "${new_path}.exe"; then 34598 input_to_shortpath="${new_path}.exe" 34599 elif test -f "${new_path}.cmd"; then 34600 input_to_shortpath="${new_path}.cmd" 34601 else 34602 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 34603 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 34604 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34605 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34606 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34607 fi 34608 else 34609 input_to_shortpath="$new_path" 34610 fi 34611 34612 # Call helper function which possibly converts this using DOS-style short mode. 34613 # If so, the updated path is stored in $new_path. 34614 new_path="$input_to_shortpath" 34615 34616 input_path="$input_to_shortpath" 34617 # Check if we need to convert this using DOS-style short mode. If the path 34618 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34619 # take no chances and rewrite it. 34620 # Note: m4 eats our [], so we need to use [ and ] instead. 34621 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34622 if test "x$has_forbidden_chars" != x; then 34623 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34624 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34625 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34626 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34627 # Going to short mode and back again did indeed matter. Since short mode is 34628 # case insensitive, let's make it lowercase to improve readability. 34629 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34630 # Now convert it back to Unix-style (cygpath) 34631 input_path=`$CYGPATH -u "$shortmode_path"` 34632 new_path="$input_path" 34633 fi 34634 fi 34635 34636 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34637 if test "x$test_cygdrive_prefix" = x; then 34638 # As a simple fix, exclude /usr/bin since it's not a real path. 34639 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34640 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34641 # a path prefixed by /cygdrive for fixpath to work. 34642 new_path="$CYGWIN_ROOT_PATH$input_path" 34643 fi 34644 fi 34645 34646 # remove trailing .exe if any 34647 new_path="${new_path/%.exe/}" 34648 34649 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34650 34651 # First separate the path from the arguments. This will split at the first 34652 # space. 34653 complete="$CXX" 34654 path="${complete%% *}" 34655 tmp="$complete EOL" 34656 arguments="${tmp#* }" 34657 34658 # Input might be given as Windows format, start by converting to 34659 # unix format. 34660 new_path="$path" 34661 34662 windows_path="$new_path" 34663 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34664 unix_path=`$CYGPATH -u "$windows_path"` 34665 new_path="$unix_path" 34666 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34667 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34668 new_path="$unix_path" 34669 fi 34670 34671 34672 # Now try to locate executable using which 34673 new_path=`$WHICH "$new_path" 2> /dev/null` 34674 34675 if test "x$new_path" = x; then 34676 # Oops. Which didn't find the executable. 34677 # The splitting of arguments from the executable at a space might have been incorrect, 34678 # since paths with space are more likely in Windows. Give it another try with the whole 34679 # argument. 34680 path="$complete" 34681 arguments="EOL" 34682 new_path="$path" 34683 34684 windows_path="$new_path" 34685 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34686 unix_path=`$CYGPATH -u "$windows_path"` 34687 new_path="$unix_path" 34688 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34689 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34690 new_path="$unix_path" 34691 fi 34692 34693 34694 new_path=`$WHICH "$new_path" 2> /dev/null` 34695 # bat and cmd files are not always considered executable in MSYS causing which 34696 # to not find them 34697 if test "x$new_path" = x \ 34698 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34699 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34700 new_path="$path" 34701 34702 windows_path="$new_path" 34703 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34704 unix_path=`$CYGPATH -u "$windows_path"` 34705 new_path="$unix_path" 34706 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34707 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34708 new_path="$unix_path" 34709 fi 34710 34711 fi 34712 34713 if test "x$new_path" = x; then 34714 # It's still not found. Now this is an unrecoverable error. 34715 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34716 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34717 has_space=`$ECHO "$complete" | $GREP " "` 34718 if test "x$has_space" != x; then 34719 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34720 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34721 fi 34722 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34723 fi 34724 fi 34725 34726 # Now new_path has a complete unix path to the binary 34727 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34728 # Keep paths in /bin as-is, but remove trailing .exe if any 34729 new_path="${new_path/%.exe/}" 34730 # Do not save /bin paths to all_fixpath_prefixes! 34731 else 34732 # Not in mixed or Windows style, start by that. 34733 new_path=`cmd //c echo $new_path` 34734 34735 input_path="$new_path" 34736 # Check if we need to convert this using DOS-style short mode. If the path 34737 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34738 # take no chances and rewrite it. 34739 # Note: m4 eats our [], so we need to use [ and ] instead. 34740 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34741 if test "x$has_forbidden_chars" != x; then 34742 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34743 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34744 fi 34745 34746 # Output is in $new_path 34747 34748 windows_path="$new_path" 34749 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34750 unix_path=`$CYGPATH -u "$windows_path"` 34751 new_path="$unix_path" 34752 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34753 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34754 new_path="$unix_path" 34755 fi 34756 34757 # remove trailing .exe if any 34758 new_path="${new_path/%.exe/}" 34759 34760 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34761 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34762 fi 34763 34764 else 34765 # We're on a unix platform. Hooray! :) 34766 # First separate the path from the arguments. This will split at the first 34767 # space. 34768 complete="$CXX" 34769 path="${complete%% *}" 34770 tmp="$complete EOL" 34771 arguments="${tmp#* }" 34772 34773 # Cannot rely on the command "which" here since it doesn't always work. 34774 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34775 if test -z "$is_absolute_path"; then 34776 # Path to executable is not absolute. Find it. 34777 IFS_save="$IFS" 34778 IFS=: 34779 for p in $PATH; do 34780 if test -f "$p/$path" && test -x "$p/$path"; then 34781 new_path="$p/$path" 34782 break 34783 fi 34784 done 34785 IFS="$IFS_save" 34786 else 34787 # This is an absolute path, we can use it without further modifications. 34788 new_path="$path" 34789 fi 34790 34791 if test "x$new_path" = x; then 34792 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34793 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34794 has_space=`$ECHO "$complete" | $GREP " "` 34795 if test "x$has_space" != x; then 34796 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34797 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34798 fi 34799 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34800 fi 34801 fi 34802 34803 # Now join together the path and the arguments once again 34804 if test "x$arguments" != xEOL; then 34805 new_complete="$new_path ${arguments% *}" 34806 else 34807 new_complete="$new_path" 34808 fi 34809 34810 if test "x$complete" != "x$new_complete"; then 34811 CXX="$new_complete" 34812 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 34813 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 34814 fi 34815 fi 34816 34817 TEST_COMPILER="$CXX" 34818 34819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 34820 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 34821 SYMLINK_ORIGINAL="$TEST_COMPILER" 34822 34823 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34824 # Follow a chain of symbolic links. Use readlink 34825 # where it exists, else fall back to horribly 34826 # complicated shell code. 34827 if test "x$READLINK_TESTED" != yes; then 34828 # On MacOSX there is a readlink tool with a different 34829 # purpose than the GNU readlink tool. Check the found readlink. 34830 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34831 if test "x$ISGNU" = x; then 34832 # A readlink that we do not know how to use. 34833 # Are there other non-GNU readlinks out there? 34834 READLINK_TESTED=yes 34835 READLINK= 34836 fi 34837 fi 34838 34839 if test "x$READLINK" != x; then 34840 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 34841 else 34842 # Save the current directory for restoring afterwards 34843 STARTDIR=$PWD 34844 COUNTER=0 34845 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 34846 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 34847 cd $sym_link_dir 34848 # Use -P flag to resolve symlinks in directories. 34849 cd `$THEPWDCMD -P` 34850 sym_link_dir=`$THEPWDCMD -P` 34851 # Resolve file symlinks 34852 while test $COUNTER -lt 20; do 34853 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34854 if test "x$ISLINK" == x; then 34855 # This is not a symbolic link! We are done! 34856 break 34857 fi 34858 # Again resolve directory symlinks since the target of the just found 34859 # link could be in a different directory 34860 cd `$DIRNAME $ISLINK` 34861 sym_link_dir=`$THEPWDCMD -P` 34862 sym_link_file=`$BASENAME $ISLINK` 34863 let COUNTER=COUNTER+1 34864 done 34865 cd $STARTDIR 34866 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 34867 fi 34868 fi 34869 34870 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 34871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 34872 $as_echo "no symlink" >&6; } 34873 else 34874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 34875 $as_echo "$SYMLINK_ORIGINAL" >&6; } 34876 34877 # We can't handle ccache by gcc wrappers, since we need to know if we're 34878 # using ccache. Instead ccache usage must be controlled by a configure option. 34879 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 34880 if test "x$COMPILER_BASENAME" = "xccache"; then 34881 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 34882 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 34883 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 34884 fi 34885 fi 34886 34887 34888 COMPILER=$CXX 34889 COMPILER_NAME=$COMPILER_NAME 34890 34891 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34892 # cc -V output typically looks like 34893 # cc: Sun C 5.12 Linux_i386 2011/11/16 34894 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34895 # Check that this is likely to be the Solaris Studio cc. 34896 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 34897 if test $? -ne 0; then 34898 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34899 { $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 34900 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34901 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34902 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34903 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34904 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34905 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34906 fi 34907 # Remove usage instructions (if present), and 34908 # collapse compiler output into a single line 34909 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34910 $SED -e 's/ *[Uu]sage:.*//'` 34911 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34912 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34913 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34914 # xlc -qversion output typically looks like 34915 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34916 # Version: 11.01.0000.0015 34917 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34918 # Check that this is likely to be the IBM XL C compiler. 34919 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 34920 if test $? -ne 0; then 34921 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34922 { $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 34923 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34924 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34925 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34926 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34927 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34928 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34929 fi 34930 # Collapse compiler output into a single line 34931 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34932 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34933 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34934 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34935 # There is no specific version flag, but all output starts with a version string. 34936 # First line typically looks something like: 34937 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34938 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34939 # Check that this is likely to be Microsoft CL.EXE. 34940 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34941 if test $? -ne 0; then 34942 { $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 34943 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34944 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34945 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34946 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34947 fi 34948 # Collapse compiler output into a single line 34949 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34950 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34951 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34952 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34953 # gcc --version output typically looks like 34954 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34955 # Copyright (C) 2013 Free Software Foundation, Inc. 34956 # This is free software; see the source for copying conditions. There is NO 34957 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34958 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34959 # Check that this is likely to be GCC. 34960 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34961 if test $? -ne 0; then 34962 { $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 34963 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34964 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34965 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34966 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34967 fi 34968 # Remove Copyright and legalese from version string, and 34969 # collapse into a single line 34970 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34971 $SED -e 's/ *Copyright .*//'` 34972 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34973 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34974 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34975 # clang --version output typically looks like 34976 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34977 # clang version 3.3 (tags/RELEASE_33/final) 34978 # or 34979 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34980 # Target: x86_64-pc-linux-gnu 34981 # Thread model: posix 34982 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34983 # Check that this is likely to be clang 34984 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34985 if test $? -ne 0; then 34986 { $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 34987 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34988 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34989 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34990 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34991 fi 34992 # Collapse compiler output into a single line 34993 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34994 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34995 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34996 else 34997 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34998 fi 34999 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 35000 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 35001 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 35002 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 35003 35004 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 35005 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 35006 35007 35008 # Now that we have resolved CXX ourself, let autoconf have its go at it 35009 ac_ext=cpp 35010 ac_cpp='$CXXCPP $CPPFLAGS' 35011 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35012 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35013 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35014 if test -z "$CXX"; then 35015 if test -n "$CCC"; then 35016 CXX=$CCC 35017 else 35018 if test -n "$ac_tool_prefix"; then 35019 for ac_prog in $CXX 35020 do 35021 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 35022 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 35023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35024 $as_echo_n "checking for $ac_word... " >&6; } 35025 if ${ac_cv_prog_CXX+:} false; then : 35026 $as_echo_n "(cached) " >&6 35027 else 35028 if test -n "$CXX"; then 35029 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35030 else 35031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35032 for as_dir in $PATH 35033 do 35034 IFS=$as_save_IFS 35035 test -z "$as_dir" && as_dir=. 35036 for ac_exec_ext in '' $ac_executable_extensions; do 35037 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35038 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35039 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35040 break 2 35041 fi 35042 done 35043 done 35044 IFS=$as_save_IFS 35045 35046 fi 35047 fi 35048 CXX=$ac_cv_prog_CXX 35049 if test -n "$CXX"; then 35050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 35051 $as_echo "$CXX" >&6; } 35052 else 35053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35054 $as_echo "no" >&6; } 35055 fi 35056 35057 35058 test -n "$CXX" && break 35059 done 35060 fi 35061 if test -z "$CXX"; then 35062 ac_ct_CXX=$CXX 35063 for ac_prog in $CXX 35064 do 35065 # Extract the first word of "$ac_prog", so it can be a program name with args. 35066 set dummy $ac_prog; ac_word=$2 35067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35068 $as_echo_n "checking for $ac_word... " >&6; } 35069 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 35070 $as_echo_n "(cached) " >&6 35071 else 35072 if test -n "$ac_ct_CXX"; then 35073 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 35074 else 35075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35076 for as_dir in $PATH 35077 do 35078 IFS=$as_save_IFS 35079 test -z "$as_dir" && as_dir=. 35080 for ac_exec_ext in '' $ac_executable_extensions; do 35081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35082 ac_cv_prog_ac_ct_CXX="$ac_prog" 35083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35084 break 2 35085 fi 35086 done 35087 done 35088 IFS=$as_save_IFS 35089 35090 fi 35091 fi 35092 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 35093 if test -n "$ac_ct_CXX"; then 35094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 35095 $as_echo "$ac_ct_CXX" >&6; } 35096 else 35097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35098 $as_echo "no" >&6; } 35099 fi 35100 35101 35102 test -n "$ac_ct_CXX" && break 35103 done 35104 35105 if test "x$ac_ct_CXX" = x; then 35106 CXX="g++" 35107 else 35108 case $cross_compiling:$ac_tool_warned in 35109 yes:) 35110 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35111 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35112 ac_tool_warned=yes ;; 35113 esac 35114 CXX=$ac_ct_CXX 35115 fi 35116 fi 35117 35118 fi 35119 fi 35120 # Provide some information about the compiler. 35121 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 35122 set X $ac_compile 35123 ac_compiler=$2 35124 for ac_option in --version -v -V -qversion; do 35125 { { ac_try="$ac_compiler $ac_option >&5" 35126 case "(($ac_try" in 35127 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 35128 *) ac_try_echo=$ac_try;; 35129 esac 35130 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 35131 $as_echo "$ac_try_echo"; } >&5 35132 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 35133 ac_status=$? 35134 if test -s conftest.err; then 35135 sed '10a\ 35136 ... rest of stderr output deleted ... 35137 10q' conftest.err >conftest.er1 35138 cat conftest.er1 >&5 35139 fi 35140 rm -f conftest.er1 conftest.err 35141 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 35142 test $ac_status = 0; } 35143 done 35144 35145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 35146 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 35147 if ${ac_cv_cxx_compiler_gnu+:} false; then : 35148 $as_echo_n "(cached) " >&6 35149 else 35150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35151 /* end confdefs.h. */ 35152 35153 int 35154 main () 35155 { 35156 #ifndef __GNUC__ 35157 choke me 35158 #endif 35159 35160 ; 35161 return 0; 35162 } 35163 _ACEOF 35164 if ac_fn_cxx_try_compile "$LINENO"; then : 35165 ac_compiler_gnu=yes 35166 else 35167 ac_compiler_gnu=no 35168 fi 35169 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35170 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 35171 35172 fi 35173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 35174 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 35175 if test $ac_compiler_gnu = yes; then 35176 GXX=yes 35177 else 35178 GXX= 35179 fi 35180 ac_test_CXXFLAGS=${CXXFLAGS+set} 35181 ac_save_CXXFLAGS=$CXXFLAGS 35182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 35183 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 35184 if ${ac_cv_prog_cxx_g+:} false; then : 35185 $as_echo_n "(cached) " >&6 35186 else 35187 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 35188 ac_cxx_werror_flag=yes 35189 ac_cv_prog_cxx_g=no 35190 CXXFLAGS="-g" 35191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35192 /* end confdefs.h. */ 35193 35194 int 35195 main () 35196 { 35197 35198 ; 35199 return 0; 35200 } 35201 _ACEOF 35202 if ac_fn_cxx_try_compile "$LINENO"; then : 35203 ac_cv_prog_cxx_g=yes 35204 else 35205 CXXFLAGS="" 35206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35207 /* end confdefs.h. */ 35208 35209 int 35210 main () 35211 { 35212 35213 ; 35214 return 0; 35215 } 35216 _ACEOF 35217 if ac_fn_cxx_try_compile "$LINENO"; then : 35218 35219 else 35220 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35221 CXXFLAGS="-g" 35222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35223 /* end confdefs.h. */ 35224 35225 int 35226 main () 35227 { 35228 35229 ; 35230 return 0; 35231 } 35232 _ACEOF 35233 if ac_fn_cxx_try_compile "$LINENO"; then : 35234 ac_cv_prog_cxx_g=yes 35235 fi 35236 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35237 fi 35238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35239 fi 35240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35241 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35242 fi 35243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 35244 $as_echo "$ac_cv_prog_cxx_g" >&6; } 35245 if test "$ac_test_CXXFLAGS" = set; then 35246 CXXFLAGS=$ac_save_CXXFLAGS 35247 elif test $ac_cv_prog_cxx_g = yes; then 35248 if test "$GXX" = yes; then 35249 CXXFLAGS="-g -O2" 35250 else 35251 CXXFLAGS="-g" 35252 fi 35253 else 35254 if test "$GXX" = yes; then 35255 CXXFLAGS="-O2" 35256 else 35257 CXXFLAGS= 35258 fi 35259 fi 35260 ac_ext=cpp 35261 ac_cpp='$CXXCPP $CPPFLAGS' 35262 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35263 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35264 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35265 35266 35267 # This is the compiler version number on the form X.Y[.Z] 35268 35269 35270 35271 35272 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 35273 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 35274 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 35275 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 35276 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 35277 fi 35278 35279 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 35280 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 35281 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 35282 $as_echo "$as_me: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 35283 fi 35284 35285 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 35286 { $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 35287 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 35288 fi 35289 35290 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$CC_VERSION_NUMBER"` 35291 35292 35293 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 35294 35295 35296 35297 35298 35299 35300 35301 35302 35303 35304 35305 35306 35307 35308 35309 35310 35311 35312 35313 35314 35315 35316 35317 35318 35319 35320 35321 35322 35323 35324 35325 35326 35327 35328 35329 35330 35331 35332 35333 35334 35335 35336 35337 35338 35339 35340 35341 35342 35343 # Execute function body 35344 35345 # Need to assign to a variable since m4 is blocked from modifying parts in []. 35346 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 35347 35348 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 35349 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only three parts (X.Y.Z) is supported" "$LINENO" 5 35350 fi 35351 35352 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 35353 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 35354 fi 35355 35356 # Version comparison method inspired by http://stackoverflow.com/a/24067243 35357 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 35358 35359 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 35360 : 35361 35362 else 35363 : 35364 35365 { $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 35366 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 35367 35368 35369 fi 35370 35371 35372 35373 35374 35375 35376 35377 35378 35379 35380 35381 35382 35383 35384 fi 35385 35386 # 35387 # Setup the preprocessor (CPP and CXXCPP) 35388 # 35389 ac_ext=c 35390 ac_cpp='$CPP $CPPFLAGS' 35391 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35392 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35393 ac_compiler_gnu=$ac_cv_c_compiler_gnu 35394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 35395 $as_echo_n "checking how to run the C preprocessor... " >&6; } 35396 # On Suns, sometimes $CPP names a directory. 35397 if test -n "$CPP" && test -d "$CPP"; then 35398 CPP= 35399 fi 35400 if test -z "$CPP"; then 35401 if ${ac_cv_prog_CPP+:} false; then : 35402 $as_echo_n "(cached) " >&6 35403 else 35404 # Double quotes because CPP needs to be expanded 35405 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 35406 do 35407 ac_preproc_ok=false 35408 for ac_c_preproc_warn_flag in '' yes 35409 do 35410 # Use a header file that comes with gcc, so configuring glibc 35411 # with a fresh cross-compiler works. 35412 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35413 # <limits.h> exists even on freestanding compilers. 35414 # On the NeXT, cc -E runs the code through the compiler's parser, 35415 # not just through cpp. "Syntax error" is here to catch this case. 35416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35417 /* end confdefs.h. */ 35418 #ifdef __STDC__ 35419 # include <limits.h> 35420 #else 35421 # include <assert.h> 35422 #endif 35423 Syntax error 35424 _ACEOF 35425 if ac_fn_c_try_cpp "$LINENO"; then : 35426 35427 else 35428 # Broken: fails on valid input. 35429 continue 35430 fi 35431 rm -f conftest.err conftest.i conftest.$ac_ext 35432 35433 # OK, works on sane cases. Now check whether nonexistent headers 35434 # can be detected and how. 35435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35436 /* end confdefs.h. */ 35437 #include <ac_nonexistent.h> 35438 _ACEOF 35439 if ac_fn_c_try_cpp "$LINENO"; then : 35440 # Broken: success on invalid input. 35441 continue 35442 else 35443 # Passes both tests. 35444 ac_preproc_ok=: 35445 break 35446 fi 35447 rm -f conftest.err conftest.i conftest.$ac_ext 35448 35449 done 35450 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35451 rm -f conftest.i conftest.err conftest.$ac_ext 35452 if $ac_preproc_ok; then : 35453 break 35454 fi 35455 35456 done 35457 ac_cv_prog_CPP=$CPP 35458 35459 fi 35460 CPP=$ac_cv_prog_CPP 35461 else 35462 ac_cv_prog_CPP=$CPP 35463 fi 35464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 35465 $as_echo "$CPP" >&6; } 35466 ac_preproc_ok=false 35467 for ac_c_preproc_warn_flag in '' yes 35468 do 35469 # Use a header file that comes with gcc, so configuring glibc 35470 # with a fresh cross-compiler works. 35471 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35472 # <limits.h> exists even on freestanding compilers. 35473 # On the NeXT, cc -E runs the code through the compiler's parser, 35474 # not just through cpp. "Syntax error" is here to catch this case. 35475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35476 /* end confdefs.h. */ 35477 #ifdef __STDC__ 35478 # include <limits.h> 35479 #else 35480 # include <assert.h> 35481 #endif 35482 Syntax error 35483 _ACEOF 35484 if ac_fn_c_try_cpp "$LINENO"; then : 35485 35486 else 35487 # Broken: fails on valid input. 35488 continue 35489 fi 35490 rm -f conftest.err conftest.i conftest.$ac_ext 35491 35492 # OK, works on sane cases. Now check whether nonexistent headers 35493 # can be detected and how. 35494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35495 /* end confdefs.h. */ 35496 #include <ac_nonexistent.h> 35497 _ACEOF 35498 if ac_fn_c_try_cpp "$LINENO"; then : 35499 # Broken: success on invalid input. 35500 continue 35501 else 35502 # Passes both tests. 35503 ac_preproc_ok=: 35504 break 35505 fi 35506 rm -f conftest.err conftest.i conftest.$ac_ext 35507 35508 done 35509 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35510 rm -f conftest.i conftest.err conftest.$ac_ext 35511 if $ac_preproc_ok; then : 35512 35513 else 35514 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35515 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35516 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 35517 See \`config.log' for more details" "$LINENO" 5; } 35518 fi 35519 35520 ac_ext=cpp 35521 ac_cpp='$CXXCPP $CPPFLAGS' 35522 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35523 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35524 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35525 35526 35527 # Only process if variable expands to non-empty 35528 35529 if test "x$CPP" != x; then 35530 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35531 35532 # First separate the path from the arguments. This will split at the first 35533 # space. 35534 complete="$CPP" 35535 path="${complete%% *}" 35536 tmp="$complete EOL" 35537 arguments="${tmp#* }" 35538 35539 # Input might be given as Windows format, start by converting to 35540 # unix format. 35541 new_path=`$CYGPATH -u "$path"` 35542 35543 # Now try to locate executable using which 35544 new_path=`$WHICH "$new_path" 2> /dev/null` 35545 # bat and cmd files are not always considered executable in cygwin causing which 35546 # to not find them 35547 if test "x$new_path" = x \ 35548 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35549 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35550 new_path=`$CYGPATH -u "$path"` 35551 fi 35552 if test "x$new_path" = x; then 35553 # Oops. Which didn't find the executable. 35554 # The splitting of arguments from the executable at a space might have been incorrect, 35555 # since paths with space are more likely in Windows. Give it another try with the whole 35556 # argument. 35557 path="$complete" 35558 arguments="EOL" 35559 new_path=`$CYGPATH -u "$path"` 35560 new_path=`$WHICH "$new_path" 2> /dev/null` 35561 # bat and cmd files are not always considered executable in cygwin causing which 35562 # to not find them 35563 if test "x$new_path" = x \ 35564 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35565 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35566 new_path=`$CYGPATH -u "$path"` 35567 fi 35568 if test "x$new_path" = x; then 35569 # It's still not found. Now this is an unrecoverable error. 35570 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35571 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35572 has_space=`$ECHO "$complete" | $GREP " "` 35573 if test "x$has_space" != x; then 35574 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35575 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35576 fi 35577 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35578 fi 35579 fi 35580 35581 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35582 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35583 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35584 # "foo.exe" is OK but "foo" is an error. 35585 # 35586 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35587 # It is also a way to make sure we got the proper file name for the real test later on. 35588 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35589 if test "x$test_shortpath" = x; then 35590 # Short path failed, file does not exist as specified. 35591 # Try adding .exe or .cmd 35592 if test -f "${new_path}.exe"; then 35593 input_to_shortpath="${new_path}.exe" 35594 elif test -f "${new_path}.cmd"; then 35595 input_to_shortpath="${new_path}.cmd" 35596 else 35597 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 35598 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 35599 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35600 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35601 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35602 fi 35603 else 35604 input_to_shortpath="$new_path" 35605 fi 35606 35607 # Call helper function which possibly converts this using DOS-style short mode. 35608 # If so, the updated path is stored in $new_path. 35609 new_path="$input_to_shortpath" 35610 35611 input_path="$input_to_shortpath" 35612 # Check if we need to convert this using DOS-style short mode. If the path 35613 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35614 # take no chances and rewrite it. 35615 # Note: m4 eats our [], so we need to use [ and ] instead. 35616 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35617 if test "x$has_forbidden_chars" != x; then 35618 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35619 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35620 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35621 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35622 # Going to short mode and back again did indeed matter. Since short mode is 35623 # case insensitive, let's make it lowercase to improve readability. 35624 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35625 # Now convert it back to Unix-style (cygpath) 35626 input_path=`$CYGPATH -u "$shortmode_path"` 35627 new_path="$input_path" 35628 fi 35629 fi 35630 35631 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35632 if test "x$test_cygdrive_prefix" = x; then 35633 # As a simple fix, exclude /usr/bin since it's not a real path. 35634 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35635 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35636 # a path prefixed by /cygdrive for fixpath to work. 35637 new_path="$CYGWIN_ROOT_PATH$input_path" 35638 fi 35639 fi 35640 35641 # remove trailing .exe if any 35642 new_path="${new_path/%.exe/}" 35643 35644 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35645 35646 # First separate the path from the arguments. This will split at the first 35647 # space. 35648 complete="$CPP" 35649 path="${complete%% *}" 35650 tmp="$complete EOL" 35651 arguments="${tmp#* }" 35652 35653 # Input might be given as Windows format, start by converting to 35654 # unix format. 35655 new_path="$path" 35656 35657 windows_path="$new_path" 35658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35659 unix_path=`$CYGPATH -u "$windows_path"` 35660 new_path="$unix_path" 35661 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35662 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35663 new_path="$unix_path" 35664 fi 35665 35666 35667 # Now try to locate executable using which 35668 new_path=`$WHICH "$new_path" 2> /dev/null` 35669 35670 if test "x$new_path" = x; then 35671 # Oops. Which didn't find the executable. 35672 # The splitting of arguments from the executable at a space might have been incorrect, 35673 # since paths with space are more likely in Windows. Give it another try with the whole 35674 # argument. 35675 path="$complete" 35676 arguments="EOL" 35677 new_path="$path" 35678 35679 windows_path="$new_path" 35680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35681 unix_path=`$CYGPATH -u "$windows_path"` 35682 new_path="$unix_path" 35683 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35684 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35685 new_path="$unix_path" 35686 fi 35687 35688 35689 new_path=`$WHICH "$new_path" 2> /dev/null` 35690 # bat and cmd files are not always considered executable in MSYS causing which 35691 # to not find them 35692 if test "x$new_path" = x \ 35693 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35694 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35695 new_path="$path" 35696 35697 windows_path="$new_path" 35698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35699 unix_path=`$CYGPATH -u "$windows_path"` 35700 new_path="$unix_path" 35701 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35702 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35703 new_path="$unix_path" 35704 fi 35705 35706 fi 35707 35708 if test "x$new_path" = x; then 35709 # It's still not found. Now this is an unrecoverable error. 35710 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35711 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35712 has_space=`$ECHO "$complete" | $GREP " "` 35713 if test "x$has_space" != x; then 35714 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35715 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35716 fi 35717 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35718 fi 35719 fi 35720 35721 # Now new_path has a complete unix path to the binary 35722 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35723 # Keep paths in /bin as-is, but remove trailing .exe if any 35724 new_path="${new_path/%.exe/}" 35725 # Do not save /bin paths to all_fixpath_prefixes! 35726 else 35727 # Not in mixed or Windows style, start by that. 35728 new_path=`cmd //c echo $new_path` 35729 35730 input_path="$new_path" 35731 # Check if we need to convert this using DOS-style short mode. If the path 35732 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35733 # take no chances and rewrite it. 35734 # Note: m4 eats our [], so we need to use [ and ] instead. 35735 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35736 if test "x$has_forbidden_chars" != x; then 35737 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35738 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35739 fi 35740 35741 # Output is in $new_path 35742 35743 windows_path="$new_path" 35744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35745 unix_path=`$CYGPATH -u "$windows_path"` 35746 new_path="$unix_path" 35747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35748 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35749 new_path="$unix_path" 35750 fi 35751 35752 # remove trailing .exe if any 35753 new_path="${new_path/%.exe/}" 35754 35755 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35756 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35757 fi 35758 35759 else 35760 # We're on a unix platform. Hooray! :) 35761 # First separate the path from the arguments. This will split at the first 35762 # space. 35763 complete="$CPP" 35764 path="${complete%% *}" 35765 tmp="$complete EOL" 35766 arguments="${tmp#* }" 35767 35768 # Cannot rely on the command "which" here since it doesn't always work. 35769 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35770 if test -z "$is_absolute_path"; then 35771 # Path to executable is not absolute. Find it. 35772 IFS_save="$IFS" 35773 IFS=: 35774 for p in $PATH; do 35775 if test -f "$p/$path" && test -x "$p/$path"; then 35776 new_path="$p/$path" 35777 break 35778 fi 35779 done 35780 IFS="$IFS_save" 35781 else 35782 # This is an absolute path, we can use it without further modifications. 35783 new_path="$path" 35784 fi 35785 35786 if test "x$new_path" = x; then 35787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35788 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35789 has_space=`$ECHO "$complete" | $GREP " "` 35790 if test "x$has_space" != x; then 35791 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35792 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35793 fi 35794 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35795 fi 35796 fi 35797 35798 # Now join together the path and the arguments once again 35799 if test "x$arguments" != xEOL; then 35800 new_complete="$new_path ${arguments% *}" 35801 else 35802 new_complete="$new_path" 35803 fi 35804 35805 if test "x$complete" != "x$new_complete"; then 35806 CPP="$new_complete" 35807 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 35808 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 35809 fi 35810 fi 35811 35812 ac_ext=cpp 35813 ac_cpp='$CXXCPP $CPPFLAGS' 35814 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35815 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35816 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 35818 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 35819 if test -z "$CXXCPP"; then 35820 if ${ac_cv_prog_CXXCPP+:} false; then : 35821 $as_echo_n "(cached) " >&6 35822 else 35823 # Double quotes because CXXCPP needs to be expanded 35824 for CXXCPP in "$CXX -E" "/lib/cpp" 35825 do 35826 ac_preproc_ok=false 35827 for ac_cxx_preproc_warn_flag in '' yes 35828 do 35829 # Use a header file that comes with gcc, so configuring glibc 35830 # with a fresh cross-compiler works. 35831 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35832 # <limits.h> exists even on freestanding compilers. 35833 # On the NeXT, cc -E runs the code through the compiler's parser, 35834 # not just through cpp. "Syntax error" is here to catch this case. 35835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35836 /* end confdefs.h. */ 35837 #ifdef __STDC__ 35838 # include <limits.h> 35839 #else 35840 # include <assert.h> 35841 #endif 35842 Syntax error 35843 _ACEOF 35844 if ac_fn_cxx_try_cpp "$LINENO"; then : 35845 35846 else 35847 # Broken: fails on valid input. 35848 continue 35849 fi 35850 rm -f conftest.err conftest.i conftest.$ac_ext 35851 35852 # OK, works on sane cases. Now check whether nonexistent headers 35853 # can be detected and how. 35854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35855 /* end confdefs.h. */ 35856 #include <ac_nonexistent.h> 35857 _ACEOF 35858 if ac_fn_cxx_try_cpp "$LINENO"; then : 35859 # Broken: success on invalid input. 35860 continue 35861 else 35862 # Passes both tests. 35863 ac_preproc_ok=: 35864 break 35865 fi 35866 rm -f conftest.err conftest.i conftest.$ac_ext 35867 35868 done 35869 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35870 rm -f conftest.i conftest.err conftest.$ac_ext 35871 if $ac_preproc_ok; then : 35872 break 35873 fi 35874 35875 done 35876 ac_cv_prog_CXXCPP=$CXXCPP 35877 35878 fi 35879 CXXCPP=$ac_cv_prog_CXXCPP 35880 else 35881 ac_cv_prog_CXXCPP=$CXXCPP 35882 fi 35883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 35884 $as_echo "$CXXCPP" >&6; } 35885 ac_preproc_ok=false 35886 for ac_cxx_preproc_warn_flag in '' yes 35887 do 35888 # Use a header file that comes with gcc, so configuring glibc 35889 # with a fresh cross-compiler works. 35890 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35891 # <limits.h> exists even on freestanding compilers. 35892 # On the NeXT, cc -E runs the code through the compiler's parser, 35893 # not just through cpp. "Syntax error" is here to catch this case. 35894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35895 /* end confdefs.h. */ 35896 #ifdef __STDC__ 35897 # include <limits.h> 35898 #else 35899 # include <assert.h> 35900 #endif 35901 Syntax error 35902 _ACEOF 35903 if ac_fn_cxx_try_cpp "$LINENO"; then : 35904 35905 else 35906 # Broken: fails on valid input. 35907 continue 35908 fi 35909 rm -f conftest.err conftest.i conftest.$ac_ext 35910 35911 # OK, works on sane cases. Now check whether nonexistent headers 35912 # can be detected and how. 35913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35914 /* end confdefs.h. */ 35915 #include <ac_nonexistent.h> 35916 _ACEOF 35917 if ac_fn_cxx_try_cpp "$LINENO"; then : 35918 # Broken: success on invalid input. 35919 continue 35920 else 35921 # Passes both tests. 35922 ac_preproc_ok=: 35923 break 35924 fi 35925 rm -f conftest.err conftest.i conftest.$ac_ext 35926 35927 done 35928 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35929 rm -f conftest.i conftest.err conftest.$ac_ext 35930 if $ac_preproc_ok; then : 35931 35932 else 35933 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35934 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35935 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 35936 See \`config.log' for more details" "$LINENO" 5; } 35937 fi 35938 35939 ac_ext=cpp 35940 ac_cpp='$CXXCPP $CPPFLAGS' 35941 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35942 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35943 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35944 35945 35946 # Only process if variable expands to non-empty 35947 35948 if test "x$CXXCPP" != x; then 35949 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35950 35951 # First separate the path from the arguments. This will split at the first 35952 # space. 35953 complete="$CXXCPP" 35954 path="${complete%% *}" 35955 tmp="$complete EOL" 35956 arguments="${tmp#* }" 35957 35958 # Input might be given as Windows format, start by converting to 35959 # unix format. 35960 new_path=`$CYGPATH -u "$path"` 35961 35962 # Now try to locate executable using which 35963 new_path=`$WHICH "$new_path" 2> /dev/null` 35964 # bat and cmd files are not always considered executable in cygwin causing which 35965 # to not find them 35966 if test "x$new_path" = x \ 35967 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35968 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35969 new_path=`$CYGPATH -u "$path"` 35970 fi 35971 if test "x$new_path" = x; then 35972 # Oops. Which didn't find the executable. 35973 # The splitting of arguments from the executable at a space might have been incorrect, 35974 # since paths with space are more likely in Windows. Give it another try with the whole 35975 # argument. 35976 path="$complete" 35977 arguments="EOL" 35978 new_path=`$CYGPATH -u "$path"` 35979 new_path=`$WHICH "$new_path" 2> /dev/null` 35980 # bat and cmd files are not always considered executable in cygwin causing which 35981 # to not find them 35982 if test "x$new_path" = x \ 35983 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35984 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35985 new_path=`$CYGPATH -u "$path"` 35986 fi 35987 if test "x$new_path" = x; then 35988 # It's still not found. Now this is an unrecoverable error. 35989 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 35990 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 35991 has_space=`$ECHO "$complete" | $GREP " "` 35992 if test "x$has_space" != x; then 35993 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35994 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35995 fi 35996 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35997 fi 35998 fi 35999 36000 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36001 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36002 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36003 # "foo.exe" is OK but "foo" is an error. 36004 # 36005 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36006 # It is also a way to make sure we got the proper file name for the real test later on. 36007 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36008 if test "x$test_shortpath" = x; then 36009 # Short path failed, file does not exist as specified. 36010 # Try adding .exe or .cmd 36011 if test -f "${new_path}.exe"; then 36012 input_to_shortpath="${new_path}.exe" 36013 elif test -f "${new_path}.cmd"; then 36014 input_to_shortpath="${new_path}.cmd" 36015 else 36016 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 36017 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 36018 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36019 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36020 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36021 fi 36022 else 36023 input_to_shortpath="$new_path" 36024 fi 36025 36026 # Call helper function which possibly converts this using DOS-style short mode. 36027 # If so, the updated path is stored in $new_path. 36028 new_path="$input_to_shortpath" 36029 36030 input_path="$input_to_shortpath" 36031 # Check if we need to convert this using DOS-style short mode. If the path 36032 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36033 # take no chances and rewrite it. 36034 # Note: m4 eats our [], so we need to use [ and ] instead. 36035 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36036 if test "x$has_forbidden_chars" != x; then 36037 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36038 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36039 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36040 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36041 # Going to short mode and back again did indeed matter. Since short mode is 36042 # case insensitive, let's make it lowercase to improve readability. 36043 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36044 # Now convert it back to Unix-style (cygpath) 36045 input_path=`$CYGPATH -u "$shortmode_path"` 36046 new_path="$input_path" 36047 fi 36048 fi 36049 36050 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36051 if test "x$test_cygdrive_prefix" = x; then 36052 # As a simple fix, exclude /usr/bin since it's not a real path. 36053 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36054 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36055 # a path prefixed by /cygdrive for fixpath to work. 36056 new_path="$CYGWIN_ROOT_PATH$input_path" 36057 fi 36058 fi 36059 36060 # remove trailing .exe if any 36061 new_path="${new_path/%.exe/}" 36062 36063 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36064 36065 # First separate the path from the arguments. This will split at the first 36066 # space. 36067 complete="$CXXCPP" 36068 path="${complete%% *}" 36069 tmp="$complete EOL" 36070 arguments="${tmp#* }" 36071 36072 # Input might be given as Windows format, start by converting to 36073 # unix format. 36074 new_path="$path" 36075 36076 windows_path="$new_path" 36077 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36078 unix_path=`$CYGPATH -u "$windows_path"` 36079 new_path="$unix_path" 36080 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36081 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36082 new_path="$unix_path" 36083 fi 36084 36085 36086 # Now try to locate executable using which 36087 new_path=`$WHICH "$new_path" 2> /dev/null` 36088 36089 if test "x$new_path" = x; then 36090 # Oops. Which didn't find the executable. 36091 # The splitting of arguments from the executable at a space might have been incorrect, 36092 # since paths with space are more likely in Windows. Give it another try with the whole 36093 # argument. 36094 path="$complete" 36095 arguments="EOL" 36096 new_path="$path" 36097 36098 windows_path="$new_path" 36099 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36100 unix_path=`$CYGPATH -u "$windows_path"` 36101 new_path="$unix_path" 36102 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36103 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36104 new_path="$unix_path" 36105 fi 36106 36107 36108 new_path=`$WHICH "$new_path" 2> /dev/null` 36109 # bat and cmd files are not always considered executable in MSYS causing which 36110 # to not find them 36111 if test "x$new_path" = x \ 36112 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36113 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36114 new_path="$path" 36115 36116 windows_path="$new_path" 36117 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36118 unix_path=`$CYGPATH -u "$windows_path"` 36119 new_path="$unix_path" 36120 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36121 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36122 new_path="$unix_path" 36123 fi 36124 36125 fi 36126 36127 if test "x$new_path" = x; then 36128 # It's still not found. Now this is an unrecoverable error. 36129 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36130 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36131 has_space=`$ECHO "$complete" | $GREP " "` 36132 if test "x$has_space" != x; then 36133 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36134 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36135 fi 36136 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36137 fi 36138 fi 36139 36140 # Now new_path has a complete unix path to the binary 36141 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36142 # Keep paths in /bin as-is, but remove trailing .exe if any 36143 new_path="${new_path/%.exe/}" 36144 # Do not save /bin paths to all_fixpath_prefixes! 36145 else 36146 # Not in mixed or Windows style, start by that. 36147 new_path=`cmd //c echo $new_path` 36148 36149 input_path="$new_path" 36150 # Check if we need to convert this using DOS-style short mode. If the path 36151 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36152 # take no chances and rewrite it. 36153 # Note: m4 eats our [], so we need to use [ and ] instead. 36154 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36155 if test "x$has_forbidden_chars" != x; then 36156 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36157 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36158 fi 36159 36160 # Output is in $new_path 36161 36162 windows_path="$new_path" 36163 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36164 unix_path=`$CYGPATH -u "$windows_path"` 36165 new_path="$unix_path" 36166 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36167 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36168 new_path="$unix_path" 36169 fi 36170 36171 # remove trailing .exe if any 36172 new_path="${new_path/%.exe/}" 36173 36174 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36175 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36176 fi 36177 36178 else 36179 # We're on a unix platform. Hooray! :) 36180 # First separate the path from the arguments. This will split at the first 36181 # space. 36182 complete="$CXXCPP" 36183 path="${complete%% *}" 36184 tmp="$complete EOL" 36185 arguments="${tmp#* }" 36186 36187 # Cannot rely on the command "which" here since it doesn't always work. 36188 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36189 if test -z "$is_absolute_path"; then 36190 # Path to executable is not absolute. Find it. 36191 IFS_save="$IFS" 36192 IFS=: 36193 for p in $PATH; do 36194 if test -f "$p/$path" && test -x "$p/$path"; then 36195 new_path="$p/$path" 36196 break 36197 fi 36198 done 36199 IFS="$IFS_save" 36200 else 36201 # This is an absolute path, we can use it without further modifications. 36202 new_path="$path" 36203 fi 36204 36205 if test "x$new_path" = x; then 36206 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36207 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36208 has_space=`$ECHO "$complete" | $GREP " "` 36209 if test "x$has_space" != x; then 36210 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36211 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36212 fi 36213 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36214 fi 36215 fi 36216 36217 # Now join together the path and the arguments once again 36218 if test "x$arguments" != xEOL; then 36219 new_complete="$new_path ${arguments% *}" 36220 else 36221 new_complete="$new_path" 36222 fi 36223 36224 if test "x$complete" != "x$new_complete"; then 36225 CXXCPP="$new_complete" 36226 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 36227 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 36228 fi 36229 fi 36230 36231 36232 # 36233 # Setup the linker (LD) 36234 # 36235 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 36236 # In the Microsoft toolchain we have a separate LD command "link". 36237 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 36238 # a cygwin program for something completely different. 36239 # Extract the first word of "link", so it can be a program name with args. 36240 set dummy link; ac_word=$2 36241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36242 $as_echo_n "checking for $ac_word... " >&6; } 36243 if ${ac_cv_prog_LD+:} false; then : 36244 $as_echo_n "(cached) " >&6 36245 else 36246 if test -n "$LD"; then 36247 ac_cv_prog_LD="$LD" # Let the user override the test. 36248 else 36249 ac_prog_rejected=no 36250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36251 for as_dir in $PATH 36252 do 36253 IFS=$as_save_IFS 36254 test -z "$as_dir" && as_dir=. 36255 for ac_exec_ext in '' $ac_executable_extensions; do 36256 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36257 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 36258 ac_prog_rejected=yes 36259 continue 36260 fi 36261 ac_cv_prog_LD="link" 36262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36263 break 2 36264 fi 36265 done 36266 done 36267 IFS=$as_save_IFS 36268 36269 if test $ac_prog_rejected = yes; then 36270 # We found a bogon in the path, so make sure we never use it. 36271 set dummy $ac_cv_prog_LD 36272 shift 36273 if test $# != 0; then 36274 # We chose a different compiler from the bogus one. 36275 # However, it has the same basename, so the bogon will be chosen 36276 # first if we set LD to just the basename; use the full file name. 36277 shift 36278 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 36279 fi 36280 fi 36281 fi 36282 fi 36283 LD=$ac_cv_prog_LD 36284 if test -n "$LD"; then 36285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 36286 $as_echo "$LD" >&6; } 36287 else 36288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36289 $as_echo "no" >&6; } 36290 fi 36291 36292 36293 36294 # Only process if variable expands to non-empty 36295 36296 if test "x$LD" != x; then 36297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36298 36299 # First separate the path from the arguments. This will split at the first 36300 # space. 36301 complete="$LD" 36302 path="${complete%% *}" 36303 tmp="$complete EOL" 36304 arguments="${tmp#* }" 36305 36306 # Input might be given as Windows format, start by converting to 36307 # unix format. 36308 new_path=`$CYGPATH -u "$path"` 36309 36310 # Now try to locate executable using which 36311 new_path=`$WHICH "$new_path" 2> /dev/null` 36312 # bat and cmd files are not always considered executable in cygwin causing which 36313 # to not find them 36314 if test "x$new_path" = x \ 36315 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36316 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36317 new_path=`$CYGPATH -u "$path"` 36318 fi 36319 if test "x$new_path" = x; then 36320 # Oops. Which didn't find the executable. 36321 # The splitting of arguments from the executable at a space might have been incorrect, 36322 # since paths with space are more likely in Windows. Give it another try with the whole 36323 # argument. 36324 path="$complete" 36325 arguments="EOL" 36326 new_path=`$CYGPATH -u "$path"` 36327 new_path=`$WHICH "$new_path" 2> /dev/null` 36328 # bat and cmd files are not always considered executable in cygwin causing which 36329 # to not find them 36330 if test "x$new_path" = x \ 36331 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36332 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36333 new_path=`$CYGPATH -u "$path"` 36334 fi 36335 if test "x$new_path" = x; then 36336 # It's still not found. Now this is an unrecoverable error. 36337 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36338 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36339 has_space=`$ECHO "$complete" | $GREP " "` 36340 if test "x$has_space" != x; then 36341 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36342 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36343 fi 36344 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36345 fi 36346 fi 36347 36348 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36349 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36350 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36351 # "foo.exe" is OK but "foo" is an error. 36352 # 36353 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36354 # It is also a way to make sure we got the proper file name for the real test later on. 36355 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36356 if test "x$test_shortpath" = x; then 36357 # Short path failed, file does not exist as specified. 36358 # Try adding .exe or .cmd 36359 if test -f "${new_path}.exe"; then 36360 input_to_shortpath="${new_path}.exe" 36361 elif test -f "${new_path}.cmd"; then 36362 input_to_shortpath="${new_path}.cmd" 36363 else 36364 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 36365 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 36366 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36367 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36368 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36369 fi 36370 else 36371 input_to_shortpath="$new_path" 36372 fi 36373 36374 # Call helper function which possibly converts this using DOS-style short mode. 36375 # If so, the updated path is stored in $new_path. 36376 new_path="$input_to_shortpath" 36377 36378 input_path="$input_to_shortpath" 36379 # Check if we need to convert this using DOS-style short mode. If the path 36380 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36381 # take no chances and rewrite it. 36382 # Note: m4 eats our [], so we need to use [ and ] instead. 36383 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36384 if test "x$has_forbidden_chars" != x; then 36385 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36386 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36387 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36388 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36389 # Going to short mode and back again did indeed matter. Since short mode is 36390 # case insensitive, let's make it lowercase to improve readability. 36391 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36392 # Now convert it back to Unix-style (cygpath) 36393 input_path=`$CYGPATH -u "$shortmode_path"` 36394 new_path="$input_path" 36395 fi 36396 fi 36397 36398 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36399 if test "x$test_cygdrive_prefix" = x; then 36400 # As a simple fix, exclude /usr/bin since it's not a real path. 36401 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36402 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36403 # a path prefixed by /cygdrive for fixpath to work. 36404 new_path="$CYGWIN_ROOT_PATH$input_path" 36405 fi 36406 fi 36407 36408 # remove trailing .exe if any 36409 new_path="${new_path/%.exe/}" 36410 36411 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36412 36413 # First separate the path from the arguments. This will split at the first 36414 # space. 36415 complete="$LD" 36416 path="${complete%% *}" 36417 tmp="$complete EOL" 36418 arguments="${tmp#* }" 36419 36420 # Input might be given as Windows format, start by converting to 36421 # unix format. 36422 new_path="$path" 36423 36424 windows_path="$new_path" 36425 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36426 unix_path=`$CYGPATH -u "$windows_path"` 36427 new_path="$unix_path" 36428 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36429 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36430 new_path="$unix_path" 36431 fi 36432 36433 36434 # Now try to locate executable using which 36435 new_path=`$WHICH "$new_path" 2> /dev/null` 36436 36437 if test "x$new_path" = x; then 36438 # Oops. Which didn't find the executable. 36439 # The splitting of arguments from the executable at a space might have been incorrect, 36440 # since paths with space are more likely in Windows. Give it another try with the whole 36441 # argument. 36442 path="$complete" 36443 arguments="EOL" 36444 new_path="$path" 36445 36446 windows_path="$new_path" 36447 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36448 unix_path=`$CYGPATH -u "$windows_path"` 36449 new_path="$unix_path" 36450 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36451 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36452 new_path="$unix_path" 36453 fi 36454 36455 36456 new_path=`$WHICH "$new_path" 2> /dev/null` 36457 # bat and cmd files are not always considered executable in MSYS causing which 36458 # to not find them 36459 if test "x$new_path" = x \ 36460 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36461 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36462 new_path="$path" 36463 36464 windows_path="$new_path" 36465 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36466 unix_path=`$CYGPATH -u "$windows_path"` 36467 new_path="$unix_path" 36468 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36469 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36470 new_path="$unix_path" 36471 fi 36472 36473 fi 36474 36475 if test "x$new_path" = x; then 36476 # It's still not found. Now this is an unrecoverable error. 36477 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36478 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36479 has_space=`$ECHO "$complete" | $GREP " "` 36480 if test "x$has_space" != x; then 36481 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36482 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36483 fi 36484 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36485 fi 36486 fi 36487 36488 # Now new_path has a complete unix path to the binary 36489 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36490 # Keep paths in /bin as-is, but remove trailing .exe if any 36491 new_path="${new_path/%.exe/}" 36492 # Do not save /bin paths to all_fixpath_prefixes! 36493 else 36494 # Not in mixed or Windows style, start by that. 36495 new_path=`cmd //c echo $new_path` 36496 36497 input_path="$new_path" 36498 # Check if we need to convert this using DOS-style short mode. If the path 36499 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36500 # take no chances and rewrite it. 36501 # Note: m4 eats our [], so we need to use [ and ] instead. 36502 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36503 if test "x$has_forbidden_chars" != x; then 36504 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36505 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36506 fi 36507 36508 # Output is in $new_path 36509 36510 windows_path="$new_path" 36511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36512 unix_path=`$CYGPATH -u "$windows_path"` 36513 new_path="$unix_path" 36514 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36515 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36516 new_path="$unix_path" 36517 fi 36518 36519 # remove trailing .exe if any 36520 new_path="${new_path/%.exe/}" 36521 36522 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36523 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36524 fi 36525 36526 else 36527 # We're on a unix platform. Hooray! :) 36528 # First separate the path from the arguments. This will split at the first 36529 # space. 36530 complete="$LD" 36531 path="${complete%% *}" 36532 tmp="$complete EOL" 36533 arguments="${tmp#* }" 36534 36535 # Cannot rely on the command "which" here since it doesn't always work. 36536 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36537 if test -z "$is_absolute_path"; then 36538 # Path to executable is not absolute. Find it. 36539 IFS_save="$IFS" 36540 IFS=: 36541 for p in $PATH; do 36542 if test -f "$p/$path" && test -x "$p/$path"; then 36543 new_path="$p/$path" 36544 break 36545 fi 36546 done 36547 IFS="$IFS_save" 36548 else 36549 # This is an absolute path, we can use it without further modifications. 36550 new_path="$path" 36551 fi 36552 36553 if test "x$new_path" = x; then 36554 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36555 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36556 has_space=`$ECHO "$complete" | $GREP " "` 36557 if test "x$has_space" != x; then 36558 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36559 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36560 fi 36561 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36562 fi 36563 fi 36564 36565 # Now join together the path and the arguments once again 36566 if test "x$arguments" != xEOL; then 36567 new_complete="$new_path ${arguments% *}" 36568 else 36569 new_complete="$new_path" 36570 fi 36571 36572 if test "x$complete" != "x$new_complete"; then 36573 LD="$new_complete" 36574 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 36575 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 36576 fi 36577 fi 36578 36579 # Verify that we indeed succeeded with this trick. 36580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 36581 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 36582 "$LD" --version > /dev/null 36583 if test $? -eq 0 ; then 36584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36585 $as_echo "no" >&6; } 36586 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 36587 else 36588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 36589 $as_echo "yes" >&6; } 36590 fi 36591 LDCXX="$LD" 36592 else 36593 # All other toolchains use the compiler to link. 36594 LD="$CC" 36595 LDCXX="$CXX" 36596 fi 36597 36598 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 36599 36600 36601 # 36602 # Setup the assembler (AS) 36603 # 36604 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 36605 36606 36607 # Publish this variable in the help. 36608 36609 36610 if [ -z "${AS+x}" ]; then 36611 # The variable is not set by user, try to locate tool using the code snippet 36612 for ac_prog in as 36613 do 36614 # Extract the first word of "$ac_prog", so it can be a program name with args. 36615 set dummy $ac_prog; ac_word=$2 36616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36617 $as_echo_n "checking for $ac_word... " >&6; } 36618 if ${ac_cv_path_AS+:} false; then : 36619 $as_echo_n "(cached) " >&6 36620 else 36621 case $AS in 36622 [\\/]* | ?:[\\/]*) 36623 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36624 ;; 36625 *) 36626 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36627 for as_dir in $PATH 36628 do 36629 IFS=$as_save_IFS 36630 test -z "$as_dir" && as_dir=. 36631 for ac_exec_ext in '' $ac_executable_extensions; do 36632 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36633 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36634 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36635 break 2 36636 fi 36637 done 36638 done 36639 IFS=$as_save_IFS 36640 36641 ;; 36642 esac 36643 fi 36644 AS=$ac_cv_path_AS 36645 if test -n "$AS"; then 36646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36647 $as_echo "$AS" >&6; } 36648 else 36649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36650 $as_echo "no" >&6; } 36651 fi 36652 36653 36654 test -n "$AS" && break 36655 done 36656 36657 else 36658 # The variable is set, but is it from the command line or the environment? 36659 36660 # Try to remove the string !AS! from our list. 36661 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 36662 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 36663 # If it failed, the variable was not from the command line. Ignore it, 36664 # but warn the user (except for BASH, which is always set by the calling BASH). 36665 if test "xAS" != xBASH; then 36666 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 36667 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 36668 fi 36669 # Try to locate tool using the code snippet 36670 for ac_prog in as 36671 do 36672 # Extract the first word of "$ac_prog", so it can be a program name with args. 36673 set dummy $ac_prog; ac_word=$2 36674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36675 $as_echo_n "checking for $ac_word... " >&6; } 36676 if ${ac_cv_path_AS+:} false; then : 36677 $as_echo_n "(cached) " >&6 36678 else 36679 case $AS in 36680 [\\/]* | ?:[\\/]*) 36681 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36682 ;; 36683 *) 36684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36685 for as_dir in $PATH 36686 do 36687 IFS=$as_save_IFS 36688 test -z "$as_dir" && as_dir=. 36689 for ac_exec_ext in '' $ac_executable_extensions; do 36690 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36691 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36693 break 2 36694 fi 36695 done 36696 done 36697 IFS=$as_save_IFS 36698 36699 ;; 36700 esac 36701 fi 36702 AS=$ac_cv_path_AS 36703 if test -n "$AS"; then 36704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36705 $as_echo "$AS" >&6; } 36706 else 36707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36708 $as_echo "no" >&6; } 36709 fi 36710 36711 36712 test -n "$AS" && break 36713 done 36714 36715 else 36716 # If it succeeded, then it was overridden by the user. We will use it 36717 # for the tool. 36718 36719 # First remove it from the list of overridden variables, so we can test 36720 # for unknown variables in the end. 36721 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 36722 36723 # Check if we try to supply an empty value 36724 if test "x$AS" = x; then 36725 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 36726 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 36727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36728 $as_echo_n "checking for AS... " >&6; } 36729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 36730 $as_echo "disabled" >&6; } 36731 else 36732 # Check if the provided tool contains a complete path. 36733 tool_specified="$AS" 36734 tool_basename="${tool_specified##*/}" 36735 if test "x$tool_basename" = "x$tool_specified"; then 36736 # A command without a complete path is provided, search $PATH. 36737 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 36738 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 36739 # Extract the first word of "$tool_basename", so it can be a program name with args. 36740 set dummy $tool_basename; ac_word=$2 36741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36742 $as_echo_n "checking for $ac_word... " >&6; } 36743 if ${ac_cv_path_AS+:} false; then : 36744 $as_echo_n "(cached) " >&6 36745 else 36746 case $AS in 36747 [\\/]* | ?:[\\/]*) 36748 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36749 ;; 36750 *) 36751 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36752 for as_dir in $PATH 36753 do 36754 IFS=$as_save_IFS 36755 test -z "$as_dir" && as_dir=. 36756 for ac_exec_ext in '' $ac_executable_extensions; do 36757 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36758 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36759 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36760 break 2 36761 fi 36762 done 36763 done 36764 IFS=$as_save_IFS 36765 36766 ;; 36767 esac 36768 fi 36769 AS=$ac_cv_path_AS 36770 if test -n "$AS"; then 36771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36772 $as_echo "$AS" >&6; } 36773 else 36774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36775 $as_echo "no" >&6; } 36776 fi 36777 36778 36779 if test "x$AS" = x; then 36780 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 36781 fi 36782 else 36783 # Otherwise we believe it is a complete path. Use it as it is. 36784 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 36785 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 36786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36787 $as_echo_n "checking for AS... " >&6; } 36788 if test ! -x "$tool_specified"; then 36789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 36790 $as_echo "not found" >&6; } 36791 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 36792 fi 36793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 36794 $as_echo "$tool_specified" >&6; } 36795 fi 36796 fi 36797 fi 36798 36799 fi 36800 36801 36802 36803 # Only process if variable expands to non-empty 36804 36805 if test "x$AS" != x; then 36806 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36807 36808 # First separate the path from the arguments. This will split at the first 36809 # space. 36810 complete="$AS" 36811 path="${complete%% *}" 36812 tmp="$complete EOL" 36813 arguments="${tmp#* }" 36814 36815 # Input might be given as Windows format, start by converting to 36816 # unix format. 36817 new_path=`$CYGPATH -u "$path"` 36818 36819 # Now try to locate executable using which 36820 new_path=`$WHICH "$new_path" 2> /dev/null` 36821 # bat and cmd files are not always considered executable in cygwin causing which 36822 # to not find them 36823 if test "x$new_path" = x \ 36824 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36825 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36826 new_path=`$CYGPATH -u "$path"` 36827 fi 36828 if test "x$new_path" = x; then 36829 # Oops. Which didn't find the executable. 36830 # The splitting of arguments from the executable at a space might have been incorrect, 36831 # since paths with space are more likely in Windows. Give it another try with the whole 36832 # argument. 36833 path="$complete" 36834 arguments="EOL" 36835 new_path=`$CYGPATH -u "$path"` 36836 new_path=`$WHICH "$new_path" 2> /dev/null` 36837 # bat and cmd files are not always considered executable in cygwin causing which 36838 # to not find them 36839 if test "x$new_path" = x \ 36840 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36841 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36842 new_path=`$CYGPATH -u "$path"` 36843 fi 36844 if test "x$new_path" = x; then 36845 # It's still not found. Now this is an unrecoverable error. 36846 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36847 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36848 has_space=`$ECHO "$complete" | $GREP " "` 36849 if test "x$has_space" != x; then 36850 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36851 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36852 fi 36853 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36854 fi 36855 fi 36856 36857 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36858 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36859 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36860 # "foo.exe" is OK but "foo" is an error. 36861 # 36862 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36863 # It is also a way to make sure we got the proper file name for the real test later on. 36864 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36865 if test "x$test_shortpath" = x; then 36866 # Short path failed, file does not exist as specified. 36867 # Try adding .exe or .cmd 36868 if test -f "${new_path}.exe"; then 36869 input_to_shortpath="${new_path}.exe" 36870 elif test -f "${new_path}.cmd"; then 36871 input_to_shortpath="${new_path}.cmd" 36872 else 36873 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 36874 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 36875 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36876 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36877 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36878 fi 36879 else 36880 input_to_shortpath="$new_path" 36881 fi 36882 36883 # Call helper function which possibly converts this using DOS-style short mode. 36884 # If so, the updated path is stored in $new_path. 36885 new_path="$input_to_shortpath" 36886 36887 input_path="$input_to_shortpath" 36888 # Check if we need to convert this using DOS-style short mode. If the path 36889 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36890 # take no chances and rewrite it. 36891 # Note: m4 eats our [], so we need to use [ and ] instead. 36892 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36893 if test "x$has_forbidden_chars" != x; then 36894 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36895 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36896 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36897 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36898 # Going to short mode and back again did indeed matter. Since short mode is 36899 # case insensitive, let's make it lowercase to improve readability. 36900 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36901 # Now convert it back to Unix-style (cygpath) 36902 input_path=`$CYGPATH -u "$shortmode_path"` 36903 new_path="$input_path" 36904 fi 36905 fi 36906 36907 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36908 if test "x$test_cygdrive_prefix" = x; then 36909 # As a simple fix, exclude /usr/bin since it's not a real path. 36910 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36911 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36912 # a path prefixed by /cygdrive for fixpath to work. 36913 new_path="$CYGWIN_ROOT_PATH$input_path" 36914 fi 36915 fi 36916 36917 # remove trailing .exe if any 36918 new_path="${new_path/%.exe/}" 36919 36920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36921 36922 # First separate the path from the arguments. This will split at the first 36923 # space. 36924 complete="$AS" 36925 path="${complete%% *}" 36926 tmp="$complete EOL" 36927 arguments="${tmp#* }" 36928 36929 # Input might be given as Windows format, start by converting to 36930 # unix format. 36931 new_path="$path" 36932 36933 windows_path="$new_path" 36934 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36935 unix_path=`$CYGPATH -u "$windows_path"` 36936 new_path="$unix_path" 36937 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36938 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36939 new_path="$unix_path" 36940 fi 36941 36942 36943 # Now try to locate executable using which 36944 new_path=`$WHICH "$new_path" 2> /dev/null` 36945 36946 if test "x$new_path" = x; then 36947 # Oops. Which didn't find the executable. 36948 # The splitting of arguments from the executable at a space might have been incorrect, 36949 # since paths with space are more likely in Windows. Give it another try with the whole 36950 # argument. 36951 path="$complete" 36952 arguments="EOL" 36953 new_path="$path" 36954 36955 windows_path="$new_path" 36956 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36957 unix_path=`$CYGPATH -u "$windows_path"` 36958 new_path="$unix_path" 36959 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36960 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36961 new_path="$unix_path" 36962 fi 36963 36964 36965 new_path=`$WHICH "$new_path" 2> /dev/null` 36966 # bat and cmd files are not always considered executable in MSYS causing which 36967 # to not find them 36968 if test "x$new_path" = x \ 36969 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36970 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36971 new_path="$path" 36972 36973 windows_path="$new_path" 36974 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36975 unix_path=`$CYGPATH -u "$windows_path"` 36976 new_path="$unix_path" 36977 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36978 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36979 new_path="$unix_path" 36980 fi 36981 36982 fi 36983 36984 if test "x$new_path" = x; then 36985 # It's still not found. Now this is an unrecoverable error. 36986 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36987 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36988 has_space=`$ECHO "$complete" | $GREP " "` 36989 if test "x$has_space" != x; then 36990 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36991 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36992 fi 36993 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36994 fi 36995 fi 36996 36997 # Now new_path has a complete unix path to the binary 36998 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36999 # Keep paths in /bin as-is, but remove trailing .exe if any 37000 new_path="${new_path/%.exe/}" 37001 # Do not save /bin paths to all_fixpath_prefixes! 37002 else 37003 # Not in mixed or Windows style, start by that. 37004 new_path=`cmd //c echo $new_path` 37005 37006 input_path="$new_path" 37007 # Check if we need to convert this using DOS-style short mode. If the path 37008 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37009 # take no chances and rewrite it. 37010 # Note: m4 eats our [], so we need to use [ and ] instead. 37011 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37012 if test "x$has_forbidden_chars" != x; then 37013 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37014 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37015 fi 37016 37017 # Output is in $new_path 37018 37019 windows_path="$new_path" 37020 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37021 unix_path=`$CYGPATH -u "$windows_path"` 37022 new_path="$unix_path" 37023 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37024 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37025 new_path="$unix_path" 37026 fi 37027 37028 # remove trailing .exe if any 37029 new_path="${new_path/%.exe/}" 37030 37031 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37032 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37033 fi 37034 37035 else 37036 # We're on a unix platform. Hooray! :) 37037 # First separate the path from the arguments. This will split at the first 37038 # space. 37039 complete="$AS" 37040 path="${complete%% *}" 37041 tmp="$complete EOL" 37042 arguments="${tmp#* }" 37043 37044 # Cannot rely on the command "which" here since it doesn't always work. 37045 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37046 if test -z "$is_absolute_path"; then 37047 # Path to executable is not absolute. Find it. 37048 IFS_save="$IFS" 37049 IFS=: 37050 for p in $PATH; do 37051 if test -f "$p/$path" && test -x "$p/$path"; then 37052 new_path="$p/$path" 37053 break 37054 fi 37055 done 37056 IFS="$IFS_save" 37057 else 37058 # This is an absolute path, we can use it without further modifications. 37059 new_path="$path" 37060 fi 37061 37062 if test "x$new_path" = x; then 37063 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37064 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37065 has_space=`$ECHO "$complete" | $GREP " "` 37066 if test "x$has_space" != x; then 37067 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37068 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37069 fi 37070 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37071 fi 37072 fi 37073 37074 # Now join together the path and the arguments once again 37075 if test "x$arguments" != xEOL; then 37076 new_complete="$new_path ${arguments% *}" 37077 else 37078 new_complete="$new_path" 37079 fi 37080 37081 if test "x$complete" != "x$new_complete"; then 37082 AS="$new_complete" 37083 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 37084 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 37085 fi 37086 fi 37087 37088 if test "x$AS" = x; then 37089 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 37090 fi 37091 else 37092 # FIXME: is this correct for microsoft? 37093 AS="$CC -c" 37094 fi 37095 37096 37097 # 37098 # Setup the archiver (AR) 37099 # 37100 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37101 # The corresponding ar tool is lib.exe (used to create static libraries) 37102 # Extract the first word of "lib", so it can be a program name with args. 37103 set dummy lib; ac_word=$2 37104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37105 $as_echo_n "checking for $ac_word... " >&6; } 37106 if ${ac_cv_prog_AR+:} false; then : 37107 $as_echo_n "(cached) " >&6 37108 else 37109 if test -n "$AR"; then 37110 ac_cv_prog_AR="$AR" # Let the user override the test. 37111 else 37112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37113 for as_dir in $PATH 37114 do 37115 IFS=$as_save_IFS 37116 test -z "$as_dir" && as_dir=. 37117 for ac_exec_ext in '' $ac_executable_extensions; do 37118 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37119 ac_cv_prog_AR="lib" 37120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37121 break 2 37122 fi 37123 done 37124 done 37125 IFS=$as_save_IFS 37126 37127 fi 37128 fi 37129 AR=$ac_cv_prog_AR 37130 if test -n "$AR"; then 37131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37132 $as_echo "$AR" >&6; } 37133 else 37134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37135 $as_echo "no" >&6; } 37136 fi 37137 37138 37139 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 37140 37141 37142 # Publish this variable in the help. 37143 37144 37145 if [ -z "${AR+x}" ]; then 37146 # The variable is not set by user, try to locate tool using the code snippet 37147 if test -n "$ac_tool_prefix"; then 37148 for ac_prog in ar gcc-ar 37149 do 37150 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37151 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37153 $as_echo_n "checking for $ac_word... " >&6; } 37154 if ${ac_cv_prog_AR+:} false; then : 37155 $as_echo_n "(cached) " >&6 37156 else 37157 if test -n "$AR"; then 37158 ac_cv_prog_AR="$AR" # Let the user override the test. 37159 else 37160 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37161 for as_dir in $PATH 37162 do 37163 IFS=$as_save_IFS 37164 test -z "$as_dir" && as_dir=. 37165 for ac_exec_ext in '' $ac_executable_extensions; do 37166 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37167 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37168 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37169 break 2 37170 fi 37171 done 37172 done 37173 IFS=$as_save_IFS 37174 37175 fi 37176 fi 37177 AR=$ac_cv_prog_AR 37178 if test -n "$AR"; then 37179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37180 $as_echo "$AR" >&6; } 37181 else 37182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37183 $as_echo "no" >&6; } 37184 fi 37185 37186 37187 test -n "$AR" && break 37188 done 37189 fi 37190 if test -z "$AR"; then 37191 ac_ct_AR=$AR 37192 for ac_prog in ar gcc-ar 37193 do 37194 # Extract the first word of "$ac_prog", so it can be a program name with args. 37195 set dummy $ac_prog; ac_word=$2 37196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37197 $as_echo_n "checking for $ac_word... " >&6; } 37198 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37199 $as_echo_n "(cached) " >&6 37200 else 37201 if test -n "$ac_ct_AR"; then 37202 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37203 else 37204 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37205 for as_dir in $PATH 37206 do 37207 IFS=$as_save_IFS 37208 test -z "$as_dir" && as_dir=. 37209 for ac_exec_ext in '' $ac_executable_extensions; do 37210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37211 ac_cv_prog_ac_ct_AR="$ac_prog" 37212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37213 break 2 37214 fi 37215 done 37216 done 37217 IFS=$as_save_IFS 37218 37219 fi 37220 fi 37221 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37222 if test -n "$ac_ct_AR"; then 37223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37224 $as_echo "$ac_ct_AR" >&6; } 37225 else 37226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37227 $as_echo "no" >&6; } 37228 fi 37229 37230 37231 test -n "$ac_ct_AR" && break 37232 done 37233 37234 if test "x$ac_ct_AR" = x; then 37235 AR="" 37236 else 37237 case $cross_compiling:$ac_tool_warned in 37238 yes:) 37239 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37240 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37241 ac_tool_warned=yes ;; 37242 esac 37243 AR=$ac_ct_AR 37244 fi 37245 fi 37246 37247 else 37248 # The variable is set, but is it from the command line or the environment? 37249 37250 # Try to remove the string !AR! from our list. 37251 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37252 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37253 # If it failed, the variable was not from the command line. Ignore it, 37254 # but warn the user (except for BASH, which is always set by the calling BASH). 37255 if test "xAR" != xBASH; then 37256 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37257 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37258 fi 37259 # Try to locate tool using the code snippet 37260 if test -n "$ac_tool_prefix"; then 37261 for ac_prog in ar gcc-ar 37262 do 37263 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37264 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37266 $as_echo_n "checking for $ac_word... " >&6; } 37267 if ${ac_cv_prog_AR+:} false; then : 37268 $as_echo_n "(cached) " >&6 37269 else 37270 if test -n "$AR"; then 37271 ac_cv_prog_AR="$AR" # Let the user override the test. 37272 else 37273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37274 for as_dir in $PATH 37275 do 37276 IFS=$as_save_IFS 37277 test -z "$as_dir" && as_dir=. 37278 for ac_exec_ext in '' $ac_executable_extensions; do 37279 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37280 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37281 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37282 break 2 37283 fi 37284 done 37285 done 37286 IFS=$as_save_IFS 37287 37288 fi 37289 fi 37290 AR=$ac_cv_prog_AR 37291 if test -n "$AR"; then 37292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37293 $as_echo "$AR" >&6; } 37294 else 37295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37296 $as_echo "no" >&6; } 37297 fi 37298 37299 37300 test -n "$AR" && break 37301 done 37302 fi 37303 if test -z "$AR"; then 37304 ac_ct_AR=$AR 37305 for ac_prog in ar gcc-ar 37306 do 37307 # Extract the first word of "$ac_prog", so it can be a program name with args. 37308 set dummy $ac_prog; ac_word=$2 37309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37310 $as_echo_n "checking for $ac_word... " >&6; } 37311 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37312 $as_echo_n "(cached) " >&6 37313 else 37314 if test -n "$ac_ct_AR"; then 37315 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37316 else 37317 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37318 for as_dir in $PATH 37319 do 37320 IFS=$as_save_IFS 37321 test -z "$as_dir" && as_dir=. 37322 for ac_exec_ext in '' $ac_executable_extensions; do 37323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37324 ac_cv_prog_ac_ct_AR="$ac_prog" 37325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37326 break 2 37327 fi 37328 done 37329 done 37330 IFS=$as_save_IFS 37331 37332 fi 37333 fi 37334 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37335 if test -n "$ac_ct_AR"; then 37336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37337 $as_echo "$ac_ct_AR" >&6; } 37338 else 37339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37340 $as_echo "no" >&6; } 37341 fi 37342 37343 37344 test -n "$ac_ct_AR" && break 37345 done 37346 37347 if test "x$ac_ct_AR" = x; then 37348 AR="" 37349 else 37350 case $cross_compiling:$ac_tool_warned in 37351 yes:) 37352 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37353 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37354 ac_tool_warned=yes ;; 37355 esac 37356 AR=$ac_ct_AR 37357 fi 37358 fi 37359 37360 else 37361 # If it succeeded, then it was overridden by the user. We will use it 37362 # for the tool. 37363 37364 # First remove it from the list of overridden variables, so we can test 37365 # for unknown variables in the end. 37366 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37367 37368 # Check if we try to supply an empty value 37369 if test "x$AR" = x; then 37370 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37371 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37373 $as_echo_n "checking for AR... " >&6; } 37374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37375 $as_echo "disabled" >&6; } 37376 else 37377 # Check if the provided tool contains a complete path. 37378 tool_specified="$AR" 37379 tool_basename="${tool_specified##*/}" 37380 if test "x$tool_basename" = "x$tool_specified"; then 37381 # A command without a complete path is provided, search $PATH. 37382 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37383 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37384 # Extract the first word of "$tool_basename", so it can be a program name with args. 37385 set dummy $tool_basename; ac_word=$2 37386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37387 $as_echo_n "checking for $ac_word... " >&6; } 37388 if ${ac_cv_path_AR+:} false; then : 37389 $as_echo_n "(cached) " >&6 37390 else 37391 case $AR in 37392 [\\/]* | ?:[\\/]*) 37393 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37394 ;; 37395 *) 37396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37397 for as_dir in $PATH 37398 do 37399 IFS=$as_save_IFS 37400 test -z "$as_dir" && as_dir=. 37401 for ac_exec_ext in '' $ac_executable_extensions; do 37402 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37403 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37404 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37405 break 2 37406 fi 37407 done 37408 done 37409 IFS=$as_save_IFS 37410 37411 ;; 37412 esac 37413 fi 37414 AR=$ac_cv_path_AR 37415 if test -n "$AR"; then 37416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37417 $as_echo "$AR" >&6; } 37418 else 37419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37420 $as_echo "no" >&6; } 37421 fi 37422 37423 37424 if test "x$AR" = x; then 37425 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37426 fi 37427 else 37428 # Otherwise we believe it is a complete path. Use it as it is. 37429 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37430 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37432 $as_echo_n "checking for AR... " >&6; } 37433 if test ! -x "$tool_specified"; then 37434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37435 $as_echo "not found" >&6; } 37436 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37437 fi 37438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37439 $as_echo "$tool_specified" >&6; } 37440 fi 37441 fi 37442 fi 37443 37444 fi 37445 37446 37447 else 37448 37449 37450 # Publish this variable in the help. 37451 37452 37453 if [ -z "${AR+x}" ]; then 37454 # The variable is not set by user, try to locate tool using the code snippet 37455 if test -n "$ac_tool_prefix"; then 37456 for ac_prog in ar 37457 do 37458 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37459 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37461 $as_echo_n "checking for $ac_word... " >&6; } 37462 if ${ac_cv_prog_AR+:} false; then : 37463 $as_echo_n "(cached) " >&6 37464 else 37465 if test -n "$AR"; then 37466 ac_cv_prog_AR="$AR" # Let the user override the test. 37467 else 37468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37469 for as_dir in $PATH 37470 do 37471 IFS=$as_save_IFS 37472 test -z "$as_dir" && as_dir=. 37473 for ac_exec_ext in '' $ac_executable_extensions; do 37474 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37475 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37476 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37477 break 2 37478 fi 37479 done 37480 done 37481 IFS=$as_save_IFS 37482 37483 fi 37484 fi 37485 AR=$ac_cv_prog_AR 37486 if test -n "$AR"; then 37487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37488 $as_echo "$AR" >&6; } 37489 else 37490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37491 $as_echo "no" >&6; } 37492 fi 37493 37494 37495 test -n "$AR" && break 37496 done 37497 fi 37498 if test -z "$AR"; then 37499 ac_ct_AR=$AR 37500 for ac_prog in ar 37501 do 37502 # Extract the first word of "$ac_prog", so it can be a program name with args. 37503 set dummy $ac_prog; ac_word=$2 37504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37505 $as_echo_n "checking for $ac_word... " >&6; } 37506 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37507 $as_echo_n "(cached) " >&6 37508 else 37509 if test -n "$ac_ct_AR"; then 37510 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37511 else 37512 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37513 for as_dir in $PATH 37514 do 37515 IFS=$as_save_IFS 37516 test -z "$as_dir" && as_dir=. 37517 for ac_exec_ext in '' $ac_executable_extensions; do 37518 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37519 ac_cv_prog_ac_ct_AR="$ac_prog" 37520 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37521 break 2 37522 fi 37523 done 37524 done 37525 IFS=$as_save_IFS 37526 37527 fi 37528 fi 37529 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37530 if test -n "$ac_ct_AR"; then 37531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37532 $as_echo "$ac_ct_AR" >&6; } 37533 else 37534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37535 $as_echo "no" >&6; } 37536 fi 37537 37538 37539 test -n "$ac_ct_AR" && break 37540 done 37541 37542 if test "x$ac_ct_AR" = x; then 37543 AR="" 37544 else 37545 case $cross_compiling:$ac_tool_warned in 37546 yes:) 37547 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37548 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37549 ac_tool_warned=yes ;; 37550 esac 37551 AR=$ac_ct_AR 37552 fi 37553 fi 37554 37555 else 37556 # The variable is set, but is it from the command line or the environment? 37557 37558 # Try to remove the string !AR! from our list. 37559 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37560 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37561 # If it failed, the variable was not from the command line. Ignore it, 37562 # but warn the user (except for BASH, which is always set by the calling BASH). 37563 if test "xAR" != xBASH; then 37564 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37565 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37566 fi 37567 # Try to locate tool using the code snippet 37568 if test -n "$ac_tool_prefix"; then 37569 for ac_prog in ar 37570 do 37571 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37572 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37574 $as_echo_n "checking for $ac_word... " >&6; } 37575 if ${ac_cv_prog_AR+:} false; then : 37576 $as_echo_n "(cached) " >&6 37577 else 37578 if test -n "$AR"; then 37579 ac_cv_prog_AR="$AR" # Let the user override the test. 37580 else 37581 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37582 for as_dir in $PATH 37583 do 37584 IFS=$as_save_IFS 37585 test -z "$as_dir" && as_dir=. 37586 for ac_exec_ext in '' $ac_executable_extensions; do 37587 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37588 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37589 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37590 break 2 37591 fi 37592 done 37593 done 37594 IFS=$as_save_IFS 37595 37596 fi 37597 fi 37598 AR=$ac_cv_prog_AR 37599 if test -n "$AR"; then 37600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37601 $as_echo "$AR" >&6; } 37602 else 37603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37604 $as_echo "no" >&6; } 37605 fi 37606 37607 37608 test -n "$AR" && break 37609 done 37610 fi 37611 if test -z "$AR"; then 37612 ac_ct_AR=$AR 37613 for ac_prog in ar 37614 do 37615 # Extract the first word of "$ac_prog", so it can be a program name with args. 37616 set dummy $ac_prog; ac_word=$2 37617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37618 $as_echo_n "checking for $ac_word... " >&6; } 37619 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37620 $as_echo_n "(cached) " >&6 37621 else 37622 if test -n "$ac_ct_AR"; then 37623 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37624 else 37625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37626 for as_dir in $PATH 37627 do 37628 IFS=$as_save_IFS 37629 test -z "$as_dir" && as_dir=. 37630 for ac_exec_ext in '' $ac_executable_extensions; do 37631 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37632 ac_cv_prog_ac_ct_AR="$ac_prog" 37633 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37634 break 2 37635 fi 37636 done 37637 done 37638 IFS=$as_save_IFS 37639 37640 fi 37641 fi 37642 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37643 if test -n "$ac_ct_AR"; then 37644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37645 $as_echo "$ac_ct_AR" >&6; } 37646 else 37647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37648 $as_echo "no" >&6; } 37649 fi 37650 37651 37652 test -n "$ac_ct_AR" && break 37653 done 37654 37655 if test "x$ac_ct_AR" = x; then 37656 AR="" 37657 else 37658 case $cross_compiling:$ac_tool_warned in 37659 yes:) 37660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37661 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37662 ac_tool_warned=yes ;; 37663 esac 37664 AR=$ac_ct_AR 37665 fi 37666 fi 37667 37668 else 37669 # If it succeeded, then it was overridden by the user. We will use it 37670 # for the tool. 37671 37672 # First remove it from the list of overridden variables, so we can test 37673 # for unknown variables in the end. 37674 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37675 37676 # Check if we try to supply an empty value 37677 if test "x$AR" = x; then 37678 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37679 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37681 $as_echo_n "checking for AR... " >&6; } 37682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37683 $as_echo "disabled" >&6; } 37684 else 37685 # Check if the provided tool contains a complete path. 37686 tool_specified="$AR" 37687 tool_basename="${tool_specified##*/}" 37688 if test "x$tool_basename" = "x$tool_specified"; then 37689 # A command without a complete path is provided, search $PATH. 37690 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37691 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37692 # Extract the first word of "$tool_basename", so it can be a program name with args. 37693 set dummy $tool_basename; ac_word=$2 37694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37695 $as_echo_n "checking for $ac_word... " >&6; } 37696 if ${ac_cv_path_AR+:} false; then : 37697 $as_echo_n "(cached) " >&6 37698 else 37699 case $AR in 37700 [\\/]* | ?:[\\/]*) 37701 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37702 ;; 37703 *) 37704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37705 for as_dir in $PATH 37706 do 37707 IFS=$as_save_IFS 37708 test -z "$as_dir" && as_dir=. 37709 for ac_exec_ext in '' $ac_executable_extensions; do 37710 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37711 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37713 break 2 37714 fi 37715 done 37716 done 37717 IFS=$as_save_IFS 37718 37719 ;; 37720 esac 37721 fi 37722 AR=$ac_cv_path_AR 37723 if test -n "$AR"; then 37724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37725 $as_echo "$AR" >&6; } 37726 else 37727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37728 $as_echo "no" >&6; } 37729 fi 37730 37731 37732 if test "x$AR" = x; then 37733 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37734 fi 37735 else 37736 # Otherwise we believe it is a complete path. Use it as it is. 37737 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37738 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37740 $as_echo_n "checking for AR... " >&6; } 37741 if test ! -x "$tool_specified"; then 37742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37743 $as_echo "not found" >&6; } 37744 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37745 fi 37746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37747 $as_echo "$tool_specified" >&6; } 37748 fi 37749 fi 37750 fi 37751 37752 fi 37753 37754 37755 fi 37756 37757 # Only process if variable expands to non-empty 37758 37759 if test "x$AR" != x; then 37760 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37761 37762 # First separate the path from the arguments. This will split at the first 37763 # space. 37764 complete="$AR" 37765 path="${complete%% *}" 37766 tmp="$complete EOL" 37767 arguments="${tmp#* }" 37768 37769 # Input might be given as Windows format, start by converting to 37770 # unix format. 37771 new_path=`$CYGPATH -u "$path"` 37772 37773 # Now try to locate executable using which 37774 new_path=`$WHICH "$new_path" 2> /dev/null` 37775 # bat and cmd files are not always considered executable in cygwin causing which 37776 # to not find them 37777 if test "x$new_path" = x \ 37778 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37779 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37780 new_path=`$CYGPATH -u "$path"` 37781 fi 37782 if test "x$new_path" = x; then 37783 # Oops. Which didn't find the executable. 37784 # The splitting of arguments from the executable at a space might have been incorrect, 37785 # since paths with space are more likely in Windows. Give it another try with the whole 37786 # argument. 37787 path="$complete" 37788 arguments="EOL" 37789 new_path=`$CYGPATH -u "$path"` 37790 new_path=`$WHICH "$new_path" 2> /dev/null` 37791 # bat and cmd files are not always considered executable in cygwin causing which 37792 # to not find them 37793 if test "x$new_path" = x \ 37794 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37795 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37796 new_path=`$CYGPATH -u "$path"` 37797 fi 37798 if test "x$new_path" = x; then 37799 # It's still not found. Now this is an unrecoverable error. 37800 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37801 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37802 has_space=`$ECHO "$complete" | $GREP " "` 37803 if test "x$has_space" != x; then 37804 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37805 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37806 fi 37807 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37808 fi 37809 fi 37810 37811 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37812 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37813 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37814 # "foo.exe" is OK but "foo" is an error. 37815 # 37816 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37817 # It is also a way to make sure we got the proper file name for the real test later on. 37818 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37819 if test "x$test_shortpath" = x; then 37820 # Short path failed, file does not exist as specified. 37821 # Try adding .exe or .cmd 37822 if test -f "${new_path}.exe"; then 37823 input_to_shortpath="${new_path}.exe" 37824 elif test -f "${new_path}.cmd"; then 37825 input_to_shortpath="${new_path}.cmd" 37826 else 37827 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 37828 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 37829 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37830 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37831 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37832 fi 37833 else 37834 input_to_shortpath="$new_path" 37835 fi 37836 37837 # Call helper function which possibly converts this using DOS-style short mode. 37838 # If so, the updated path is stored in $new_path. 37839 new_path="$input_to_shortpath" 37840 37841 input_path="$input_to_shortpath" 37842 # Check if we need to convert this using DOS-style short mode. If the path 37843 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37844 # take no chances and rewrite it. 37845 # Note: m4 eats our [], so we need to use [ and ] instead. 37846 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37847 if test "x$has_forbidden_chars" != x; then 37848 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37849 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37850 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37851 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37852 # Going to short mode and back again did indeed matter. Since short mode is 37853 # case insensitive, let's make it lowercase to improve readability. 37854 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37855 # Now convert it back to Unix-style (cygpath) 37856 input_path=`$CYGPATH -u "$shortmode_path"` 37857 new_path="$input_path" 37858 fi 37859 fi 37860 37861 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37862 if test "x$test_cygdrive_prefix" = x; then 37863 # As a simple fix, exclude /usr/bin since it's not a real path. 37864 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37865 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37866 # a path prefixed by /cygdrive for fixpath to work. 37867 new_path="$CYGWIN_ROOT_PATH$input_path" 37868 fi 37869 fi 37870 37871 # remove trailing .exe if any 37872 new_path="${new_path/%.exe/}" 37873 37874 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37875 37876 # First separate the path from the arguments. This will split at the first 37877 # space. 37878 complete="$AR" 37879 path="${complete%% *}" 37880 tmp="$complete EOL" 37881 arguments="${tmp#* }" 37882 37883 # Input might be given as Windows format, start by converting to 37884 # unix format. 37885 new_path="$path" 37886 37887 windows_path="$new_path" 37888 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37889 unix_path=`$CYGPATH -u "$windows_path"` 37890 new_path="$unix_path" 37891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37892 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37893 new_path="$unix_path" 37894 fi 37895 37896 37897 # Now try to locate executable using which 37898 new_path=`$WHICH "$new_path" 2> /dev/null` 37899 37900 if test "x$new_path" = x; then 37901 # Oops. Which didn't find the executable. 37902 # The splitting of arguments from the executable at a space might have been incorrect, 37903 # since paths with space are more likely in Windows. Give it another try with the whole 37904 # argument. 37905 path="$complete" 37906 arguments="EOL" 37907 new_path="$path" 37908 37909 windows_path="$new_path" 37910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37911 unix_path=`$CYGPATH -u "$windows_path"` 37912 new_path="$unix_path" 37913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37914 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37915 new_path="$unix_path" 37916 fi 37917 37918 37919 new_path=`$WHICH "$new_path" 2> /dev/null` 37920 # bat and cmd files are not always considered executable in MSYS causing which 37921 # to not find them 37922 if test "x$new_path" = x \ 37923 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37924 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37925 new_path="$path" 37926 37927 windows_path="$new_path" 37928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37929 unix_path=`$CYGPATH -u "$windows_path"` 37930 new_path="$unix_path" 37931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37932 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37933 new_path="$unix_path" 37934 fi 37935 37936 fi 37937 37938 if test "x$new_path" = x; then 37939 # It's still not found. Now this is an unrecoverable error. 37940 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37941 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37942 has_space=`$ECHO "$complete" | $GREP " "` 37943 if test "x$has_space" != x; then 37944 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37945 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37946 fi 37947 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37948 fi 37949 fi 37950 37951 # Now new_path has a complete unix path to the binary 37952 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37953 # Keep paths in /bin as-is, but remove trailing .exe if any 37954 new_path="${new_path/%.exe/}" 37955 # Do not save /bin paths to all_fixpath_prefixes! 37956 else 37957 # Not in mixed or Windows style, start by that. 37958 new_path=`cmd //c echo $new_path` 37959 37960 input_path="$new_path" 37961 # Check if we need to convert this using DOS-style short mode. If the path 37962 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37963 # take no chances and rewrite it. 37964 # Note: m4 eats our [], so we need to use [ and ] instead. 37965 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37966 if test "x$has_forbidden_chars" != x; then 37967 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37968 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37969 fi 37970 37971 # Output is in $new_path 37972 37973 windows_path="$new_path" 37974 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37975 unix_path=`$CYGPATH -u "$windows_path"` 37976 new_path="$unix_path" 37977 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37978 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37979 new_path="$unix_path" 37980 fi 37981 37982 # remove trailing .exe if any 37983 new_path="${new_path/%.exe/}" 37984 37985 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37986 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37987 fi 37988 37989 else 37990 # We're on a unix platform. Hooray! :) 37991 # First separate the path from the arguments. This will split at the first 37992 # space. 37993 complete="$AR" 37994 path="${complete%% *}" 37995 tmp="$complete EOL" 37996 arguments="${tmp#* }" 37997 37998 # Cannot rely on the command "which" here since it doesn't always work. 37999 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38000 if test -z "$is_absolute_path"; then 38001 # Path to executable is not absolute. Find it. 38002 IFS_save="$IFS" 38003 IFS=: 38004 for p in $PATH; do 38005 if test -f "$p/$path" && test -x "$p/$path"; then 38006 new_path="$p/$path" 38007 break 38008 fi 38009 done 38010 IFS="$IFS_save" 38011 else 38012 # This is an absolute path, we can use it without further modifications. 38013 new_path="$path" 38014 fi 38015 38016 if test "x$new_path" = x; then 38017 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38018 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38019 has_space=`$ECHO "$complete" | $GREP " "` 38020 if test "x$has_space" != x; then 38021 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38022 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38023 fi 38024 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38025 fi 38026 fi 38027 38028 # Now join together the path and the arguments once again 38029 if test "x$arguments" != xEOL; then 38030 new_complete="$new_path ${arguments% *}" 38031 else 38032 new_complete="$new_path" 38033 fi 38034 38035 if test "x$complete" != "x$new_complete"; then 38036 AR="$new_complete" 38037 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38038 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38039 fi 38040 fi 38041 38042 38043 38044 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 38045 38046 38047 # Publish this variable in the help. 38048 38049 38050 if [ -z "${LIPO+x}" ]; then 38051 # The variable is not set by user, try to locate tool using the code snippet 38052 for ac_prog in lipo 38053 do 38054 # Extract the first word of "$ac_prog", so it can be a program name with args. 38055 set dummy $ac_prog; ac_word=$2 38056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38057 $as_echo_n "checking for $ac_word... " >&6; } 38058 if ${ac_cv_path_LIPO+:} false; then : 38059 $as_echo_n "(cached) " >&6 38060 else 38061 case $LIPO in 38062 [\\/]* | ?:[\\/]*) 38063 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38064 ;; 38065 *) 38066 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38067 for as_dir in $PATH 38068 do 38069 IFS=$as_save_IFS 38070 test -z "$as_dir" && as_dir=. 38071 for ac_exec_ext in '' $ac_executable_extensions; do 38072 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38073 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38074 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38075 break 2 38076 fi 38077 done 38078 done 38079 IFS=$as_save_IFS 38080 38081 ;; 38082 esac 38083 fi 38084 LIPO=$ac_cv_path_LIPO 38085 if test -n "$LIPO"; then 38086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38087 $as_echo "$LIPO" >&6; } 38088 else 38089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38090 $as_echo "no" >&6; } 38091 fi 38092 38093 38094 test -n "$LIPO" && break 38095 done 38096 38097 else 38098 # The variable is set, but is it from the command line or the environment? 38099 38100 # Try to remove the string !LIPO! from our list. 38101 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 38102 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38103 # If it failed, the variable was not from the command line. Ignore it, 38104 # but warn the user (except for BASH, which is always set by the calling BASH). 38105 if test "xLIPO" != xBASH; then 38106 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 38107 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 38108 fi 38109 # Try to locate tool using the code snippet 38110 for ac_prog in lipo 38111 do 38112 # Extract the first word of "$ac_prog", so it can be a program name with args. 38113 set dummy $ac_prog; ac_word=$2 38114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38115 $as_echo_n "checking for $ac_word... " >&6; } 38116 if ${ac_cv_path_LIPO+:} false; then : 38117 $as_echo_n "(cached) " >&6 38118 else 38119 case $LIPO in 38120 [\\/]* | ?:[\\/]*) 38121 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38122 ;; 38123 *) 38124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38125 for as_dir in $PATH 38126 do 38127 IFS=$as_save_IFS 38128 test -z "$as_dir" && as_dir=. 38129 for ac_exec_ext in '' $ac_executable_extensions; do 38130 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38131 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38132 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38133 break 2 38134 fi 38135 done 38136 done 38137 IFS=$as_save_IFS 38138 38139 ;; 38140 esac 38141 fi 38142 LIPO=$ac_cv_path_LIPO 38143 if test -n "$LIPO"; then 38144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38145 $as_echo "$LIPO" >&6; } 38146 else 38147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38148 $as_echo "no" >&6; } 38149 fi 38150 38151 38152 test -n "$LIPO" && break 38153 done 38154 38155 else 38156 # If it succeeded, then it was overridden by the user. We will use it 38157 # for the tool. 38158 38159 # First remove it from the list of overridden variables, so we can test 38160 # for unknown variables in the end. 38161 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38162 38163 # Check if we try to supply an empty value 38164 if test "x$LIPO" = x; then 38165 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 38166 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 38167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38168 $as_echo_n "checking for LIPO... " >&6; } 38169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38170 $as_echo "disabled" >&6; } 38171 else 38172 # Check if the provided tool contains a complete path. 38173 tool_specified="$LIPO" 38174 tool_basename="${tool_specified##*/}" 38175 if test "x$tool_basename" = "x$tool_specified"; then 38176 # A command without a complete path is provided, search $PATH. 38177 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 38178 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 38179 # Extract the first word of "$tool_basename", so it can be a program name with args. 38180 set dummy $tool_basename; ac_word=$2 38181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38182 $as_echo_n "checking for $ac_word... " >&6; } 38183 if ${ac_cv_path_LIPO+:} false; then : 38184 $as_echo_n "(cached) " >&6 38185 else 38186 case $LIPO in 38187 [\\/]* | ?:[\\/]*) 38188 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38189 ;; 38190 *) 38191 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38192 for as_dir in $PATH 38193 do 38194 IFS=$as_save_IFS 38195 test -z "$as_dir" && as_dir=. 38196 for ac_exec_ext in '' $ac_executable_extensions; do 38197 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38198 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38199 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38200 break 2 38201 fi 38202 done 38203 done 38204 IFS=$as_save_IFS 38205 38206 ;; 38207 esac 38208 fi 38209 LIPO=$ac_cv_path_LIPO 38210 if test -n "$LIPO"; then 38211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38212 $as_echo "$LIPO" >&6; } 38213 else 38214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38215 $as_echo "no" >&6; } 38216 fi 38217 38218 38219 if test "x$LIPO" = x; then 38220 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38221 fi 38222 else 38223 # Otherwise we believe it is a complete path. Use it as it is. 38224 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 38225 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 38226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38227 $as_echo_n "checking for LIPO... " >&6; } 38228 if test ! -x "$tool_specified"; then 38229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38230 $as_echo "not found" >&6; } 38231 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 38232 fi 38233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38234 $as_echo "$tool_specified" >&6; } 38235 fi 38236 fi 38237 fi 38238 38239 fi 38240 38241 38242 38243 # Only process if variable expands to non-empty 38244 38245 if test "x$LIPO" != x; then 38246 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38247 38248 # First separate the path from the arguments. This will split at the first 38249 # space. 38250 complete="$LIPO" 38251 path="${complete%% *}" 38252 tmp="$complete EOL" 38253 arguments="${tmp#* }" 38254 38255 # Input might be given as Windows format, start by converting to 38256 # unix format. 38257 new_path=`$CYGPATH -u "$path"` 38258 38259 # Now try to locate executable using which 38260 new_path=`$WHICH "$new_path" 2> /dev/null` 38261 # bat and cmd files are not always considered executable in cygwin causing which 38262 # to not find them 38263 if test "x$new_path" = x \ 38264 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38265 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38266 new_path=`$CYGPATH -u "$path"` 38267 fi 38268 if test "x$new_path" = x; then 38269 # Oops. Which didn't find the executable. 38270 # The splitting of arguments from the executable at a space might have been incorrect, 38271 # since paths with space are more likely in Windows. Give it another try with the whole 38272 # argument. 38273 path="$complete" 38274 arguments="EOL" 38275 new_path=`$CYGPATH -u "$path"` 38276 new_path=`$WHICH "$new_path" 2> /dev/null` 38277 # bat and cmd files are not always considered executable in cygwin causing which 38278 # to not find them 38279 if test "x$new_path" = x \ 38280 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38281 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38282 new_path=`$CYGPATH -u "$path"` 38283 fi 38284 if test "x$new_path" = x; then 38285 # It's still not found. Now this is an unrecoverable error. 38286 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38287 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38288 has_space=`$ECHO "$complete" | $GREP " "` 38289 if test "x$has_space" != x; then 38290 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38291 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38292 fi 38293 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38294 fi 38295 fi 38296 38297 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38298 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38299 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38300 # "foo.exe" is OK but "foo" is an error. 38301 # 38302 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38303 # It is also a way to make sure we got the proper file name for the real test later on. 38304 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38305 if test "x$test_shortpath" = x; then 38306 # Short path failed, file does not exist as specified. 38307 # Try adding .exe or .cmd 38308 if test -f "${new_path}.exe"; then 38309 input_to_shortpath="${new_path}.exe" 38310 elif test -f "${new_path}.cmd"; then 38311 input_to_shortpath="${new_path}.cmd" 38312 else 38313 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 38314 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 38315 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38316 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38317 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38318 fi 38319 else 38320 input_to_shortpath="$new_path" 38321 fi 38322 38323 # Call helper function which possibly converts this using DOS-style short mode. 38324 # If so, the updated path is stored in $new_path. 38325 new_path="$input_to_shortpath" 38326 38327 input_path="$input_to_shortpath" 38328 # Check if we need to convert this using DOS-style short mode. If the path 38329 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38330 # take no chances and rewrite it. 38331 # Note: m4 eats our [], so we need to use [ and ] instead. 38332 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38333 if test "x$has_forbidden_chars" != x; then 38334 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38335 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38336 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38337 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38338 # Going to short mode and back again did indeed matter. Since short mode is 38339 # case insensitive, let's make it lowercase to improve readability. 38340 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38341 # Now convert it back to Unix-style (cygpath) 38342 input_path=`$CYGPATH -u "$shortmode_path"` 38343 new_path="$input_path" 38344 fi 38345 fi 38346 38347 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38348 if test "x$test_cygdrive_prefix" = x; then 38349 # As a simple fix, exclude /usr/bin since it's not a real path. 38350 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38351 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38352 # a path prefixed by /cygdrive for fixpath to work. 38353 new_path="$CYGWIN_ROOT_PATH$input_path" 38354 fi 38355 fi 38356 38357 # remove trailing .exe if any 38358 new_path="${new_path/%.exe/}" 38359 38360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38361 38362 # First separate the path from the arguments. This will split at the first 38363 # space. 38364 complete="$LIPO" 38365 path="${complete%% *}" 38366 tmp="$complete EOL" 38367 arguments="${tmp#* }" 38368 38369 # Input might be given as Windows format, start by converting to 38370 # unix format. 38371 new_path="$path" 38372 38373 windows_path="$new_path" 38374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38375 unix_path=`$CYGPATH -u "$windows_path"` 38376 new_path="$unix_path" 38377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38379 new_path="$unix_path" 38380 fi 38381 38382 38383 # Now try to locate executable using which 38384 new_path=`$WHICH "$new_path" 2> /dev/null` 38385 38386 if test "x$new_path" = x; then 38387 # Oops. Which didn't find the executable. 38388 # The splitting of arguments from the executable at a space might have been incorrect, 38389 # since paths with space are more likely in Windows. Give it another try with the whole 38390 # argument. 38391 path="$complete" 38392 arguments="EOL" 38393 new_path="$path" 38394 38395 windows_path="$new_path" 38396 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38397 unix_path=`$CYGPATH -u "$windows_path"` 38398 new_path="$unix_path" 38399 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38400 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38401 new_path="$unix_path" 38402 fi 38403 38404 38405 new_path=`$WHICH "$new_path" 2> /dev/null` 38406 # bat and cmd files are not always considered executable in MSYS causing which 38407 # to not find them 38408 if test "x$new_path" = x \ 38409 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38410 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38411 new_path="$path" 38412 38413 windows_path="$new_path" 38414 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38415 unix_path=`$CYGPATH -u "$windows_path"` 38416 new_path="$unix_path" 38417 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38418 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38419 new_path="$unix_path" 38420 fi 38421 38422 fi 38423 38424 if test "x$new_path" = x; then 38425 # It's still not found. Now this is an unrecoverable error. 38426 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38427 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38428 has_space=`$ECHO "$complete" | $GREP " "` 38429 if test "x$has_space" != x; then 38430 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38431 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38432 fi 38433 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38434 fi 38435 fi 38436 38437 # Now new_path has a complete unix path to the binary 38438 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38439 # Keep paths in /bin as-is, but remove trailing .exe if any 38440 new_path="${new_path/%.exe/}" 38441 # Do not save /bin paths to all_fixpath_prefixes! 38442 else 38443 # Not in mixed or Windows style, start by that. 38444 new_path=`cmd //c echo $new_path` 38445 38446 input_path="$new_path" 38447 # Check if we need to convert this using DOS-style short mode. If the path 38448 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38449 # take no chances and rewrite it. 38450 # Note: m4 eats our [], so we need to use [ and ] instead. 38451 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38452 if test "x$has_forbidden_chars" != x; then 38453 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38454 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38455 fi 38456 38457 # Output is in $new_path 38458 38459 windows_path="$new_path" 38460 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38461 unix_path=`$CYGPATH -u "$windows_path"` 38462 new_path="$unix_path" 38463 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38464 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38465 new_path="$unix_path" 38466 fi 38467 38468 # remove trailing .exe if any 38469 new_path="${new_path/%.exe/}" 38470 38471 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38472 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38473 fi 38474 38475 else 38476 # We're on a unix platform. Hooray! :) 38477 # First separate the path from the arguments. This will split at the first 38478 # space. 38479 complete="$LIPO" 38480 path="${complete%% *}" 38481 tmp="$complete EOL" 38482 arguments="${tmp#* }" 38483 38484 # Cannot rely on the command "which" here since it doesn't always work. 38485 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38486 if test -z "$is_absolute_path"; then 38487 # Path to executable is not absolute. Find it. 38488 IFS_save="$IFS" 38489 IFS=: 38490 for p in $PATH; do 38491 if test -f "$p/$path" && test -x "$p/$path"; then 38492 new_path="$p/$path" 38493 break 38494 fi 38495 done 38496 IFS="$IFS_save" 38497 else 38498 # This is an absolute path, we can use it without further modifications. 38499 new_path="$path" 38500 fi 38501 38502 if test "x$new_path" = x; then 38503 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38504 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38505 has_space=`$ECHO "$complete" | $GREP " "` 38506 if test "x$has_space" != x; then 38507 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38508 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38509 fi 38510 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38511 fi 38512 fi 38513 38514 # Now join together the path and the arguments once again 38515 if test "x$arguments" != xEOL; then 38516 new_complete="$new_path ${arguments% *}" 38517 else 38518 new_complete="$new_path" 38519 fi 38520 38521 if test "x$complete" != "x$new_complete"; then 38522 LIPO="$new_complete" 38523 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 38524 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 38525 fi 38526 fi 38527 38528 fi 38529 38530 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38531 # Extract the first word of "mt", so it can be a program name with args. 38532 set dummy mt; ac_word=$2 38533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38534 $as_echo_n "checking for $ac_word... " >&6; } 38535 if ${ac_cv_prog_MT+:} false; then : 38536 $as_echo_n "(cached) " >&6 38537 else 38538 if test -n "$MT"; then 38539 ac_cv_prog_MT="$MT" # Let the user override the test. 38540 else 38541 ac_prog_rejected=no 38542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38543 for as_dir in $PATH 38544 do 38545 IFS=$as_save_IFS 38546 test -z "$as_dir" && as_dir=. 38547 for ac_exec_ext in '' $ac_executable_extensions; do 38548 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38549 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 38550 ac_prog_rejected=yes 38551 continue 38552 fi 38553 ac_cv_prog_MT="mt" 38554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38555 break 2 38556 fi 38557 done 38558 done 38559 IFS=$as_save_IFS 38560 38561 if test $ac_prog_rejected = yes; then 38562 # We found a bogon in the path, so make sure we never use it. 38563 set dummy $ac_cv_prog_MT 38564 shift 38565 if test $# != 0; then 38566 # We chose a different compiler from the bogus one. 38567 # However, it has the same basename, so the bogon will be chosen 38568 # first if we set MT to just the basename; use the full file name. 38569 shift 38570 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 38571 fi 38572 fi 38573 fi 38574 fi 38575 MT=$ac_cv_prog_MT 38576 if test -n "$MT"; then 38577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 38578 $as_echo "$MT" >&6; } 38579 else 38580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38581 $as_echo "no" >&6; } 38582 fi 38583 38584 38585 38586 # Only process if variable expands to non-empty 38587 38588 if test "x$MT" != x; then 38589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38590 38591 # First separate the path from the arguments. This will split at the first 38592 # space. 38593 complete="$MT" 38594 path="${complete%% *}" 38595 tmp="$complete EOL" 38596 arguments="${tmp#* }" 38597 38598 # Input might be given as Windows format, start by converting to 38599 # unix format. 38600 new_path=`$CYGPATH -u "$path"` 38601 38602 # Now try to locate executable using which 38603 new_path=`$WHICH "$new_path" 2> /dev/null` 38604 # bat and cmd files are not always considered executable in cygwin causing which 38605 # to not find them 38606 if test "x$new_path" = x \ 38607 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38608 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38609 new_path=`$CYGPATH -u "$path"` 38610 fi 38611 if test "x$new_path" = x; then 38612 # Oops. Which didn't find the executable. 38613 # The splitting of arguments from the executable at a space might have been incorrect, 38614 # since paths with space are more likely in Windows. Give it another try with the whole 38615 # argument. 38616 path="$complete" 38617 arguments="EOL" 38618 new_path=`$CYGPATH -u "$path"` 38619 new_path=`$WHICH "$new_path" 2> /dev/null` 38620 # bat and cmd files are not always considered executable in cygwin causing which 38621 # to not find them 38622 if test "x$new_path" = x \ 38623 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38624 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38625 new_path=`$CYGPATH -u "$path"` 38626 fi 38627 if test "x$new_path" = x; then 38628 # It's still not found. Now this is an unrecoverable error. 38629 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38630 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38631 has_space=`$ECHO "$complete" | $GREP " "` 38632 if test "x$has_space" != x; then 38633 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38634 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38635 fi 38636 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38637 fi 38638 fi 38639 38640 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38641 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38642 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38643 # "foo.exe" is OK but "foo" is an error. 38644 # 38645 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38646 # It is also a way to make sure we got the proper file name for the real test later on. 38647 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38648 if test "x$test_shortpath" = x; then 38649 # Short path failed, file does not exist as specified. 38650 # Try adding .exe or .cmd 38651 if test -f "${new_path}.exe"; then 38652 input_to_shortpath="${new_path}.exe" 38653 elif test -f "${new_path}.cmd"; then 38654 input_to_shortpath="${new_path}.cmd" 38655 else 38656 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 38657 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 38658 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38659 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38660 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38661 fi 38662 else 38663 input_to_shortpath="$new_path" 38664 fi 38665 38666 # Call helper function which possibly converts this using DOS-style short mode. 38667 # If so, the updated path is stored in $new_path. 38668 new_path="$input_to_shortpath" 38669 38670 input_path="$input_to_shortpath" 38671 # Check if we need to convert this using DOS-style short mode. If the path 38672 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38673 # take no chances and rewrite it. 38674 # Note: m4 eats our [], so we need to use [ and ] instead. 38675 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38676 if test "x$has_forbidden_chars" != x; then 38677 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38678 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38679 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38680 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38681 # Going to short mode and back again did indeed matter. Since short mode is 38682 # case insensitive, let's make it lowercase to improve readability. 38683 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38684 # Now convert it back to Unix-style (cygpath) 38685 input_path=`$CYGPATH -u "$shortmode_path"` 38686 new_path="$input_path" 38687 fi 38688 fi 38689 38690 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38691 if test "x$test_cygdrive_prefix" = x; then 38692 # As a simple fix, exclude /usr/bin since it's not a real path. 38693 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38694 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38695 # a path prefixed by /cygdrive for fixpath to work. 38696 new_path="$CYGWIN_ROOT_PATH$input_path" 38697 fi 38698 fi 38699 38700 # remove trailing .exe if any 38701 new_path="${new_path/%.exe/}" 38702 38703 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38704 38705 # First separate the path from the arguments. This will split at the first 38706 # space. 38707 complete="$MT" 38708 path="${complete%% *}" 38709 tmp="$complete EOL" 38710 arguments="${tmp#* }" 38711 38712 # Input might be given as Windows format, start by converting to 38713 # unix format. 38714 new_path="$path" 38715 38716 windows_path="$new_path" 38717 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38718 unix_path=`$CYGPATH -u "$windows_path"` 38719 new_path="$unix_path" 38720 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38721 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38722 new_path="$unix_path" 38723 fi 38724 38725 38726 # Now try to locate executable using which 38727 new_path=`$WHICH "$new_path" 2> /dev/null` 38728 38729 if test "x$new_path" = x; then 38730 # Oops. Which didn't find the executable. 38731 # The splitting of arguments from the executable at a space might have been incorrect, 38732 # since paths with space are more likely in Windows. Give it another try with the whole 38733 # argument. 38734 path="$complete" 38735 arguments="EOL" 38736 new_path="$path" 38737 38738 windows_path="$new_path" 38739 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38740 unix_path=`$CYGPATH -u "$windows_path"` 38741 new_path="$unix_path" 38742 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38743 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38744 new_path="$unix_path" 38745 fi 38746 38747 38748 new_path=`$WHICH "$new_path" 2> /dev/null` 38749 # bat and cmd files are not always considered executable in MSYS causing which 38750 # to not find them 38751 if test "x$new_path" = x \ 38752 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38753 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38754 new_path="$path" 38755 38756 windows_path="$new_path" 38757 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38758 unix_path=`$CYGPATH -u "$windows_path"` 38759 new_path="$unix_path" 38760 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38761 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38762 new_path="$unix_path" 38763 fi 38764 38765 fi 38766 38767 if test "x$new_path" = x; then 38768 # It's still not found. Now this is an unrecoverable error. 38769 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38770 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38771 has_space=`$ECHO "$complete" | $GREP " "` 38772 if test "x$has_space" != x; then 38773 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38774 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38775 fi 38776 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38777 fi 38778 fi 38779 38780 # Now new_path has a complete unix path to the binary 38781 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38782 # Keep paths in /bin as-is, but remove trailing .exe if any 38783 new_path="${new_path/%.exe/}" 38784 # Do not save /bin paths to all_fixpath_prefixes! 38785 else 38786 # Not in mixed or Windows style, start by that. 38787 new_path=`cmd //c echo $new_path` 38788 38789 input_path="$new_path" 38790 # Check if we need to convert this using DOS-style short mode. If the path 38791 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38792 # take no chances and rewrite it. 38793 # Note: m4 eats our [], so we need to use [ and ] instead. 38794 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38795 if test "x$has_forbidden_chars" != x; then 38796 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38797 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38798 fi 38799 38800 # Output is in $new_path 38801 38802 windows_path="$new_path" 38803 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38804 unix_path=`$CYGPATH -u "$windows_path"` 38805 new_path="$unix_path" 38806 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38807 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38808 new_path="$unix_path" 38809 fi 38810 38811 # remove trailing .exe if any 38812 new_path="${new_path/%.exe/}" 38813 38814 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38815 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38816 fi 38817 38818 else 38819 # We're on a unix platform. Hooray! :) 38820 # First separate the path from the arguments. This will split at the first 38821 # space. 38822 complete="$MT" 38823 path="${complete%% *}" 38824 tmp="$complete EOL" 38825 arguments="${tmp#* }" 38826 38827 # Cannot rely on the command "which" here since it doesn't always work. 38828 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38829 if test -z "$is_absolute_path"; then 38830 # Path to executable is not absolute. Find it. 38831 IFS_save="$IFS" 38832 IFS=: 38833 for p in $PATH; do 38834 if test -f "$p/$path" && test -x "$p/$path"; then 38835 new_path="$p/$path" 38836 break 38837 fi 38838 done 38839 IFS="$IFS_save" 38840 else 38841 # This is an absolute path, we can use it without further modifications. 38842 new_path="$path" 38843 fi 38844 38845 if test "x$new_path" = x; then 38846 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38847 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38848 has_space=`$ECHO "$complete" | $GREP " "` 38849 if test "x$has_space" != x; then 38850 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38851 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38852 fi 38853 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38854 fi 38855 fi 38856 38857 # Now join together the path and the arguments once again 38858 if test "x$arguments" != xEOL; then 38859 new_complete="$new_path ${arguments% *}" 38860 else 38861 new_complete="$new_path" 38862 fi 38863 38864 if test "x$complete" != "x$new_complete"; then 38865 MT="$new_complete" 38866 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 38867 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 38868 fi 38869 fi 38870 38871 # Setup the resource compiler (RC) 38872 # Extract the first word of "rc", so it can be a program name with args. 38873 set dummy rc; ac_word=$2 38874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38875 $as_echo_n "checking for $ac_word... " >&6; } 38876 if ${ac_cv_prog_RC+:} false; then : 38877 $as_echo_n "(cached) " >&6 38878 else 38879 if test -n "$RC"; then 38880 ac_cv_prog_RC="$RC" # Let the user override the test. 38881 else 38882 ac_prog_rejected=no 38883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38884 for as_dir in $PATH 38885 do 38886 IFS=$as_save_IFS 38887 test -z "$as_dir" && as_dir=. 38888 for ac_exec_ext in '' $ac_executable_extensions; do 38889 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38890 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 38891 ac_prog_rejected=yes 38892 continue 38893 fi 38894 ac_cv_prog_RC="rc" 38895 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38896 break 2 38897 fi 38898 done 38899 done 38900 IFS=$as_save_IFS 38901 38902 if test $ac_prog_rejected = yes; then 38903 # We found a bogon in the path, so make sure we never use it. 38904 set dummy $ac_cv_prog_RC 38905 shift 38906 if test $# != 0; then 38907 # We chose a different compiler from the bogus one. 38908 # However, it has the same basename, so the bogon will be chosen 38909 # first if we set RC to just the basename; use the full file name. 38910 shift 38911 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 38912 fi 38913 fi 38914 fi 38915 fi 38916 RC=$ac_cv_prog_RC 38917 if test -n "$RC"; then 38918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 38919 $as_echo "$RC" >&6; } 38920 else 38921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38922 $as_echo "no" >&6; } 38923 fi 38924 38925 38926 38927 # Only process if variable expands to non-empty 38928 38929 if test "x$RC" != x; then 38930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38931 38932 # First separate the path from the arguments. This will split at the first 38933 # space. 38934 complete="$RC" 38935 path="${complete%% *}" 38936 tmp="$complete EOL" 38937 arguments="${tmp#* }" 38938 38939 # Input might be given as Windows format, start by converting to 38940 # unix format. 38941 new_path=`$CYGPATH -u "$path"` 38942 38943 # Now try to locate executable using which 38944 new_path=`$WHICH "$new_path" 2> /dev/null` 38945 # bat and cmd files are not always considered executable in cygwin causing which 38946 # to not find them 38947 if test "x$new_path" = x \ 38948 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38949 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38950 new_path=`$CYGPATH -u "$path"` 38951 fi 38952 if test "x$new_path" = x; then 38953 # Oops. Which didn't find the executable. 38954 # The splitting of arguments from the executable at a space might have been incorrect, 38955 # since paths with space are more likely in Windows. Give it another try with the whole 38956 # argument. 38957 path="$complete" 38958 arguments="EOL" 38959 new_path=`$CYGPATH -u "$path"` 38960 new_path=`$WHICH "$new_path" 2> /dev/null` 38961 # bat and cmd files are not always considered executable in cygwin causing which 38962 # to not find them 38963 if test "x$new_path" = x \ 38964 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38965 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38966 new_path=`$CYGPATH -u "$path"` 38967 fi 38968 if test "x$new_path" = x; then 38969 # It's still not found. Now this is an unrecoverable error. 38970 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 38971 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 38972 has_space=`$ECHO "$complete" | $GREP " "` 38973 if test "x$has_space" != x; then 38974 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38975 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38976 fi 38977 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38978 fi 38979 fi 38980 38981 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38982 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38983 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38984 # "foo.exe" is OK but "foo" is an error. 38985 # 38986 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38987 # It is also a way to make sure we got the proper file name for the real test later on. 38988 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38989 if test "x$test_shortpath" = x; then 38990 # Short path failed, file does not exist as specified. 38991 # Try adding .exe or .cmd 38992 if test -f "${new_path}.exe"; then 38993 input_to_shortpath="${new_path}.exe" 38994 elif test -f "${new_path}.cmd"; then 38995 input_to_shortpath="${new_path}.cmd" 38996 else 38997 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 38998 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 38999 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39000 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39001 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39002 fi 39003 else 39004 input_to_shortpath="$new_path" 39005 fi 39006 39007 # Call helper function which possibly converts this using DOS-style short mode. 39008 # If so, the updated path is stored in $new_path. 39009 new_path="$input_to_shortpath" 39010 39011 input_path="$input_to_shortpath" 39012 # Check if we need to convert this using DOS-style short mode. If the path 39013 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39014 # take no chances and rewrite it. 39015 # Note: m4 eats our [], so we need to use [ and ] instead. 39016 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39017 if test "x$has_forbidden_chars" != x; then 39018 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39019 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39020 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39021 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39022 # Going to short mode and back again did indeed matter. Since short mode is 39023 # case insensitive, let's make it lowercase to improve readability. 39024 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39025 # Now convert it back to Unix-style (cygpath) 39026 input_path=`$CYGPATH -u "$shortmode_path"` 39027 new_path="$input_path" 39028 fi 39029 fi 39030 39031 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39032 if test "x$test_cygdrive_prefix" = x; then 39033 # As a simple fix, exclude /usr/bin since it's not a real path. 39034 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39035 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39036 # a path prefixed by /cygdrive for fixpath to work. 39037 new_path="$CYGWIN_ROOT_PATH$input_path" 39038 fi 39039 fi 39040 39041 # remove trailing .exe if any 39042 new_path="${new_path/%.exe/}" 39043 39044 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39045 39046 # First separate the path from the arguments. This will split at the first 39047 # space. 39048 complete="$RC" 39049 path="${complete%% *}" 39050 tmp="$complete EOL" 39051 arguments="${tmp#* }" 39052 39053 # Input might be given as Windows format, start by converting to 39054 # unix format. 39055 new_path="$path" 39056 39057 windows_path="$new_path" 39058 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39059 unix_path=`$CYGPATH -u "$windows_path"` 39060 new_path="$unix_path" 39061 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39062 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39063 new_path="$unix_path" 39064 fi 39065 39066 39067 # Now try to locate executable using which 39068 new_path=`$WHICH "$new_path" 2> /dev/null` 39069 39070 if test "x$new_path" = x; then 39071 # Oops. Which didn't find the executable. 39072 # The splitting of arguments from the executable at a space might have been incorrect, 39073 # since paths with space are more likely in Windows. Give it another try with the whole 39074 # argument. 39075 path="$complete" 39076 arguments="EOL" 39077 new_path="$path" 39078 39079 windows_path="$new_path" 39080 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39081 unix_path=`$CYGPATH -u "$windows_path"` 39082 new_path="$unix_path" 39083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39084 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39085 new_path="$unix_path" 39086 fi 39087 39088 39089 new_path=`$WHICH "$new_path" 2> /dev/null` 39090 # bat and cmd files are not always considered executable in MSYS causing which 39091 # to not find them 39092 if test "x$new_path" = x \ 39093 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39094 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39095 new_path="$path" 39096 39097 windows_path="$new_path" 39098 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39099 unix_path=`$CYGPATH -u "$windows_path"` 39100 new_path="$unix_path" 39101 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39102 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39103 new_path="$unix_path" 39104 fi 39105 39106 fi 39107 39108 if test "x$new_path" = x; then 39109 # It's still not found. Now this is an unrecoverable error. 39110 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39111 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39112 has_space=`$ECHO "$complete" | $GREP " "` 39113 if test "x$has_space" != x; then 39114 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39115 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39116 fi 39117 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39118 fi 39119 fi 39120 39121 # Now new_path has a complete unix path to the binary 39122 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39123 # Keep paths in /bin as-is, but remove trailing .exe if any 39124 new_path="${new_path/%.exe/}" 39125 # Do not save /bin paths to all_fixpath_prefixes! 39126 else 39127 # Not in mixed or Windows style, start by that. 39128 new_path=`cmd //c echo $new_path` 39129 39130 input_path="$new_path" 39131 # Check if we need to convert this using DOS-style short mode. If the path 39132 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39133 # take no chances and rewrite it. 39134 # Note: m4 eats our [], so we need to use [ and ] instead. 39135 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39136 if test "x$has_forbidden_chars" != x; then 39137 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39138 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39139 fi 39140 39141 # Output is in $new_path 39142 39143 windows_path="$new_path" 39144 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39145 unix_path=`$CYGPATH -u "$windows_path"` 39146 new_path="$unix_path" 39147 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39148 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39149 new_path="$unix_path" 39150 fi 39151 39152 # remove trailing .exe if any 39153 new_path="${new_path/%.exe/}" 39154 39155 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39156 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39157 fi 39158 39159 else 39160 # We're on a unix platform. Hooray! :) 39161 # First separate the path from the arguments. This will split at the first 39162 # space. 39163 complete="$RC" 39164 path="${complete%% *}" 39165 tmp="$complete EOL" 39166 arguments="${tmp#* }" 39167 39168 # Cannot rely on the command "which" here since it doesn't always work. 39169 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39170 if test -z "$is_absolute_path"; then 39171 # Path to executable is not absolute. Find it. 39172 IFS_save="$IFS" 39173 IFS=: 39174 for p in $PATH; do 39175 if test -f "$p/$path" && test -x "$p/$path"; then 39176 new_path="$p/$path" 39177 break 39178 fi 39179 done 39180 IFS="$IFS_save" 39181 else 39182 # This is an absolute path, we can use it without further modifications. 39183 new_path="$path" 39184 fi 39185 39186 if test "x$new_path" = x; then 39187 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39188 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39189 has_space=`$ECHO "$complete" | $GREP " "` 39190 if test "x$has_space" != x; then 39191 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39192 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39193 fi 39194 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39195 fi 39196 fi 39197 39198 # Now join together the path and the arguments once again 39199 if test "x$arguments" != xEOL; then 39200 new_complete="$new_path ${arguments% *}" 39201 else 39202 new_complete="$new_path" 39203 fi 39204 39205 if test "x$complete" != "x$new_complete"; then 39206 RC="$new_complete" 39207 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 39208 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 39209 fi 39210 fi 39211 39212 # Extract the first word of "dumpbin", so it can be a program name with args. 39213 set dummy dumpbin; ac_word=$2 39214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39215 $as_echo_n "checking for $ac_word... " >&6; } 39216 if ${ac_cv_prog_DUMPBIN+:} false; then : 39217 $as_echo_n "(cached) " >&6 39218 else 39219 if test -n "$DUMPBIN"; then 39220 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 39221 else 39222 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39223 for as_dir in $PATH 39224 do 39225 IFS=$as_save_IFS 39226 test -z "$as_dir" && as_dir=. 39227 for ac_exec_ext in '' $ac_executable_extensions; do 39228 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39229 ac_cv_prog_DUMPBIN="dumpbin" 39230 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39231 break 2 39232 fi 39233 done 39234 done 39235 IFS=$as_save_IFS 39236 39237 fi 39238 fi 39239 DUMPBIN=$ac_cv_prog_DUMPBIN 39240 if test -n "$DUMPBIN"; then 39241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 39242 $as_echo "$DUMPBIN" >&6; } 39243 else 39244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39245 $as_echo "no" >&6; } 39246 fi 39247 39248 39249 39250 # Only process if variable expands to non-empty 39251 39252 if test "x$DUMPBIN" != x; then 39253 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39254 39255 # First separate the path from the arguments. This will split at the first 39256 # space. 39257 complete="$DUMPBIN" 39258 path="${complete%% *}" 39259 tmp="$complete EOL" 39260 arguments="${tmp#* }" 39261 39262 # Input might be given as Windows format, start by converting to 39263 # unix format. 39264 new_path=`$CYGPATH -u "$path"` 39265 39266 # Now try to locate executable using which 39267 new_path=`$WHICH "$new_path" 2> /dev/null` 39268 # bat and cmd files are not always considered executable in cygwin causing which 39269 # to not find them 39270 if test "x$new_path" = x \ 39271 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39272 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39273 new_path=`$CYGPATH -u "$path"` 39274 fi 39275 if test "x$new_path" = x; then 39276 # Oops. Which didn't find the executable. 39277 # The splitting of arguments from the executable at a space might have been incorrect, 39278 # since paths with space are more likely in Windows. Give it another try with the whole 39279 # argument. 39280 path="$complete" 39281 arguments="EOL" 39282 new_path=`$CYGPATH -u "$path"` 39283 new_path=`$WHICH "$new_path" 2> /dev/null` 39284 # bat and cmd files are not always considered executable in cygwin causing which 39285 # to not find them 39286 if test "x$new_path" = x \ 39287 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39288 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39289 new_path=`$CYGPATH -u "$path"` 39290 fi 39291 if test "x$new_path" = x; then 39292 # It's still not found. Now this is an unrecoverable error. 39293 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39294 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39295 has_space=`$ECHO "$complete" | $GREP " "` 39296 if test "x$has_space" != x; then 39297 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39298 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39299 fi 39300 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39301 fi 39302 fi 39303 39304 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39305 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39306 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39307 # "foo.exe" is OK but "foo" is an error. 39308 # 39309 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39310 # It is also a way to make sure we got the proper file name for the real test later on. 39311 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39312 if test "x$test_shortpath" = x; then 39313 # Short path failed, file does not exist as specified. 39314 # Try adding .exe or .cmd 39315 if test -f "${new_path}.exe"; then 39316 input_to_shortpath="${new_path}.exe" 39317 elif test -f "${new_path}.cmd"; then 39318 input_to_shortpath="${new_path}.cmd" 39319 else 39320 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 39321 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 39322 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39323 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39324 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39325 fi 39326 else 39327 input_to_shortpath="$new_path" 39328 fi 39329 39330 # Call helper function which possibly converts this using DOS-style short mode. 39331 # If so, the updated path is stored in $new_path. 39332 new_path="$input_to_shortpath" 39333 39334 input_path="$input_to_shortpath" 39335 # Check if we need to convert this using DOS-style short mode. If the path 39336 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39337 # take no chances and rewrite it. 39338 # Note: m4 eats our [], so we need to use [ and ] instead. 39339 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39340 if test "x$has_forbidden_chars" != x; then 39341 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39342 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39343 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39344 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39345 # Going to short mode and back again did indeed matter. Since short mode is 39346 # case insensitive, let's make it lowercase to improve readability. 39347 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39348 # Now convert it back to Unix-style (cygpath) 39349 input_path=`$CYGPATH -u "$shortmode_path"` 39350 new_path="$input_path" 39351 fi 39352 fi 39353 39354 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39355 if test "x$test_cygdrive_prefix" = x; then 39356 # As a simple fix, exclude /usr/bin since it's not a real path. 39357 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39358 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39359 # a path prefixed by /cygdrive for fixpath to work. 39360 new_path="$CYGWIN_ROOT_PATH$input_path" 39361 fi 39362 fi 39363 39364 # remove trailing .exe if any 39365 new_path="${new_path/%.exe/}" 39366 39367 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39368 39369 # First separate the path from the arguments. This will split at the first 39370 # space. 39371 complete="$DUMPBIN" 39372 path="${complete%% *}" 39373 tmp="$complete EOL" 39374 arguments="${tmp#* }" 39375 39376 # Input might be given as Windows format, start by converting to 39377 # unix format. 39378 new_path="$path" 39379 39380 windows_path="$new_path" 39381 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39382 unix_path=`$CYGPATH -u "$windows_path"` 39383 new_path="$unix_path" 39384 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39385 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39386 new_path="$unix_path" 39387 fi 39388 39389 39390 # Now try to locate executable using which 39391 new_path=`$WHICH "$new_path" 2> /dev/null` 39392 39393 if test "x$new_path" = x; then 39394 # Oops. Which didn't find the executable. 39395 # The splitting of arguments from the executable at a space might have been incorrect, 39396 # since paths with space are more likely in Windows. Give it another try with the whole 39397 # argument. 39398 path="$complete" 39399 arguments="EOL" 39400 new_path="$path" 39401 39402 windows_path="$new_path" 39403 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39404 unix_path=`$CYGPATH -u "$windows_path"` 39405 new_path="$unix_path" 39406 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39407 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39408 new_path="$unix_path" 39409 fi 39410 39411 39412 new_path=`$WHICH "$new_path" 2> /dev/null` 39413 # bat and cmd files are not always considered executable in MSYS causing which 39414 # to not find them 39415 if test "x$new_path" = x \ 39416 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39417 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39418 new_path="$path" 39419 39420 windows_path="$new_path" 39421 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39422 unix_path=`$CYGPATH -u "$windows_path"` 39423 new_path="$unix_path" 39424 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39425 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39426 new_path="$unix_path" 39427 fi 39428 39429 fi 39430 39431 if test "x$new_path" = x; then 39432 # It's still not found. Now this is an unrecoverable error. 39433 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39434 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39435 has_space=`$ECHO "$complete" | $GREP " "` 39436 if test "x$has_space" != x; then 39437 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39438 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39439 fi 39440 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39441 fi 39442 fi 39443 39444 # Now new_path has a complete unix path to the binary 39445 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39446 # Keep paths in /bin as-is, but remove trailing .exe if any 39447 new_path="${new_path/%.exe/}" 39448 # Do not save /bin paths to all_fixpath_prefixes! 39449 else 39450 # Not in mixed or Windows style, start by that. 39451 new_path=`cmd //c echo $new_path` 39452 39453 input_path="$new_path" 39454 # Check if we need to convert this using DOS-style short mode. If the path 39455 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39456 # take no chances and rewrite it. 39457 # Note: m4 eats our [], so we need to use [ and ] instead. 39458 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39459 if test "x$has_forbidden_chars" != x; then 39460 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39461 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39462 fi 39463 39464 # Output is in $new_path 39465 39466 windows_path="$new_path" 39467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39468 unix_path=`$CYGPATH -u "$windows_path"` 39469 new_path="$unix_path" 39470 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39471 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39472 new_path="$unix_path" 39473 fi 39474 39475 # remove trailing .exe if any 39476 new_path="${new_path/%.exe/}" 39477 39478 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39479 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39480 fi 39481 39482 else 39483 # We're on a unix platform. Hooray! :) 39484 # First separate the path from the arguments. This will split at the first 39485 # space. 39486 complete="$DUMPBIN" 39487 path="${complete%% *}" 39488 tmp="$complete EOL" 39489 arguments="${tmp#* }" 39490 39491 # Cannot rely on the command "which" here since it doesn't always work. 39492 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39493 if test -z "$is_absolute_path"; then 39494 # Path to executable is not absolute. Find it. 39495 IFS_save="$IFS" 39496 IFS=: 39497 for p in $PATH; do 39498 if test -f "$p/$path" && test -x "$p/$path"; then 39499 new_path="$p/$path" 39500 break 39501 fi 39502 done 39503 IFS="$IFS_save" 39504 else 39505 # This is an absolute path, we can use it without further modifications. 39506 new_path="$path" 39507 fi 39508 39509 if test "x$new_path" = x; then 39510 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39511 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39512 has_space=`$ECHO "$complete" | $GREP " "` 39513 if test "x$has_space" != x; then 39514 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39515 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39516 fi 39517 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39518 fi 39519 fi 39520 39521 # Now join together the path and the arguments once again 39522 if test "x$arguments" != xEOL; then 39523 new_complete="$new_path ${arguments% *}" 39524 else 39525 new_complete="$new_path" 39526 fi 39527 39528 if test "x$complete" != "x$new_complete"; then 39529 DUMPBIN="$new_complete" 39530 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 39531 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 39532 fi 39533 fi 39534 39535 # We need to check for 'msbuild.exe' because at the place where we expect to 39536 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 39537 # won't find the 'msbuild.exe' executable in that case (and the 39538 # 'ac_executable_extensions' is unusable due to performance reasons). 39539 # Notice that we intentionally don't fix up the path to MSBUILD because we 39540 # will call it in a DOS shell during freetype detection on Windows (see 39541 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 39542 # Extract the first word of "msbuild.exe", so it can be a program name with args. 39543 set dummy msbuild.exe; ac_word=$2 39544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39545 $as_echo_n "checking for $ac_word... " >&6; } 39546 if ${ac_cv_prog_MSBUILD+:} false; then : 39547 $as_echo_n "(cached) " >&6 39548 else 39549 if test -n "$MSBUILD"; then 39550 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 39551 else 39552 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39553 for as_dir in $PATH 39554 do 39555 IFS=$as_save_IFS 39556 test -z "$as_dir" && as_dir=. 39557 for ac_exec_ext in '' $ac_executable_extensions; do 39558 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39559 ac_cv_prog_MSBUILD="msbuild.exe" 39560 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39561 break 2 39562 fi 39563 done 39564 done 39565 IFS=$as_save_IFS 39566 39567 fi 39568 fi 39569 MSBUILD=$ac_cv_prog_MSBUILD 39570 if test -n "$MSBUILD"; then 39571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 39572 $as_echo "$MSBUILD" >&6; } 39573 else 39574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39575 $as_echo "no" >&6; } 39576 fi 39577 39578 39579 fi 39580 39581 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 39582 39583 39584 # Publish this variable in the help. 39585 39586 39587 if [ -z "${STRIP+x}" ]; then 39588 # The variable is not set by user, try to locate tool using the code snippet 39589 for ac_prog in strip 39590 do 39591 # Extract the first word of "$ac_prog", so it can be a program name with args. 39592 set dummy $ac_prog; ac_word=$2 39593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39594 $as_echo_n "checking for $ac_word... " >&6; } 39595 if ${ac_cv_path_STRIP+:} false; then : 39596 $as_echo_n "(cached) " >&6 39597 else 39598 case $STRIP in 39599 [\\/]* | ?:[\\/]*) 39600 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39601 ;; 39602 *) 39603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39604 for as_dir in $PATH 39605 do 39606 IFS=$as_save_IFS 39607 test -z "$as_dir" && as_dir=. 39608 for ac_exec_ext in '' $ac_executable_extensions; do 39609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39610 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39612 break 2 39613 fi 39614 done 39615 done 39616 IFS=$as_save_IFS 39617 39618 ;; 39619 esac 39620 fi 39621 STRIP=$ac_cv_path_STRIP 39622 if test -n "$STRIP"; then 39623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39624 $as_echo "$STRIP" >&6; } 39625 else 39626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39627 $as_echo "no" >&6; } 39628 fi 39629 39630 39631 test -n "$STRIP" && break 39632 done 39633 39634 else 39635 # The variable is set, but is it from the command line or the environment? 39636 39637 # Try to remove the string !STRIP! from our list. 39638 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 39639 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39640 # If it failed, the variable was not from the command line. Ignore it, 39641 # but warn the user (except for BASH, which is always set by the calling BASH). 39642 if test "xSTRIP" != xBASH; then 39643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 39644 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 39645 fi 39646 # Try to locate tool using the code snippet 39647 for ac_prog in strip 39648 do 39649 # Extract the first word of "$ac_prog", so it can be a program name with args. 39650 set dummy $ac_prog; ac_word=$2 39651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39652 $as_echo_n "checking for $ac_word... " >&6; } 39653 if ${ac_cv_path_STRIP+:} false; then : 39654 $as_echo_n "(cached) " >&6 39655 else 39656 case $STRIP in 39657 [\\/]* | ?:[\\/]*) 39658 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39659 ;; 39660 *) 39661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39662 for as_dir in $PATH 39663 do 39664 IFS=$as_save_IFS 39665 test -z "$as_dir" && as_dir=. 39666 for ac_exec_ext in '' $ac_executable_extensions; do 39667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39668 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39670 break 2 39671 fi 39672 done 39673 done 39674 IFS=$as_save_IFS 39675 39676 ;; 39677 esac 39678 fi 39679 STRIP=$ac_cv_path_STRIP 39680 if test -n "$STRIP"; then 39681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39682 $as_echo "$STRIP" >&6; } 39683 else 39684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39685 $as_echo "no" >&6; } 39686 fi 39687 39688 39689 test -n "$STRIP" && break 39690 done 39691 39692 else 39693 # If it succeeded, then it was overridden by the user. We will use it 39694 # for the tool. 39695 39696 # First remove it from the list of overridden variables, so we can test 39697 # for unknown variables in the end. 39698 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39699 39700 # Check if we try to supply an empty value 39701 if test "x$STRIP" = x; then 39702 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 39703 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 39704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39705 $as_echo_n "checking for STRIP... " >&6; } 39706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39707 $as_echo "disabled" >&6; } 39708 else 39709 # Check if the provided tool contains a complete path. 39710 tool_specified="$STRIP" 39711 tool_basename="${tool_specified##*/}" 39712 if test "x$tool_basename" = "x$tool_specified"; then 39713 # A command without a complete path is provided, search $PATH. 39714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 39715 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 39716 # Extract the first word of "$tool_basename", so it can be a program name with args. 39717 set dummy $tool_basename; ac_word=$2 39718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39719 $as_echo_n "checking for $ac_word... " >&6; } 39720 if ${ac_cv_path_STRIP+:} false; then : 39721 $as_echo_n "(cached) " >&6 39722 else 39723 case $STRIP in 39724 [\\/]* | ?:[\\/]*) 39725 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39726 ;; 39727 *) 39728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39729 for as_dir in $PATH 39730 do 39731 IFS=$as_save_IFS 39732 test -z "$as_dir" && as_dir=. 39733 for ac_exec_ext in '' $ac_executable_extensions; do 39734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39735 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39737 break 2 39738 fi 39739 done 39740 done 39741 IFS=$as_save_IFS 39742 39743 ;; 39744 esac 39745 fi 39746 STRIP=$ac_cv_path_STRIP 39747 if test -n "$STRIP"; then 39748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39749 $as_echo "$STRIP" >&6; } 39750 else 39751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39752 $as_echo "no" >&6; } 39753 fi 39754 39755 39756 if test "x$STRIP" = x; then 39757 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39758 fi 39759 else 39760 # Otherwise we believe it is a complete path. Use it as it is. 39761 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 39762 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 39763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39764 $as_echo_n "checking for STRIP... " >&6; } 39765 if test ! -x "$tool_specified"; then 39766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39767 $as_echo "not found" >&6; } 39768 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 39769 fi 39770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39771 $as_echo "$tool_specified" >&6; } 39772 fi 39773 fi 39774 fi 39775 39776 fi 39777 39778 39779 39780 # Only process if variable expands to non-empty 39781 39782 if test "x$STRIP" != x; then 39783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39784 39785 # First separate the path from the arguments. This will split at the first 39786 # space. 39787 complete="$STRIP" 39788 path="${complete%% *}" 39789 tmp="$complete EOL" 39790 arguments="${tmp#* }" 39791 39792 # Input might be given as Windows format, start by converting to 39793 # unix format. 39794 new_path=`$CYGPATH -u "$path"` 39795 39796 # Now try to locate executable using which 39797 new_path=`$WHICH "$new_path" 2> /dev/null` 39798 # bat and cmd files are not always considered executable in cygwin causing which 39799 # to not find them 39800 if test "x$new_path" = x \ 39801 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39802 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39803 new_path=`$CYGPATH -u "$path"` 39804 fi 39805 if test "x$new_path" = x; then 39806 # Oops. Which didn't find the executable. 39807 # The splitting of arguments from the executable at a space might have been incorrect, 39808 # since paths with space are more likely in Windows. Give it another try with the whole 39809 # argument. 39810 path="$complete" 39811 arguments="EOL" 39812 new_path=`$CYGPATH -u "$path"` 39813 new_path=`$WHICH "$new_path" 2> /dev/null` 39814 # bat and cmd files are not always considered executable in cygwin causing which 39815 # to not find them 39816 if test "x$new_path" = x \ 39817 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39818 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39819 new_path=`$CYGPATH -u "$path"` 39820 fi 39821 if test "x$new_path" = x; then 39822 # It's still not found. Now this is an unrecoverable error. 39823 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39824 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39825 has_space=`$ECHO "$complete" | $GREP " "` 39826 if test "x$has_space" != x; then 39827 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39828 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39829 fi 39830 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39831 fi 39832 fi 39833 39834 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39835 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39836 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39837 # "foo.exe" is OK but "foo" is an error. 39838 # 39839 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39840 # It is also a way to make sure we got the proper file name for the real test later on. 39841 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39842 if test "x$test_shortpath" = x; then 39843 # Short path failed, file does not exist as specified. 39844 # Try adding .exe or .cmd 39845 if test -f "${new_path}.exe"; then 39846 input_to_shortpath="${new_path}.exe" 39847 elif test -f "${new_path}.cmd"; then 39848 input_to_shortpath="${new_path}.cmd" 39849 else 39850 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 39851 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 39852 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39853 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39854 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39855 fi 39856 else 39857 input_to_shortpath="$new_path" 39858 fi 39859 39860 # Call helper function which possibly converts this using DOS-style short mode. 39861 # If so, the updated path is stored in $new_path. 39862 new_path="$input_to_shortpath" 39863 39864 input_path="$input_to_shortpath" 39865 # Check if we need to convert this using DOS-style short mode. If the path 39866 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39867 # take no chances and rewrite it. 39868 # Note: m4 eats our [], so we need to use [ and ] instead. 39869 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39870 if test "x$has_forbidden_chars" != x; then 39871 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39872 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39873 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39874 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39875 # Going to short mode and back again did indeed matter. Since short mode is 39876 # case insensitive, let's make it lowercase to improve readability. 39877 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39878 # Now convert it back to Unix-style (cygpath) 39879 input_path=`$CYGPATH -u "$shortmode_path"` 39880 new_path="$input_path" 39881 fi 39882 fi 39883 39884 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39885 if test "x$test_cygdrive_prefix" = x; then 39886 # As a simple fix, exclude /usr/bin since it's not a real path. 39887 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39888 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39889 # a path prefixed by /cygdrive for fixpath to work. 39890 new_path="$CYGWIN_ROOT_PATH$input_path" 39891 fi 39892 fi 39893 39894 # remove trailing .exe if any 39895 new_path="${new_path/%.exe/}" 39896 39897 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39898 39899 # First separate the path from the arguments. This will split at the first 39900 # space. 39901 complete="$STRIP" 39902 path="${complete%% *}" 39903 tmp="$complete EOL" 39904 arguments="${tmp#* }" 39905 39906 # Input might be given as Windows format, start by converting to 39907 # unix format. 39908 new_path="$path" 39909 39910 windows_path="$new_path" 39911 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39912 unix_path=`$CYGPATH -u "$windows_path"` 39913 new_path="$unix_path" 39914 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39915 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39916 new_path="$unix_path" 39917 fi 39918 39919 39920 # Now try to locate executable using which 39921 new_path=`$WHICH "$new_path" 2> /dev/null` 39922 39923 if test "x$new_path" = x; then 39924 # Oops. Which didn't find the executable. 39925 # The splitting of arguments from the executable at a space might have been incorrect, 39926 # since paths with space are more likely in Windows. Give it another try with the whole 39927 # argument. 39928 path="$complete" 39929 arguments="EOL" 39930 new_path="$path" 39931 39932 windows_path="$new_path" 39933 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39934 unix_path=`$CYGPATH -u "$windows_path"` 39935 new_path="$unix_path" 39936 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39937 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39938 new_path="$unix_path" 39939 fi 39940 39941 39942 new_path=`$WHICH "$new_path" 2> /dev/null` 39943 # bat and cmd files are not always considered executable in MSYS causing which 39944 # to not find them 39945 if test "x$new_path" = x \ 39946 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39947 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39948 new_path="$path" 39949 39950 windows_path="$new_path" 39951 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39952 unix_path=`$CYGPATH -u "$windows_path"` 39953 new_path="$unix_path" 39954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39955 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39956 new_path="$unix_path" 39957 fi 39958 39959 fi 39960 39961 if test "x$new_path" = x; then 39962 # It's still not found. Now this is an unrecoverable error. 39963 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39964 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39965 has_space=`$ECHO "$complete" | $GREP " "` 39966 if test "x$has_space" != x; then 39967 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39968 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39969 fi 39970 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39971 fi 39972 fi 39973 39974 # Now new_path has a complete unix path to the binary 39975 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39976 # Keep paths in /bin as-is, but remove trailing .exe if any 39977 new_path="${new_path/%.exe/}" 39978 # Do not save /bin paths to all_fixpath_prefixes! 39979 else 39980 # Not in mixed or Windows style, start by that. 39981 new_path=`cmd //c echo $new_path` 39982 39983 input_path="$new_path" 39984 # Check if we need to convert this using DOS-style short mode. If the path 39985 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39986 # take no chances and rewrite it. 39987 # Note: m4 eats our [], so we need to use [ and ] instead. 39988 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39989 if test "x$has_forbidden_chars" != x; then 39990 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39991 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39992 fi 39993 39994 # Output is in $new_path 39995 39996 windows_path="$new_path" 39997 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39998 unix_path=`$CYGPATH -u "$windows_path"` 39999 new_path="$unix_path" 40000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40001 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40002 new_path="$unix_path" 40003 fi 40004 40005 # remove trailing .exe if any 40006 new_path="${new_path/%.exe/}" 40007 40008 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40009 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40010 fi 40011 40012 else 40013 # We're on a unix platform. Hooray! :) 40014 # First separate the path from the arguments. This will split at the first 40015 # space. 40016 complete="$STRIP" 40017 path="${complete%% *}" 40018 tmp="$complete EOL" 40019 arguments="${tmp#* }" 40020 40021 # Cannot rely on the command "which" here since it doesn't always work. 40022 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40023 if test -z "$is_absolute_path"; then 40024 # Path to executable is not absolute. Find it. 40025 IFS_save="$IFS" 40026 IFS=: 40027 for p in $PATH; do 40028 if test -f "$p/$path" && test -x "$p/$path"; then 40029 new_path="$p/$path" 40030 break 40031 fi 40032 done 40033 IFS="$IFS_save" 40034 else 40035 # This is an absolute path, we can use it without further modifications. 40036 new_path="$path" 40037 fi 40038 40039 if test "x$new_path" = x; then 40040 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40041 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40042 has_space=`$ECHO "$complete" | $GREP " "` 40043 if test "x$has_space" != x; then 40044 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40045 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40046 fi 40047 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40048 fi 40049 fi 40050 40051 # Now join together the path and the arguments once again 40052 if test "x$arguments" != xEOL; then 40053 new_complete="$new_path ${arguments% *}" 40054 else 40055 new_complete="$new_path" 40056 fi 40057 40058 if test "x$complete" != "x$new_complete"; then 40059 STRIP="$new_complete" 40060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 40061 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 40062 fi 40063 fi 40064 40065 40066 40067 # Publish this variable in the help. 40068 40069 40070 if [ -z "${NM+x}" ]; then 40071 # The variable is not set by user, try to locate tool using the code snippet 40072 for ac_prog in nm 40073 do 40074 # Extract the first word of "$ac_prog", so it can be a program name with args. 40075 set dummy $ac_prog; ac_word=$2 40076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40077 $as_echo_n "checking for $ac_word... " >&6; } 40078 if ${ac_cv_path_NM+:} false; then : 40079 $as_echo_n "(cached) " >&6 40080 else 40081 case $NM in 40082 [\\/]* | ?:[\\/]*) 40083 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40084 ;; 40085 *) 40086 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40087 for as_dir in $PATH 40088 do 40089 IFS=$as_save_IFS 40090 test -z "$as_dir" && as_dir=. 40091 for ac_exec_ext in '' $ac_executable_extensions; do 40092 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40093 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40094 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40095 break 2 40096 fi 40097 done 40098 done 40099 IFS=$as_save_IFS 40100 40101 ;; 40102 esac 40103 fi 40104 NM=$ac_cv_path_NM 40105 if test -n "$NM"; then 40106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40107 $as_echo "$NM" >&6; } 40108 else 40109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40110 $as_echo "no" >&6; } 40111 fi 40112 40113 40114 test -n "$NM" && break 40115 done 40116 40117 else 40118 # The variable is set, but is it from the command line or the environment? 40119 40120 # Try to remove the string !NM! from our list. 40121 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 40122 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40123 # If it failed, the variable was not from the command line. Ignore it, 40124 # but warn the user (except for BASH, which is always set by the calling BASH). 40125 if test "xNM" != xBASH; then 40126 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 40127 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 40128 fi 40129 # Try to locate tool using the code snippet 40130 for ac_prog in nm 40131 do 40132 # Extract the first word of "$ac_prog", so it can be a program name with args. 40133 set dummy $ac_prog; ac_word=$2 40134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40135 $as_echo_n "checking for $ac_word... " >&6; } 40136 if ${ac_cv_path_NM+:} false; then : 40137 $as_echo_n "(cached) " >&6 40138 else 40139 case $NM in 40140 [\\/]* | ?:[\\/]*) 40141 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40142 ;; 40143 *) 40144 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40145 for as_dir in $PATH 40146 do 40147 IFS=$as_save_IFS 40148 test -z "$as_dir" && as_dir=. 40149 for ac_exec_ext in '' $ac_executable_extensions; do 40150 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40151 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40153 break 2 40154 fi 40155 done 40156 done 40157 IFS=$as_save_IFS 40158 40159 ;; 40160 esac 40161 fi 40162 NM=$ac_cv_path_NM 40163 if test -n "$NM"; then 40164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40165 $as_echo "$NM" >&6; } 40166 else 40167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40168 $as_echo "no" >&6; } 40169 fi 40170 40171 40172 test -n "$NM" && break 40173 done 40174 40175 else 40176 # If it succeeded, then it was overridden by the user. We will use it 40177 # for the tool. 40178 40179 # First remove it from the list of overridden variables, so we can test 40180 # for unknown variables in the end. 40181 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40182 40183 # Check if we try to supply an empty value 40184 if test "x$NM" = x; then 40185 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 40186 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 40187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40188 $as_echo_n "checking for NM... " >&6; } 40189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40190 $as_echo "disabled" >&6; } 40191 else 40192 # Check if the provided tool contains a complete path. 40193 tool_specified="$NM" 40194 tool_basename="${tool_specified##*/}" 40195 if test "x$tool_basename" = "x$tool_specified"; then 40196 # A command without a complete path is provided, search $PATH. 40197 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 40198 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 40199 # Extract the first word of "$tool_basename", so it can be a program name with args. 40200 set dummy $tool_basename; ac_word=$2 40201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40202 $as_echo_n "checking for $ac_word... " >&6; } 40203 if ${ac_cv_path_NM+:} false; then : 40204 $as_echo_n "(cached) " >&6 40205 else 40206 case $NM in 40207 [\\/]* | ?:[\\/]*) 40208 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40209 ;; 40210 *) 40211 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40212 for as_dir in $PATH 40213 do 40214 IFS=$as_save_IFS 40215 test -z "$as_dir" && as_dir=. 40216 for ac_exec_ext in '' $ac_executable_extensions; do 40217 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40218 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40220 break 2 40221 fi 40222 done 40223 done 40224 IFS=$as_save_IFS 40225 40226 ;; 40227 esac 40228 fi 40229 NM=$ac_cv_path_NM 40230 if test -n "$NM"; then 40231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40232 $as_echo "$NM" >&6; } 40233 else 40234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40235 $as_echo "no" >&6; } 40236 fi 40237 40238 40239 if test "x$NM" = x; then 40240 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40241 fi 40242 else 40243 # Otherwise we believe it is a complete path. Use it as it is. 40244 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 40245 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 40246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40247 $as_echo_n "checking for NM... " >&6; } 40248 if test ! -x "$tool_specified"; then 40249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40250 $as_echo "not found" >&6; } 40251 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 40252 fi 40253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40254 $as_echo "$tool_specified" >&6; } 40255 fi 40256 fi 40257 fi 40258 40259 fi 40260 40261 40262 40263 # Only process if variable expands to non-empty 40264 40265 if test "x$NM" != x; then 40266 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40267 40268 # First separate the path from the arguments. This will split at the first 40269 # space. 40270 complete="$NM" 40271 path="${complete%% *}" 40272 tmp="$complete EOL" 40273 arguments="${tmp#* }" 40274 40275 # Input might be given as Windows format, start by converting to 40276 # unix format. 40277 new_path=`$CYGPATH -u "$path"` 40278 40279 # Now try to locate executable using which 40280 new_path=`$WHICH "$new_path" 2> /dev/null` 40281 # bat and cmd files are not always considered executable in cygwin causing which 40282 # to not find them 40283 if test "x$new_path" = x \ 40284 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40285 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40286 new_path=`$CYGPATH -u "$path"` 40287 fi 40288 if test "x$new_path" = x; then 40289 # Oops. Which didn't find the executable. 40290 # The splitting of arguments from the executable at a space might have been incorrect, 40291 # since paths with space are more likely in Windows. Give it another try with the whole 40292 # argument. 40293 path="$complete" 40294 arguments="EOL" 40295 new_path=`$CYGPATH -u "$path"` 40296 new_path=`$WHICH "$new_path" 2> /dev/null` 40297 # bat and cmd files are not always considered executable in cygwin causing which 40298 # to not find them 40299 if test "x$new_path" = x \ 40300 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40301 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40302 new_path=`$CYGPATH -u "$path"` 40303 fi 40304 if test "x$new_path" = x; then 40305 # It's still not found. Now this is an unrecoverable error. 40306 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40307 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40308 has_space=`$ECHO "$complete" | $GREP " "` 40309 if test "x$has_space" != x; then 40310 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40311 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40312 fi 40313 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40314 fi 40315 fi 40316 40317 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40318 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40319 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40320 # "foo.exe" is OK but "foo" is an error. 40321 # 40322 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40323 # It is also a way to make sure we got the proper file name for the real test later on. 40324 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40325 if test "x$test_shortpath" = x; then 40326 # Short path failed, file does not exist as specified. 40327 # Try adding .exe or .cmd 40328 if test -f "${new_path}.exe"; then 40329 input_to_shortpath="${new_path}.exe" 40330 elif test -f "${new_path}.cmd"; then 40331 input_to_shortpath="${new_path}.cmd" 40332 else 40333 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 40334 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 40335 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40336 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40337 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40338 fi 40339 else 40340 input_to_shortpath="$new_path" 40341 fi 40342 40343 # Call helper function which possibly converts this using DOS-style short mode. 40344 # If so, the updated path is stored in $new_path. 40345 new_path="$input_to_shortpath" 40346 40347 input_path="$input_to_shortpath" 40348 # Check if we need to convert this using DOS-style short mode. If the path 40349 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40350 # take no chances and rewrite it. 40351 # Note: m4 eats our [], so we need to use [ and ] instead. 40352 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40353 if test "x$has_forbidden_chars" != x; then 40354 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40355 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40356 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40357 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40358 # Going to short mode and back again did indeed matter. Since short mode is 40359 # case insensitive, let's make it lowercase to improve readability. 40360 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40361 # Now convert it back to Unix-style (cygpath) 40362 input_path=`$CYGPATH -u "$shortmode_path"` 40363 new_path="$input_path" 40364 fi 40365 fi 40366 40367 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40368 if test "x$test_cygdrive_prefix" = x; then 40369 # As a simple fix, exclude /usr/bin since it's not a real path. 40370 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40371 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40372 # a path prefixed by /cygdrive for fixpath to work. 40373 new_path="$CYGWIN_ROOT_PATH$input_path" 40374 fi 40375 fi 40376 40377 # remove trailing .exe if any 40378 new_path="${new_path/%.exe/}" 40379 40380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40381 40382 # First separate the path from the arguments. This will split at the first 40383 # space. 40384 complete="$NM" 40385 path="${complete%% *}" 40386 tmp="$complete EOL" 40387 arguments="${tmp#* }" 40388 40389 # Input might be given as Windows format, start by converting to 40390 # unix format. 40391 new_path="$path" 40392 40393 windows_path="$new_path" 40394 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40395 unix_path=`$CYGPATH -u "$windows_path"` 40396 new_path="$unix_path" 40397 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40398 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40399 new_path="$unix_path" 40400 fi 40401 40402 40403 # Now try to locate executable using which 40404 new_path=`$WHICH "$new_path" 2> /dev/null` 40405 40406 if test "x$new_path" = x; then 40407 # Oops. Which didn't find the executable. 40408 # The splitting of arguments from the executable at a space might have been incorrect, 40409 # since paths with space are more likely in Windows. Give it another try with the whole 40410 # argument. 40411 path="$complete" 40412 arguments="EOL" 40413 new_path="$path" 40414 40415 windows_path="$new_path" 40416 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40417 unix_path=`$CYGPATH -u "$windows_path"` 40418 new_path="$unix_path" 40419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40420 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40421 new_path="$unix_path" 40422 fi 40423 40424 40425 new_path=`$WHICH "$new_path" 2> /dev/null` 40426 # bat and cmd files are not always considered executable in MSYS causing which 40427 # to not find them 40428 if test "x$new_path" = x \ 40429 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40430 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40431 new_path="$path" 40432 40433 windows_path="$new_path" 40434 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40435 unix_path=`$CYGPATH -u "$windows_path"` 40436 new_path="$unix_path" 40437 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40438 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40439 new_path="$unix_path" 40440 fi 40441 40442 fi 40443 40444 if test "x$new_path" = x; then 40445 # It's still not found. Now this is an unrecoverable error. 40446 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40447 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40448 has_space=`$ECHO "$complete" | $GREP " "` 40449 if test "x$has_space" != x; then 40450 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40451 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40452 fi 40453 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40454 fi 40455 fi 40456 40457 # Now new_path has a complete unix path to the binary 40458 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40459 # Keep paths in /bin as-is, but remove trailing .exe if any 40460 new_path="${new_path/%.exe/}" 40461 # Do not save /bin paths to all_fixpath_prefixes! 40462 else 40463 # Not in mixed or Windows style, start by that. 40464 new_path=`cmd //c echo $new_path` 40465 40466 input_path="$new_path" 40467 # Check if we need to convert this using DOS-style short mode. If the path 40468 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40469 # take no chances and rewrite it. 40470 # Note: m4 eats our [], so we need to use [ and ] instead. 40471 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40472 if test "x$has_forbidden_chars" != x; then 40473 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40474 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40475 fi 40476 40477 # Output is in $new_path 40478 40479 windows_path="$new_path" 40480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40481 unix_path=`$CYGPATH -u "$windows_path"` 40482 new_path="$unix_path" 40483 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40484 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40485 new_path="$unix_path" 40486 fi 40487 40488 # remove trailing .exe if any 40489 new_path="${new_path/%.exe/}" 40490 40491 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40492 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40493 fi 40494 40495 else 40496 # We're on a unix platform. Hooray! :) 40497 # First separate the path from the arguments. This will split at the first 40498 # space. 40499 complete="$NM" 40500 path="${complete%% *}" 40501 tmp="$complete EOL" 40502 arguments="${tmp#* }" 40503 40504 # Cannot rely on the command "which" here since it doesn't always work. 40505 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40506 if test -z "$is_absolute_path"; then 40507 # Path to executable is not absolute. Find it. 40508 IFS_save="$IFS" 40509 IFS=: 40510 for p in $PATH; do 40511 if test -f "$p/$path" && test -x "$p/$path"; then 40512 new_path="$p/$path" 40513 break 40514 fi 40515 done 40516 IFS="$IFS_save" 40517 else 40518 # This is an absolute path, we can use it without further modifications. 40519 new_path="$path" 40520 fi 40521 40522 if test "x$new_path" = x; then 40523 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40524 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40525 has_space=`$ECHO "$complete" | $GREP " "` 40526 if test "x$has_space" != x; then 40527 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40528 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40529 fi 40530 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40531 fi 40532 fi 40533 40534 # Now join together the path and the arguments once again 40535 if test "x$arguments" != xEOL; then 40536 new_complete="$new_path ${arguments% *}" 40537 else 40538 new_complete="$new_path" 40539 fi 40540 40541 if test "x$complete" != "x$new_complete"; then 40542 NM="$new_complete" 40543 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 40544 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 40545 fi 40546 fi 40547 40548 40549 40550 # Publish this variable in the help. 40551 40552 40553 if [ -z "${GNM+x}" ]; then 40554 # The variable is not set by user, try to locate tool using the code snippet 40555 for ac_prog in gnm 40556 do 40557 # Extract the first word of "$ac_prog", so it can be a program name with args. 40558 set dummy $ac_prog; ac_word=$2 40559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40560 $as_echo_n "checking for $ac_word... " >&6; } 40561 if ${ac_cv_path_GNM+:} false; then : 40562 $as_echo_n "(cached) " >&6 40563 else 40564 case $GNM in 40565 [\\/]* | ?:[\\/]*) 40566 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40567 ;; 40568 *) 40569 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40570 for as_dir in $PATH 40571 do 40572 IFS=$as_save_IFS 40573 test -z "$as_dir" && as_dir=. 40574 for ac_exec_ext in '' $ac_executable_extensions; do 40575 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40576 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40577 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40578 break 2 40579 fi 40580 done 40581 done 40582 IFS=$as_save_IFS 40583 40584 ;; 40585 esac 40586 fi 40587 GNM=$ac_cv_path_GNM 40588 if test -n "$GNM"; then 40589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40590 $as_echo "$GNM" >&6; } 40591 else 40592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40593 $as_echo "no" >&6; } 40594 fi 40595 40596 40597 test -n "$GNM" && break 40598 done 40599 40600 else 40601 # The variable is set, but is it from the command line or the environment? 40602 40603 # Try to remove the string !GNM! from our list. 40604 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 40605 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40606 # If it failed, the variable was not from the command line. Ignore it, 40607 # but warn the user (except for BASH, which is always set by the calling BASH). 40608 if test "xGNM" != xBASH; then 40609 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 40610 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 40611 fi 40612 # Try to locate tool using the code snippet 40613 for ac_prog in gnm 40614 do 40615 # Extract the first word of "$ac_prog", so it can be a program name with args. 40616 set dummy $ac_prog; ac_word=$2 40617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40618 $as_echo_n "checking for $ac_word... " >&6; } 40619 if ${ac_cv_path_GNM+:} false; then : 40620 $as_echo_n "(cached) " >&6 40621 else 40622 case $GNM in 40623 [\\/]* | ?:[\\/]*) 40624 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40625 ;; 40626 *) 40627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40628 for as_dir in $PATH 40629 do 40630 IFS=$as_save_IFS 40631 test -z "$as_dir" && as_dir=. 40632 for ac_exec_ext in '' $ac_executable_extensions; do 40633 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40634 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40635 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40636 break 2 40637 fi 40638 done 40639 done 40640 IFS=$as_save_IFS 40641 40642 ;; 40643 esac 40644 fi 40645 GNM=$ac_cv_path_GNM 40646 if test -n "$GNM"; then 40647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40648 $as_echo "$GNM" >&6; } 40649 else 40650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40651 $as_echo "no" >&6; } 40652 fi 40653 40654 40655 test -n "$GNM" && break 40656 done 40657 40658 else 40659 # If it succeeded, then it was overridden by the user. We will use it 40660 # for the tool. 40661 40662 # First remove it from the list of overridden variables, so we can test 40663 # for unknown variables in the end. 40664 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40665 40666 # Check if we try to supply an empty value 40667 if test "x$GNM" = x; then 40668 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 40669 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 40670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 40671 $as_echo_n "checking for GNM... " >&6; } 40672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40673 $as_echo "disabled" >&6; } 40674 else 40675 # Check if the provided tool contains a complete path. 40676 tool_specified="$GNM" 40677 tool_basename="${tool_specified##*/}" 40678 if test "x$tool_basename" = "x$tool_specified"; then 40679 # A command without a complete path is provided, search $PATH. 40680 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 40681 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 40682 # Extract the first word of "$tool_basename", so it can be a program name with args. 40683 set dummy $tool_basename; ac_word=$2 40684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40685 $as_echo_n "checking for $ac_word... " >&6; } 40686 if ${ac_cv_path_GNM+:} false; then : 40687 $as_echo_n "(cached) " >&6 40688 else 40689 case $GNM in 40690 [\\/]* | ?:[\\/]*) 40691 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40692 ;; 40693 *) 40694 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40695 for as_dir in $PATH 40696 do 40697 IFS=$as_save_IFS 40698 test -z "$as_dir" && as_dir=. 40699 for ac_exec_ext in '' $ac_executable_extensions; do 40700 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40701 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40702 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40703 break 2 40704 fi 40705 done 40706 done 40707 IFS=$as_save_IFS 40708 40709 ;; 40710 esac 40711 fi 40712 GNM=$ac_cv_path_GNM 40713 if test -n "$GNM"; then 40714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40715 $as_echo "$GNM" >&6; } 40716 else 40717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40718 $as_echo "no" >&6; } 40719 fi 40720 40721 40722 if test "x$GNM" = x; then 40723 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40724 fi 40725 else 40726 # Otherwise we believe it is a complete path. Use it as it is. 40727 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 40728 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 40729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 40730 $as_echo_n "checking for GNM... " >&6; } 40731 if test ! -x "$tool_specified"; then 40732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40733 $as_echo "not found" >&6; } 40734 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 40735 fi 40736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40737 $as_echo "$tool_specified" >&6; } 40738 fi 40739 fi 40740 fi 40741 40742 fi 40743 40744 40745 40746 # Only process if variable expands to non-empty 40747 40748 if test "x$GNM" != x; then 40749 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40750 40751 # First separate the path from the arguments. This will split at the first 40752 # space. 40753 complete="$GNM" 40754 path="${complete%% *}" 40755 tmp="$complete EOL" 40756 arguments="${tmp#* }" 40757 40758 # Input might be given as Windows format, start by converting to 40759 # unix format. 40760 new_path=`$CYGPATH -u "$path"` 40761 40762 # Now try to locate executable using which 40763 new_path=`$WHICH "$new_path" 2> /dev/null` 40764 # bat and cmd files are not always considered executable in cygwin causing which 40765 # to not find them 40766 if test "x$new_path" = x \ 40767 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40768 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40769 new_path=`$CYGPATH -u "$path"` 40770 fi 40771 if test "x$new_path" = x; then 40772 # Oops. Which didn't find the executable. 40773 # The splitting of arguments from the executable at a space might have been incorrect, 40774 # since paths with space are more likely in Windows. Give it another try with the whole 40775 # argument. 40776 path="$complete" 40777 arguments="EOL" 40778 new_path=`$CYGPATH -u "$path"` 40779 new_path=`$WHICH "$new_path" 2> /dev/null` 40780 # bat and cmd files are not always considered executable in cygwin causing which 40781 # to not find them 40782 if test "x$new_path" = x \ 40783 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40784 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40785 new_path=`$CYGPATH -u "$path"` 40786 fi 40787 if test "x$new_path" = x; then 40788 # It's still not found. Now this is an unrecoverable error. 40789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40790 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40791 has_space=`$ECHO "$complete" | $GREP " "` 40792 if test "x$has_space" != x; then 40793 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40794 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40795 fi 40796 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40797 fi 40798 fi 40799 40800 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40801 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40802 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40803 # "foo.exe" is OK but "foo" is an error. 40804 # 40805 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40806 # It is also a way to make sure we got the proper file name for the real test later on. 40807 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40808 if test "x$test_shortpath" = x; then 40809 # Short path failed, file does not exist as specified. 40810 # Try adding .exe or .cmd 40811 if test -f "${new_path}.exe"; then 40812 input_to_shortpath="${new_path}.exe" 40813 elif test -f "${new_path}.cmd"; then 40814 input_to_shortpath="${new_path}.cmd" 40815 else 40816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 40817 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 40818 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40819 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40820 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40821 fi 40822 else 40823 input_to_shortpath="$new_path" 40824 fi 40825 40826 # Call helper function which possibly converts this using DOS-style short mode. 40827 # If so, the updated path is stored in $new_path. 40828 new_path="$input_to_shortpath" 40829 40830 input_path="$input_to_shortpath" 40831 # Check if we need to convert this using DOS-style short mode. If the path 40832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40833 # take no chances and rewrite it. 40834 # Note: m4 eats our [], so we need to use [ and ] instead. 40835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40836 if test "x$has_forbidden_chars" != x; then 40837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40838 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40839 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40840 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40841 # Going to short mode and back again did indeed matter. Since short mode is 40842 # case insensitive, let's make it lowercase to improve readability. 40843 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40844 # Now convert it back to Unix-style (cygpath) 40845 input_path=`$CYGPATH -u "$shortmode_path"` 40846 new_path="$input_path" 40847 fi 40848 fi 40849 40850 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40851 if test "x$test_cygdrive_prefix" = x; then 40852 # As a simple fix, exclude /usr/bin since it's not a real path. 40853 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40854 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40855 # a path prefixed by /cygdrive for fixpath to work. 40856 new_path="$CYGWIN_ROOT_PATH$input_path" 40857 fi 40858 fi 40859 40860 # remove trailing .exe if any 40861 new_path="${new_path/%.exe/}" 40862 40863 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40864 40865 # First separate the path from the arguments. This will split at the first 40866 # space. 40867 complete="$GNM" 40868 path="${complete%% *}" 40869 tmp="$complete EOL" 40870 arguments="${tmp#* }" 40871 40872 # Input might be given as Windows format, start by converting to 40873 # unix format. 40874 new_path="$path" 40875 40876 windows_path="$new_path" 40877 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40878 unix_path=`$CYGPATH -u "$windows_path"` 40879 new_path="$unix_path" 40880 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40881 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40882 new_path="$unix_path" 40883 fi 40884 40885 40886 # Now try to locate executable using which 40887 new_path=`$WHICH "$new_path" 2> /dev/null` 40888 40889 if test "x$new_path" = x; then 40890 # Oops. Which didn't find the executable. 40891 # The splitting of arguments from the executable at a space might have been incorrect, 40892 # since paths with space are more likely in Windows. Give it another try with the whole 40893 # argument. 40894 path="$complete" 40895 arguments="EOL" 40896 new_path="$path" 40897 40898 windows_path="$new_path" 40899 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40900 unix_path=`$CYGPATH -u "$windows_path"` 40901 new_path="$unix_path" 40902 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40903 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40904 new_path="$unix_path" 40905 fi 40906 40907 40908 new_path=`$WHICH "$new_path" 2> /dev/null` 40909 # bat and cmd files are not always considered executable in MSYS causing which 40910 # to not find them 40911 if test "x$new_path" = x \ 40912 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40913 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40914 new_path="$path" 40915 40916 windows_path="$new_path" 40917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40918 unix_path=`$CYGPATH -u "$windows_path"` 40919 new_path="$unix_path" 40920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40921 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40922 new_path="$unix_path" 40923 fi 40924 40925 fi 40926 40927 if test "x$new_path" = x; then 40928 # It's still not found. Now this is an unrecoverable error. 40929 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40930 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40931 has_space=`$ECHO "$complete" | $GREP " "` 40932 if test "x$has_space" != x; then 40933 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40934 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40935 fi 40936 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40937 fi 40938 fi 40939 40940 # Now new_path has a complete unix path to the binary 40941 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40942 # Keep paths in /bin as-is, but remove trailing .exe if any 40943 new_path="${new_path/%.exe/}" 40944 # Do not save /bin paths to all_fixpath_prefixes! 40945 else 40946 # Not in mixed or Windows style, start by that. 40947 new_path=`cmd //c echo $new_path` 40948 40949 input_path="$new_path" 40950 # Check if we need to convert this using DOS-style short mode. If the path 40951 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40952 # take no chances and rewrite it. 40953 # Note: m4 eats our [], so we need to use [ and ] instead. 40954 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40955 if test "x$has_forbidden_chars" != x; then 40956 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40957 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40958 fi 40959 40960 # Output is in $new_path 40961 40962 windows_path="$new_path" 40963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40964 unix_path=`$CYGPATH -u "$windows_path"` 40965 new_path="$unix_path" 40966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40967 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40968 new_path="$unix_path" 40969 fi 40970 40971 # remove trailing .exe if any 40972 new_path="${new_path/%.exe/}" 40973 40974 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40975 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40976 fi 40977 40978 else 40979 # We're on a unix platform. Hooray! :) 40980 # First separate the path from the arguments. This will split at the first 40981 # space. 40982 complete="$GNM" 40983 path="${complete%% *}" 40984 tmp="$complete EOL" 40985 arguments="${tmp#* }" 40986 40987 # Cannot rely on the command "which" here since it doesn't always work. 40988 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40989 if test -z "$is_absolute_path"; then 40990 # Path to executable is not absolute. Find it. 40991 IFS_save="$IFS" 40992 IFS=: 40993 for p in $PATH; do 40994 if test -f "$p/$path" && test -x "$p/$path"; then 40995 new_path="$p/$path" 40996 break 40997 fi 40998 done 40999 IFS="$IFS_save" 41000 else 41001 # This is an absolute path, we can use it without further modifications. 41002 new_path="$path" 41003 fi 41004 41005 if test "x$new_path" = x; then 41006 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41007 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41008 has_space=`$ECHO "$complete" | $GREP " "` 41009 if test "x$has_space" != x; then 41010 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41011 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41012 fi 41013 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41014 fi 41015 fi 41016 41017 # Now join together the path and the arguments once again 41018 if test "x$arguments" != xEOL; then 41019 new_complete="$new_path ${arguments% *}" 41020 else 41021 new_complete="$new_path" 41022 fi 41023 41024 if test "x$complete" != "x$new_complete"; then 41025 GNM="$new_complete" 41026 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 41027 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 41028 fi 41029 fi 41030 41031 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 41032 # FIXME: we should unify this with the solaris case above. 41033 41034 41035 # Publish this variable in the help. 41036 41037 41038 if [ -z "${STRIP+x}" ]; then 41039 # The variable is not set by user, try to locate tool using the code snippet 41040 if test -n "$ac_tool_prefix"; then 41041 for ac_prog in strip 41042 do 41043 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41044 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41046 $as_echo_n "checking for $ac_word... " >&6; } 41047 if ${ac_cv_prog_STRIP+:} false; then : 41048 $as_echo_n "(cached) " >&6 41049 else 41050 if test -n "$STRIP"; then 41051 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41052 else 41053 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41054 for as_dir in $PATH 41055 do 41056 IFS=$as_save_IFS 41057 test -z "$as_dir" && as_dir=. 41058 for ac_exec_ext in '' $ac_executable_extensions; do 41059 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41060 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41061 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41062 break 2 41063 fi 41064 done 41065 done 41066 IFS=$as_save_IFS 41067 41068 fi 41069 fi 41070 STRIP=$ac_cv_prog_STRIP 41071 if test -n "$STRIP"; then 41072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41073 $as_echo "$STRIP" >&6; } 41074 else 41075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41076 $as_echo "no" >&6; } 41077 fi 41078 41079 41080 test -n "$STRIP" && break 41081 done 41082 fi 41083 if test -z "$STRIP"; then 41084 ac_ct_STRIP=$STRIP 41085 for ac_prog in strip 41086 do 41087 # Extract the first word of "$ac_prog", so it can be a program name with args. 41088 set dummy $ac_prog; ac_word=$2 41089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41090 $as_echo_n "checking for $ac_word... " >&6; } 41091 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41092 $as_echo_n "(cached) " >&6 41093 else 41094 if test -n "$ac_ct_STRIP"; then 41095 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41096 else 41097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41098 for as_dir in $PATH 41099 do 41100 IFS=$as_save_IFS 41101 test -z "$as_dir" && as_dir=. 41102 for ac_exec_ext in '' $ac_executable_extensions; do 41103 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41104 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41105 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41106 break 2 41107 fi 41108 done 41109 done 41110 IFS=$as_save_IFS 41111 41112 fi 41113 fi 41114 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41115 if test -n "$ac_ct_STRIP"; then 41116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41117 $as_echo "$ac_ct_STRIP" >&6; } 41118 else 41119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41120 $as_echo "no" >&6; } 41121 fi 41122 41123 41124 test -n "$ac_ct_STRIP" && break 41125 done 41126 41127 if test "x$ac_ct_STRIP" = x; then 41128 STRIP="" 41129 else 41130 case $cross_compiling:$ac_tool_warned in 41131 yes:) 41132 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41133 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41134 ac_tool_warned=yes ;; 41135 esac 41136 STRIP=$ac_ct_STRIP 41137 fi 41138 fi 41139 41140 else 41141 # The variable is set, but is it from the command line or the environment? 41142 41143 # Try to remove the string !STRIP! from our list. 41144 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 41145 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41146 # If it failed, the variable was not from the command line. Ignore it, 41147 # but warn the user (except for BASH, which is always set by the calling BASH). 41148 if test "xSTRIP" != xBASH; then 41149 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 41150 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 41151 fi 41152 # Try to locate tool using the code snippet 41153 if test -n "$ac_tool_prefix"; then 41154 for ac_prog in strip 41155 do 41156 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41157 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41159 $as_echo_n "checking for $ac_word... " >&6; } 41160 if ${ac_cv_prog_STRIP+:} false; then : 41161 $as_echo_n "(cached) " >&6 41162 else 41163 if test -n "$STRIP"; then 41164 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41165 else 41166 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41167 for as_dir in $PATH 41168 do 41169 IFS=$as_save_IFS 41170 test -z "$as_dir" && as_dir=. 41171 for ac_exec_ext in '' $ac_executable_extensions; do 41172 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41173 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41174 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41175 break 2 41176 fi 41177 done 41178 done 41179 IFS=$as_save_IFS 41180 41181 fi 41182 fi 41183 STRIP=$ac_cv_prog_STRIP 41184 if test -n "$STRIP"; then 41185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41186 $as_echo "$STRIP" >&6; } 41187 else 41188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41189 $as_echo "no" >&6; } 41190 fi 41191 41192 41193 test -n "$STRIP" && break 41194 done 41195 fi 41196 if test -z "$STRIP"; then 41197 ac_ct_STRIP=$STRIP 41198 for ac_prog in strip 41199 do 41200 # Extract the first word of "$ac_prog", so it can be a program name with args. 41201 set dummy $ac_prog; ac_word=$2 41202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41203 $as_echo_n "checking for $ac_word... " >&6; } 41204 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41205 $as_echo_n "(cached) " >&6 41206 else 41207 if test -n "$ac_ct_STRIP"; then 41208 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41209 else 41210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41211 for as_dir in $PATH 41212 do 41213 IFS=$as_save_IFS 41214 test -z "$as_dir" && as_dir=. 41215 for ac_exec_ext in '' $ac_executable_extensions; do 41216 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41217 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41218 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41219 break 2 41220 fi 41221 done 41222 done 41223 IFS=$as_save_IFS 41224 41225 fi 41226 fi 41227 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41228 if test -n "$ac_ct_STRIP"; then 41229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41230 $as_echo "$ac_ct_STRIP" >&6; } 41231 else 41232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41233 $as_echo "no" >&6; } 41234 fi 41235 41236 41237 test -n "$ac_ct_STRIP" && break 41238 done 41239 41240 if test "x$ac_ct_STRIP" = x; then 41241 STRIP="" 41242 else 41243 case $cross_compiling:$ac_tool_warned in 41244 yes:) 41245 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41246 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41247 ac_tool_warned=yes ;; 41248 esac 41249 STRIP=$ac_ct_STRIP 41250 fi 41251 fi 41252 41253 else 41254 # If it succeeded, then it was overridden by the user. We will use it 41255 # for the tool. 41256 41257 # First remove it from the list of overridden variables, so we can test 41258 # for unknown variables in the end. 41259 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41260 41261 # Check if we try to supply an empty value 41262 if test "x$STRIP" = x; then 41263 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 41264 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 41265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41266 $as_echo_n "checking for STRIP... " >&6; } 41267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41268 $as_echo "disabled" >&6; } 41269 else 41270 # Check if the provided tool contains a complete path. 41271 tool_specified="$STRIP" 41272 tool_basename="${tool_specified##*/}" 41273 if test "x$tool_basename" = "x$tool_specified"; then 41274 # A command without a complete path is provided, search $PATH. 41275 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 41276 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 41277 # Extract the first word of "$tool_basename", so it can be a program name with args. 41278 set dummy $tool_basename; ac_word=$2 41279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41280 $as_echo_n "checking for $ac_word... " >&6; } 41281 if ${ac_cv_path_STRIP+:} false; then : 41282 $as_echo_n "(cached) " >&6 41283 else 41284 case $STRIP in 41285 [\\/]* | ?:[\\/]*) 41286 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41287 ;; 41288 *) 41289 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41290 for as_dir in $PATH 41291 do 41292 IFS=$as_save_IFS 41293 test -z "$as_dir" && as_dir=. 41294 for ac_exec_ext in '' $ac_executable_extensions; do 41295 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41296 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41297 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41298 break 2 41299 fi 41300 done 41301 done 41302 IFS=$as_save_IFS 41303 41304 ;; 41305 esac 41306 fi 41307 STRIP=$ac_cv_path_STRIP 41308 if test -n "$STRIP"; then 41309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41310 $as_echo "$STRIP" >&6; } 41311 else 41312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41313 $as_echo "no" >&6; } 41314 fi 41315 41316 41317 if test "x$STRIP" = x; then 41318 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41319 fi 41320 else 41321 # Otherwise we believe it is a complete path. Use it as it is. 41322 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 41323 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 41324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41325 $as_echo_n "checking for STRIP... " >&6; } 41326 if test ! -x "$tool_specified"; then 41327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41328 $as_echo "not found" >&6; } 41329 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 41330 fi 41331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41332 $as_echo "$tool_specified" >&6; } 41333 fi 41334 fi 41335 fi 41336 41337 fi 41338 41339 41340 41341 # Only process if variable expands to non-empty 41342 41343 if test "x$STRIP" != x; then 41344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41345 41346 # First separate the path from the arguments. This will split at the first 41347 # space. 41348 complete="$STRIP" 41349 path="${complete%% *}" 41350 tmp="$complete EOL" 41351 arguments="${tmp#* }" 41352 41353 # Input might be given as Windows format, start by converting to 41354 # unix format. 41355 new_path=`$CYGPATH -u "$path"` 41356 41357 # Now try to locate executable using which 41358 new_path=`$WHICH "$new_path" 2> /dev/null` 41359 # bat and cmd files are not always considered executable in cygwin causing which 41360 # to not find them 41361 if test "x$new_path" = x \ 41362 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41363 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41364 new_path=`$CYGPATH -u "$path"` 41365 fi 41366 if test "x$new_path" = x; then 41367 # Oops. Which didn't find the executable. 41368 # The splitting of arguments from the executable at a space might have been incorrect, 41369 # since paths with space are more likely in Windows. Give it another try with the whole 41370 # argument. 41371 path="$complete" 41372 arguments="EOL" 41373 new_path=`$CYGPATH -u "$path"` 41374 new_path=`$WHICH "$new_path" 2> /dev/null` 41375 # bat and cmd files are not always considered executable in cygwin causing which 41376 # to not find them 41377 if test "x$new_path" = x \ 41378 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41379 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41380 new_path=`$CYGPATH -u "$path"` 41381 fi 41382 if test "x$new_path" = x; then 41383 # It's still not found. Now this is an unrecoverable error. 41384 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41385 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41386 has_space=`$ECHO "$complete" | $GREP " "` 41387 if test "x$has_space" != x; then 41388 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41389 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41390 fi 41391 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41392 fi 41393 fi 41394 41395 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41396 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41397 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41398 # "foo.exe" is OK but "foo" is an error. 41399 # 41400 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41401 # It is also a way to make sure we got the proper file name for the real test later on. 41402 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41403 if test "x$test_shortpath" = x; then 41404 # Short path failed, file does not exist as specified. 41405 # Try adding .exe or .cmd 41406 if test -f "${new_path}.exe"; then 41407 input_to_shortpath="${new_path}.exe" 41408 elif test -f "${new_path}.cmd"; then 41409 input_to_shortpath="${new_path}.cmd" 41410 else 41411 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 41412 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 41413 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41414 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41415 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41416 fi 41417 else 41418 input_to_shortpath="$new_path" 41419 fi 41420 41421 # Call helper function which possibly converts this using DOS-style short mode. 41422 # If so, the updated path is stored in $new_path. 41423 new_path="$input_to_shortpath" 41424 41425 input_path="$input_to_shortpath" 41426 # Check if we need to convert this using DOS-style short mode. If the path 41427 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41428 # take no chances and rewrite it. 41429 # Note: m4 eats our [], so we need to use [ and ] instead. 41430 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41431 if test "x$has_forbidden_chars" != x; then 41432 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41433 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41434 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41435 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41436 # Going to short mode and back again did indeed matter. Since short mode is 41437 # case insensitive, let's make it lowercase to improve readability. 41438 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41439 # Now convert it back to Unix-style (cygpath) 41440 input_path=`$CYGPATH -u "$shortmode_path"` 41441 new_path="$input_path" 41442 fi 41443 fi 41444 41445 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41446 if test "x$test_cygdrive_prefix" = x; then 41447 # As a simple fix, exclude /usr/bin since it's not a real path. 41448 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41449 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41450 # a path prefixed by /cygdrive for fixpath to work. 41451 new_path="$CYGWIN_ROOT_PATH$input_path" 41452 fi 41453 fi 41454 41455 # remove trailing .exe if any 41456 new_path="${new_path/%.exe/}" 41457 41458 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41459 41460 # First separate the path from the arguments. This will split at the first 41461 # space. 41462 complete="$STRIP" 41463 path="${complete%% *}" 41464 tmp="$complete EOL" 41465 arguments="${tmp#* }" 41466 41467 # Input might be given as Windows format, start by converting to 41468 # unix format. 41469 new_path="$path" 41470 41471 windows_path="$new_path" 41472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41473 unix_path=`$CYGPATH -u "$windows_path"` 41474 new_path="$unix_path" 41475 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41476 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41477 new_path="$unix_path" 41478 fi 41479 41480 41481 # Now try to locate executable using which 41482 new_path=`$WHICH "$new_path" 2> /dev/null` 41483 41484 if test "x$new_path" = x; then 41485 # Oops. Which didn't find the executable. 41486 # The splitting of arguments from the executable at a space might have been incorrect, 41487 # since paths with space are more likely in Windows. Give it another try with the whole 41488 # argument. 41489 path="$complete" 41490 arguments="EOL" 41491 new_path="$path" 41492 41493 windows_path="$new_path" 41494 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41495 unix_path=`$CYGPATH -u "$windows_path"` 41496 new_path="$unix_path" 41497 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41498 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41499 new_path="$unix_path" 41500 fi 41501 41502 41503 new_path=`$WHICH "$new_path" 2> /dev/null` 41504 # bat and cmd files are not always considered executable in MSYS causing which 41505 # to not find them 41506 if test "x$new_path" = x \ 41507 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41508 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41509 new_path="$path" 41510 41511 windows_path="$new_path" 41512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41513 unix_path=`$CYGPATH -u "$windows_path"` 41514 new_path="$unix_path" 41515 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41516 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41517 new_path="$unix_path" 41518 fi 41519 41520 fi 41521 41522 if test "x$new_path" = x; then 41523 # It's still not found. Now this is an unrecoverable error. 41524 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41525 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41526 has_space=`$ECHO "$complete" | $GREP " "` 41527 if test "x$has_space" != x; then 41528 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41529 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41530 fi 41531 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41532 fi 41533 fi 41534 41535 # Now new_path has a complete unix path to the binary 41536 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41537 # Keep paths in /bin as-is, but remove trailing .exe if any 41538 new_path="${new_path/%.exe/}" 41539 # Do not save /bin paths to all_fixpath_prefixes! 41540 else 41541 # Not in mixed or Windows style, start by that. 41542 new_path=`cmd //c echo $new_path` 41543 41544 input_path="$new_path" 41545 # Check if we need to convert this using DOS-style short mode. If the path 41546 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41547 # take no chances and rewrite it. 41548 # Note: m4 eats our [], so we need to use [ and ] instead. 41549 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41550 if test "x$has_forbidden_chars" != x; then 41551 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41552 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41553 fi 41554 41555 # Output is in $new_path 41556 41557 windows_path="$new_path" 41558 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41559 unix_path=`$CYGPATH -u "$windows_path"` 41560 new_path="$unix_path" 41561 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41562 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41563 new_path="$unix_path" 41564 fi 41565 41566 # remove trailing .exe if any 41567 new_path="${new_path/%.exe/}" 41568 41569 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41570 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41571 fi 41572 41573 else 41574 # We're on a unix platform. Hooray! :) 41575 # First separate the path from the arguments. This will split at the first 41576 # space. 41577 complete="$STRIP" 41578 path="${complete%% *}" 41579 tmp="$complete EOL" 41580 arguments="${tmp#* }" 41581 41582 # Cannot rely on the command "which" here since it doesn't always work. 41583 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41584 if test -z "$is_absolute_path"; then 41585 # Path to executable is not absolute. Find it. 41586 IFS_save="$IFS" 41587 IFS=: 41588 for p in $PATH; do 41589 if test -f "$p/$path" && test -x "$p/$path"; then 41590 new_path="$p/$path" 41591 break 41592 fi 41593 done 41594 IFS="$IFS_save" 41595 else 41596 # This is an absolute path, we can use it without further modifications. 41597 new_path="$path" 41598 fi 41599 41600 if test "x$new_path" = x; then 41601 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41602 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41603 has_space=`$ECHO "$complete" | $GREP " "` 41604 if test "x$has_space" != x; then 41605 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41606 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41607 fi 41608 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41609 fi 41610 fi 41611 41612 # Now join together the path and the arguments once again 41613 if test "x$arguments" != xEOL; then 41614 new_complete="$new_path ${arguments% *}" 41615 else 41616 new_complete="$new_path" 41617 fi 41618 41619 if test "x$complete" != "x$new_complete"; then 41620 STRIP="$new_complete" 41621 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 41622 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 41623 fi 41624 fi 41625 41626 if test "x$TOOLCHAIN_TYPE" = xgcc; then 41627 41628 41629 # Publish this variable in the help. 41630 41631 41632 if [ -z "${NM+x}" ]; then 41633 # The variable is not set by user, try to locate tool using the code snippet 41634 if test -n "$ac_tool_prefix"; then 41635 for ac_prog in nm gcc-nm 41636 do 41637 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41638 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41640 $as_echo_n "checking for $ac_word... " >&6; } 41641 if ${ac_cv_prog_NM+:} false; then : 41642 $as_echo_n "(cached) " >&6 41643 else 41644 if test -n "$NM"; then 41645 ac_cv_prog_NM="$NM" # Let the user override the test. 41646 else 41647 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41648 for as_dir in $PATH 41649 do 41650 IFS=$as_save_IFS 41651 test -z "$as_dir" && as_dir=. 41652 for ac_exec_ext in '' $ac_executable_extensions; do 41653 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41654 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41655 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41656 break 2 41657 fi 41658 done 41659 done 41660 IFS=$as_save_IFS 41661 41662 fi 41663 fi 41664 NM=$ac_cv_prog_NM 41665 if test -n "$NM"; then 41666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41667 $as_echo "$NM" >&6; } 41668 else 41669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41670 $as_echo "no" >&6; } 41671 fi 41672 41673 41674 test -n "$NM" && break 41675 done 41676 fi 41677 if test -z "$NM"; then 41678 ac_ct_NM=$NM 41679 for ac_prog in nm gcc-nm 41680 do 41681 # Extract the first word of "$ac_prog", so it can be a program name with args. 41682 set dummy $ac_prog; ac_word=$2 41683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41684 $as_echo_n "checking for $ac_word... " >&6; } 41685 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41686 $as_echo_n "(cached) " >&6 41687 else 41688 if test -n "$ac_ct_NM"; then 41689 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41690 else 41691 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41692 for as_dir in $PATH 41693 do 41694 IFS=$as_save_IFS 41695 test -z "$as_dir" && as_dir=. 41696 for ac_exec_ext in '' $ac_executable_extensions; do 41697 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41698 ac_cv_prog_ac_ct_NM="$ac_prog" 41699 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41700 break 2 41701 fi 41702 done 41703 done 41704 IFS=$as_save_IFS 41705 41706 fi 41707 fi 41708 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41709 if test -n "$ac_ct_NM"; then 41710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41711 $as_echo "$ac_ct_NM" >&6; } 41712 else 41713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41714 $as_echo "no" >&6; } 41715 fi 41716 41717 41718 test -n "$ac_ct_NM" && break 41719 done 41720 41721 if test "x$ac_ct_NM" = x; then 41722 NM="" 41723 else 41724 case $cross_compiling:$ac_tool_warned in 41725 yes:) 41726 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41727 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41728 ac_tool_warned=yes ;; 41729 esac 41730 NM=$ac_ct_NM 41731 fi 41732 fi 41733 41734 else 41735 # The variable is set, but is it from the command line or the environment? 41736 41737 # Try to remove the string !NM! from our list. 41738 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 41739 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41740 # If it failed, the variable was not from the command line. Ignore it, 41741 # but warn the user (except for BASH, which is always set by the calling BASH). 41742 if test "xNM" != xBASH; then 41743 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 41744 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 41745 fi 41746 # Try to locate tool using the code snippet 41747 if test -n "$ac_tool_prefix"; then 41748 for ac_prog in nm gcc-nm 41749 do 41750 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41751 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41753 $as_echo_n "checking for $ac_word... " >&6; } 41754 if ${ac_cv_prog_NM+:} false; then : 41755 $as_echo_n "(cached) " >&6 41756 else 41757 if test -n "$NM"; then 41758 ac_cv_prog_NM="$NM" # Let the user override the test. 41759 else 41760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41761 for as_dir in $PATH 41762 do 41763 IFS=$as_save_IFS 41764 test -z "$as_dir" && as_dir=. 41765 for ac_exec_ext in '' $ac_executable_extensions; do 41766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41767 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41769 break 2 41770 fi 41771 done 41772 done 41773 IFS=$as_save_IFS 41774 41775 fi 41776 fi 41777 NM=$ac_cv_prog_NM 41778 if test -n "$NM"; then 41779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41780 $as_echo "$NM" >&6; } 41781 else 41782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41783 $as_echo "no" >&6; } 41784 fi 41785 41786 41787 test -n "$NM" && break 41788 done 41789 fi 41790 if test -z "$NM"; then 41791 ac_ct_NM=$NM 41792 for ac_prog in nm gcc-nm 41793 do 41794 # Extract the first word of "$ac_prog", so it can be a program name with args. 41795 set dummy $ac_prog; ac_word=$2 41796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41797 $as_echo_n "checking for $ac_word... " >&6; } 41798 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41799 $as_echo_n "(cached) " >&6 41800 else 41801 if test -n "$ac_ct_NM"; then 41802 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41803 else 41804 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41805 for as_dir in $PATH 41806 do 41807 IFS=$as_save_IFS 41808 test -z "$as_dir" && as_dir=. 41809 for ac_exec_ext in '' $ac_executable_extensions; do 41810 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41811 ac_cv_prog_ac_ct_NM="$ac_prog" 41812 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41813 break 2 41814 fi 41815 done 41816 done 41817 IFS=$as_save_IFS 41818 41819 fi 41820 fi 41821 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41822 if test -n "$ac_ct_NM"; then 41823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41824 $as_echo "$ac_ct_NM" >&6; } 41825 else 41826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41827 $as_echo "no" >&6; } 41828 fi 41829 41830 41831 test -n "$ac_ct_NM" && break 41832 done 41833 41834 if test "x$ac_ct_NM" = x; then 41835 NM="" 41836 else 41837 case $cross_compiling:$ac_tool_warned in 41838 yes:) 41839 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41840 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41841 ac_tool_warned=yes ;; 41842 esac 41843 NM=$ac_ct_NM 41844 fi 41845 fi 41846 41847 else 41848 # If it succeeded, then it was overridden by the user. We will use it 41849 # for the tool. 41850 41851 # First remove it from the list of overridden variables, so we can test 41852 # for unknown variables in the end. 41853 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41854 41855 # Check if we try to supply an empty value 41856 if test "x$NM" = x; then 41857 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41858 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41860 $as_echo_n "checking for NM... " >&6; } 41861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41862 $as_echo "disabled" >&6; } 41863 else 41864 # Check if the provided tool contains a complete path. 41865 tool_specified="$NM" 41866 tool_basename="${tool_specified##*/}" 41867 if test "x$tool_basename" = "x$tool_specified"; then 41868 # A command without a complete path is provided, search $PATH. 41869 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41870 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41871 # Extract the first word of "$tool_basename", so it can be a program name with args. 41872 set dummy $tool_basename; ac_word=$2 41873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41874 $as_echo_n "checking for $ac_word... " >&6; } 41875 if ${ac_cv_path_NM+:} false; then : 41876 $as_echo_n "(cached) " >&6 41877 else 41878 case $NM in 41879 [\\/]* | ?:[\\/]*) 41880 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41881 ;; 41882 *) 41883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41884 for as_dir in $PATH 41885 do 41886 IFS=$as_save_IFS 41887 test -z "$as_dir" && as_dir=. 41888 for ac_exec_ext in '' $ac_executable_extensions; do 41889 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41890 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41891 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41892 break 2 41893 fi 41894 done 41895 done 41896 IFS=$as_save_IFS 41897 41898 ;; 41899 esac 41900 fi 41901 NM=$ac_cv_path_NM 41902 if test -n "$NM"; then 41903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41904 $as_echo "$NM" >&6; } 41905 else 41906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41907 $as_echo "no" >&6; } 41908 fi 41909 41910 41911 if test "x$NM" = x; then 41912 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41913 fi 41914 else 41915 # Otherwise we believe it is a complete path. Use it as it is. 41916 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41917 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41919 $as_echo_n "checking for NM... " >&6; } 41920 if test ! -x "$tool_specified"; then 41921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41922 $as_echo "not found" >&6; } 41923 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41924 fi 41925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41926 $as_echo "$tool_specified" >&6; } 41927 fi 41928 fi 41929 fi 41930 41931 fi 41932 41933 41934 else 41935 41936 41937 # Publish this variable in the help. 41938 41939 41940 if [ -z "${NM+x}" ]; then 41941 # The variable is not set by user, try to locate tool using the code snippet 41942 if test -n "$ac_tool_prefix"; then 41943 for ac_prog in nm 41944 do 41945 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41946 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41948 $as_echo_n "checking for $ac_word... " >&6; } 41949 if ${ac_cv_prog_NM+:} false; then : 41950 $as_echo_n "(cached) " >&6 41951 else 41952 if test -n "$NM"; then 41953 ac_cv_prog_NM="$NM" # Let the user override the test. 41954 else 41955 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41956 for as_dir in $PATH 41957 do 41958 IFS=$as_save_IFS 41959 test -z "$as_dir" && as_dir=. 41960 for ac_exec_ext in '' $ac_executable_extensions; do 41961 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41962 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41963 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41964 break 2 41965 fi 41966 done 41967 done 41968 IFS=$as_save_IFS 41969 41970 fi 41971 fi 41972 NM=$ac_cv_prog_NM 41973 if test -n "$NM"; then 41974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41975 $as_echo "$NM" >&6; } 41976 else 41977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41978 $as_echo "no" >&6; } 41979 fi 41980 41981 41982 test -n "$NM" && break 41983 done 41984 fi 41985 if test -z "$NM"; then 41986 ac_ct_NM=$NM 41987 for ac_prog in nm 41988 do 41989 # Extract the first word of "$ac_prog", so it can be a program name with args. 41990 set dummy $ac_prog; ac_word=$2 41991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41992 $as_echo_n "checking for $ac_word... " >&6; } 41993 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41994 $as_echo_n "(cached) " >&6 41995 else 41996 if test -n "$ac_ct_NM"; then 41997 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41998 else 41999 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42000 for as_dir in $PATH 42001 do 42002 IFS=$as_save_IFS 42003 test -z "$as_dir" && as_dir=. 42004 for ac_exec_ext in '' $ac_executable_extensions; do 42005 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42006 ac_cv_prog_ac_ct_NM="$ac_prog" 42007 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42008 break 2 42009 fi 42010 done 42011 done 42012 IFS=$as_save_IFS 42013 42014 fi 42015 fi 42016 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42017 if test -n "$ac_ct_NM"; then 42018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42019 $as_echo "$ac_ct_NM" >&6; } 42020 else 42021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42022 $as_echo "no" >&6; } 42023 fi 42024 42025 42026 test -n "$ac_ct_NM" && break 42027 done 42028 42029 if test "x$ac_ct_NM" = x; then 42030 NM="" 42031 else 42032 case $cross_compiling:$ac_tool_warned in 42033 yes:) 42034 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42035 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42036 ac_tool_warned=yes ;; 42037 esac 42038 NM=$ac_ct_NM 42039 fi 42040 fi 42041 42042 else 42043 # The variable is set, but is it from the command line or the environment? 42044 42045 # Try to remove the string !NM! from our list. 42046 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42047 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42048 # If it failed, the variable was not from the command line. Ignore it, 42049 # but warn the user (except for BASH, which is always set by the calling BASH). 42050 if test "xNM" != xBASH; then 42051 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42052 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42053 fi 42054 # Try to locate tool using the code snippet 42055 if test -n "$ac_tool_prefix"; then 42056 for ac_prog in nm 42057 do 42058 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42059 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42061 $as_echo_n "checking for $ac_word... " >&6; } 42062 if ${ac_cv_prog_NM+:} false; then : 42063 $as_echo_n "(cached) " >&6 42064 else 42065 if test -n "$NM"; then 42066 ac_cv_prog_NM="$NM" # Let the user override the test. 42067 else 42068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42069 for as_dir in $PATH 42070 do 42071 IFS=$as_save_IFS 42072 test -z "$as_dir" && as_dir=. 42073 for ac_exec_ext in '' $ac_executable_extensions; do 42074 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42075 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42076 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42077 break 2 42078 fi 42079 done 42080 done 42081 IFS=$as_save_IFS 42082 42083 fi 42084 fi 42085 NM=$ac_cv_prog_NM 42086 if test -n "$NM"; then 42087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42088 $as_echo "$NM" >&6; } 42089 else 42090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42091 $as_echo "no" >&6; } 42092 fi 42093 42094 42095 test -n "$NM" && break 42096 done 42097 fi 42098 if test -z "$NM"; then 42099 ac_ct_NM=$NM 42100 for ac_prog in nm 42101 do 42102 # Extract the first word of "$ac_prog", so it can be a program name with args. 42103 set dummy $ac_prog; ac_word=$2 42104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42105 $as_echo_n "checking for $ac_word... " >&6; } 42106 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42107 $as_echo_n "(cached) " >&6 42108 else 42109 if test -n "$ac_ct_NM"; then 42110 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42111 else 42112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42113 for as_dir in $PATH 42114 do 42115 IFS=$as_save_IFS 42116 test -z "$as_dir" && as_dir=. 42117 for ac_exec_ext in '' $ac_executable_extensions; do 42118 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42119 ac_cv_prog_ac_ct_NM="$ac_prog" 42120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42121 break 2 42122 fi 42123 done 42124 done 42125 IFS=$as_save_IFS 42126 42127 fi 42128 fi 42129 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42130 if test -n "$ac_ct_NM"; then 42131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42132 $as_echo "$ac_ct_NM" >&6; } 42133 else 42134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42135 $as_echo "no" >&6; } 42136 fi 42137 42138 42139 test -n "$ac_ct_NM" && break 42140 done 42141 42142 if test "x$ac_ct_NM" = x; then 42143 NM="" 42144 else 42145 case $cross_compiling:$ac_tool_warned in 42146 yes:) 42147 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42148 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42149 ac_tool_warned=yes ;; 42150 esac 42151 NM=$ac_ct_NM 42152 fi 42153 fi 42154 42155 else 42156 # If it succeeded, then it was overridden by the user. We will use it 42157 # for the tool. 42158 42159 # First remove it from the list of overridden variables, so we can test 42160 # for unknown variables in the end. 42161 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42162 42163 # Check if we try to supply an empty value 42164 if test "x$NM" = x; then 42165 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42166 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42168 $as_echo_n "checking for NM... " >&6; } 42169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42170 $as_echo "disabled" >&6; } 42171 else 42172 # Check if the provided tool contains a complete path. 42173 tool_specified="$NM" 42174 tool_basename="${tool_specified##*/}" 42175 if test "x$tool_basename" = "x$tool_specified"; then 42176 # A command without a complete path is provided, search $PATH. 42177 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42178 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42179 # Extract the first word of "$tool_basename", so it can be a program name with args. 42180 set dummy $tool_basename; ac_word=$2 42181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42182 $as_echo_n "checking for $ac_word... " >&6; } 42183 if ${ac_cv_path_NM+:} false; then : 42184 $as_echo_n "(cached) " >&6 42185 else 42186 case $NM in 42187 [\\/]* | ?:[\\/]*) 42188 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42189 ;; 42190 *) 42191 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42192 for as_dir in $PATH 42193 do 42194 IFS=$as_save_IFS 42195 test -z "$as_dir" && as_dir=. 42196 for ac_exec_ext in '' $ac_executable_extensions; do 42197 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42198 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42199 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42200 break 2 42201 fi 42202 done 42203 done 42204 IFS=$as_save_IFS 42205 42206 ;; 42207 esac 42208 fi 42209 NM=$ac_cv_path_NM 42210 if test -n "$NM"; then 42211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42212 $as_echo "$NM" >&6; } 42213 else 42214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42215 $as_echo "no" >&6; } 42216 fi 42217 42218 42219 if test "x$NM" = x; then 42220 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42221 fi 42222 else 42223 # Otherwise we believe it is a complete path. Use it as it is. 42224 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42225 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42227 $as_echo_n "checking for NM... " >&6; } 42228 if test ! -x "$tool_specified"; then 42229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42230 $as_echo "not found" >&6; } 42231 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42232 fi 42233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42234 $as_echo "$tool_specified" >&6; } 42235 fi 42236 fi 42237 fi 42238 42239 fi 42240 42241 42242 fi 42243 42244 # Only process if variable expands to non-empty 42245 42246 if test "x$NM" != x; then 42247 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42248 42249 # First separate the path from the arguments. This will split at the first 42250 # space. 42251 complete="$NM" 42252 path="${complete%% *}" 42253 tmp="$complete EOL" 42254 arguments="${tmp#* }" 42255 42256 # Input might be given as Windows format, start by converting to 42257 # unix format. 42258 new_path=`$CYGPATH -u "$path"` 42259 42260 # Now try to locate executable using which 42261 new_path=`$WHICH "$new_path" 2> /dev/null` 42262 # bat and cmd files are not always considered executable in cygwin causing which 42263 # to not find them 42264 if test "x$new_path" = x \ 42265 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42266 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42267 new_path=`$CYGPATH -u "$path"` 42268 fi 42269 if test "x$new_path" = x; then 42270 # Oops. Which didn't find the executable. 42271 # The splitting of arguments from the executable at a space might have been incorrect, 42272 # since paths with space are more likely in Windows. Give it another try with the whole 42273 # argument. 42274 path="$complete" 42275 arguments="EOL" 42276 new_path=`$CYGPATH -u "$path"` 42277 new_path=`$WHICH "$new_path" 2> /dev/null` 42278 # bat and cmd files are not always considered executable in cygwin causing which 42279 # to not find them 42280 if test "x$new_path" = x \ 42281 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42282 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42283 new_path=`$CYGPATH -u "$path"` 42284 fi 42285 if test "x$new_path" = x; then 42286 # It's still not found. Now this is an unrecoverable error. 42287 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42288 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42289 has_space=`$ECHO "$complete" | $GREP " "` 42290 if test "x$has_space" != x; then 42291 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42292 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42293 fi 42294 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42295 fi 42296 fi 42297 42298 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42299 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42300 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42301 # "foo.exe" is OK but "foo" is an error. 42302 # 42303 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42304 # It is also a way to make sure we got the proper file name for the real test later on. 42305 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42306 if test "x$test_shortpath" = x; then 42307 # Short path failed, file does not exist as specified. 42308 # Try adding .exe or .cmd 42309 if test -f "${new_path}.exe"; then 42310 input_to_shortpath="${new_path}.exe" 42311 elif test -f "${new_path}.cmd"; then 42312 input_to_shortpath="${new_path}.cmd" 42313 else 42314 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 42315 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 42316 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42317 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42318 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42319 fi 42320 else 42321 input_to_shortpath="$new_path" 42322 fi 42323 42324 # Call helper function which possibly converts this using DOS-style short mode. 42325 # If so, the updated path is stored in $new_path. 42326 new_path="$input_to_shortpath" 42327 42328 input_path="$input_to_shortpath" 42329 # Check if we need to convert this using DOS-style short mode. If the path 42330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42331 # take no chances and rewrite it. 42332 # Note: m4 eats our [], so we need to use [ and ] instead. 42333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42334 if test "x$has_forbidden_chars" != x; then 42335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42336 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42337 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42338 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42339 # Going to short mode and back again did indeed matter. Since short mode is 42340 # case insensitive, let's make it lowercase to improve readability. 42341 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42342 # Now convert it back to Unix-style (cygpath) 42343 input_path=`$CYGPATH -u "$shortmode_path"` 42344 new_path="$input_path" 42345 fi 42346 fi 42347 42348 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42349 if test "x$test_cygdrive_prefix" = x; then 42350 # As a simple fix, exclude /usr/bin since it's not a real path. 42351 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42352 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42353 # a path prefixed by /cygdrive for fixpath to work. 42354 new_path="$CYGWIN_ROOT_PATH$input_path" 42355 fi 42356 fi 42357 42358 # remove trailing .exe if any 42359 new_path="${new_path/%.exe/}" 42360 42361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42362 42363 # First separate the path from the arguments. This will split at the first 42364 # space. 42365 complete="$NM" 42366 path="${complete%% *}" 42367 tmp="$complete EOL" 42368 arguments="${tmp#* }" 42369 42370 # Input might be given as Windows format, start by converting to 42371 # unix format. 42372 new_path="$path" 42373 42374 windows_path="$new_path" 42375 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42376 unix_path=`$CYGPATH -u "$windows_path"` 42377 new_path="$unix_path" 42378 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42379 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42380 new_path="$unix_path" 42381 fi 42382 42383 42384 # Now try to locate executable using which 42385 new_path=`$WHICH "$new_path" 2> /dev/null` 42386 42387 if test "x$new_path" = x; then 42388 # Oops. Which didn't find the executable. 42389 # The splitting of arguments from the executable at a space might have been incorrect, 42390 # since paths with space are more likely in Windows. Give it another try with the whole 42391 # argument. 42392 path="$complete" 42393 arguments="EOL" 42394 new_path="$path" 42395 42396 windows_path="$new_path" 42397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42398 unix_path=`$CYGPATH -u "$windows_path"` 42399 new_path="$unix_path" 42400 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42401 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42402 new_path="$unix_path" 42403 fi 42404 42405 42406 new_path=`$WHICH "$new_path" 2> /dev/null` 42407 # bat and cmd files are not always considered executable in MSYS causing which 42408 # to not find them 42409 if test "x$new_path" = x \ 42410 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42411 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42412 new_path="$path" 42413 42414 windows_path="$new_path" 42415 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42416 unix_path=`$CYGPATH -u "$windows_path"` 42417 new_path="$unix_path" 42418 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42419 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42420 new_path="$unix_path" 42421 fi 42422 42423 fi 42424 42425 if test "x$new_path" = x; then 42426 # It's still not found. Now this is an unrecoverable error. 42427 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42428 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42429 has_space=`$ECHO "$complete" | $GREP " "` 42430 if test "x$has_space" != x; then 42431 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42432 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42433 fi 42434 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42435 fi 42436 fi 42437 42438 # Now new_path has a complete unix path to the binary 42439 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42440 # Keep paths in /bin as-is, but remove trailing .exe if any 42441 new_path="${new_path/%.exe/}" 42442 # Do not save /bin paths to all_fixpath_prefixes! 42443 else 42444 # Not in mixed or Windows style, start by that. 42445 new_path=`cmd //c echo $new_path` 42446 42447 input_path="$new_path" 42448 # Check if we need to convert this using DOS-style short mode. If the path 42449 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42450 # take no chances and rewrite it. 42451 # Note: m4 eats our [], so we need to use [ and ] instead. 42452 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42453 if test "x$has_forbidden_chars" != x; then 42454 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42455 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42456 fi 42457 42458 # Output is in $new_path 42459 42460 windows_path="$new_path" 42461 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42462 unix_path=`$CYGPATH -u "$windows_path"` 42463 new_path="$unix_path" 42464 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42465 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42466 new_path="$unix_path" 42467 fi 42468 42469 # remove trailing .exe if any 42470 new_path="${new_path/%.exe/}" 42471 42472 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42473 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42474 fi 42475 42476 else 42477 # We're on a unix platform. Hooray! :) 42478 # First separate the path from the arguments. This will split at the first 42479 # space. 42480 complete="$NM" 42481 path="${complete%% *}" 42482 tmp="$complete EOL" 42483 arguments="${tmp#* }" 42484 42485 # Cannot rely on the command "which" here since it doesn't always work. 42486 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42487 if test -z "$is_absolute_path"; then 42488 # Path to executable is not absolute. Find it. 42489 IFS_save="$IFS" 42490 IFS=: 42491 for p in $PATH; do 42492 if test -f "$p/$path" && test -x "$p/$path"; then 42493 new_path="$p/$path" 42494 break 42495 fi 42496 done 42497 IFS="$IFS_save" 42498 else 42499 # This is an absolute path, we can use it without further modifications. 42500 new_path="$path" 42501 fi 42502 42503 if test "x$new_path" = x; then 42504 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42505 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42506 has_space=`$ECHO "$complete" | $GREP " "` 42507 if test "x$has_space" != x; then 42508 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42509 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42510 fi 42511 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42512 fi 42513 fi 42514 42515 # Now join together the path and the arguments once again 42516 if test "x$arguments" != xEOL; then 42517 new_complete="$new_path ${arguments% *}" 42518 else 42519 new_complete="$new_path" 42520 fi 42521 42522 if test "x$complete" != "x$new_complete"; then 42523 NM="$new_complete" 42524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 42525 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 42526 fi 42527 fi 42528 42529 GNM="$NM" 42530 42531 fi 42532 42533 # objcopy is used for moving debug symbols to separate files when 42534 # full debug symbols are enabled. 42535 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 42536 42537 42538 # Publish this variable in the help. 42539 42540 42541 if [ -z "${OBJCOPY+x}" ]; then 42542 # The variable is not set by user, try to locate tool using the code snippet 42543 if test -n "$ac_tool_prefix"; then 42544 for ac_prog in gobjcopy objcopy 42545 do 42546 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42547 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42549 $as_echo_n "checking for $ac_word... " >&6; } 42550 if ${ac_cv_prog_OBJCOPY+:} false; then : 42551 $as_echo_n "(cached) " >&6 42552 else 42553 if test -n "$OBJCOPY"; then 42554 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 42555 else 42556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42557 for as_dir in $PATH 42558 do 42559 IFS=$as_save_IFS 42560 test -z "$as_dir" && as_dir=. 42561 for ac_exec_ext in '' $ac_executable_extensions; do 42562 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42563 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 42564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42565 break 2 42566 fi 42567 done 42568 done 42569 IFS=$as_save_IFS 42570 42571 fi 42572 fi 42573 OBJCOPY=$ac_cv_prog_OBJCOPY 42574 if test -n "$OBJCOPY"; then 42575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42576 $as_echo "$OBJCOPY" >&6; } 42577 else 42578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42579 $as_echo "no" >&6; } 42580 fi 42581 42582 42583 test -n "$OBJCOPY" && break 42584 done 42585 fi 42586 if test -z "$OBJCOPY"; then 42587 ac_ct_OBJCOPY=$OBJCOPY 42588 for ac_prog in gobjcopy objcopy 42589 do 42590 # Extract the first word of "$ac_prog", so it can be a program name with args. 42591 set dummy $ac_prog; ac_word=$2 42592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42593 $as_echo_n "checking for $ac_word... " >&6; } 42594 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 42595 $as_echo_n "(cached) " >&6 42596 else 42597 if test -n "$ac_ct_OBJCOPY"; then 42598 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 42599 else 42600 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42601 for as_dir in $PATH 42602 do 42603 IFS=$as_save_IFS 42604 test -z "$as_dir" && as_dir=. 42605 for ac_exec_ext in '' $ac_executable_extensions; do 42606 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42607 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 42608 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42609 break 2 42610 fi 42611 done 42612 done 42613 IFS=$as_save_IFS 42614 42615 fi 42616 fi 42617 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 42618 if test -n "$ac_ct_OBJCOPY"; then 42619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 42620 $as_echo "$ac_ct_OBJCOPY" >&6; } 42621 else 42622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42623 $as_echo "no" >&6; } 42624 fi 42625 42626 42627 test -n "$ac_ct_OBJCOPY" && break 42628 done 42629 42630 if test "x$ac_ct_OBJCOPY" = x; then 42631 OBJCOPY="" 42632 else 42633 case $cross_compiling:$ac_tool_warned in 42634 yes:) 42635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42636 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42637 ac_tool_warned=yes ;; 42638 esac 42639 OBJCOPY=$ac_ct_OBJCOPY 42640 fi 42641 fi 42642 42643 else 42644 # The variable is set, but is it from the command line or the environment? 42645 42646 # Try to remove the string !OBJCOPY! from our list. 42647 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 42648 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42649 # If it failed, the variable was not from the command line. Ignore it, 42650 # but warn the user (except for BASH, which is always set by the calling BASH). 42651 if test "xOBJCOPY" != xBASH; then 42652 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 42653 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 42654 fi 42655 # Try to locate tool using the code snippet 42656 if test -n "$ac_tool_prefix"; then 42657 for ac_prog in gobjcopy objcopy 42658 do 42659 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42660 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42662 $as_echo_n "checking for $ac_word... " >&6; } 42663 if ${ac_cv_prog_OBJCOPY+:} false; then : 42664 $as_echo_n "(cached) " >&6 42665 else 42666 if test -n "$OBJCOPY"; then 42667 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 42668 else 42669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42670 for as_dir in $PATH 42671 do 42672 IFS=$as_save_IFS 42673 test -z "$as_dir" && as_dir=. 42674 for ac_exec_ext in '' $ac_executable_extensions; do 42675 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42676 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 42677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42678 break 2 42679 fi 42680 done 42681 done 42682 IFS=$as_save_IFS 42683 42684 fi 42685 fi 42686 OBJCOPY=$ac_cv_prog_OBJCOPY 42687 if test -n "$OBJCOPY"; then 42688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42689 $as_echo "$OBJCOPY" >&6; } 42690 else 42691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42692 $as_echo "no" >&6; } 42693 fi 42694 42695 42696 test -n "$OBJCOPY" && break 42697 done 42698 fi 42699 if test -z "$OBJCOPY"; then 42700 ac_ct_OBJCOPY=$OBJCOPY 42701 for ac_prog in gobjcopy objcopy 42702 do 42703 # Extract the first word of "$ac_prog", so it can be a program name with args. 42704 set dummy $ac_prog; ac_word=$2 42705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42706 $as_echo_n "checking for $ac_word... " >&6; } 42707 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 42708 $as_echo_n "(cached) " >&6 42709 else 42710 if test -n "$ac_ct_OBJCOPY"; then 42711 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 42712 else 42713 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42714 for as_dir in $PATH 42715 do 42716 IFS=$as_save_IFS 42717 test -z "$as_dir" && as_dir=. 42718 for ac_exec_ext in '' $ac_executable_extensions; do 42719 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42720 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 42721 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42722 break 2 42723 fi 42724 done 42725 done 42726 IFS=$as_save_IFS 42727 42728 fi 42729 fi 42730 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 42731 if test -n "$ac_ct_OBJCOPY"; then 42732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 42733 $as_echo "$ac_ct_OBJCOPY" >&6; } 42734 else 42735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42736 $as_echo "no" >&6; } 42737 fi 42738 42739 42740 test -n "$ac_ct_OBJCOPY" && break 42741 done 42742 42743 if test "x$ac_ct_OBJCOPY" = x; then 42744 OBJCOPY="" 42745 else 42746 case $cross_compiling:$ac_tool_warned in 42747 yes:) 42748 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42749 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42750 ac_tool_warned=yes ;; 42751 esac 42752 OBJCOPY=$ac_ct_OBJCOPY 42753 fi 42754 fi 42755 42756 else 42757 # If it succeeded, then it was overridden by the user. We will use it 42758 # for the tool. 42759 42760 # First remove it from the list of overridden variables, so we can test 42761 # for unknown variables in the end. 42762 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42763 42764 # Check if we try to supply an empty value 42765 if test "x$OBJCOPY" = x; then 42766 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 42767 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 42768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42769 $as_echo_n "checking for OBJCOPY... " >&6; } 42770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42771 $as_echo "disabled" >&6; } 42772 else 42773 # Check if the provided tool contains a complete path. 42774 tool_specified="$OBJCOPY" 42775 tool_basename="${tool_specified##*/}" 42776 if test "x$tool_basename" = "x$tool_specified"; then 42777 # A command without a complete path is provided, search $PATH. 42778 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 42779 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 42780 # Extract the first word of "$tool_basename", so it can be a program name with args. 42781 set dummy $tool_basename; ac_word=$2 42782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42783 $as_echo_n "checking for $ac_word... " >&6; } 42784 if ${ac_cv_path_OBJCOPY+:} false; then : 42785 $as_echo_n "(cached) " >&6 42786 else 42787 case $OBJCOPY in 42788 [\\/]* | ?:[\\/]*) 42789 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 42790 ;; 42791 *) 42792 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42793 for as_dir in $PATH 42794 do 42795 IFS=$as_save_IFS 42796 test -z "$as_dir" && as_dir=. 42797 for ac_exec_ext in '' $ac_executable_extensions; do 42798 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42799 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 42800 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42801 break 2 42802 fi 42803 done 42804 done 42805 IFS=$as_save_IFS 42806 42807 ;; 42808 esac 42809 fi 42810 OBJCOPY=$ac_cv_path_OBJCOPY 42811 if test -n "$OBJCOPY"; then 42812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42813 $as_echo "$OBJCOPY" >&6; } 42814 else 42815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42816 $as_echo "no" >&6; } 42817 fi 42818 42819 42820 if test "x$OBJCOPY" = x; then 42821 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42822 fi 42823 else 42824 # Otherwise we believe it is a complete path. Use it as it is. 42825 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 42826 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 42827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42828 $as_echo_n "checking for OBJCOPY... " >&6; } 42829 if test ! -x "$tool_specified"; then 42830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42831 $as_echo "not found" >&6; } 42832 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 42833 fi 42834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42835 $as_echo "$tool_specified" >&6; } 42836 fi 42837 fi 42838 fi 42839 42840 fi 42841 42842 42843 # Only call fixup if objcopy was found. 42844 if test -n "$OBJCOPY"; then 42845 42846 # Only process if variable expands to non-empty 42847 42848 if test "x$OBJCOPY" != x; then 42849 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42850 42851 # First separate the path from the arguments. This will split at the first 42852 # space. 42853 complete="$OBJCOPY" 42854 path="${complete%% *}" 42855 tmp="$complete EOL" 42856 arguments="${tmp#* }" 42857 42858 # Input might be given as Windows format, start by converting to 42859 # unix format. 42860 new_path=`$CYGPATH -u "$path"` 42861 42862 # Now try to locate executable using which 42863 new_path=`$WHICH "$new_path" 2> /dev/null` 42864 # bat and cmd files are not always considered executable in cygwin causing which 42865 # to not find them 42866 if test "x$new_path" = x \ 42867 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42868 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42869 new_path=`$CYGPATH -u "$path"` 42870 fi 42871 if test "x$new_path" = x; then 42872 # Oops. Which didn't find the executable. 42873 # The splitting of arguments from the executable at a space might have been incorrect, 42874 # since paths with space are more likely in Windows. Give it another try with the whole 42875 # argument. 42876 path="$complete" 42877 arguments="EOL" 42878 new_path=`$CYGPATH -u "$path"` 42879 new_path=`$WHICH "$new_path" 2> /dev/null` 42880 # bat and cmd files are not always considered executable in cygwin causing which 42881 # to not find them 42882 if test "x$new_path" = x \ 42883 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42884 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42885 new_path=`$CYGPATH -u "$path"` 42886 fi 42887 if test "x$new_path" = x; then 42888 # It's still not found. Now this is an unrecoverable error. 42889 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 42890 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 42891 has_space=`$ECHO "$complete" | $GREP " "` 42892 if test "x$has_space" != x; then 42893 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42894 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42895 fi 42896 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42897 fi 42898 fi 42899 42900 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42901 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42902 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42903 # "foo.exe" is OK but "foo" is an error. 42904 # 42905 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42906 # It is also a way to make sure we got the proper file name for the real test later on. 42907 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42908 if test "x$test_shortpath" = x; then 42909 # Short path failed, file does not exist as specified. 42910 # Try adding .exe or .cmd 42911 if test -f "${new_path}.exe"; then 42912 input_to_shortpath="${new_path}.exe" 42913 elif test -f "${new_path}.cmd"; then 42914 input_to_shortpath="${new_path}.cmd" 42915 else 42916 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 42917 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 42918 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42919 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42920 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42921 fi 42922 else 42923 input_to_shortpath="$new_path" 42924 fi 42925 42926 # Call helper function which possibly converts this using DOS-style short mode. 42927 # If so, the updated path is stored in $new_path. 42928 new_path="$input_to_shortpath" 42929 42930 input_path="$input_to_shortpath" 42931 # Check if we need to convert this using DOS-style short mode. If the path 42932 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42933 # take no chances and rewrite it. 42934 # Note: m4 eats our [], so we need to use [ and ] instead. 42935 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42936 if test "x$has_forbidden_chars" != x; then 42937 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42938 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42939 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42940 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42941 # Going to short mode and back again did indeed matter. Since short mode is 42942 # case insensitive, let's make it lowercase to improve readability. 42943 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42944 # Now convert it back to Unix-style (cygpath) 42945 input_path=`$CYGPATH -u "$shortmode_path"` 42946 new_path="$input_path" 42947 fi 42948 fi 42949 42950 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42951 if test "x$test_cygdrive_prefix" = x; then 42952 # As a simple fix, exclude /usr/bin since it's not a real path. 42953 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42954 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42955 # a path prefixed by /cygdrive for fixpath to work. 42956 new_path="$CYGWIN_ROOT_PATH$input_path" 42957 fi 42958 fi 42959 42960 # remove trailing .exe if any 42961 new_path="${new_path/%.exe/}" 42962 42963 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42964 42965 # First separate the path from the arguments. This will split at the first 42966 # space. 42967 complete="$OBJCOPY" 42968 path="${complete%% *}" 42969 tmp="$complete EOL" 42970 arguments="${tmp#* }" 42971 42972 # Input might be given as Windows format, start by converting to 42973 # unix format. 42974 new_path="$path" 42975 42976 windows_path="$new_path" 42977 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42978 unix_path=`$CYGPATH -u "$windows_path"` 42979 new_path="$unix_path" 42980 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42981 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42982 new_path="$unix_path" 42983 fi 42984 42985 42986 # Now try to locate executable using which 42987 new_path=`$WHICH "$new_path" 2> /dev/null` 42988 42989 if test "x$new_path" = x; then 42990 # Oops. Which didn't find the executable. 42991 # The splitting of arguments from the executable at a space might have been incorrect, 42992 # since paths with space are more likely in Windows. Give it another try with the whole 42993 # argument. 42994 path="$complete" 42995 arguments="EOL" 42996 new_path="$path" 42997 42998 windows_path="$new_path" 42999 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43000 unix_path=`$CYGPATH -u "$windows_path"` 43001 new_path="$unix_path" 43002 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43003 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43004 new_path="$unix_path" 43005 fi 43006 43007 43008 new_path=`$WHICH "$new_path" 2> /dev/null` 43009 # bat and cmd files are not always considered executable in MSYS causing which 43010 # to not find them 43011 if test "x$new_path" = x \ 43012 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43013 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43014 new_path="$path" 43015 43016 windows_path="$new_path" 43017 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43018 unix_path=`$CYGPATH -u "$windows_path"` 43019 new_path="$unix_path" 43020 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43021 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43022 new_path="$unix_path" 43023 fi 43024 43025 fi 43026 43027 if test "x$new_path" = x; then 43028 # It's still not found. Now this is an unrecoverable error. 43029 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43030 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43031 has_space=`$ECHO "$complete" | $GREP " "` 43032 if test "x$has_space" != x; then 43033 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43034 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43035 fi 43036 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43037 fi 43038 fi 43039 43040 # Now new_path has a complete unix path to the binary 43041 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43042 # Keep paths in /bin as-is, but remove trailing .exe if any 43043 new_path="${new_path/%.exe/}" 43044 # Do not save /bin paths to all_fixpath_prefixes! 43045 else 43046 # Not in mixed or Windows style, start by that. 43047 new_path=`cmd //c echo $new_path` 43048 43049 input_path="$new_path" 43050 # Check if we need to convert this using DOS-style short mode. If the path 43051 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43052 # take no chances and rewrite it. 43053 # Note: m4 eats our [], so we need to use [ and ] instead. 43054 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43055 if test "x$has_forbidden_chars" != x; then 43056 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43057 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43058 fi 43059 43060 # Output is in $new_path 43061 43062 windows_path="$new_path" 43063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43064 unix_path=`$CYGPATH -u "$windows_path"` 43065 new_path="$unix_path" 43066 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43067 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43068 new_path="$unix_path" 43069 fi 43070 43071 # remove trailing .exe if any 43072 new_path="${new_path/%.exe/}" 43073 43074 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43075 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43076 fi 43077 43078 else 43079 # We're on a unix platform. Hooray! :) 43080 # First separate the path from the arguments. This will split at the first 43081 # space. 43082 complete="$OBJCOPY" 43083 path="${complete%% *}" 43084 tmp="$complete EOL" 43085 arguments="${tmp#* }" 43086 43087 # Cannot rely on the command "which" here since it doesn't always work. 43088 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43089 if test -z "$is_absolute_path"; then 43090 # Path to executable is not absolute. Find it. 43091 IFS_save="$IFS" 43092 IFS=: 43093 for p in $PATH; do 43094 if test -f "$p/$path" && test -x "$p/$path"; then 43095 new_path="$p/$path" 43096 break 43097 fi 43098 done 43099 IFS="$IFS_save" 43100 else 43101 # This is an absolute path, we can use it without further modifications. 43102 new_path="$path" 43103 fi 43104 43105 if test "x$new_path" = x; then 43106 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43107 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43108 has_space=`$ECHO "$complete" | $GREP " "` 43109 if test "x$has_space" != x; then 43110 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43111 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43112 fi 43113 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43114 fi 43115 fi 43116 43117 # Now join together the path and the arguments once again 43118 if test "x$arguments" != xEOL; then 43119 new_complete="$new_path ${arguments% *}" 43120 else 43121 new_complete="$new_path" 43122 fi 43123 43124 if test "x$complete" != "x$new_complete"; then 43125 OBJCOPY="$new_complete" 43126 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 43127 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 43128 fi 43129 fi 43130 43131 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 43132 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 43133 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 43134 # - version number is last blank separate word on first line 43135 # - version number formats that have been seen: 43136 # - <major>.<minor> 43137 # - <major>.<minor>.<micro> 43138 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 43139 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 43140 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 43141 -e 's/.* //' \ 43142 -e '/^[01]\./b bad' \ 43143 -e '/^2\./{' \ 43144 -e ' s/^2\.//' \ 43145 -e ' /^[0-9]$/b bad' \ 43146 -e ' /^[0-9]\./b bad' \ 43147 -e ' /^1[0-9]$/b bad' \ 43148 -e ' /^1[0-9]\./b bad' \ 43149 -e ' /^20\./b bad' \ 43150 -e ' /^21\.0$/b bad' \ 43151 -e ' /^21\.0\./b bad' \ 43152 -e '}' \ 43153 -e ':good' \ 43154 -e 's/.*/VALID_VERSION/p' \ 43155 -e 'q' \ 43156 -e ':bad' \ 43157 -e 's/.*/BAD_VERSION/p' \ 43158 -e 'q'` 43159 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 43160 OBJCOPY= 43161 { $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 43162 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 43163 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 43164 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 43165 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 43166 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 43167 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 43168 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 43169 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 43170 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 43171 fi 43172 fi 43173 fi 43174 fi 43175 43176 43177 43178 # Publish this variable in the help. 43179 43180 43181 if [ -z "${OBJDUMP+x}" ]; then 43182 # The variable is not set by user, try to locate tool using the code snippet 43183 if test -n "$ac_tool_prefix"; then 43184 for ac_prog in gobjdump objdump 43185 do 43186 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43187 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43189 $as_echo_n "checking for $ac_word... " >&6; } 43190 if ${ac_cv_prog_OBJDUMP+:} false; then : 43191 $as_echo_n "(cached) " >&6 43192 else 43193 if test -n "$OBJDUMP"; then 43194 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43195 else 43196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43197 for as_dir in $PATH 43198 do 43199 IFS=$as_save_IFS 43200 test -z "$as_dir" && as_dir=. 43201 for ac_exec_ext in '' $ac_executable_extensions; do 43202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43203 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43205 break 2 43206 fi 43207 done 43208 done 43209 IFS=$as_save_IFS 43210 43211 fi 43212 fi 43213 OBJDUMP=$ac_cv_prog_OBJDUMP 43214 if test -n "$OBJDUMP"; then 43215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43216 $as_echo "$OBJDUMP" >&6; } 43217 else 43218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43219 $as_echo "no" >&6; } 43220 fi 43221 43222 43223 test -n "$OBJDUMP" && break 43224 done 43225 fi 43226 if test -z "$OBJDUMP"; then 43227 ac_ct_OBJDUMP=$OBJDUMP 43228 for ac_prog in gobjdump objdump 43229 do 43230 # Extract the first word of "$ac_prog", so it can be a program name with args. 43231 set dummy $ac_prog; ac_word=$2 43232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43233 $as_echo_n "checking for $ac_word... " >&6; } 43234 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43235 $as_echo_n "(cached) " >&6 43236 else 43237 if test -n "$ac_ct_OBJDUMP"; then 43238 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43239 else 43240 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43241 for as_dir in $PATH 43242 do 43243 IFS=$as_save_IFS 43244 test -z "$as_dir" && as_dir=. 43245 for ac_exec_ext in '' $ac_executable_extensions; do 43246 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43247 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43248 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43249 break 2 43250 fi 43251 done 43252 done 43253 IFS=$as_save_IFS 43254 43255 fi 43256 fi 43257 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43258 if test -n "$ac_ct_OBJDUMP"; then 43259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43260 $as_echo "$ac_ct_OBJDUMP" >&6; } 43261 else 43262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43263 $as_echo "no" >&6; } 43264 fi 43265 43266 43267 test -n "$ac_ct_OBJDUMP" && break 43268 done 43269 43270 if test "x$ac_ct_OBJDUMP" = x; then 43271 OBJDUMP="" 43272 else 43273 case $cross_compiling:$ac_tool_warned in 43274 yes:) 43275 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43276 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43277 ac_tool_warned=yes ;; 43278 esac 43279 OBJDUMP=$ac_ct_OBJDUMP 43280 fi 43281 fi 43282 43283 else 43284 # The variable is set, but is it from the command line or the environment? 43285 43286 # Try to remove the string !OBJDUMP! from our list. 43287 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 43288 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43289 # If it failed, the variable was not from the command line. Ignore it, 43290 # but warn the user (except for BASH, which is always set by the calling BASH). 43291 if test "xOBJDUMP" != xBASH; then 43292 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 43293 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 43294 fi 43295 # Try to locate tool using the code snippet 43296 if test -n "$ac_tool_prefix"; then 43297 for ac_prog in gobjdump objdump 43298 do 43299 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43300 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43302 $as_echo_n "checking for $ac_word... " >&6; } 43303 if ${ac_cv_prog_OBJDUMP+:} false; then : 43304 $as_echo_n "(cached) " >&6 43305 else 43306 if test -n "$OBJDUMP"; then 43307 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43308 else 43309 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43310 for as_dir in $PATH 43311 do 43312 IFS=$as_save_IFS 43313 test -z "$as_dir" && as_dir=. 43314 for ac_exec_ext in '' $ac_executable_extensions; do 43315 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43316 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43317 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43318 break 2 43319 fi 43320 done 43321 done 43322 IFS=$as_save_IFS 43323 43324 fi 43325 fi 43326 OBJDUMP=$ac_cv_prog_OBJDUMP 43327 if test -n "$OBJDUMP"; then 43328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43329 $as_echo "$OBJDUMP" >&6; } 43330 else 43331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43332 $as_echo "no" >&6; } 43333 fi 43334 43335 43336 test -n "$OBJDUMP" && break 43337 done 43338 fi 43339 if test -z "$OBJDUMP"; then 43340 ac_ct_OBJDUMP=$OBJDUMP 43341 for ac_prog in gobjdump objdump 43342 do 43343 # Extract the first word of "$ac_prog", so it can be a program name with args. 43344 set dummy $ac_prog; ac_word=$2 43345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43346 $as_echo_n "checking for $ac_word... " >&6; } 43347 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43348 $as_echo_n "(cached) " >&6 43349 else 43350 if test -n "$ac_ct_OBJDUMP"; then 43351 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43352 else 43353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43354 for as_dir in $PATH 43355 do 43356 IFS=$as_save_IFS 43357 test -z "$as_dir" && as_dir=. 43358 for ac_exec_ext in '' $ac_executable_extensions; do 43359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43360 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43362 break 2 43363 fi 43364 done 43365 done 43366 IFS=$as_save_IFS 43367 43368 fi 43369 fi 43370 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43371 if test -n "$ac_ct_OBJDUMP"; then 43372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43373 $as_echo "$ac_ct_OBJDUMP" >&6; } 43374 else 43375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43376 $as_echo "no" >&6; } 43377 fi 43378 43379 43380 test -n "$ac_ct_OBJDUMP" && break 43381 done 43382 43383 if test "x$ac_ct_OBJDUMP" = x; then 43384 OBJDUMP="" 43385 else 43386 case $cross_compiling:$ac_tool_warned in 43387 yes:) 43388 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43389 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43390 ac_tool_warned=yes ;; 43391 esac 43392 OBJDUMP=$ac_ct_OBJDUMP 43393 fi 43394 fi 43395 43396 else 43397 # If it succeeded, then it was overridden by the user. We will use it 43398 # for the tool. 43399 43400 # First remove it from the list of overridden variables, so we can test 43401 # for unknown variables in the end. 43402 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43403 43404 # Check if we try to supply an empty value 43405 if test "x$OBJDUMP" = x; then 43406 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 43407 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 43408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43409 $as_echo_n "checking for OBJDUMP... " >&6; } 43410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43411 $as_echo "disabled" >&6; } 43412 else 43413 # Check if the provided tool contains a complete path. 43414 tool_specified="$OBJDUMP" 43415 tool_basename="${tool_specified##*/}" 43416 if test "x$tool_basename" = "x$tool_specified"; then 43417 # A command without a complete path is provided, search $PATH. 43418 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 43419 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 43420 # Extract the first word of "$tool_basename", so it can be a program name with args. 43421 set dummy $tool_basename; ac_word=$2 43422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43423 $as_echo_n "checking for $ac_word... " >&6; } 43424 if ${ac_cv_path_OBJDUMP+:} false; then : 43425 $as_echo_n "(cached) " >&6 43426 else 43427 case $OBJDUMP in 43428 [\\/]* | ?:[\\/]*) 43429 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 43430 ;; 43431 *) 43432 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43433 for as_dir in $PATH 43434 do 43435 IFS=$as_save_IFS 43436 test -z "$as_dir" && as_dir=. 43437 for ac_exec_ext in '' $ac_executable_extensions; do 43438 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43439 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 43440 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43441 break 2 43442 fi 43443 done 43444 done 43445 IFS=$as_save_IFS 43446 43447 ;; 43448 esac 43449 fi 43450 OBJDUMP=$ac_cv_path_OBJDUMP 43451 if test -n "$OBJDUMP"; then 43452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43453 $as_echo "$OBJDUMP" >&6; } 43454 else 43455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43456 $as_echo "no" >&6; } 43457 fi 43458 43459 43460 if test "x$OBJDUMP" = x; then 43461 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43462 fi 43463 else 43464 # Otherwise we believe it is a complete path. Use it as it is. 43465 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 43466 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 43467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43468 $as_echo_n "checking for OBJDUMP... " >&6; } 43469 if test ! -x "$tool_specified"; then 43470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43471 $as_echo "not found" >&6; } 43472 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 43473 fi 43474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43475 $as_echo "$tool_specified" >&6; } 43476 fi 43477 fi 43478 fi 43479 43480 fi 43481 43482 43483 if test "x$OBJDUMP" != x; then 43484 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 43485 # bails if argument is missing. 43486 43487 # Only process if variable expands to non-empty 43488 43489 if test "x$OBJDUMP" != x; then 43490 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43491 43492 # First separate the path from the arguments. This will split at the first 43493 # space. 43494 complete="$OBJDUMP" 43495 path="${complete%% *}" 43496 tmp="$complete EOL" 43497 arguments="${tmp#* }" 43498 43499 # Input might be given as Windows format, start by converting to 43500 # unix format. 43501 new_path=`$CYGPATH -u "$path"` 43502 43503 # Now try to locate executable using which 43504 new_path=`$WHICH "$new_path" 2> /dev/null` 43505 # bat and cmd files are not always considered executable in cygwin causing which 43506 # to not find them 43507 if test "x$new_path" = x \ 43508 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43509 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43510 new_path=`$CYGPATH -u "$path"` 43511 fi 43512 if test "x$new_path" = x; then 43513 # Oops. Which didn't find the executable. 43514 # The splitting of arguments from the executable at a space might have been incorrect, 43515 # since paths with space are more likely in Windows. Give it another try with the whole 43516 # argument. 43517 path="$complete" 43518 arguments="EOL" 43519 new_path=`$CYGPATH -u "$path"` 43520 new_path=`$WHICH "$new_path" 2> /dev/null` 43521 # bat and cmd files are not always considered executable in cygwin causing which 43522 # to not find them 43523 if test "x$new_path" = x \ 43524 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43525 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43526 new_path=`$CYGPATH -u "$path"` 43527 fi 43528 if test "x$new_path" = x; then 43529 # It's still not found. Now this is an unrecoverable error. 43530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43531 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43532 has_space=`$ECHO "$complete" | $GREP " "` 43533 if test "x$has_space" != x; then 43534 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43535 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43536 fi 43537 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43538 fi 43539 fi 43540 43541 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43542 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43543 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43544 # "foo.exe" is OK but "foo" is an error. 43545 # 43546 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43547 # It is also a way to make sure we got the proper file name for the real test later on. 43548 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43549 if test "x$test_shortpath" = x; then 43550 # Short path failed, file does not exist as specified. 43551 # Try adding .exe or .cmd 43552 if test -f "${new_path}.exe"; then 43553 input_to_shortpath="${new_path}.exe" 43554 elif test -f "${new_path}.cmd"; then 43555 input_to_shortpath="${new_path}.cmd" 43556 else 43557 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 43558 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 43559 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43560 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43561 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43562 fi 43563 else 43564 input_to_shortpath="$new_path" 43565 fi 43566 43567 # Call helper function which possibly converts this using DOS-style short mode. 43568 # If so, the updated path is stored in $new_path. 43569 new_path="$input_to_shortpath" 43570 43571 input_path="$input_to_shortpath" 43572 # Check if we need to convert this using DOS-style short mode. If the path 43573 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43574 # take no chances and rewrite it. 43575 # Note: m4 eats our [], so we need to use [ and ] instead. 43576 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43577 if test "x$has_forbidden_chars" != x; then 43578 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43579 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43580 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43581 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43582 # Going to short mode and back again did indeed matter. Since short mode is 43583 # case insensitive, let's make it lowercase to improve readability. 43584 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43585 # Now convert it back to Unix-style (cygpath) 43586 input_path=`$CYGPATH -u "$shortmode_path"` 43587 new_path="$input_path" 43588 fi 43589 fi 43590 43591 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43592 if test "x$test_cygdrive_prefix" = x; then 43593 # As a simple fix, exclude /usr/bin since it's not a real path. 43594 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43595 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43596 # a path prefixed by /cygdrive for fixpath to work. 43597 new_path="$CYGWIN_ROOT_PATH$input_path" 43598 fi 43599 fi 43600 43601 # remove trailing .exe if any 43602 new_path="${new_path/%.exe/}" 43603 43604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43605 43606 # First separate the path from the arguments. This will split at the first 43607 # space. 43608 complete="$OBJDUMP" 43609 path="${complete%% *}" 43610 tmp="$complete EOL" 43611 arguments="${tmp#* }" 43612 43613 # Input might be given as Windows format, start by converting to 43614 # unix format. 43615 new_path="$path" 43616 43617 windows_path="$new_path" 43618 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43619 unix_path=`$CYGPATH -u "$windows_path"` 43620 new_path="$unix_path" 43621 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43622 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43623 new_path="$unix_path" 43624 fi 43625 43626 43627 # Now try to locate executable using which 43628 new_path=`$WHICH "$new_path" 2> /dev/null` 43629 43630 if test "x$new_path" = x; then 43631 # Oops. Which didn't find the executable. 43632 # The splitting of arguments from the executable at a space might have been incorrect, 43633 # since paths with space are more likely in Windows. Give it another try with the whole 43634 # argument. 43635 path="$complete" 43636 arguments="EOL" 43637 new_path="$path" 43638 43639 windows_path="$new_path" 43640 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43641 unix_path=`$CYGPATH -u "$windows_path"` 43642 new_path="$unix_path" 43643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43644 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43645 new_path="$unix_path" 43646 fi 43647 43648 43649 new_path=`$WHICH "$new_path" 2> /dev/null` 43650 # bat and cmd files are not always considered executable in MSYS causing which 43651 # to not find them 43652 if test "x$new_path" = x \ 43653 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43654 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43655 new_path="$path" 43656 43657 windows_path="$new_path" 43658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43659 unix_path=`$CYGPATH -u "$windows_path"` 43660 new_path="$unix_path" 43661 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43662 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43663 new_path="$unix_path" 43664 fi 43665 43666 fi 43667 43668 if test "x$new_path" = x; then 43669 # It's still not found. Now this is an unrecoverable error. 43670 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43671 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43672 has_space=`$ECHO "$complete" | $GREP " "` 43673 if test "x$has_space" != x; then 43674 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43675 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43676 fi 43677 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43678 fi 43679 fi 43680 43681 # Now new_path has a complete unix path to the binary 43682 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43683 # Keep paths in /bin as-is, but remove trailing .exe if any 43684 new_path="${new_path/%.exe/}" 43685 # Do not save /bin paths to all_fixpath_prefixes! 43686 else 43687 # Not in mixed or Windows style, start by that. 43688 new_path=`cmd //c echo $new_path` 43689 43690 input_path="$new_path" 43691 # Check if we need to convert this using DOS-style short mode. If the path 43692 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43693 # take no chances and rewrite it. 43694 # Note: m4 eats our [], so we need to use [ and ] instead. 43695 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43696 if test "x$has_forbidden_chars" != x; then 43697 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43698 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43699 fi 43700 43701 # Output is in $new_path 43702 43703 windows_path="$new_path" 43704 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43705 unix_path=`$CYGPATH -u "$windows_path"` 43706 new_path="$unix_path" 43707 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43708 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43709 new_path="$unix_path" 43710 fi 43711 43712 # remove trailing .exe if any 43713 new_path="${new_path/%.exe/}" 43714 43715 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43716 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43717 fi 43718 43719 else 43720 # We're on a unix platform. Hooray! :) 43721 # First separate the path from the arguments. This will split at the first 43722 # space. 43723 complete="$OBJDUMP" 43724 path="${complete%% *}" 43725 tmp="$complete EOL" 43726 arguments="${tmp#* }" 43727 43728 # Cannot rely on the command "which" here since it doesn't always work. 43729 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43730 if test -z "$is_absolute_path"; then 43731 # Path to executable is not absolute. Find it. 43732 IFS_save="$IFS" 43733 IFS=: 43734 for p in $PATH; do 43735 if test -f "$p/$path" && test -x "$p/$path"; then 43736 new_path="$p/$path" 43737 break 43738 fi 43739 done 43740 IFS="$IFS_save" 43741 else 43742 # This is an absolute path, we can use it without further modifications. 43743 new_path="$path" 43744 fi 43745 43746 if test "x$new_path" = x; then 43747 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43748 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43749 has_space=`$ECHO "$complete" | $GREP " "` 43750 if test "x$has_space" != x; then 43751 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43752 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43753 fi 43754 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43755 fi 43756 fi 43757 43758 # Now join together the path and the arguments once again 43759 if test "x$arguments" != xEOL; then 43760 new_complete="$new_path ${arguments% *}" 43761 else 43762 new_complete="$new_path" 43763 fi 43764 43765 if test "x$complete" != "x$new_complete"; then 43766 OBJDUMP="$new_complete" 43767 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 43768 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 43769 fi 43770 fi 43771 43772 fi 43773 43774 43775 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 43776 # to remain in place. Otherwise the compiler will not work in some siutations 43777 # in later configure checks. 43778 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 43779 PATH="$OLD_PATH" 43780 fi 43781 43782 # Restore the flags to the user specified values. 43783 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 43784 CFLAGS="$ORG_CFLAGS" 43785 CXXFLAGS="$ORG_CXXFLAGS" 43786 43787 43788 # Finally do some processing after the detection phase 43789 43790 if test "x$COMPILE_TYPE" = "xcross"; then 43791 # Now we need to find a C/C++ compiler that can build executables for the 43792 # build platform. We can't use the AC_PROG_CC macro, since it can only be 43793 # used once. Also, we need to do this without adding a tools dir to the 43794 # path, otherwise we might pick up cross-compilers which don't use standard 43795 # naming. 43796 43797 OLDPATH="$PATH" 43798 43799 43800 # Check whether --with-build-devkit was given. 43801 if test "${with_build_devkit+set}" = set; then : 43802 withval=$with_build_devkit; 43803 fi 43804 43805 if test "x$with_build_devkit" = "xyes"; then 43806 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 43807 elif test -n "$with_build_devkit"; then 43808 if test ! -d "$with_build_devkit"; then 43809 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 43810 else 43811 43812 # Only process if variable expands to non-empty 43813 43814 if test "x$with_build_devkit" != x; then 43815 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43816 43817 # Input might be given as Windows format, start by converting to 43818 # unix format. 43819 path="$with_build_devkit" 43820 new_path=`$CYGPATH -u "$path"` 43821 43822 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43823 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43824 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43825 # "foo.exe" is OK but "foo" is an error. 43826 # 43827 # This test is therefore slightly more accurate than "test -f" to check for file precense. 43828 # It is also a way to make sure we got the proper file name for the real test later on. 43829 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43830 if test "x$test_shortpath" = x; then 43831 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43832 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43833 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 43834 fi 43835 43836 # Call helper function which possibly converts this using DOS-style short mode. 43837 # If so, the updated path is stored in $new_path. 43838 43839 input_path="$new_path" 43840 # Check if we need to convert this using DOS-style short mode. If the path 43841 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43842 # take no chances and rewrite it. 43843 # Note: m4 eats our [], so we need to use [ and ] instead. 43844 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43845 if test "x$has_forbidden_chars" != x; then 43846 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43847 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43848 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43849 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43850 # Going to short mode and back again did indeed matter. Since short mode is 43851 # case insensitive, let's make it lowercase to improve readability. 43852 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43853 # Now convert it back to Unix-style (cygpath) 43854 input_path=`$CYGPATH -u "$shortmode_path"` 43855 new_path="$input_path" 43856 fi 43857 fi 43858 43859 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43860 if test "x$test_cygdrive_prefix" = x; then 43861 # As a simple fix, exclude /usr/bin since it's not a real path. 43862 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 43863 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43864 # a path prefixed by /cygdrive for fixpath to work. 43865 new_path="$CYGWIN_ROOT_PATH$input_path" 43866 fi 43867 fi 43868 43869 43870 if test "x$path" != "x$new_path"; then 43871 with_build_devkit="$new_path" 43872 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43873 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43874 fi 43875 43876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43877 43878 path="$with_build_devkit" 43879 has_colon=`$ECHO $path | $GREP ^.:` 43880 new_path="$path" 43881 if test "x$has_colon" = x; then 43882 # Not in mixed or Windows style, start by that. 43883 new_path=`cmd //c echo $path` 43884 fi 43885 43886 43887 input_path="$new_path" 43888 # Check if we need to convert this using DOS-style short mode. If the path 43889 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43890 # take no chances and rewrite it. 43891 # Note: m4 eats our [], so we need to use [ and ] instead. 43892 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43893 if test "x$has_forbidden_chars" != x; then 43894 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43895 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43896 fi 43897 43898 43899 windows_path="$new_path" 43900 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43901 unix_path=`$CYGPATH -u "$windows_path"` 43902 new_path="$unix_path" 43903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43904 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43905 new_path="$unix_path" 43906 fi 43907 43908 if test "x$path" != "x$new_path"; then 43909 with_build_devkit="$new_path" 43910 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43911 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43912 fi 43913 43914 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43915 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43916 43917 else 43918 # We're on a unix platform. Hooray! :) 43919 path="$with_build_devkit" 43920 has_space=`$ECHO "$path" | $GREP " "` 43921 if test "x$has_space" != x; then 43922 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43923 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43924 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 43925 fi 43926 43927 # Use eval to expand a potential ~ 43928 eval path="$path" 43929 if test ! -f "$path" && test ! -d "$path"; then 43930 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 43931 fi 43932 43933 if test -d "$path"; then 43934 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 43935 else 43936 dir="`$DIRNAME "$path"`" 43937 base="`$BASENAME "$path"`" 43938 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 43939 fi 43940 fi 43941 fi 43942 43943 BUILD_DEVKIT_ROOT="$with_build_devkit" 43944 # Check for a meta data info file in the root of the devkit 43945 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 43946 # Process devkit.info so that existing devkit variables are not 43947 # modified by this 43948 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 43949 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 43950 -e "s/\$host/\$build/g" \ 43951 $BUILD_DEVKIT_ROOT/devkit.info \ 43952 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43953 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43954 # This potentially sets the following: 43955 # A descriptive name of the devkit 43956 43957 if test "x$BUILD_DEVKIT_NAME" = x; then 43958 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 43959 fi 43960 43961 # Corresponds to --with-extra-path 43962 43963 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 43964 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 43965 fi 43966 43967 # Corresponds to --with-toolchain-path 43968 43969 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 43970 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 43971 fi 43972 43973 # Corresponds to --with-sysroot 43974 43975 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 43976 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 43977 fi 43978 43979 # Skip the Window specific parts 43980 fi 43981 43982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 43983 $as_echo_n "checking for build platform devkit... " >&6; } 43984 if test "x$BUILD_DEVKIT_NAME" != x; then 43985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 43986 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 43987 else 43988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 43989 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 43990 fi 43991 43992 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 43993 43994 if test "x$BUILD_SYSROOT" != "x"; then 43995 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 43996 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 43997 # Solaris Studio does not have a concept of sysroot. Instead we must 43998 # make sure the default include and lib dirs are appended to each 43999 # compile and link command line. Must also add -I-xbuiltin to enable 44000 # inlining of system functions and intrinsics. 44001 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 44002 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 44003 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \ 44004 -L$BUILD_SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR" 44005 fi 44006 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 44007 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 44008 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 44009 elif test "x$TOOLCHAIN_TYPE" = xclang; then 44010 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 44011 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 44012 fi 44013 # Propagate the sysroot args to hotspot 44014 BUILD_LEGACY_EXTRA_CFLAGS="$BUILD_LEGACY_EXTRA_CFLAGS $BUILD_SYSROOT_CFLAGS" 44015 BUILD_LEGACY_EXTRA_CXXFLAGS="$BUILD_LEGACY_EXTRA_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 44016 BUILD_LEGACY_EXTRA_LDFLAGS="$BUILD_LEGACY_EXTRA_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 44017 # The global CFLAGS and LDFLAGS variables need these for configure to function 44018 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 44019 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 44020 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 44021 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 44022 fi 44023 44024 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 44025 # We also need -iframework<path>/System/Library/Frameworks 44026 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44027 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44028 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 44029 # set this here so it doesn't have to be peppered throughout the forest 44030 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44031 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44032 fi 44033 44034 44035 44036 44037 44038 # Fallback default of just /bin if DEVKIT_PATH is not defined 44039 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44040 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 44041 fi 44042 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 44043 fi 44044 fi 44045 44046 # FIXME: we should list the discovered compilers as an exclude pattern! 44047 # If we do that, we can do this detection before POST_DETECTION, and still 44048 # find the build compilers in the tools dir, if needed. 44049 44050 44051 44052 # Publish this variable in the help. 44053 44054 44055 if [ -z "${BUILD_CC+x}" ]; then 44056 # The variable is not set by user, try to locate tool using the code snippet 44057 for ac_prog in cl cc gcc 44058 do 44059 # Extract the first word of "$ac_prog", so it can be a program name with args. 44060 set dummy $ac_prog; ac_word=$2 44061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44062 $as_echo_n "checking for $ac_word... " >&6; } 44063 if ${ac_cv_path_BUILD_CC+:} false; then : 44064 $as_echo_n "(cached) " >&6 44065 else 44066 case $BUILD_CC in 44067 [\\/]* | ?:[\\/]*) 44068 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44069 ;; 44070 *) 44071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44072 for as_dir in $PATH 44073 do 44074 IFS=$as_save_IFS 44075 test -z "$as_dir" && as_dir=. 44076 for ac_exec_ext in '' $ac_executable_extensions; do 44077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44078 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44080 break 2 44081 fi 44082 done 44083 done 44084 IFS=$as_save_IFS 44085 44086 ;; 44087 esac 44088 fi 44089 BUILD_CC=$ac_cv_path_BUILD_CC 44090 if test -n "$BUILD_CC"; then 44091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44092 $as_echo "$BUILD_CC" >&6; } 44093 else 44094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44095 $as_echo "no" >&6; } 44096 fi 44097 44098 44099 test -n "$BUILD_CC" && break 44100 done 44101 44102 else 44103 # The variable is set, but is it from the command line or the environment? 44104 44105 # Try to remove the string !BUILD_CC! from our list. 44106 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 44107 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44108 # If it failed, the variable was not from the command line. Ignore it, 44109 # but warn the user (except for BASH, which is always set by the calling BASH). 44110 if test "xBUILD_CC" != xBASH; then 44111 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 44112 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 44113 fi 44114 # Try to locate tool using the code snippet 44115 for ac_prog in cl cc gcc 44116 do 44117 # Extract the first word of "$ac_prog", so it can be a program name with args. 44118 set dummy $ac_prog; ac_word=$2 44119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44120 $as_echo_n "checking for $ac_word... " >&6; } 44121 if ${ac_cv_path_BUILD_CC+:} false; then : 44122 $as_echo_n "(cached) " >&6 44123 else 44124 case $BUILD_CC in 44125 [\\/]* | ?:[\\/]*) 44126 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44127 ;; 44128 *) 44129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44130 for as_dir in $PATH 44131 do 44132 IFS=$as_save_IFS 44133 test -z "$as_dir" && as_dir=. 44134 for ac_exec_ext in '' $ac_executable_extensions; do 44135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44136 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44138 break 2 44139 fi 44140 done 44141 done 44142 IFS=$as_save_IFS 44143 44144 ;; 44145 esac 44146 fi 44147 BUILD_CC=$ac_cv_path_BUILD_CC 44148 if test -n "$BUILD_CC"; then 44149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44150 $as_echo "$BUILD_CC" >&6; } 44151 else 44152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44153 $as_echo "no" >&6; } 44154 fi 44155 44156 44157 test -n "$BUILD_CC" && break 44158 done 44159 44160 else 44161 # If it succeeded, then it was overridden by the user. We will use it 44162 # for the tool. 44163 44164 # First remove it from the list of overridden variables, so we can test 44165 # for unknown variables in the end. 44166 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44167 44168 # Check if we try to supply an empty value 44169 if test "x$BUILD_CC" = x; then 44170 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 44171 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 44172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44173 $as_echo_n "checking for BUILD_CC... " >&6; } 44174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44175 $as_echo "disabled" >&6; } 44176 else 44177 # Check if the provided tool contains a complete path. 44178 tool_specified="$BUILD_CC" 44179 tool_basename="${tool_specified##*/}" 44180 if test "x$tool_basename" = "x$tool_specified"; then 44181 # A command without a complete path is provided, search $PATH. 44182 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 44183 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 44184 # Extract the first word of "$tool_basename", so it can be a program name with args. 44185 set dummy $tool_basename; ac_word=$2 44186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44187 $as_echo_n "checking for $ac_word... " >&6; } 44188 if ${ac_cv_path_BUILD_CC+:} false; then : 44189 $as_echo_n "(cached) " >&6 44190 else 44191 case $BUILD_CC in 44192 [\\/]* | ?:[\\/]*) 44193 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44194 ;; 44195 *) 44196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44197 for as_dir in $PATH 44198 do 44199 IFS=$as_save_IFS 44200 test -z "$as_dir" && as_dir=. 44201 for ac_exec_ext in '' $ac_executable_extensions; do 44202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44203 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44205 break 2 44206 fi 44207 done 44208 done 44209 IFS=$as_save_IFS 44210 44211 ;; 44212 esac 44213 fi 44214 BUILD_CC=$ac_cv_path_BUILD_CC 44215 if test -n "$BUILD_CC"; then 44216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44217 $as_echo "$BUILD_CC" >&6; } 44218 else 44219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44220 $as_echo "no" >&6; } 44221 fi 44222 44223 44224 if test "x$BUILD_CC" = x; then 44225 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44226 fi 44227 else 44228 # Otherwise we believe it is a complete path. Use it as it is. 44229 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 44230 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 44231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44232 $as_echo_n "checking for BUILD_CC... " >&6; } 44233 if test ! -x "$tool_specified"; then 44234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44235 $as_echo "not found" >&6; } 44236 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 44237 fi 44238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44239 $as_echo "$tool_specified" >&6; } 44240 fi 44241 fi 44242 fi 44243 44244 fi 44245 44246 44247 44248 if test "x$BUILD_CC" = x; then 44249 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 44250 fi 44251 44252 44253 44254 # Only process if variable expands to non-empty 44255 44256 if test "x$BUILD_CC" != x; then 44257 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44258 44259 # First separate the path from the arguments. This will split at the first 44260 # space. 44261 complete="$BUILD_CC" 44262 path="${complete%% *}" 44263 tmp="$complete EOL" 44264 arguments="${tmp#* }" 44265 44266 # Input might be given as Windows format, start by converting to 44267 # unix format. 44268 new_path=`$CYGPATH -u "$path"` 44269 44270 # Now try to locate executable using which 44271 new_path=`$WHICH "$new_path" 2> /dev/null` 44272 # bat and cmd files are not always considered executable in cygwin causing which 44273 # to not find them 44274 if test "x$new_path" = x \ 44275 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44276 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44277 new_path=`$CYGPATH -u "$path"` 44278 fi 44279 if test "x$new_path" = x; then 44280 # Oops. Which didn't find the executable. 44281 # The splitting of arguments from the executable at a space might have been incorrect, 44282 # since paths with space are more likely in Windows. Give it another try with the whole 44283 # argument. 44284 path="$complete" 44285 arguments="EOL" 44286 new_path=`$CYGPATH -u "$path"` 44287 new_path=`$WHICH "$new_path" 2> /dev/null` 44288 # bat and cmd files are not always considered executable in cygwin causing which 44289 # to not find them 44290 if test "x$new_path" = x \ 44291 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44292 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44293 new_path=`$CYGPATH -u "$path"` 44294 fi 44295 if test "x$new_path" = x; then 44296 # It's still not found. Now this is an unrecoverable error. 44297 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44298 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44299 has_space=`$ECHO "$complete" | $GREP " "` 44300 if test "x$has_space" != x; then 44301 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44302 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44303 fi 44304 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44305 fi 44306 fi 44307 44308 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44309 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44310 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44311 # "foo.exe" is OK but "foo" is an error. 44312 # 44313 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44314 # It is also a way to make sure we got the proper file name for the real test later on. 44315 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44316 if test "x$test_shortpath" = x; then 44317 # Short path failed, file does not exist as specified. 44318 # Try adding .exe or .cmd 44319 if test -f "${new_path}.exe"; then 44320 input_to_shortpath="${new_path}.exe" 44321 elif test -f "${new_path}.cmd"; then 44322 input_to_shortpath="${new_path}.cmd" 44323 else 44324 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 44325 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 44326 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44327 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44328 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44329 fi 44330 else 44331 input_to_shortpath="$new_path" 44332 fi 44333 44334 # Call helper function which possibly converts this using DOS-style short mode. 44335 # If so, the updated path is stored in $new_path. 44336 new_path="$input_to_shortpath" 44337 44338 input_path="$input_to_shortpath" 44339 # Check if we need to convert this using DOS-style short mode. If the path 44340 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44341 # take no chances and rewrite it. 44342 # Note: m4 eats our [], so we need to use [ and ] instead. 44343 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44344 if test "x$has_forbidden_chars" != x; then 44345 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44346 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44347 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44348 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44349 # Going to short mode and back again did indeed matter. Since short mode is 44350 # case insensitive, let's make it lowercase to improve readability. 44351 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44352 # Now convert it back to Unix-style (cygpath) 44353 input_path=`$CYGPATH -u "$shortmode_path"` 44354 new_path="$input_path" 44355 fi 44356 fi 44357 44358 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44359 if test "x$test_cygdrive_prefix" = x; then 44360 # As a simple fix, exclude /usr/bin since it's not a real path. 44361 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44362 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44363 # a path prefixed by /cygdrive for fixpath to work. 44364 new_path="$CYGWIN_ROOT_PATH$input_path" 44365 fi 44366 fi 44367 44368 # remove trailing .exe if any 44369 new_path="${new_path/%.exe/}" 44370 44371 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44372 44373 # First separate the path from the arguments. This will split at the first 44374 # space. 44375 complete="$BUILD_CC" 44376 path="${complete%% *}" 44377 tmp="$complete EOL" 44378 arguments="${tmp#* }" 44379 44380 # Input might be given as Windows format, start by converting to 44381 # unix format. 44382 new_path="$path" 44383 44384 windows_path="$new_path" 44385 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44386 unix_path=`$CYGPATH -u "$windows_path"` 44387 new_path="$unix_path" 44388 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44389 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44390 new_path="$unix_path" 44391 fi 44392 44393 44394 # Now try to locate executable using which 44395 new_path=`$WHICH "$new_path" 2> /dev/null` 44396 44397 if test "x$new_path" = x; then 44398 # Oops. Which didn't find the executable. 44399 # The splitting of arguments from the executable at a space might have been incorrect, 44400 # since paths with space are more likely in Windows. Give it another try with the whole 44401 # argument. 44402 path="$complete" 44403 arguments="EOL" 44404 new_path="$path" 44405 44406 windows_path="$new_path" 44407 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44408 unix_path=`$CYGPATH -u "$windows_path"` 44409 new_path="$unix_path" 44410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44411 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44412 new_path="$unix_path" 44413 fi 44414 44415 44416 new_path=`$WHICH "$new_path" 2> /dev/null` 44417 # bat and cmd files are not always considered executable in MSYS causing which 44418 # to not find them 44419 if test "x$new_path" = x \ 44420 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44421 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44422 new_path="$path" 44423 44424 windows_path="$new_path" 44425 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44426 unix_path=`$CYGPATH -u "$windows_path"` 44427 new_path="$unix_path" 44428 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44429 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44430 new_path="$unix_path" 44431 fi 44432 44433 fi 44434 44435 if test "x$new_path" = x; then 44436 # It's still not found. Now this is an unrecoverable error. 44437 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44438 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44439 has_space=`$ECHO "$complete" | $GREP " "` 44440 if test "x$has_space" != x; then 44441 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44442 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44443 fi 44444 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44445 fi 44446 fi 44447 44448 # Now new_path has a complete unix path to the binary 44449 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44450 # Keep paths in /bin as-is, but remove trailing .exe if any 44451 new_path="${new_path/%.exe/}" 44452 # Do not save /bin paths to all_fixpath_prefixes! 44453 else 44454 # Not in mixed or Windows style, start by that. 44455 new_path=`cmd //c echo $new_path` 44456 44457 input_path="$new_path" 44458 # Check if we need to convert this using DOS-style short mode. If the path 44459 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44460 # take no chances and rewrite it. 44461 # Note: m4 eats our [], so we need to use [ and ] instead. 44462 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44463 if test "x$has_forbidden_chars" != x; then 44464 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44465 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44466 fi 44467 44468 # Output is in $new_path 44469 44470 windows_path="$new_path" 44471 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44472 unix_path=`$CYGPATH -u "$windows_path"` 44473 new_path="$unix_path" 44474 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44475 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44476 new_path="$unix_path" 44477 fi 44478 44479 # remove trailing .exe if any 44480 new_path="${new_path/%.exe/}" 44481 44482 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44483 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44484 fi 44485 44486 else 44487 # We're on a unix platform. Hooray! :) 44488 # First separate the path from the arguments. This will split at the first 44489 # space. 44490 complete="$BUILD_CC" 44491 path="${complete%% *}" 44492 tmp="$complete EOL" 44493 arguments="${tmp#* }" 44494 44495 # Cannot rely on the command "which" here since it doesn't always work. 44496 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44497 if test -z "$is_absolute_path"; then 44498 # Path to executable is not absolute. Find it. 44499 IFS_save="$IFS" 44500 IFS=: 44501 for p in $PATH; do 44502 if test -f "$p/$path" && test -x "$p/$path"; then 44503 new_path="$p/$path" 44504 break 44505 fi 44506 done 44507 IFS="$IFS_save" 44508 else 44509 # This is an absolute path, we can use it without further modifications. 44510 new_path="$path" 44511 fi 44512 44513 if test "x$new_path" = x; then 44514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44515 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44516 has_space=`$ECHO "$complete" | $GREP " "` 44517 if test "x$has_space" != x; then 44518 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44519 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44520 fi 44521 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44522 fi 44523 fi 44524 44525 # Now join together the path and the arguments once again 44526 if test "x$arguments" != xEOL; then 44527 new_complete="$new_path ${arguments% *}" 44528 else 44529 new_complete="$new_path" 44530 fi 44531 44532 if test "x$complete" != "x$new_complete"; then 44533 BUILD_CC="$new_complete" 44534 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 44535 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 44536 fi 44537 fi 44538 44539 44540 44541 44542 # Publish this variable in the help. 44543 44544 44545 if [ -z "${BUILD_CXX+x}" ]; then 44546 # The variable is not set by user, try to locate tool using the code snippet 44547 for ac_prog in cl CC g++ 44548 do 44549 # Extract the first word of "$ac_prog", so it can be a program name with args. 44550 set dummy $ac_prog; ac_word=$2 44551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44552 $as_echo_n "checking for $ac_word... " >&6; } 44553 if ${ac_cv_path_BUILD_CXX+:} false; then : 44554 $as_echo_n "(cached) " >&6 44555 else 44556 case $BUILD_CXX in 44557 [\\/]* | ?:[\\/]*) 44558 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44559 ;; 44560 *) 44561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44562 for as_dir in $PATH 44563 do 44564 IFS=$as_save_IFS 44565 test -z "$as_dir" && as_dir=. 44566 for ac_exec_ext in '' $ac_executable_extensions; do 44567 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44568 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44570 break 2 44571 fi 44572 done 44573 done 44574 IFS=$as_save_IFS 44575 44576 ;; 44577 esac 44578 fi 44579 BUILD_CXX=$ac_cv_path_BUILD_CXX 44580 if test -n "$BUILD_CXX"; then 44581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44582 $as_echo "$BUILD_CXX" >&6; } 44583 else 44584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44585 $as_echo "no" >&6; } 44586 fi 44587 44588 44589 test -n "$BUILD_CXX" && break 44590 done 44591 44592 else 44593 # The variable is set, but is it from the command line or the environment? 44594 44595 # Try to remove the string !BUILD_CXX! from our list. 44596 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 44597 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44598 # If it failed, the variable was not from the command line. Ignore it, 44599 # but warn the user (except for BASH, which is always set by the calling BASH). 44600 if test "xBUILD_CXX" != xBASH; then 44601 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 44602 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 44603 fi 44604 # Try to locate tool using the code snippet 44605 for ac_prog in cl CC g++ 44606 do 44607 # Extract the first word of "$ac_prog", so it can be a program name with args. 44608 set dummy $ac_prog; ac_word=$2 44609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44610 $as_echo_n "checking for $ac_word... " >&6; } 44611 if ${ac_cv_path_BUILD_CXX+:} false; then : 44612 $as_echo_n "(cached) " >&6 44613 else 44614 case $BUILD_CXX in 44615 [\\/]* | ?:[\\/]*) 44616 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44617 ;; 44618 *) 44619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44620 for as_dir in $PATH 44621 do 44622 IFS=$as_save_IFS 44623 test -z "$as_dir" && as_dir=. 44624 for ac_exec_ext in '' $ac_executable_extensions; do 44625 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44626 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44627 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44628 break 2 44629 fi 44630 done 44631 done 44632 IFS=$as_save_IFS 44633 44634 ;; 44635 esac 44636 fi 44637 BUILD_CXX=$ac_cv_path_BUILD_CXX 44638 if test -n "$BUILD_CXX"; then 44639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44640 $as_echo "$BUILD_CXX" >&6; } 44641 else 44642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44643 $as_echo "no" >&6; } 44644 fi 44645 44646 44647 test -n "$BUILD_CXX" && break 44648 done 44649 44650 else 44651 # If it succeeded, then it was overridden by the user. We will use it 44652 # for the tool. 44653 44654 # First remove it from the list of overridden variables, so we can test 44655 # for unknown variables in the end. 44656 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44657 44658 # Check if we try to supply an empty value 44659 if test "x$BUILD_CXX" = x; then 44660 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 44661 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 44662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 44663 $as_echo_n "checking for BUILD_CXX... " >&6; } 44664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44665 $as_echo "disabled" >&6; } 44666 else 44667 # Check if the provided tool contains a complete path. 44668 tool_specified="$BUILD_CXX" 44669 tool_basename="${tool_specified##*/}" 44670 if test "x$tool_basename" = "x$tool_specified"; then 44671 # A command without a complete path is provided, search $PATH. 44672 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 44673 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 44674 # Extract the first word of "$tool_basename", so it can be a program name with args. 44675 set dummy $tool_basename; ac_word=$2 44676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44677 $as_echo_n "checking for $ac_word... " >&6; } 44678 if ${ac_cv_path_BUILD_CXX+:} false; then : 44679 $as_echo_n "(cached) " >&6 44680 else 44681 case $BUILD_CXX in 44682 [\\/]* | ?:[\\/]*) 44683 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44684 ;; 44685 *) 44686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44687 for as_dir in $PATH 44688 do 44689 IFS=$as_save_IFS 44690 test -z "$as_dir" && as_dir=. 44691 for ac_exec_ext in '' $ac_executable_extensions; do 44692 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44693 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44695 break 2 44696 fi 44697 done 44698 done 44699 IFS=$as_save_IFS 44700 44701 ;; 44702 esac 44703 fi 44704 BUILD_CXX=$ac_cv_path_BUILD_CXX 44705 if test -n "$BUILD_CXX"; then 44706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44707 $as_echo "$BUILD_CXX" >&6; } 44708 else 44709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44710 $as_echo "no" >&6; } 44711 fi 44712 44713 44714 if test "x$BUILD_CXX" = x; then 44715 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44716 fi 44717 else 44718 # Otherwise we believe it is a complete path. Use it as it is. 44719 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 44720 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 44721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 44722 $as_echo_n "checking for BUILD_CXX... " >&6; } 44723 if test ! -x "$tool_specified"; then 44724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44725 $as_echo "not found" >&6; } 44726 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 44727 fi 44728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44729 $as_echo "$tool_specified" >&6; } 44730 fi 44731 fi 44732 fi 44733 44734 fi 44735 44736 44737 44738 if test "x$BUILD_CXX" = x; then 44739 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 44740 fi 44741 44742 44743 44744 # Only process if variable expands to non-empty 44745 44746 if test "x$BUILD_CXX" != x; then 44747 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44748 44749 # First separate the path from the arguments. This will split at the first 44750 # space. 44751 complete="$BUILD_CXX" 44752 path="${complete%% *}" 44753 tmp="$complete EOL" 44754 arguments="${tmp#* }" 44755 44756 # Input might be given as Windows format, start by converting to 44757 # unix format. 44758 new_path=`$CYGPATH -u "$path"` 44759 44760 # Now try to locate executable using which 44761 new_path=`$WHICH "$new_path" 2> /dev/null` 44762 # bat and cmd files are not always considered executable in cygwin causing which 44763 # to not find them 44764 if test "x$new_path" = x \ 44765 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44766 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44767 new_path=`$CYGPATH -u "$path"` 44768 fi 44769 if test "x$new_path" = x; then 44770 # Oops. Which didn't find the executable. 44771 # The splitting of arguments from the executable at a space might have been incorrect, 44772 # since paths with space are more likely in Windows. Give it another try with the whole 44773 # argument. 44774 path="$complete" 44775 arguments="EOL" 44776 new_path=`$CYGPATH -u "$path"` 44777 new_path=`$WHICH "$new_path" 2> /dev/null` 44778 # bat and cmd files are not always considered executable in cygwin causing which 44779 # to not find them 44780 if test "x$new_path" = x \ 44781 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44782 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44783 new_path=`$CYGPATH -u "$path"` 44784 fi 44785 if test "x$new_path" = x; then 44786 # It's still not found. Now this is an unrecoverable error. 44787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44788 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44789 has_space=`$ECHO "$complete" | $GREP " "` 44790 if test "x$has_space" != x; then 44791 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44792 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44793 fi 44794 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44795 fi 44796 fi 44797 44798 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44799 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44800 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44801 # "foo.exe" is OK but "foo" is an error. 44802 # 44803 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44804 # It is also a way to make sure we got the proper file name for the real test later on. 44805 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44806 if test "x$test_shortpath" = x; then 44807 # Short path failed, file does not exist as specified. 44808 # Try adding .exe or .cmd 44809 if test -f "${new_path}.exe"; then 44810 input_to_shortpath="${new_path}.exe" 44811 elif test -f "${new_path}.cmd"; then 44812 input_to_shortpath="${new_path}.cmd" 44813 else 44814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 44815 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 44816 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44817 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44818 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44819 fi 44820 else 44821 input_to_shortpath="$new_path" 44822 fi 44823 44824 # Call helper function which possibly converts this using DOS-style short mode. 44825 # If so, the updated path is stored in $new_path. 44826 new_path="$input_to_shortpath" 44827 44828 input_path="$input_to_shortpath" 44829 # Check if we need to convert this using DOS-style short mode. If the path 44830 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44831 # take no chances and rewrite it. 44832 # Note: m4 eats our [], so we need to use [ and ] instead. 44833 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44834 if test "x$has_forbidden_chars" != x; then 44835 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44836 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44837 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44838 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44839 # Going to short mode and back again did indeed matter. Since short mode is 44840 # case insensitive, let's make it lowercase to improve readability. 44841 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44842 # Now convert it back to Unix-style (cygpath) 44843 input_path=`$CYGPATH -u "$shortmode_path"` 44844 new_path="$input_path" 44845 fi 44846 fi 44847 44848 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44849 if test "x$test_cygdrive_prefix" = x; then 44850 # As a simple fix, exclude /usr/bin since it's not a real path. 44851 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44852 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44853 # a path prefixed by /cygdrive for fixpath to work. 44854 new_path="$CYGWIN_ROOT_PATH$input_path" 44855 fi 44856 fi 44857 44858 # remove trailing .exe if any 44859 new_path="${new_path/%.exe/}" 44860 44861 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44862 44863 # First separate the path from the arguments. This will split at the first 44864 # space. 44865 complete="$BUILD_CXX" 44866 path="${complete%% *}" 44867 tmp="$complete EOL" 44868 arguments="${tmp#* }" 44869 44870 # Input might be given as Windows format, start by converting to 44871 # unix format. 44872 new_path="$path" 44873 44874 windows_path="$new_path" 44875 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44876 unix_path=`$CYGPATH -u "$windows_path"` 44877 new_path="$unix_path" 44878 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44879 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44880 new_path="$unix_path" 44881 fi 44882 44883 44884 # Now try to locate executable using which 44885 new_path=`$WHICH "$new_path" 2> /dev/null` 44886 44887 if test "x$new_path" = x; then 44888 # Oops. Which didn't find the executable. 44889 # The splitting of arguments from the executable at a space might have been incorrect, 44890 # since paths with space are more likely in Windows. Give it another try with the whole 44891 # argument. 44892 path="$complete" 44893 arguments="EOL" 44894 new_path="$path" 44895 44896 windows_path="$new_path" 44897 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44898 unix_path=`$CYGPATH -u "$windows_path"` 44899 new_path="$unix_path" 44900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44901 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44902 new_path="$unix_path" 44903 fi 44904 44905 44906 new_path=`$WHICH "$new_path" 2> /dev/null` 44907 # bat and cmd files are not always considered executable in MSYS causing which 44908 # to not find them 44909 if test "x$new_path" = x \ 44910 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44911 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44912 new_path="$path" 44913 44914 windows_path="$new_path" 44915 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44916 unix_path=`$CYGPATH -u "$windows_path"` 44917 new_path="$unix_path" 44918 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44919 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44920 new_path="$unix_path" 44921 fi 44922 44923 fi 44924 44925 if test "x$new_path" = x; then 44926 # It's still not found. Now this is an unrecoverable error. 44927 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44928 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44929 has_space=`$ECHO "$complete" | $GREP " "` 44930 if test "x$has_space" != x; then 44931 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44932 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44933 fi 44934 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44935 fi 44936 fi 44937 44938 # Now new_path has a complete unix path to the binary 44939 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44940 # Keep paths in /bin as-is, but remove trailing .exe if any 44941 new_path="${new_path/%.exe/}" 44942 # Do not save /bin paths to all_fixpath_prefixes! 44943 else 44944 # Not in mixed or Windows style, start by that. 44945 new_path=`cmd //c echo $new_path` 44946 44947 input_path="$new_path" 44948 # Check if we need to convert this using DOS-style short mode. If the path 44949 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44950 # take no chances and rewrite it. 44951 # Note: m4 eats our [], so we need to use [ and ] instead. 44952 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44953 if test "x$has_forbidden_chars" != x; then 44954 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44955 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44956 fi 44957 44958 # Output is in $new_path 44959 44960 windows_path="$new_path" 44961 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44962 unix_path=`$CYGPATH -u "$windows_path"` 44963 new_path="$unix_path" 44964 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44965 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44966 new_path="$unix_path" 44967 fi 44968 44969 # remove trailing .exe if any 44970 new_path="${new_path/%.exe/}" 44971 44972 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44973 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44974 fi 44975 44976 else 44977 # We're on a unix platform. Hooray! :) 44978 # First separate the path from the arguments. This will split at the first 44979 # space. 44980 complete="$BUILD_CXX" 44981 path="${complete%% *}" 44982 tmp="$complete EOL" 44983 arguments="${tmp#* }" 44984 44985 # Cannot rely on the command "which" here since it doesn't always work. 44986 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44987 if test -z "$is_absolute_path"; then 44988 # Path to executable is not absolute. Find it. 44989 IFS_save="$IFS" 44990 IFS=: 44991 for p in $PATH; do 44992 if test -f "$p/$path" && test -x "$p/$path"; then 44993 new_path="$p/$path" 44994 break 44995 fi 44996 done 44997 IFS="$IFS_save" 44998 else 44999 # This is an absolute path, we can use it without further modifications. 45000 new_path="$path" 45001 fi 45002 45003 if test "x$new_path" = x; then 45004 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45005 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45006 has_space=`$ECHO "$complete" | $GREP " "` 45007 if test "x$has_space" != x; then 45008 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45009 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45010 fi 45011 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45012 fi 45013 fi 45014 45015 # Now join together the path and the arguments once again 45016 if test "x$arguments" != xEOL; then 45017 new_complete="$new_path ${arguments% *}" 45018 else 45019 new_complete="$new_path" 45020 fi 45021 45022 if test "x$complete" != "x$new_complete"; then 45023 BUILD_CXX="$new_complete" 45024 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 45025 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 45026 fi 45027 fi 45028 45029 45030 45031 # Publish this variable in the help. 45032 45033 45034 if [ -z "${BUILD_NM+x}" ]; then 45035 # The variable is not set by user, try to locate tool using the code snippet 45036 for ac_prog in nm gcc-nm 45037 do 45038 # Extract the first word of "$ac_prog", so it can be a program name with args. 45039 set dummy $ac_prog; ac_word=$2 45040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45041 $as_echo_n "checking for $ac_word... " >&6; } 45042 if ${ac_cv_path_BUILD_NM+:} false; then : 45043 $as_echo_n "(cached) " >&6 45044 else 45045 case $BUILD_NM in 45046 [\\/]* | ?:[\\/]*) 45047 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45048 ;; 45049 *) 45050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45051 for as_dir in $PATH 45052 do 45053 IFS=$as_save_IFS 45054 test -z "$as_dir" && as_dir=. 45055 for ac_exec_ext in '' $ac_executable_extensions; do 45056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45057 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45059 break 2 45060 fi 45061 done 45062 done 45063 IFS=$as_save_IFS 45064 45065 ;; 45066 esac 45067 fi 45068 BUILD_NM=$ac_cv_path_BUILD_NM 45069 if test -n "$BUILD_NM"; then 45070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45071 $as_echo "$BUILD_NM" >&6; } 45072 else 45073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45074 $as_echo "no" >&6; } 45075 fi 45076 45077 45078 test -n "$BUILD_NM" && break 45079 done 45080 45081 else 45082 # The variable is set, but is it from the command line or the environment? 45083 45084 # Try to remove the string !BUILD_NM! from our list. 45085 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 45086 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45087 # If it failed, the variable was not from the command line. Ignore it, 45088 # but warn the user (except for BASH, which is always set by the calling BASH). 45089 if test "xBUILD_NM" != xBASH; then 45090 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 45091 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 45092 fi 45093 # Try to locate tool using the code snippet 45094 for ac_prog in nm gcc-nm 45095 do 45096 # Extract the first word of "$ac_prog", so it can be a program name with args. 45097 set dummy $ac_prog; ac_word=$2 45098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45099 $as_echo_n "checking for $ac_word... " >&6; } 45100 if ${ac_cv_path_BUILD_NM+:} false; then : 45101 $as_echo_n "(cached) " >&6 45102 else 45103 case $BUILD_NM in 45104 [\\/]* | ?:[\\/]*) 45105 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45106 ;; 45107 *) 45108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45109 for as_dir in $PATH 45110 do 45111 IFS=$as_save_IFS 45112 test -z "$as_dir" && as_dir=. 45113 for ac_exec_ext in '' $ac_executable_extensions; do 45114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45115 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45117 break 2 45118 fi 45119 done 45120 done 45121 IFS=$as_save_IFS 45122 45123 ;; 45124 esac 45125 fi 45126 BUILD_NM=$ac_cv_path_BUILD_NM 45127 if test -n "$BUILD_NM"; then 45128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45129 $as_echo "$BUILD_NM" >&6; } 45130 else 45131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45132 $as_echo "no" >&6; } 45133 fi 45134 45135 45136 test -n "$BUILD_NM" && break 45137 done 45138 45139 else 45140 # If it succeeded, then it was overridden by the user. We will use it 45141 # for the tool. 45142 45143 # First remove it from the list of overridden variables, so we can test 45144 # for unknown variables in the end. 45145 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45146 45147 # Check if we try to supply an empty value 45148 if test "x$BUILD_NM" = x; then 45149 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 45150 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 45151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45152 $as_echo_n "checking for BUILD_NM... " >&6; } 45153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45154 $as_echo "disabled" >&6; } 45155 else 45156 # Check if the provided tool contains a complete path. 45157 tool_specified="$BUILD_NM" 45158 tool_basename="${tool_specified##*/}" 45159 if test "x$tool_basename" = "x$tool_specified"; then 45160 # A command without a complete path is provided, search $PATH. 45161 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 45162 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 45163 # Extract the first word of "$tool_basename", so it can be a program name with args. 45164 set dummy $tool_basename; ac_word=$2 45165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45166 $as_echo_n "checking for $ac_word... " >&6; } 45167 if ${ac_cv_path_BUILD_NM+:} false; then : 45168 $as_echo_n "(cached) " >&6 45169 else 45170 case $BUILD_NM in 45171 [\\/]* | ?:[\\/]*) 45172 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45173 ;; 45174 *) 45175 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45176 for as_dir in $PATH 45177 do 45178 IFS=$as_save_IFS 45179 test -z "$as_dir" && as_dir=. 45180 for ac_exec_ext in '' $ac_executable_extensions; do 45181 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45182 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45183 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45184 break 2 45185 fi 45186 done 45187 done 45188 IFS=$as_save_IFS 45189 45190 ;; 45191 esac 45192 fi 45193 BUILD_NM=$ac_cv_path_BUILD_NM 45194 if test -n "$BUILD_NM"; then 45195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45196 $as_echo "$BUILD_NM" >&6; } 45197 else 45198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45199 $as_echo "no" >&6; } 45200 fi 45201 45202 45203 if test "x$BUILD_NM" = x; then 45204 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45205 fi 45206 else 45207 # Otherwise we believe it is a complete path. Use it as it is. 45208 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 45209 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 45210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45211 $as_echo_n "checking for BUILD_NM... " >&6; } 45212 if test ! -x "$tool_specified"; then 45213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45214 $as_echo "not found" >&6; } 45215 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 45216 fi 45217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45218 $as_echo "$tool_specified" >&6; } 45219 fi 45220 fi 45221 fi 45222 45223 fi 45224 45225 45226 45227 # Only process if variable expands to non-empty 45228 45229 if test "x$BUILD_NM" != x; then 45230 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45231 45232 # First separate the path from the arguments. This will split at the first 45233 # space. 45234 complete="$BUILD_NM" 45235 path="${complete%% *}" 45236 tmp="$complete EOL" 45237 arguments="${tmp#* }" 45238 45239 # Input might be given as Windows format, start by converting to 45240 # unix format. 45241 new_path=`$CYGPATH -u "$path"` 45242 45243 # Now try to locate executable using which 45244 new_path=`$WHICH "$new_path" 2> /dev/null` 45245 # bat and cmd files are not always considered executable in cygwin causing which 45246 # to not find them 45247 if test "x$new_path" = x \ 45248 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45249 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45250 new_path=`$CYGPATH -u "$path"` 45251 fi 45252 if test "x$new_path" = x; then 45253 # Oops. Which didn't find the executable. 45254 # The splitting of arguments from the executable at a space might have been incorrect, 45255 # since paths with space are more likely in Windows. Give it another try with the whole 45256 # argument. 45257 path="$complete" 45258 arguments="EOL" 45259 new_path=`$CYGPATH -u "$path"` 45260 new_path=`$WHICH "$new_path" 2> /dev/null` 45261 # bat and cmd files are not always considered executable in cygwin causing which 45262 # to not find them 45263 if test "x$new_path" = x \ 45264 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45265 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45266 new_path=`$CYGPATH -u "$path"` 45267 fi 45268 if test "x$new_path" = x; then 45269 # It's still not found. Now this is an unrecoverable error. 45270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45271 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45272 has_space=`$ECHO "$complete" | $GREP " "` 45273 if test "x$has_space" != x; then 45274 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45275 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45276 fi 45277 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45278 fi 45279 fi 45280 45281 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45282 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45283 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45284 # "foo.exe" is OK but "foo" is an error. 45285 # 45286 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45287 # It is also a way to make sure we got the proper file name for the real test later on. 45288 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45289 if test "x$test_shortpath" = x; then 45290 # Short path failed, file does not exist as specified. 45291 # Try adding .exe or .cmd 45292 if test -f "${new_path}.exe"; then 45293 input_to_shortpath="${new_path}.exe" 45294 elif test -f "${new_path}.cmd"; then 45295 input_to_shortpath="${new_path}.cmd" 45296 else 45297 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 45298 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 45299 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45300 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45301 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45302 fi 45303 else 45304 input_to_shortpath="$new_path" 45305 fi 45306 45307 # Call helper function which possibly converts this using DOS-style short mode. 45308 # If so, the updated path is stored in $new_path. 45309 new_path="$input_to_shortpath" 45310 45311 input_path="$input_to_shortpath" 45312 # Check if we need to convert this using DOS-style short mode. If the path 45313 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45314 # take no chances and rewrite it. 45315 # Note: m4 eats our [], so we need to use [ and ] instead. 45316 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45317 if test "x$has_forbidden_chars" != x; then 45318 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45319 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45320 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45321 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45322 # Going to short mode and back again did indeed matter. Since short mode is 45323 # case insensitive, let's make it lowercase to improve readability. 45324 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45325 # Now convert it back to Unix-style (cygpath) 45326 input_path=`$CYGPATH -u "$shortmode_path"` 45327 new_path="$input_path" 45328 fi 45329 fi 45330 45331 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45332 if test "x$test_cygdrive_prefix" = x; then 45333 # As a simple fix, exclude /usr/bin since it's not a real path. 45334 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45335 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45336 # a path prefixed by /cygdrive for fixpath to work. 45337 new_path="$CYGWIN_ROOT_PATH$input_path" 45338 fi 45339 fi 45340 45341 # remove trailing .exe if any 45342 new_path="${new_path/%.exe/}" 45343 45344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45345 45346 # First separate the path from the arguments. This will split at the first 45347 # space. 45348 complete="$BUILD_NM" 45349 path="${complete%% *}" 45350 tmp="$complete EOL" 45351 arguments="${tmp#* }" 45352 45353 # Input might be given as Windows format, start by converting to 45354 # unix format. 45355 new_path="$path" 45356 45357 windows_path="$new_path" 45358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45359 unix_path=`$CYGPATH -u "$windows_path"` 45360 new_path="$unix_path" 45361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45362 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45363 new_path="$unix_path" 45364 fi 45365 45366 45367 # Now try to locate executable using which 45368 new_path=`$WHICH "$new_path" 2> /dev/null` 45369 45370 if test "x$new_path" = x; then 45371 # Oops. Which didn't find the executable. 45372 # The splitting of arguments from the executable at a space might have been incorrect, 45373 # since paths with space are more likely in Windows. Give it another try with the whole 45374 # argument. 45375 path="$complete" 45376 arguments="EOL" 45377 new_path="$path" 45378 45379 windows_path="$new_path" 45380 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45381 unix_path=`$CYGPATH -u "$windows_path"` 45382 new_path="$unix_path" 45383 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45384 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45385 new_path="$unix_path" 45386 fi 45387 45388 45389 new_path=`$WHICH "$new_path" 2> /dev/null` 45390 # bat and cmd files are not always considered executable in MSYS causing which 45391 # to not find them 45392 if test "x$new_path" = x \ 45393 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45394 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45395 new_path="$path" 45396 45397 windows_path="$new_path" 45398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45399 unix_path=`$CYGPATH -u "$windows_path"` 45400 new_path="$unix_path" 45401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45402 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45403 new_path="$unix_path" 45404 fi 45405 45406 fi 45407 45408 if test "x$new_path" = x; then 45409 # It's still not found. Now this is an unrecoverable error. 45410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45411 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45412 has_space=`$ECHO "$complete" | $GREP " "` 45413 if test "x$has_space" != x; then 45414 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45415 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45416 fi 45417 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45418 fi 45419 fi 45420 45421 # Now new_path has a complete unix path to the binary 45422 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45423 # Keep paths in /bin as-is, but remove trailing .exe if any 45424 new_path="${new_path/%.exe/}" 45425 # Do not save /bin paths to all_fixpath_prefixes! 45426 else 45427 # Not in mixed or Windows style, start by that. 45428 new_path=`cmd //c echo $new_path` 45429 45430 input_path="$new_path" 45431 # Check if we need to convert this using DOS-style short mode. If the path 45432 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45433 # take no chances and rewrite it. 45434 # Note: m4 eats our [], so we need to use [ and ] instead. 45435 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45436 if test "x$has_forbidden_chars" != x; then 45437 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45438 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45439 fi 45440 45441 # Output is in $new_path 45442 45443 windows_path="$new_path" 45444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45445 unix_path=`$CYGPATH -u "$windows_path"` 45446 new_path="$unix_path" 45447 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45448 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45449 new_path="$unix_path" 45450 fi 45451 45452 # remove trailing .exe if any 45453 new_path="${new_path/%.exe/}" 45454 45455 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45456 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45457 fi 45458 45459 else 45460 # We're on a unix platform. Hooray! :) 45461 # First separate the path from the arguments. This will split at the first 45462 # space. 45463 complete="$BUILD_NM" 45464 path="${complete%% *}" 45465 tmp="$complete EOL" 45466 arguments="${tmp#* }" 45467 45468 # Cannot rely on the command "which" here since it doesn't always work. 45469 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45470 if test -z "$is_absolute_path"; then 45471 # Path to executable is not absolute. Find it. 45472 IFS_save="$IFS" 45473 IFS=: 45474 for p in $PATH; do 45475 if test -f "$p/$path" && test -x "$p/$path"; then 45476 new_path="$p/$path" 45477 break 45478 fi 45479 done 45480 IFS="$IFS_save" 45481 else 45482 # This is an absolute path, we can use it without further modifications. 45483 new_path="$path" 45484 fi 45485 45486 if test "x$new_path" = x; then 45487 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45488 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45489 has_space=`$ECHO "$complete" | $GREP " "` 45490 if test "x$has_space" != x; then 45491 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45492 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45493 fi 45494 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45495 fi 45496 fi 45497 45498 # Now join together the path and the arguments once again 45499 if test "x$arguments" != xEOL; then 45500 new_complete="$new_path ${arguments% *}" 45501 else 45502 new_complete="$new_path" 45503 fi 45504 45505 if test "x$complete" != "x$new_complete"; then 45506 BUILD_NM="$new_complete" 45507 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 45508 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 45509 fi 45510 fi 45511 45512 45513 45514 # Publish this variable in the help. 45515 45516 45517 if [ -z "${BUILD_AR+x}" ]; then 45518 # The variable is not set by user, try to locate tool using the code snippet 45519 for ac_prog in ar gcc-ar 45520 do 45521 # Extract the first word of "$ac_prog", so it can be a program name with args. 45522 set dummy $ac_prog; ac_word=$2 45523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45524 $as_echo_n "checking for $ac_word... " >&6; } 45525 if ${ac_cv_path_BUILD_AR+:} false; then : 45526 $as_echo_n "(cached) " >&6 45527 else 45528 case $BUILD_AR in 45529 [\\/]* | ?:[\\/]*) 45530 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45531 ;; 45532 *) 45533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45534 for as_dir in $PATH 45535 do 45536 IFS=$as_save_IFS 45537 test -z "$as_dir" && as_dir=. 45538 for ac_exec_ext in '' $ac_executable_extensions; do 45539 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45540 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45541 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45542 break 2 45543 fi 45544 done 45545 done 45546 IFS=$as_save_IFS 45547 45548 ;; 45549 esac 45550 fi 45551 BUILD_AR=$ac_cv_path_BUILD_AR 45552 if test -n "$BUILD_AR"; then 45553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45554 $as_echo "$BUILD_AR" >&6; } 45555 else 45556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45557 $as_echo "no" >&6; } 45558 fi 45559 45560 45561 test -n "$BUILD_AR" && break 45562 done 45563 45564 else 45565 # The variable is set, but is it from the command line or the environment? 45566 45567 # Try to remove the string !BUILD_AR! from our list. 45568 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 45569 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45570 # If it failed, the variable was not from the command line. Ignore it, 45571 # but warn the user (except for BASH, which is always set by the calling BASH). 45572 if test "xBUILD_AR" != xBASH; then 45573 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 45574 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 45575 fi 45576 # Try to locate tool using the code snippet 45577 for ac_prog in ar gcc-ar 45578 do 45579 # Extract the first word of "$ac_prog", so it can be a program name with args. 45580 set dummy $ac_prog; ac_word=$2 45581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45582 $as_echo_n "checking for $ac_word... " >&6; } 45583 if ${ac_cv_path_BUILD_AR+:} false; then : 45584 $as_echo_n "(cached) " >&6 45585 else 45586 case $BUILD_AR in 45587 [\\/]* | ?:[\\/]*) 45588 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45589 ;; 45590 *) 45591 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45592 for as_dir in $PATH 45593 do 45594 IFS=$as_save_IFS 45595 test -z "$as_dir" && as_dir=. 45596 for ac_exec_ext in '' $ac_executable_extensions; do 45597 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45598 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45599 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45600 break 2 45601 fi 45602 done 45603 done 45604 IFS=$as_save_IFS 45605 45606 ;; 45607 esac 45608 fi 45609 BUILD_AR=$ac_cv_path_BUILD_AR 45610 if test -n "$BUILD_AR"; then 45611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45612 $as_echo "$BUILD_AR" >&6; } 45613 else 45614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45615 $as_echo "no" >&6; } 45616 fi 45617 45618 45619 test -n "$BUILD_AR" && break 45620 done 45621 45622 else 45623 # If it succeeded, then it was overridden by the user. We will use it 45624 # for the tool. 45625 45626 # First remove it from the list of overridden variables, so we can test 45627 # for unknown variables in the end. 45628 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45629 45630 # Check if we try to supply an empty value 45631 if test "x$BUILD_AR" = x; then 45632 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 45633 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 45634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 45635 $as_echo_n "checking for BUILD_AR... " >&6; } 45636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45637 $as_echo "disabled" >&6; } 45638 else 45639 # Check if the provided tool contains a complete path. 45640 tool_specified="$BUILD_AR" 45641 tool_basename="${tool_specified##*/}" 45642 if test "x$tool_basename" = "x$tool_specified"; then 45643 # A command without a complete path is provided, search $PATH. 45644 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 45645 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 45646 # Extract the first word of "$tool_basename", so it can be a program name with args. 45647 set dummy $tool_basename; ac_word=$2 45648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45649 $as_echo_n "checking for $ac_word... " >&6; } 45650 if ${ac_cv_path_BUILD_AR+:} false; then : 45651 $as_echo_n "(cached) " >&6 45652 else 45653 case $BUILD_AR in 45654 [\\/]* | ?:[\\/]*) 45655 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45656 ;; 45657 *) 45658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45659 for as_dir in $PATH 45660 do 45661 IFS=$as_save_IFS 45662 test -z "$as_dir" && as_dir=. 45663 for ac_exec_ext in '' $ac_executable_extensions; do 45664 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45665 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45666 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45667 break 2 45668 fi 45669 done 45670 done 45671 IFS=$as_save_IFS 45672 45673 ;; 45674 esac 45675 fi 45676 BUILD_AR=$ac_cv_path_BUILD_AR 45677 if test -n "$BUILD_AR"; then 45678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45679 $as_echo "$BUILD_AR" >&6; } 45680 else 45681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45682 $as_echo "no" >&6; } 45683 fi 45684 45685 45686 if test "x$BUILD_AR" = x; then 45687 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45688 fi 45689 else 45690 # Otherwise we believe it is a complete path. Use it as it is. 45691 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 45692 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 45693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 45694 $as_echo_n "checking for BUILD_AR... " >&6; } 45695 if test ! -x "$tool_specified"; then 45696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45697 $as_echo "not found" >&6; } 45698 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 45699 fi 45700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45701 $as_echo "$tool_specified" >&6; } 45702 fi 45703 fi 45704 fi 45705 45706 fi 45707 45708 45709 45710 # Only process if variable expands to non-empty 45711 45712 if test "x$BUILD_AR" != x; then 45713 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45714 45715 # First separate the path from the arguments. This will split at the first 45716 # space. 45717 complete="$BUILD_AR" 45718 path="${complete%% *}" 45719 tmp="$complete EOL" 45720 arguments="${tmp#* }" 45721 45722 # Input might be given as Windows format, start by converting to 45723 # unix format. 45724 new_path=`$CYGPATH -u "$path"` 45725 45726 # Now try to locate executable using which 45727 new_path=`$WHICH "$new_path" 2> /dev/null` 45728 # bat and cmd files are not always considered executable in cygwin causing which 45729 # to not find them 45730 if test "x$new_path" = x \ 45731 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45732 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45733 new_path=`$CYGPATH -u "$path"` 45734 fi 45735 if test "x$new_path" = x; then 45736 # Oops. Which didn't find the executable. 45737 # The splitting of arguments from the executable at a space might have been incorrect, 45738 # since paths with space are more likely in Windows. Give it another try with the whole 45739 # argument. 45740 path="$complete" 45741 arguments="EOL" 45742 new_path=`$CYGPATH -u "$path"` 45743 new_path=`$WHICH "$new_path" 2> /dev/null` 45744 # bat and cmd files are not always considered executable in cygwin causing which 45745 # to not find them 45746 if test "x$new_path" = x \ 45747 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45748 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45749 new_path=`$CYGPATH -u "$path"` 45750 fi 45751 if test "x$new_path" = x; then 45752 # It's still not found. Now this is an unrecoverable error. 45753 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45754 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45755 has_space=`$ECHO "$complete" | $GREP " "` 45756 if test "x$has_space" != x; then 45757 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45758 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45759 fi 45760 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45761 fi 45762 fi 45763 45764 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45765 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45766 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45767 # "foo.exe" is OK but "foo" is an error. 45768 # 45769 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45770 # It is also a way to make sure we got the proper file name for the real test later on. 45771 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45772 if test "x$test_shortpath" = x; then 45773 # Short path failed, file does not exist as specified. 45774 # Try adding .exe or .cmd 45775 if test -f "${new_path}.exe"; then 45776 input_to_shortpath="${new_path}.exe" 45777 elif test -f "${new_path}.cmd"; then 45778 input_to_shortpath="${new_path}.cmd" 45779 else 45780 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 45781 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 45782 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45783 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45784 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45785 fi 45786 else 45787 input_to_shortpath="$new_path" 45788 fi 45789 45790 # Call helper function which possibly converts this using DOS-style short mode. 45791 # If so, the updated path is stored in $new_path. 45792 new_path="$input_to_shortpath" 45793 45794 input_path="$input_to_shortpath" 45795 # Check if we need to convert this using DOS-style short mode. If the path 45796 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45797 # take no chances and rewrite it. 45798 # Note: m4 eats our [], so we need to use [ and ] instead. 45799 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45800 if test "x$has_forbidden_chars" != x; then 45801 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45802 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45803 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45804 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45805 # Going to short mode and back again did indeed matter. Since short mode is 45806 # case insensitive, let's make it lowercase to improve readability. 45807 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45808 # Now convert it back to Unix-style (cygpath) 45809 input_path=`$CYGPATH -u "$shortmode_path"` 45810 new_path="$input_path" 45811 fi 45812 fi 45813 45814 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45815 if test "x$test_cygdrive_prefix" = x; then 45816 # As a simple fix, exclude /usr/bin since it's not a real path. 45817 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45818 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45819 # a path prefixed by /cygdrive for fixpath to work. 45820 new_path="$CYGWIN_ROOT_PATH$input_path" 45821 fi 45822 fi 45823 45824 # remove trailing .exe if any 45825 new_path="${new_path/%.exe/}" 45826 45827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45828 45829 # First separate the path from the arguments. This will split at the first 45830 # space. 45831 complete="$BUILD_AR" 45832 path="${complete%% *}" 45833 tmp="$complete EOL" 45834 arguments="${tmp#* }" 45835 45836 # Input might be given as Windows format, start by converting to 45837 # unix format. 45838 new_path="$path" 45839 45840 windows_path="$new_path" 45841 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45842 unix_path=`$CYGPATH -u "$windows_path"` 45843 new_path="$unix_path" 45844 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45845 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45846 new_path="$unix_path" 45847 fi 45848 45849 45850 # Now try to locate executable using which 45851 new_path=`$WHICH "$new_path" 2> /dev/null` 45852 45853 if test "x$new_path" = x; then 45854 # Oops. Which didn't find the executable. 45855 # The splitting of arguments from the executable at a space might have been incorrect, 45856 # since paths with space are more likely in Windows. Give it another try with the whole 45857 # argument. 45858 path="$complete" 45859 arguments="EOL" 45860 new_path="$path" 45861 45862 windows_path="$new_path" 45863 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45864 unix_path=`$CYGPATH -u "$windows_path"` 45865 new_path="$unix_path" 45866 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45867 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45868 new_path="$unix_path" 45869 fi 45870 45871 45872 new_path=`$WHICH "$new_path" 2> /dev/null` 45873 # bat and cmd files are not always considered executable in MSYS causing which 45874 # to not find them 45875 if test "x$new_path" = x \ 45876 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45877 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45878 new_path="$path" 45879 45880 windows_path="$new_path" 45881 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45882 unix_path=`$CYGPATH -u "$windows_path"` 45883 new_path="$unix_path" 45884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45885 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45886 new_path="$unix_path" 45887 fi 45888 45889 fi 45890 45891 if test "x$new_path" = x; then 45892 # It's still not found. Now this is an unrecoverable error. 45893 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45894 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45895 has_space=`$ECHO "$complete" | $GREP " "` 45896 if test "x$has_space" != x; then 45897 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45898 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45899 fi 45900 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45901 fi 45902 fi 45903 45904 # Now new_path has a complete unix path to the binary 45905 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45906 # Keep paths in /bin as-is, but remove trailing .exe if any 45907 new_path="${new_path/%.exe/}" 45908 # Do not save /bin paths to all_fixpath_prefixes! 45909 else 45910 # Not in mixed or Windows style, start by that. 45911 new_path=`cmd //c echo $new_path` 45912 45913 input_path="$new_path" 45914 # Check if we need to convert this using DOS-style short mode. If the path 45915 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45916 # take no chances and rewrite it. 45917 # Note: m4 eats our [], so we need to use [ and ] instead. 45918 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45919 if test "x$has_forbidden_chars" != x; then 45920 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45921 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45922 fi 45923 45924 # Output is in $new_path 45925 45926 windows_path="$new_path" 45927 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45928 unix_path=`$CYGPATH -u "$windows_path"` 45929 new_path="$unix_path" 45930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45931 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45932 new_path="$unix_path" 45933 fi 45934 45935 # remove trailing .exe if any 45936 new_path="${new_path/%.exe/}" 45937 45938 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45939 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45940 fi 45941 45942 else 45943 # We're on a unix platform. Hooray! :) 45944 # First separate the path from the arguments. This will split at the first 45945 # space. 45946 complete="$BUILD_AR" 45947 path="${complete%% *}" 45948 tmp="$complete EOL" 45949 arguments="${tmp#* }" 45950 45951 # Cannot rely on the command "which" here since it doesn't always work. 45952 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45953 if test -z "$is_absolute_path"; then 45954 # Path to executable is not absolute. Find it. 45955 IFS_save="$IFS" 45956 IFS=: 45957 for p in $PATH; do 45958 if test -f "$p/$path" && test -x "$p/$path"; then 45959 new_path="$p/$path" 45960 break 45961 fi 45962 done 45963 IFS="$IFS_save" 45964 else 45965 # This is an absolute path, we can use it without further modifications. 45966 new_path="$path" 45967 fi 45968 45969 if test "x$new_path" = x; then 45970 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45971 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45972 has_space=`$ECHO "$complete" | $GREP " "` 45973 if test "x$has_space" != x; then 45974 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45975 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45976 fi 45977 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45978 fi 45979 fi 45980 45981 # Now join together the path and the arguments once again 45982 if test "x$arguments" != xEOL; then 45983 new_complete="$new_path ${arguments% *}" 45984 else 45985 new_complete="$new_path" 45986 fi 45987 45988 if test "x$complete" != "x$new_complete"; then 45989 BUILD_AR="$new_complete" 45990 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 45991 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 45992 fi 45993 fi 45994 45995 45996 45997 # Publish this variable in the help. 45998 45999 46000 if [ -z "${BUILD_OBJCOPY+x}" ]; then 46001 # The variable is not set by user, try to locate tool using the code snippet 46002 for ac_prog in objcopy 46003 do 46004 # Extract the first word of "$ac_prog", so it can be a program name with args. 46005 set dummy $ac_prog; ac_word=$2 46006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46007 $as_echo_n "checking for $ac_word... " >&6; } 46008 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46009 $as_echo_n "(cached) " >&6 46010 else 46011 case $BUILD_OBJCOPY in 46012 [\\/]* | ?:[\\/]*) 46013 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46014 ;; 46015 *) 46016 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46017 for as_dir in $PATH 46018 do 46019 IFS=$as_save_IFS 46020 test -z "$as_dir" && as_dir=. 46021 for ac_exec_ext in '' $ac_executable_extensions; do 46022 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46023 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46024 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46025 break 2 46026 fi 46027 done 46028 done 46029 IFS=$as_save_IFS 46030 46031 ;; 46032 esac 46033 fi 46034 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46035 if test -n "$BUILD_OBJCOPY"; then 46036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46037 $as_echo "$BUILD_OBJCOPY" >&6; } 46038 else 46039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46040 $as_echo "no" >&6; } 46041 fi 46042 46043 46044 test -n "$BUILD_OBJCOPY" && break 46045 done 46046 46047 else 46048 # The variable is set, but is it from the command line or the environment? 46049 46050 # Try to remove the string !BUILD_OBJCOPY! from our list. 46051 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 46052 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46053 # If it failed, the variable was not from the command line. Ignore it, 46054 # but warn the user (except for BASH, which is always set by the calling BASH). 46055 if test "xBUILD_OBJCOPY" != xBASH; then 46056 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 46057 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 46058 fi 46059 # Try to locate tool using the code snippet 46060 for ac_prog in objcopy 46061 do 46062 # Extract the first word of "$ac_prog", so it can be a program name with args. 46063 set dummy $ac_prog; ac_word=$2 46064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46065 $as_echo_n "checking for $ac_word... " >&6; } 46066 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46067 $as_echo_n "(cached) " >&6 46068 else 46069 case $BUILD_OBJCOPY in 46070 [\\/]* | ?:[\\/]*) 46071 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46072 ;; 46073 *) 46074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46075 for as_dir in $PATH 46076 do 46077 IFS=$as_save_IFS 46078 test -z "$as_dir" && as_dir=. 46079 for ac_exec_ext in '' $ac_executable_extensions; do 46080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46081 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46083 break 2 46084 fi 46085 done 46086 done 46087 IFS=$as_save_IFS 46088 46089 ;; 46090 esac 46091 fi 46092 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46093 if test -n "$BUILD_OBJCOPY"; then 46094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46095 $as_echo "$BUILD_OBJCOPY" >&6; } 46096 else 46097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46098 $as_echo "no" >&6; } 46099 fi 46100 46101 46102 test -n "$BUILD_OBJCOPY" && break 46103 done 46104 46105 else 46106 # If it succeeded, then it was overridden by the user. We will use it 46107 # for the tool. 46108 46109 # First remove it from the list of overridden variables, so we can test 46110 # for unknown variables in the end. 46111 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46112 46113 # Check if we try to supply an empty value 46114 if test "x$BUILD_OBJCOPY" = x; then 46115 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 46116 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 46117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46118 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46120 $as_echo "disabled" >&6; } 46121 else 46122 # Check if the provided tool contains a complete path. 46123 tool_specified="$BUILD_OBJCOPY" 46124 tool_basename="${tool_specified##*/}" 46125 if test "x$tool_basename" = "x$tool_specified"; then 46126 # A command without a complete path is provided, search $PATH. 46127 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 46128 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 46129 # Extract the first word of "$tool_basename", so it can be a program name with args. 46130 set dummy $tool_basename; ac_word=$2 46131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46132 $as_echo_n "checking for $ac_word... " >&6; } 46133 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46134 $as_echo_n "(cached) " >&6 46135 else 46136 case $BUILD_OBJCOPY in 46137 [\\/]* | ?:[\\/]*) 46138 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46139 ;; 46140 *) 46141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46142 for as_dir in $PATH 46143 do 46144 IFS=$as_save_IFS 46145 test -z "$as_dir" && as_dir=. 46146 for ac_exec_ext in '' $ac_executable_extensions; do 46147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46148 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46150 break 2 46151 fi 46152 done 46153 done 46154 IFS=$as_save_IFS 46155 46156 ;; 46157 esac 46158 fi 46159 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46160 if test -n "$BUILD_OBJCOPY"; then 46161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46162 $as_echo "$BUILD_OBJCOPY" >&6; } 46163 else 46164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46165 $as_echo "no" >&6; } 46166 fi 46167 46168 46169 if test "x$BUILD_OBJCOPY" = x; then 46170 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46171 fi 46172 else 46173 # Otherwise we believe it is a complete path. Use it as it is. 46174 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 46175 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 46176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46177 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46178 if test ! -x "$tool_specified"; then 46179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46180 $as_echo "not found" >&6; } 46181 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 46182 fi 46183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46184 $as_echo "$tool_specified" >&6; } 46185 fi 46186 fi 46187 fi 46188 46189 fi 46190 46191 46192 46193 # Only process if variable expands to non-empty 46194 46195 if test "x$BUILD_OBJCOPY" != x; then 46196 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46197 46198 # First separate the path from the arguments. This will split at the first 46199 # space. 46200 complete="$BUILD_OBJCOPY" 46201 path="${complete%% *}" 46202 tmp="$complete EOL" 46203 arguments="${tmp#* }" 46204 46205 # Input might be given as Windows format, start by converting to 46206 # unix format. 46207 new_path=`$CYGPATH -u "$path"` 46208 46209 # Now try to locate executable using which 46210 new_path=`$WHICH "$new_path" 2> /dev/null` 46211 # bat and cmd files are not always considered executable in cygwin causing which 46212 # to not find them 46213 if test "x$new_path" = x \ 46214 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46215 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46216 new_path=`$CYGPATH -u "$path"` 46217 fi 46218 if test "x$new_path" = x; then 46219 # Oops. Which didn't find the executable. 46220 # The splitting of arguments from the executable at a space might have been incorrect, 46221 # since paths with space are more likely in Windows. Give it another try with the whole 46222 # argument. 46223 path="$complete" 46224 arguments="EOL" 46225 new_path=`$CYGPATH -u "$path"` 46226 new_path=`$WHICH "$new_path" 2> /dev/null` 46227 # bat and cmd files are not always considered executable in cygwin causing which 46228 # to not find them 46229 if test "x$new_path" = x \ 46230 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46231 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46232 new_path=`$CYGPATH -u "$path"` 46233 fi 46234 if test "x$new_path" = x; then 46235 # It's still not found. Now this is an unrecoverable error. 46236 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46237 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46238 has_space=`$ECHO "$complete" | $GREP " "` 46239 if test "x$has_space" != x; then 46240 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46241 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46242 fi 46243 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46244 fi 46245 fi 46246 46247 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46248 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46249 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46250 # "foo.exe" is OK but "foo" is an error. 46251 # 46252 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46253 # It is also a way to make sure we got the proper file name for the real test later on. 46254 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46255 if test "x$test_shortpath" = x; then 46256 # Short path failed, file does not exist as specified. 46257 # Try adding .exe or .cmd 46258 if test -f "${new_path}.exe"; then 46259 input_to_shortpath="${new_path}.exe" 46260 elif test -f "${new_path}.cmd"; then 46261 input_to_shortpath="${new_path}.cmd" 46262 else 46263 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 46264 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 46265 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46266 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46267 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46268 fi 46269 else 46270 input_to_shortpath="$new_path" 46271 fi 46272 46273 # Call helper function which possibly converts this using DOS-style short mode. 46274 # If so, the updated path is stored in $new_path. 46275 new_path="$input_to_shortpath" 46276 46277 input_path="$input_to_shortpath" 46278 # Check if we need to convert this using DOS-style short mode. If the path 46279 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46280 # take no chances and rewrite it. 46281 # Note: m4 eats our [], so we need to use [ and ] instead. 46282 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46283 if test "x$has_forbidden_chars" != x; then 46284 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46285 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46286 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46287 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46288 # Going to short mode and back again did indeed matter. Since short mode is 46289 # case insensitive, let's make it lowercase to improve readability. 46290 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46291 # Now convert it back to Unix-style (cygpath) 46292 input_path=`$CYGPATH -u "$shortmode_path"` 46293 new_path="$input_path" 46294 fi 46295 fi 46296 46297 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46298 if test "x$test_cygdrive_prefix" = x; then 46299 # As a simple fix, exclude /usr/bin since it's not a real path. 46300 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46301 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46302 # a path prefixed by /cygdrive for fixpath to work. 46303 new_path="$CYGWIN_ROOT_PATH$input_path" 46304 fi 46305 fi 46306 46307 # remove trailing .exe if any 46308 new_path="${new_path/%.exe/}" 46309 46310 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46311 46312 # First separate the path from the arguments. This will split at the first 46313 # space. 46314 complete="$BUILD_OBJCOPY" 46315 path="${complete%% *}" 46316 tmp="$complete EOL" 46317 arguments="${tmp#* }" 46318 46319 # Input might be given as Windows format, start by converting to 46320 # unix format. 46321 new_path="$path" 46322 46323 windows_path="$new_path" 46324 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46325 unix_path=`$CYGPATH -u "$windows_path"` 46326 new_path="$unix_path" 46327 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46328 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46329 new_path="$unix_path" 46330 fi 46331 46332 46333 # Now try to locate executable using which 46334 new_path=`$WHICH "$new_path" 2> /dev/null` 46335 46336 if test "x$new_path" = x; then 46337 # Oops. Which didn't find the executable. 46338 # The splitting of arguments from the executable at a space might have been incorrect, 46339 # since paths with space are more likely in Windows. Give it another try with the whole 46340 # argument. 46341 path="$complete" 46342 arguments="EOL" 46343 new_path="$path" 46344 46345 windows_path="$new_path" 46346 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46347 unix_path=`$CYGPATH -u "$windows_path"` 46348 new_path="$unix_path" 46349 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46350 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46351 new_path="$unix_path" 46352 fi 46353 46354 46355 new_path=`$WHICH "$new_path" 2> /dev/null` 46356 # bat and cmd files are not always considered executable in MSYS causing which 46357 # to not find them 46358 if test "x$new_path" = x \ 46359 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46360 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46361 new_path="$path" 46362 46363 windows_path="$new_path" 46364 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46365 unix_path=`$CYGPATH -u "$windows_path"` 46366 new_path="$unix_path" 46367 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46368 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46369 new_path="$unix_path" 46370 fi 46371 46372 fi 46373 46374 if test "x$new_path" = x; then 46375 # It's still not found. Now this is an unrecoverable error. 46376 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46377 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46378 has_space=`$ECHO "$complete" | $GREP " "` 46379 if test "x$has_space" != x; then 46380 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46381 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46382 fi 46383 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46384 fi 46385 fi 46386 46387 # Now new_path has a complete unix path to the binary 46388 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46389 # Keep paths in /bin as-is, but remove trailing .exe if any 46390 new_path="${new_path/%.exe/}" 46391 # Do not save /bin paths to all_fixpath_prefixes! 46392 else 46393 # Not in mixed or Windows style, start by that. 46394 new_path=`cmd //c echo $new_path` 46395 46396 input_path="$new_path" 46397 # Check if we need to convert this using DOS-style short mode. If the path 46398 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46399 # take no chances and rewrite it. 46400 # Note: m4 eats our [], so we need to use [ and ] instead. 46401 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46402 if test "x$has_forbidden_chars" != x; then 46403 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46404 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46405 fi 46406 46407 # Output is in $new_path 46408 46409 windows_path="$new_path" 46410 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46411 unix_path=`$CYGPATH -u "$windows_path"` 46412 new_path="$unix_path" 46413 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46414 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46415 new_path="$unix_path" 46416 fi 46417 46418 # remove trailing .exe if any 46419 new_path="${new_path/%.exe/}" 46420 46421 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46422 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46423 fi 46424 46425 else 46426 # We're on a unix platform. Hooray! :) 46427 # First separate the path from the arguments. This will split at the first 46428 # space. 46429 complete="$BUILD_OBJCOPY" 46430 path="${complete%% *}" 46431 tmp="$complete EOL" 46432 arguments="${tmp#* }" 46433 46434 # Cannot rely on the command "which" here since it doesn't always work. 46435 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46436 if test -z "$is_absolute_path"; then 46437 # Path to executable is not absolute. Find it. 46438 IFS_save="$IFS" 46439 IFS=: 46440 for p in $PATH; do 46441 if test -f "$p/$path" && test -x "$p/$path"; then 46442 new_path="$p/$path" 46443 break 46444 fi 46445 done 46446 IFS="$IFS_save" 46447 else 46448 # This is an absolute path, we can use it without further modifications. 46449 new_path="$path" 46450 fi 46451 46452 if test "x$new_path" = x; then 46453 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46454 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46455 has_space=`$ECHO "$complete" | $GREP " "` 46456 if test "x$has_space" != x; then 46457 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46458 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46459 fi 46460 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46461 fi 46462 fi 46463 46464 # Now join together the path and the arguments once again 46465 if test "x$arguments" != xEOL; then 46466 new_complete="$new_path ${arguments% *}" 46467 else 46468 new_complete="$new_path" 46469 fi 46470 46471 if test "x$complete" != "x$new_complete"; then 46472 BUILD_OBJCOPY="$new_complete" 46473 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 46474 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 46475 fi 46476 fi 46477 46478 46479 46480 # Publish this variable in the help. 46481 46482 46483 if [ -z "${BUILD_STRIP+x}" ]; then 46484 # The variable is not set by user, try to locate tool using the code snippet 46485 for ac_prog in strip 46486 do 46487 # Extract the first word of "$ac_prog", so it can be a program name with args. 46488 set dummy $ac_prog; ac_word=$2 46489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46490 $as_echo_n "checking for $ac_word... " >&6; } 46491 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46492 $as_echo_n "(cached) " >&6 46493 else 46494 case $BUILD_STRIP in 46495 [\\/]* | ?:[\\/]*) 46496 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46497 ;; 46498 *) 46499 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46500 for as_dir in $PATH 46501 do 46502 IFS=$as_save_IFS 46503 test -z "$as_dir" && as_dir=. 46504 for ac_exec_ext in '' $ac_executable_extensions; do 46505 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46506 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46507 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46508 break 2 46509 fi 46510 done 46511 done 46512 IFS=$as_save_IFS 46513 46514 ;; 46515 esac 46516 fi 46517 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46518 if test -n "$BUILD_STRIP"; then 46519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46520 $as_echo "$BUILD_STRIP" >&6; } 46521 else 46522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46523 $as_echo "no" >&6; } 46524 fi 46525 46526 46527 test -n "$BUILD_STRIP" && break 46528 done 46529 46530 else 46531 # The variable is set, but is it from the command line or the environment? 46532 46533 # Try to remove the string !BUILD_STRIP! from our list. 46534 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 46535 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46536 # If it failed, the variable was not from the command line. Ignore it, 46537 # but warn the user (except for BASH, which is always set by the calling BASH). 46538 if test "xBUILD_STRIP" != xBASH; then 46539 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 46540 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 46541 fi 46542 # Try to locate tool using the code snippet 46543 for ac_prog in strip 46544 do 46545 # Extract the first word of "$ac_prog", so it can be a program name with args. 46546 set dummy $ac_prog; ac_word=$2 46547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46548 $as_echo_n "checking for $ac_word... " >&6; } 46549 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46550 $as_echo_n "(cached) " >&6 46551 else 46552 case $BUILD_STRIP in 46553 [\\/]* | ?:[\\/]*) 46554 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46555 ;; 46556 *) 46557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46558 for as_dir in $PATH 46559 do 46560 IFS=$as_save_IFS 46561 test -z "$as_dir" && as_dir=. 46562 for ac_exec_ext in '' $ac_executable_extensions; do 46563 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46564 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46566 break 2 46567 fi 46568 done 46569 done 46570 IFS=$as_save_IFS 46571 46572 ;; 46573 esac 46574 fi 46575 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46576 if test -n "$BUILD_STRIP"; then 46577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46578 $as_echo "$BUILD_STRIP" >&6; } 46579 else 46580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46581 $as_echo "no" >&6; } 46582 fi 46583 46584 46585 test -n "$BUILD_STRIP" && break 46586 done 46587 46588 else 46589 # If it succeeded, then it was overridden by the user. We will use it 46590 # for the tool. 46591 46592 # First remove it from the list of overridden variables, so we can test 46593 # for unknown variables in the end. 46594 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46595 46596 # Check if we try to supply an empty value 46597 if test "x$BUILD_STRIP" = x; then 46598 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 46599 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 46600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 46601 $as_echo_n "checking for BUILD_STRIP... " >&6; } 46602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46603 $as_echo "disabled" >&6; } 46604 else 46605 # Check if the provided tool contains a complete path. 46606 tool_specified="$BUILD_STRIP" 46607 tool_basename="${tool_specified##*/}" 46608 if test "x$tool_basename" = "x$tool_specified"; then 46609 # A command without a complete path is provided, search $PATH. 46610 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 46611 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 46612 # Extract the first word of "$tool_basename", so it can be a program name with args. 46613 set dummy $tool_basename; ac_word=$2 46614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46615 $as_echo_n "checking for $ac_word... " >&6; } 46616 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46617 $as_echo_n "(cached) " >&6 46618 else 46619 case $BUILD_STRIP in 46620 [\\/]* | ?:[\\/]*) 46621 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46622 ;; 46623 *) 46624 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46625 for as_dir in $PATH 46626 do 46627 IFS=$as_save_IFS 46628 test -z "$as_dir" && as_dir=. 46629 for ac_exec_ext in '' $ac_executable_extensions; do 46630 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46631 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46632 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46633 break 2 46634 fi 46635 done 46636 done 46637 IFS=$as_save_IFS 46638 46639 ;; 46640 esac 46641 fi 46642 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46643 if test -n "$BUILD_STRIP"; then 46644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46645 $as_echo "$BUILD_STRIP" >&6; } 46646 else 46647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46648 $as_echo "no" >&6; } 46649 fi 46650 46651 46652 if test "x$BUILD_STRIP" = x; then 46653 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46654 fi 46655 else 46656 # Otherwise we believe it is a complete path. Use it as it is. 46657 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 46658 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 46659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 46660 $as_echo_n "checking for BUILD_STRIP... " >&6; } 46661 if test ! -x "$tool_specified"; then 46662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46663 $as_echo "not found" >&6; } 46664 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 46665 fi 46666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46667 $as_echo "$tool_specified" >&6; } 46668 fi 46669 fi 46670 fi 46671 46672 fi 46673 46674 46675 46676 # Only process if variable expands to non-empty 46677 46678 if test "x$BUILD_STRIP" != x; then 46679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46680 46681 # First separate the path from the arguments. This will split at the first 46682 # space. 46683 complete="$BUILD_STRIP" 46684 path="${complete%% *}" 46685 tmp="$complete EOL" 46686 arguments="${tmp#* }" 46687 46688 # Input might be given as Windows format, start by converting to 46689 # unix format. 46690 new_path=`$CYGPATH -u "$path"` 46691 46692 # Now try to locate executable using which 46693 new_path=`$WHICH "$new_path" 2> /dev/null` 46694 # bat and cmd files are not always considered executable in cygwin causing which 46695 # to not find them 46696 if test "x$new_path" = x \ 46697 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46698 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46699 new_path=`$CYGPATH -u "$path"` 46700 fi 46701 if test "x$new_path" = x; then 46702 # Oops. Which didn't find the executable. 46703 # The splitting of arguments from the executable at a space might have been incorrect, 46704 # since paths with space are more likely in Windows. Give it another try with the whole 46705 # argument. 46706 path="$complete" 46707 arguments="EOL" 46708 new_path=`$CYGPATH -u "$path"` 46709 new_path=`$WHICH "$new_path" 2> /dev/null` 46710 # bat and cmd files are not always considered executable in cygwin causing which 46711 # to not find them 46712 if test "x$new_path" = x \ 46713 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46714 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46715 new_path=`$CYGPATH -u "$path"` 46716 fi 46717 if test "x$new_path" = x; then 46718 # It's still not found. Now this is an unrecoverable error. 46719 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46720 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46721 has_space=`$ECHO "$complete" | $GREP " "` 46722 if test "x$has_space" != x; then 46723 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46724 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46725 fi 46726 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46727 fi 46728 fi 46729 46730 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46731 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46732 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46733 # "foo.exe" is OK but "foo" is an error. 46734 # 46735 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46736 # It is also a way to make sure we got the proper file name for the real test later on. 46737 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46738 if test "x$test_shortpath" = x; then 46739 # Short path failed, file does not exist as specified. 46740 # Try adding .exe or .cmd 46741 if test -f "${new_path}.exe"; then 46742 input_to_shortpath="${new_path}.exe" 46743 elif test -f "${new_path}.cmd"; then 46744 input_to_shortpath="${new_path}.cmd" 46745 else 46746 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 46747 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 46748 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46749 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46750 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46751 fi 46752 else 46753 input_to_shortpath="$new_path" 46754 fi 46755 46756 # Call helper function which possibly converts this using DOS-style short mode. 46757 # If so, the updated path is stored in $new_path. 46758 new_path="$input_to_shortpath" 46759 46760 input_path="$input_to_shortpath" 46761 # Check if we need to convert this using DOS-style short mode. If the path 46762 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46763 # take no chances and rewrite it. 46764 # Note: m4 eats our [], so we need to use [ and ] instead. 46765 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46766 if test "x$has_forbidden_chars" != x; then 46767 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46768 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46769 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46770 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46771 # Going to short mode and back again did indeed matter. Since short mode is 46772 # case insensitive, let's make it lowercase to improve readability. 46773 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46774 # Now convert it back to Unix-style (cygpath) 46775 input_path=`$CYGPATH -u "$shortmode_path"` 46776 new_path="$input_path" 46777 fi 46778 fi 46779 46780 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46781 if test "x$test_cygdrive_prefix" = x; then 46782 # As a simple fix, exclude /usr/bin since it's not a real path. 46783 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46784 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46785 # a path prefixed by /cygdrive for fixpath to work. 46786 new_path="$CYGWIN_ROOT_PATH$input_path" 46787 fi 46788 fi 46789 46790 # remove trailing .exe if any 46791 new_path="${new_path/%.exe/}" 46792 46793 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46794 46795 # First separate the path from the arguments. This will split at the first 46796 # space. 46797 complete="$BUILD_STRIP" 46798 path="${complete%% *}" 46799 tmp="$complete EOL" 46800 arguments="${tmp#* }" 46801 46802 # Input might be given as Windows format, start by converting to 46803 # unix format. 46804 new_path="$path" 46805 46806 windows_path="$new_path" 46807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46808 unix_path=`$CYGPATH -u "$windows_path"` 46809 new_path="$unix_path" 46810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46811 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46812 new_path="$unix_path" 46813 fi 46814 46815 46816 # Now try to locate executable using which 46817 new_path=`$WHICH "$new_path" 2> /dev/null` 46818 46819 if test "x$new_path" = x; then 46820 # Oops. Which didn't find the executable. 46821 # The splitting of arguments from the executable at a space might have been incorrect, 46822 # since paths with space are more likely in Windows. Give it another try with the whole 46823 # argument. 46824 path="$complete" 46825 arguments="EOL" 46826 new_path="$path" 46827 46828 windows_path="$new_path" 46829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46830 unix_path=`$CYGPATH -u "$windows_path"` 46831 new_path="$unix_path" 46832 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46833 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46834 new_path="$unix_path" 46835 fi 46836 46837 46838 new_path=`$WHICH "$new_path" 2> /dev/null` 46839 # bat and cmd files are not always considered executable in MSYS causing which 46840 # to not find them 46841 if test "x$new_path" = x \ 46842 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46843 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46844 new_path="$path" 46845 46846 windows_path="$new_path" 46847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46848 unix_path=`$CYGPATH -u "$windows_path"` 46849 new_path="$unix_path" 46850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46851 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46852 new_path="$unix_path" 46853 fi 46854 46855 fi 46856 46857 if test "x$new_path" = x; then 46858 # It's still not found. Now this is an unrecoverable error. 46859 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46860 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46861 has_space=`$ECHO "$complete" | $GREP " "` 46862 if test "x$has_space" != x; then 46863 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46864 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46865 fi 46866 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46867 fi 46868 fi 46869 46870 # Now new_path has a complete unix path to the binary 46871 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46872 # Keep paths in /bin as-is, but remove trailing .exe if any 46873 new_path="${new_path/%.exe/}" 46874 # Do not save /bin paths to all_fixpath_prefixes! 46875 else 46876 # Not in mixed or Windows style, start by that. 46877 new_path=`cmd //c echo $new_path` 46878 46879 input_path="$new_path" 46880 # Check if we need to convert this using DOS-style short mode. If the path 46881 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46882 # take no chances and rewrite it. 46883 # Note: m4 eats our [], so we need to use [ and ] instead. 46884 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46885 if test "x$has_forbidden_chars" != x; then 46886 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46887 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46888 fi 46889 46890 # Output is in $new_path 46891 46892 windows_path="$new_path" 46893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46894 unix_path=`$CYGPATH -u "$windows_path"` 46895 new_path="$unix_path" 46896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46897 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46898 new_path="$unix_path" 46899 fi 46900 46901 # remove trailing .exe if any 46902 new_path="${new_path/%.exe/}" 46903 46904 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46905 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46906 fi 46907 46908 else 46909 # We're on a unix platform. Hooray! :) 46910 # First separate the path from the arguments. This will split at the first 46911 # space. 46912 complete="$BUILD_STRIP" 46913 path="${complete%% *}" 46914 tmp="$complete EOL" 46915 arguments="${tmp#* }" 46916 46917 # Cannot rely on the command "which" here since it doesn't always work. 46918 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46919 if test -z "$is_absolute_path"; then 46920 # Path to executable is not absolute. Find it. 46921 IFS_save="$IFS" 46922 IFS=: 46923 for p in $PATH; do 46924 if test -f "$p/$path" && test -x "$p/$path"; then 46925 new_path="$p/$path" 46926 break 46927 fi 46928 done 46929 IFS="$IFS_save" 46930 else 46931 # This is an absolute path, we can use it without further modifications. 46932 new_path="$path" 46933 fi 46934 46935 if test "x$new_path" = x; then 46936 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46937 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46938 has_space=`$ECHO "$complete" | $GREP " "` 46939 if test "x$has_space" != x; then 46940 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46941 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46942 fi 46943 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46944 fi 46945 fi 46946 46947 # Now join together the path and the arguments once again 46948 if test "x$arguments" != xEOL; then 46949 new_complete="$new_path ${arguments% *}" 46950 else 46951 new_complete="$new_path" 46952 fi 46953 46954 if test "x$complete" != "x$new_complete"; then 46955 BUILD_STRIP="$new_complete" 46956 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 46957 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 46958 fi 46959 fi 46960 46961 # Assume the C compiler is the assembler 46962 BUILD_AS="$BUILD_CC -c" 46963 # Just like for the target compiler, use the compiler as linker 46964 BUILD_LD="$BUILD_CC" 46965 BUILD_LDCXX="$BUILD_CXX" 46966 46967 PATH="$OLDPATH" 46968 46969 46970 COMPILER=$BUILD_CC 46971 COMPILER_NAME=BuildC 46972 46973 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46974 # cc -V output typically looks like 46975 # cc: Sun C 5.12 Linux_i386 2011/11/16 46976 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 46977 # Check that this is likely to be the Solaris Studio cc. 46978 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 46979 if test $? -ne 0; then 46980 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 46981 { $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 46982 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 46983 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 46984 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 46985 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 46986 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 46987 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 46988 fi 46989 # Remove usage instructions (if present), and 46990 # collapse compiler output into a single line 46991 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46992 $SED -e 's/ *[Uu]sage:.*//'` 46993 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46994 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 46995 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46996 # xlc -qversion output typically looks like 46997 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 46998 # Version: 11.01.0000.0015 46999 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47000 # Check that this is likely to be the IBM XL C compiler. 47001 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47002 if test $? -ne 0; then 47003 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47004 { $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 47005 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47006 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47007 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47008 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47009 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47010 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47011 fi 47012 # Collapse compiler output into a single line 47013 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47014 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47015 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47016 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47017 # There is no specific version flag, but all output starts with a version string. 47018 # First line typically looks something like: 47019 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47020 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47021 # Check that this is likely to be Microsoft CL.EXE. 47022 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47023 if test $? -ne 0; then 47024 { $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 47025 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47026 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47027 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47028 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47029 fi 47030 # Collapse compiler output into a single line 47031 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47032 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47033 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47034 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47035 # gcc --version output typically looks like 47036 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47037 # Copyright (C) 2013 Free Software Foundation, Inc. 47038 # This is free software; see the source for copying conditions. There is NO 47039 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47040 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47041 # Check that this is likely to be GCC. 47042 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47043 if test $? -ne 0; then 47044 { $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 47045 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47046 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47047 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47048 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47049 fi 47050 # Remove Copyright and legalese from version string, and 47051 # collapse into a single line 47052 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47053 $SED -e 's/ *Copyright .*//'` 47054 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47055 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47056 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47057 # clang --version output typically looks like 47058 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47059 # clang version 3.3 (tags/RELEASE_33/final) 47060 # or 47061 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47062 # Target: x86_64-pc-linux-gnu 47063 # Thread model: posix 47064 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47065 # Check that this is likely to be clang 47066 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47067 if test $? -ne 0; then 47068 { $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 47069 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47070 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47071 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47072 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47073 fi 47074 # Collapse compiler output into a single line 47075 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47076 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47077 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47078 else 47079 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47080 fi 47081 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47082 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47083 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47084 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 47085 47086 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47087 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47088 47089 47090 COMPILER=$BUILD_CXX 47091 COMPILER_NAME=BuildC++ 47092 47093 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47094 # cc -V output typically looks like 47095 # cc: Sun C 5.12 Linux_i386 2011/11/16 47096 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47097 # Check that this is likely to be the Solaris Studio cc. 47098 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 47099 if test $? -ne 0; then 47100 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47101 { $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 47102 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47103 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47104 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47105 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47106 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47107 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47108 fi 47109 # Remove usage instructions (if present), and 47110 # collapse compiler output into a single line 47111 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47112 $SED -e 's/ *[Uu]sage:.*//'` 47113 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47114 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47115 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47116 # xlc -qversion output typically looks like 47117 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47118 # Version: 11.01.0000.0015 47119 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47120 # Check that this is likely to be the IBM XL C compiler. 47121 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47122 if test $? -ne 0; then 47123 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47124 { $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 47125 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47126 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47127 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47128 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47129 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47130 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47131 fi 47132 # Collapse compiler output into a single line 47133 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47134 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47135 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47136 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47137 # There is no specific version flag, but all output starts with a version string. 47138 # First line typically looks something like: 47139 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47140 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47141 # Check that this is likely to be Microsoft CL.EXE. 47142 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47143 if test $? -ne 0; then 47144 { $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 47145 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47146 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47147 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47148 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47149 fi 47150 # Collapse compiler output into a single line 47151 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47152 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47153 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47154 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47155 # gcc --version output typically looks like 47156 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47157 # Copyright (C) 2013 Free Software Foundation, Inc. 47158 # This is free software; see the source for copying conditions. There is NO 47159 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47160 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47161 # Check that this is likely to be GCC. 47162 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47163 if test $? -ne 0; then 47164 { $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 47165 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47166 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47167 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47168 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47169 fi 47170 # Remove Copyright and legalese from version string, and 47171 # collapse into a single line 47172 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47173 $SED -e 's/ *Copyright .*//'` 47174 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47175 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47176 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47177 # clang --version output typically looks like 47178 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47179 # clang version 3.3 (tags/RELEASE_33/final) 47180 # or 47181 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47182 # Target: x86_64-pc-linux-gnu 47183 # Thread model: posix 47184 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47185 # Check that this is likely to be clang 47186 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47187 if test $? -ne 0; then 47188 { $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 47189 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47190 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47191 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47192 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47193 fi 47194 # Collapse compiler output into a single line 47195 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47196 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47197 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47198 else 47199 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47200 fi 47201 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47202 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47203 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47204 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 47205 47206 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47207 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47208 47209 47210 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 47211 { $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 47212 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 47213 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47214 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47215 fi 47216 47217 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47218 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 47219 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than three parts (X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&5 47220 $as_echo "$as_me: WARNING: C compiler version number has more than three parts (X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47221 fi 47222 47223 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47224 { $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 47225 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47226 fi 47227 47228 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$BUILD_CC_VERSION_NUMBER"` 47229 47230 else 47231 # If we are not cross compiling, use the normal target compilers for 47232 # building the build platform executables. 47233 BUILD_CC="$CC" 47234 BUILD_CXX="$CXX" 47235 BUILD_LD="$LD" 47236 BUILD_LDCXX="$LDCXX" 47237 BUILD_NM="$NM" 47238 BUILD_AS="$AS" 47239 BUILD_OBJCOPY="$OBJCOPY" 47240 BUILD_STRIP="$STRIP" 47241 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 47242 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 47243 BUILD_AR="$AR" 47244 47245 47246 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 47247 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 47248 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 47249 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47250 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47251 fi 47252 47253 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47254 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 47255 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 47256 $as_echo "$as_me: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47257 fi 47258 47259 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47260 { $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 47261 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47262 fi 47263 47264 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$CC_VERSION_NUMBER"` 47265 47266 fi 47267 47268 47269 47270 47271 47272 47273 47274 47275 47276 47277 47278 47279 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47280 # For hotspot, we need these in Windows mixed path, 47281 # so rewrite them all. Need added .exe suffix. 47282 HOTSPOT_CXX="$CXX.exe" 47283 HOTSPOT_LD="$LD.exe" 47284 HOTSPOT_MT="$MT.exe" 47285 HOTSPOT_RC="$RC.exe" 47286 47287 unix_path="$HOTSPOT_CXX" 47288 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47289 windows_path=`$CYGPATH -m "$unix_path"` 47290 HOTSPOT_CXX="$windows_path" 47291 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47292 windows_path=`cmd //c echo $unix_path` 47293 HOTSPOT_CXX="$windows_path" 47294 fi 47295 47296 47297 unix_path="$HOTSPOT_LD" 47298 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47299 windows_path=`$CYGPATH -m "$unix_path"` 47300 HOTSPOT_LD="$windows_path" 47301 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47302 windows_path=`cmd //c echo $unix_path` 47303 HOTSPOT_LD="$windows_path" 47304 fi 47305 47306 47307 unix_path="$HOTSPOT_MT" 47308 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47309 windows_path=`$CYGPATH -m "$unix_path"` 47310 HOTSPOT_MT="$windows_path" 47311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47312 windows_path=`cmd //c echo $unix_path` 47313 HOTSPOT_MT="$windows_path" 47314 fi 47315 47316 47317 unix_path="$HOTSPOT_RC" 47318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47319 windows_path=`$CYGPATH -m "$unix_path"` 47320 HOTSPOT_RC="$windows_path" 47321 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47322 windows_path=`cmd //c echo $unix_path` 47323 HOTSPOT_RC="$windows_path" 47324 fi 47325 47326 47327 47328 else 47329 HOTSPOT_CXX="$CXX" 47330 HOTSPOT_LD="$LD" 47331 fi 47332 47333 47334 47335 if test "x$TOOLCHAIN_TYPE" = xclang; then 47336 USE_CLANG=true 47337 fi 47338 47339 47340 47341 47342 47343 # The package path is used only on macosx? 47344 # FIXME: clean this up, and/or move it elsewhere. 47345 PACKAGE_PATH=/opt/local 47346 47347 47348 # Check for extra potential brokenness. 47349 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47350 # On Windows, double-check that we got the right compiler. 47351 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47352 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 47353 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 47354 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 47355 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 47356 fi 47357 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 47358 if test "x$COMPILER_CPU_TEST" != "xx64"; then 47359 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 47360 fi 47361 fi 47362 fi 47363 47364 if test "x$TOOLCHAIN_TYPE" = xgcc; then 47365 # If this is a --hash-style=gnu system, use --hash-style=both, why? 47366 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 47367 # This is later checked when setting flags. 47368 47369 # "-Og" suppported for GCC 4.8 and later 47370 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 47371 47372 47373 47374 47375 47376 47377 47378 47379 47380 47381 47382 47383 47384 47385 47386 47387 47388 47389 47390 47391 47392 47393 47394 47395 47396 47397 47398 47399 47400 47401 47402 47403 47404 47405 47406 47407 47408 47409 47410 47411 47412 47413 47414 47415 47416 47417 47418 # Execute function body 47419 47420 47421 47422 47423 47424 47425 47426 47427 47428 47429 47430 47431 47432 47433 47434 47435 47436 47437 47438 47439 47440 47441 47442 47443 47444 47445 47446 47447 47448 47449 47450 47451 47452 47453 47454 47455 47456 47457 47458 47459 47460 47461 47462 47463 47464 47465 47466 47467 # Execute function body 47468 47469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47470 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47471 supports=yes 47472 47473 saved_cflags="$CFLAGS" 47474 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 47475 ac_ext=c 47476 ac_cpp='$CPP $CPPFLAGS' 47477 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47478 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47479 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47480 47481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47482 /* end confdefs.h. */ 47483 int i; 47484 _ACEOF 47485 if ac_fn_c_try_compile "$LINENO"; then : 47486 47487 else 47488 supports=no 47489 fi 47490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47491 ac_ext=cpp 47492 ac_cpp='$CXXCPP $CPPFLAGS' 47493 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47494 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47495 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47496 47497 CFLAGS="$saved_cflags" 47498 47499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47500 $as_echo "$supports" >&6; } 47501 if test "x$supports" = "xyes" ; then 47502 : 47503 C_COMP_SUPPORTS="yes" 47504 else 47505 : 47506 C_COMP_SUPPORTS="no" 47507 fi 47508 47509 47510 47511 47512 47513 47514 47515 47516 47517 47518 47519 47520 47521 47522 47523 47524 47525 47526 47527 47528 47529 47530 47531 47532 47533 47534 47535 47536 47537 47538 47539 47540 47541 47542 47543 47544 47545 47546 47547 47548 47549 47550 47551 47552 47553 47554 47555 47556 47557 47558 47559 47560 47561 47562 47563 47564 47565 47566 47567 # Execute function body 47568 47569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47570 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47571 supports=yes 47572 47573 saved_cxxflags="$CXXFLAGS" 47574 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 47575 ac_ext=cpp 47576 ac_cpp='$CXXCPP $CPPFLAGS' 47577 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47578 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47579 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47580 47581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47582 /* end confdefs.h. */ 47583 int i; 47584 _ACEOF 47585 if ac_fn_cxx_try_compile "$LINENO"; then : 47586 47587 else 47588 supports=no 47589 fi 47590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47591 ac_ext=cpp 47592 ac_cpp='$CXXCPP $CPPFLAGS' 47593 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47594 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47595 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47596 47597 CXXFLAGS="$saved_cxxflags" 47598 47599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47600 $as_echo "$supports" >&6; } 47601 if test "x$supports" = "xyes" ; then 47602 : 47603 CXX_COMP_SUPPORTS="yes" 47604 else 47605 : 47606 CXX_COMP_SUPPORTS="no" 47607 fi 47608 47609 47610 47611 47612 47613 47614 47615 47616 47617 47618 47619 47620 47621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47622 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47623 supports=no 47624 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 47625 47626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47627 $as_echo "$supports" >&6; } 47628 if test "x$supports" = "xyes" ; then 47629 : 47630 HAS_CFLAG_OPTIMIZE_DEBUG=true 47631 else 47632 : 47633 HAS_CFLAG_OPTIMIZE_DEBUG=false 47634 fi 47635 47636 47637 47638 47639 47640 47641 47642 # "-z relro" supported in GNU binutils 2.17 and later 47643 LINKER_RELRO_FLAG="-Wl,-z,relro" 47644 47645 47646 47647 47648 47649 47650 47651 47652 47653 47654 47655 47656 47657 47658 47659 47660 47661 47662 47663 47664 47665 47666 47667 47668 47669 47670 47671 47672 47673 47674 47675 47676 47677 47678 47679 47680 47681 47682 47683 47684 47685 47686 47687 47688 47689 47690 47691 # Execute function body 47692 47693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 47694 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 47695 supports=yes 47696 47697 saved_ldflags="$LDFLAGS" 47698 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 47699 ac_ext=c 47700 ac_cpp='$CPP $CPPFLAGS' 47701 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47702 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47703 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47704 47705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47706 /* end confdefs.h. */ 47707 47708 int 47709 main () 47710 { 47711 47712 ; 47713 return 0; 47714 } 47715 _ACEOF 47716 if ac_fn_c_try_link "$LINENO"; then : 47717 47718 else 47719 supports=no 47720 fi 47721 rm -f core conftest.err conftest.$ac_objext \ 47722 conftest$ac_exeext conftest.$ac_ext 47723 ac_ext=cpp 47724 ac_cpp='$CXXCPP $CPPFLAGS' 47725 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47726 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47727 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47728 47729 LDFLAGS="$saved_ldflags" 47730 47731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47732 $as_echo "$supports" >&6; } 47733 if test "x$supports" = "xyes" ; then 47734 : 47735 HAS_LINKER_RELRO=true 47736 else 47737 : 47738 HAS_LINKER_RELRO=false 47739 fi 47740 47741 47742 47743 47744 47745 47746 47747 47748 47749 47750 47751 47752 47753 # "-z now" supported in GNU binutils 2.11 and later 47754 LINKER_NOW_FLAG="-Wl,-z,now" 47755 47756 47757 47758 47759 47760 47761 47762 47763 47764 47765 47766 47767 47768 47769 47770 47771 47772 47773 47774 47775 47776 47777 47778 47779 47780 47781 47782 47783 47784 47785 47786 47787 47788 47789 47790 47791 47792 47793 47794 47795 47796 47797 47798 47799 47800 47801 47802 # Execute function body 47803 47804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 47805 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 47806 supports=yes 47807 47808 saved_ldflags="$LDFLAGS" 47809 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 47810 ac_ext=c 47811 ac_cpp='$CPP $CPPFLAGS' 47812 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47813 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47814 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47815 47816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47817 /* end confdefs.h. */ 47818 47819 int 47820 main () 47821 { 47822 47823 ; 47824 return 0; 47825 } 47826 _ACEOF 47827 if ac_fn_c_try_link "$LINENO"; then : 47828 47829 else 47830 supports=no 47831 fi 47832 rm -f core conftest.err conftest.$ac_objext \ 47833 conftest$ac_exeext conftest.$ac_ext 47834 ac_ext=cpp 47835 ac_cpp='$CXXCPP $CPPFLAGS' 47836 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47837 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47838 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47839 47840 LDFLAGS="$saved_ldflags" 47841 47842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47843 $as_echo "$supports" >&6; } 47844 if test "x$supports" = "xyes" ; then 47845 : 47846 HAS_LINKER_NOW=true 47847 else 47848 : 47849 HAS_LINKER_NOW=false 47850 fi 47851 47852 47853 47854 47855 47856 47857 47858 47859 47860 47861 47862 47863 fi 47864 47865 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 47866 # in executable.' 47867 USING_BROKEN_SUSE_LD=no 47868 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 47869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 47870 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 47871 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 47872 $ECHO "int main() { }" > main.c 47873 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 47874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47875 $as_echo "no" >&6; } 47876 USING_BROKEN_SUSE_LD=no 47877 else 47878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 47879 $as_echo "yes" >&6; } 47880 USING_BROKEN_SUSE_LD=yes 47881 fi 47882 $RM version-script.map main.c a.out 47883 fi 47884 47885 47886 # Setup hotspot lecagy names for toolchains 47887 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 47888 if test "x$TOOLCHAIN_TYPE" = xclang; then 47889 HOTSPOT_TOOLCHAIN_TYPE=gcc 47890 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47891 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 47892 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47893 HOTSPOT_TOOLCHAIN_TYPE=visCPP 47894 fi 47895 47896 47897 47898 # Setup the JTReg Regression Test Harness. 47899 47900 47901 # Check whether --with-jtreg was given. 47902 if test "${with_jtreg+set}" = set; then : 47903 withval=$with_jtreg; 47904 else 47905 with_jtreg=no 47906 fi 47907 47908 47909 if test "x$with_jtreg" = xno; then 47910 # jtreg disabled 47911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 47912 $as_echo_n "checking for jtreg... " >&6; } 47913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47914 $as_echo "no" >&6; } 47915 else 47916 if test "x$with_jtreg" != xyes; then 47917 # with path specified. 47918 JT_HOME="$with_jtreg" 47919 fi 47920 47921 if test "x$JT_HOME" != x; then 47922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 47923 $as_echo_n "checking for jtreg... " >&6; } 47924 47925 # use JT_HOME enviroment var. 47926 47927 # Only process if variable expands to non-empty 47928 47929 if test "x$JT_HOME" != x; then 47930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47931 47932 # Input might be given as Windows format, start by converting to 47933 # unix format. 47934 path="$JT_HOME" 47935 new_path=`$CYGPATH -u "$path"` 47936 47937 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47938 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47939 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47940 # "foo.exe" is OK but "foo" is an error. 47941 # 47942 # This test is therefore slightly more accurate than "test -f" to check for file precense. 47943 # It is also a way to make sure we got the proper file name for the real test later on. 47944 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47945 if test "x$test_shortpath" = x; then 47946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 47947 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 47948 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 47949 fi 47950 47951 # Call helper function which possibly converts this using DOS-style short mode. 47952 # If so, the updated path is stored in $new_path. 47953 47954 input_path="$new_path" 47955 # Check if we need to convert this using DOS-style short mode. If the path 47956 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47957 # take no chances and rewrite it. 47958 # Note: m4 eats our [], so we need to use [ and ] instead. 47959 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47960 if test "x$has_forbidden_chars" != x; then 47961 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47962 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47963 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47964 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47965 # Going to short mode and back again did indeed matter. Since short mode is 47966 # case insensitive, let's make it lowercase to improve readability. 47967 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47968 # Now convert it back to Unix-style (cygpath) 47969 input_path=`$CYGPATH -u "$shortmode_path"` 47970 new_path="$input_path" 47971 fi 47972 fi 47973 47974 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47975 if test "x$test_cygdrive_prefix" = x; then 47976 # As a simple fix, exclude /usr/bin since it's not a real path. 47977 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 47978 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47979 # a path prefixed by /cygdrive for fixpath to work. 47980 new_path="$CYGWIN_ROOT_PATH$input_path" 47981 fi 47982 fi 47983 47984 47985 if test "x$path" != "x$new_path"; then 47986 JT_HOME="$new_path" 47987 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 47988 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 47989 fi 47990 47991 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47992 47993 path="$JT_HOME" 47994 has_colon=`$ECHO $path | $GREP ^.:` 47995 new_path="$path" 47996 if test "x$has_colon" = x; then 47997 # Not in mixed or Windows style, start by that. 47998 new_path=`cmd //c echo $path` 47999 fi 48000 48001 48002 input_path="$new_path" 48003 # Check if we need to convert this using DOS-style short mode. If the path 48004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48005 # take no chances and rewrite it. 48006 # Note: m4 eats our [], so we need to use [ and ] instead. 48007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48008 if test "x$has_forbidden_chars" != x; then 48009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48010 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48011 fi 48012 48013 48014 windows_path="$new_path" 48015 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48016 unix_path=`$CYGPATH -u "$windows_path"` 48017 new_path="$unix_path" 48018 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48019 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48020 new_path="$unix_path" 48021 fi 48022 48023 if test "x$path" != "x$new_path"; then 48024 JT_HOME="$new_path" 48025 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48026 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48027 fi 48028 48029 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48030 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48031 48032 else 48033 # We're on a unix platform. Hooray! :) 48034 path="$JT_HOME" 48035 has_space=`$ECHO "$path" | $GREP " "` 48036 if test "x$has_space" != x; then 48037 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48038 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48039 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48040 fi 48041 48042 # Use eval to expand a potential ~ 48043 eval path="$path" 48044 if test ! -f "$path" && test ! -d "$path"; then 48045 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 48046 fi 48047 48048 if test -d "$path"; then 48049 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 48050 else 48051 dir="`$DIRNAME "$path"`" 48052 base="`$BASENAME "$path"`" 48053 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 48054 fi 48055 fi 48056 fi 48057 48058 48059 # jtreg win32 script works for everybody 48060 JTREGEXE="$JT_HOME/bin/jtreg" 48061 48062 if test ! -f "$JTREGEXE"; then 48063 as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 48064 fi 48065 48066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48067 $as_echo "$JTREGEXE" >&6; } 48068 else 48069 # try to find jtreg on path 48070 48071 48072 48073 # Publish this variable in the help. 48074 48075 48076 if [ -z "${JTREGEXE+x}" ]; then 48077 # The variable is not set by user, try to locate tool using the code snippet 48078 for ac_prog in jtreg 48079 do 48080 # Extract the first word of "$ac_prog", so it can be a program name with args. 48081 set dummy $ac_prog; ac_word=$2 48082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48083 $as_echo_n "checking for $ac_word... " >&6; } 48084 if ${ac_cv_path_JTREGEXE+:} false; then : 48085 $as_echo_n "(cached) " >&6 48086 else 48087 case $JTREGEXE in 48088 [\\/]* | ?:[\\/]*) 48089 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48090 ;; 48091 *) 48092 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48093 for as_dir in $PATH 48094 do 48095 IFS=$as_save_IFS 48096 test -z "$as_dir" && as_dir=. 48097 for ac_exec_ext in '' $ac_executable_extensions; do 48098 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48099 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48100 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48101 break 2 48102 fi 48103 done 48104 done 48105 IFS=$as_save_IFS 48106 48107 ;; 48108 esac 48109 fi 48110 JTREGEXE=$ac_cv_path_JTREGEXE 48111 if test -n "$JTREGEXE"; then 48112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48113 $as_echo "$JTREGEXE" >&6; } 48114 else 48115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48116 $as_echo "no" >&6; } 48117 fi 48118 48119 48120 test -n "$JTREGEXE" && break 48121 done 48122 48123 else 48124 # The variable is set, but is it from the command line or the environment? 48125 48126 # Try to remove the string !JTREGEXE! from our list. 48127 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 48128 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 48129 # If it failed, the variable was not from the command line. Ignore it, 48130 # but warn the user (except for BASH, which is always set by the calling BASH). 48131 if test "xJTREGEXE" != xBASH; then 48132 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 48133 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 48134 fi 48135 # Try to locate tool using the code snippet 48136 for ac_prog in jtreg 48137 do 48138 # Extract the first word of "$ac_prog", so it can be a program name with args. 48139 set dummy $ac_prog; ac_word=$2 48140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48141 $as_echo_n "checking for $ac_word... " >&6; } 48142 if ${ac_cv_path_JTREGEXE+:} false; then : 48143 $as_echo_n "(cached) " >&6 48144 else 48145 case $JTREGEXE in 48146 [\\/]* | ?:[\\/]*) 48147 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48148 ;; 48149 *) 48150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48151 for as_dir in $PATH 48152 do 48153 IFS=$as_save_IFS 48154 test -z "$as_dir" && as_dir=. 48155 for ac_exec_ext in '' $ac_executable_extensions; do 48156 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48157 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48158 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48159 break 2 48160 fi 48161 done 48162 done 48163 IFS=$as_save_IFS 48164 48165 ;; 48166 esac 48167 fi 48168 JTREGEXE=$ac_cv_path_JTREGEXE 48169 if test -n "$JTREGEXE"; then 48170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48171 $as_echo "$JTREGEXE" >&6; } 48172 else 48173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48174 $as_echo "no" >&6; } 48175 fi 48176 48177 48178 test -n "$JTREGEXE" && break 48179 done 48180 48181 else 48182 # If it succeeded, then it was overridden by the user. We will use it 48183 # for the tool. 48184 48185 # First remove it from the list of overridden variables, so we can test 48186 # for unknown variables in the end. 48187 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48188 48189 # Check if we try to supply an empty value 48190 if test "x$JTREGEXE" = x; then 48191 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 48192 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 48193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48194 $as_echo_n "checking for JTREGEXE... " >&6; } 48195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48196 $as_echo "disabled" >&6; } 48197 else 48198 # Check if the provided tool contains a complete path. 48199 tool_specified="$JTREGEXE" 48200 tool_basename="${tool_specified##*/}" 48201 if test "x$tool_basename" = "x$tool_specified"; then 48202 # A command without a complete path is provided, search $PATH. 48203 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 48204 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 48205 # Extract the first word of "$tool_basename", so it can be a program name with args. 48206 set dummy $tool_basename; ac_word=$2 48207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48208 $as_echo_n "checking for $ac_word... " >&6; } 48209 if ${ac_cv_path_JTREGEXE+:} false; then : 48210 $as_echo_n "(cached) " >&6 48211 else 48212 case $JTREGEXE in 48213 [\\/]* | ?:[\\/]*) 48214 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48215 ;; 48216 *) 48217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48218 for as_dir in $PATH 48219 do 48220 IFS=$as_save_IFS 48221 test -z "$as_dir" && as_dir=. 48222 for ac_exec_ext in '' $ac_executable_extensions; do 48223 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48224 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48225 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48226 break 2 48227 fi 48228 done 48229 done 48230 IFS=$as_save_IFS 48231 48232 ;; 48233 esac 48234 fi 48235 JTREGEXE=$ac_cv_path_JTREGEXE 48236 if test -n "$JTREGEXE"; then 48237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48238 $as_echo "$JTREGEXE" >&6; } 48239 else 48240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48241 $as_echo "no" >&6; } 48242 fi 48243 48244 48245 if test "x$JTREGEXE" = x; then 48246 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48247 fi 48248 else 48249 # Otherwise we believe it is a complete path. Use it as it is. 48250 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 48251 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 48252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48253 $as_echo_n "checking for JTREGEXE... " >&6; } 48254 if test ! -x "$tool_specified"; then 48255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48256 $as_echo "not found" >&6; } 48257 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 48258 fi 48259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48260 $as_echo "$tool_specified" >&6; } 48261 fi 48262 fi 48263 fi 48264 48265 fi 48266 48267 48268 48269 if test "x$JTREGEXE" = x; then 48270 as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5 48271 fi 48272 48273 48274 JT_HOME="`$DIRNAME $JTREGEXE`" 48275 fi 48276 fi 48277 48278 48279 48280 48281 48282 48283 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 48284 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 48285 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 48286 # commands produced by the link step (currently AIX only) 48287 if test "x$TOOLCHAIN_TYPE" = xxlc; then 48288 COMPILER_TARGET_BITS_FLAG="-q" 48289 COMPILER_COMMAND_FILE_FLAG="-f" 48290 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 48291 else 48292 COMPILER_TARGET_BITS_FLAG="-m" 48293 COMPILER_COMMAND_FILE_FLAG="@" 48294 COMPILER_BINDCMD_FILE_FLAG="" 48295 48296 # The solstudio linker does not support @-files. 48297 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48298 COMPILER_COMMAND_FILE_FLAG= 48299 fi 48300 48301 # Check if @file is supported by gcc 48302 if test "x$TOOLCHAIN_TYPE" = xgcc; then 48303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 48304 $as_echo_n "checking if @file is supported by gcc... " >&6; } 48305 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 48306 $ECHO "" "--version" > command.file 48307 if $CXX @command.file 2>&5 >&5; then 48308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48309 $as_echo "yes" >&6; } 48310 COMPILER_COMMAND_FILE_FLAG="@" 48311 else 48312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48313 $as_echo "no" >&6; } 48314 COMPILER_COMMAND_FILE_FLAG= 48315 fi 48316 $RM command.file 48317 fi 48318 fi 48319 48320 48321 48322 48323 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 48324 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48325 ARFLAGS="-r" 48326 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48327 ARFLAGS="-X64" 48328 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 48329 # lib.exe is used as AR to create static libraries. 48330 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 48331 else 48332 ARFLAGS="" 48333 fi 48334 48335 48336 ## Setup strip. 48337 # FIXME: should this really be per platform, or should it be per toolchain type? 48338 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 48339 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 48340 if test "x$OPENJDK_TARGET_OS" = xlinux; then 48341 STRIPFLAGS="-g" 48342 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 48343 STRIPFLAGS="-x" 48344 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 48345 STRIPFLAGS="-S" 48346 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48347 STRIPFLAGS="-X32_64" 48348 fi 48349 48350 48351 48352 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48353 CC_OUT_OPTION=-Fo 48354 EXE_OUT_OPTION=-out: 48355 LD_OUT_OPTION=-out: 48356 AR_OUT_OPTION=-out: 48357 else 48358 # The option used to specify the target .o,.a or .so file. 48359 # When compiling, how to specify the to be created object file. 48360 CC_OUT_OPTION='-o$(SPACE)' 48361 # When linking, how to specify the to be created executable. 48362 EXE_OUT_OPTION='-o$(SPACE)' 48363 # When linking, how to specify the to be created dynamically linkable library. 48364 LD_OUT_OPTION='-o$(SPACE)' 48365 # When archiving, how to specify the to be create static archive for object files. 48366 AR_OUT_OPTION='rcs$(SPACE)' 48367 fi 48368 48369 48370 48371 48372 48373 # On Windows, we need to set RC flags. 48374 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48375 RC_FLAGS="-nologo -l0x409" 48376 JVM_RCFLAGS="-nologo" 48377 if test "x$DEBUG_LEVEL" = xrelease; then 48378 RC_FLAGS="$RC_FLAGS -DNDEBUG" 48379 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 48380 fi 48381 48382 # The version variables used to create RC_FLAGS may be overridden 48383 # in a custom configure script, or possibly the command line. 48384 # Let those variables be expanded at make time in spec.gmk. 48385 # The \$ are escaped to the shell, and the $(...) variables 48386 # are evaluated by make. 48387 RC_FLAGS="$RC_FLAGS \ 48388 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 48389 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 48390 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 48391 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 48392 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 48393 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 48394 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 48395 48396 JVM_RCFLAGS="$JVM_RCFLAGS \ 48397 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 48398 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 48399 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 48400 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 48401 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 48402 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 48403 -D\"HS_FNAME=jvm.dll\" \ 48404 -D\"HS_INTERNAL_NAME=jvm\"" 48405 fi 48406 48407 48408 48409 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48410 # silence copyright notice and other headers. 48411 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 48412 fi 48413 48414 48415 # Now we can test some aspects on the target using configure macros. 48416 48417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 48418 $as_echo_n "checking for ANSI C header files... " >&6; } 48419 if ${ac_cv_header_stdc+:} false; then : 48420 $as_echo_n "(cached) " >&6 48421 else 48422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48423 /* end confdefs.h. */ 48424 #include <stdlib.h> 48425 #include <stdarg.h> 48426 #include <string.h> 48427 #include <float.h> 48428 48429 int 48430 main () 48431 { 48432 48433 ; 48434 return 0; 48435 } 48436 _ACEOF 48437 if ac_fn_cxx_try_compile "$LINENO"; then : 48438 ac_cv_header_stdc=yes 48439 else 48440 ac_cv_header_stdc=no 48441 fi 48442 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48443 48444 if test $ac_cv_header_stdc = yes; then 48445 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 48446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48447 /* end confdefs.h. */ 48448 #include <string.h> 48449 48450 _ACEOF 48451 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48452 $EGREP "memchr" >/dev/null 2>&1; then : 48453 48454 else 48455 ac_cv_header_stdc=no 48456 fi 48457 rm -f conftest* 48458 48459 fi 48460 48461 if test $ac_cv_header_stdc = yes; then 48462 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 48463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48464 /* end confdefs.h. */ 48465 #include <stdlib.h> 48466 48467 _ACEOF 48468 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48469 $EGREP "free" >/dev/null 2>&1; then : 48470 48471 else 48472 ac_cv_header_stdc=no 48473 fi 48474 rm -f conftest* 48475 48476 fi 48477 48478 if test $ac_cv_header_stdc = yes; then 48479 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 48480 if test "$cross_compiling" = yes; then : 48481 : 48482 else 48483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48484 /* end confdefs.h. */ 48485 #include <ctype.h> 48486 #include <stdlib.h> 48487 #if ((' ' & 0x0FF) == 0x020) 48488 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 48489 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 48490 #else 48491 # define ISLOWER(c) \ 48492 (('a' <= (c) && (c) <= 'i') \ 48493 || ('j' <= (c) && (c) <= 'r') \ 48494 || ('s' <= (c) && (c) <= 'z')) 48495 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 48496 #endif 48497 48498 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 48499 int 48500 main () 48501 { 48502 int i; 48503 for (i = 0; i < 256; i++) 48504 if (XOR (islower (i), ISLOWER (i)) 48505 || toupper (i) != TOUPPER (i)) 48506 return 2; 48507 return 0; 48508 } 48509 _ACEOF 48510 if ac_fn_cxx_try_run "$LINENO"; then : 48511 48512 else 48513 ac_cv_header_stdc=no 48514 fi 48515 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 48516 conftest.$ac_objext conftest.beam conftest.$ac_ext 48517 fi 48518 48519 fi 48520 fi 48521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 48522 $as_echo "$ac_cv_header_stdc" >&6; } 48523 if test $ac_cv_header_stdc = yes; then 48524 48525 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 48526 48527 fi 48528 48529 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 48530 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 48531 inttypes.h stdint.h unistd.h 48532 do : 48533 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 48534 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 48535 " 48536 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 48537 cat >>confdefs.h <<_ACEOF 48538 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 48539 _ACEOF 48540 48541 fi 48542 48543 done 48544 48545 48546 48547 ############################################################################### 48548 # 48549 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 48550 # (The JVM can use 32 or 64 bit Java pointers but that decision 48551 # is made at runtime.) 48552 # 48553 48554 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 48555 # Always specify -m flag on Solaris 48556 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 48557 48558 # When we add flags to the "official" CFLAGS etc, we need to 48559 # keep track of these additions in ADDED_CFLAGS etc. These 48560 # will later be checked to make sure only controlled additions 48561 # have been made to CFLAGS etc. 48562 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48563 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48564 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48565 48566 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48567 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48568 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48569 48570 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48571 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48572 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48573 48574 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48575 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48576 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48577 48578 elif test "x$COMPILE_TYPE" = xreduced; then 48579 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 48580 # Specify -m if running reduced on unix platforms 48581 48582 # When we add flags to the "official" CFLAGS etc, we need to 48583 # keep track of these additions in ADDED_CFLAGS etc. These 48584 # will later be checked to make sure only controlled additions 48585 # have been made to CFLAGS etc. 48586 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48587 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48588 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48589 48590 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48591 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48592 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48593 48594 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48595 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48596 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48597 48598 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48599 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48600 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48601 48602 fi 48603 fi 48604 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48605 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48606 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48607 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48608 fi 48609 48610 # Make compilation sanity check 48611 for ac_header in stdio.h 48612 do : 48613 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 48614 if test "x$ac_cv_header_stdio_h" = xyes; then : 48615 cat >>confdefs.h <<_ACEOF 48616 #define HAVE_STDIO_H 1 48617 _ACEOF 48618 48619 else 48620 48621 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 48622 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 48623 if test "x$COMPILE_TYPE" = xreduced; then 48624 48625 # Print a helpful message on how to acquire the necessary build dependency. 48626 # reduced is the help tag: freetype, cups, alsa etc 48627 MISSING_DEPENDENCY=reduced 48628 48629 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48630 cygwin_help $MISSING_DEPENDENCY 48631 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48632 msys_help $MISSING_DEPENDENCY 48633 else 48634 PKGHANDLER_COMMAND= 48635 48636 case $PKGHANDLER in 48637 apt-get) 48638 apt_help $MISSING_DEPENDENCY ;; 48639 yum) 48640 yum_help $MISSING_DEPENDENCY ;; 48641 port) 48642 port_help $MISSING_DEPENDENCY ;; 48643 pkgutil) 48644 pkgutil_help $MISSING_DEPENDENCY ;; 48645 pkgadd) 48646 pkgadd_help $MISSING_DEPENDENCY ;; 48647 esac 48648 48649 if test "x$PKGHANDLER_COMMAND" != x; then 48650 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 48651 fi 48652 fi 48653 48654 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 48655 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 48656 elif test "x$COMPILE_TYPE" = xcross; then 48657 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 48658 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 48659 fi 48660 as_fn_error $? "Cannot continue." "$LINENO" 5 48661 48662 fi 48663 48664 done 48665 48666 48667 # The cast to long int works around a bug in the HP C Compiler 48668 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 48669 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 48670 # This bug is HP SR number 8606223364. 48671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 48672 $as_echo_n "checking size of int *... " >&6; } 48673 if ${ac_cv_sizeof_int_p+:} false; then : 48674 $as_echo_n "(cached) " >&6 48675 else 48676 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 48677 48678 else 48679 if test "$ac_cv_type_int_p" = yes; then 48680 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 48681 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 48682 as_fn_error 77 "cannot compute sizeof (int *) 48683 See \`config.log' for more details" "$LINENO" 5; } 48684 else 48685 ac_cv_sizeof_int_p=0 48686 fi 48687 fi 48688 48689 fi 48690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 48691 $as_echo "$ac_cv_sizeof_int_p" >&6; } 48692 48693 48694 48695 cat >>confdefs.h <<_ACEOF 48696 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 48697 _ACEOF 48698 48699 48700 48701 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 48702 if test "x$ac_cv_sizeof_int_p" = x; then 48703 # The test failed, lets stick to the assumed value. 48704 { $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 48705 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 48706 else 48707 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 48708 48709 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 48710 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 48711 # Let's try to implicitely set the compilers target architecture and retry the test 48712 { $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 48713 $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;} 48714 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 48715 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 48716 48717 # When we add flags to the "official" CFLAGS etc, we need to 48718 # keep track of these additions in ADDED_CFLAGS etc. These 48719 # will later be checked to make sure only controlled additions 48720 # have been made to CFLAGS etc. 48721 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48722 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48723 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48724 48725 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48726 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48727 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48728 48729 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48730 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48731 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48732 48733 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48734 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48735 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48736 48737 48738 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 48739 unset ac_cv_sizeof_int_p 48740 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 48741 cat >>confdefs.h <<_ACEOF 48742 #undef SIZEOF_INT_P 48743 _ACEOF 48744 48745 # The cast to long int works around a bug in the HP C Compiler 48746 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 48747 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 48748 # This bug is HP SR number 8606223364. 48749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 48750 $as_echo_n "checking size of int *... " >&6; } 48751 if ${ac_cv_sizeof_int_p+:} false; then : 48752 $as_echo_n "(cached) " >&6 48753 else 48754 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 48755 48756 else 48757 if test "$ac_cv_type_int_p" = yes; then 48758 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 48759 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 48760 as_fn_error 77 "cannot compute sizeof (int *) 48761 See \`config.log' for more details" "$LINENO" 5; } 48762 else 48763 ac_cv_sizeof_int_p=0 48764 fi 48765 fi 48766 48767 fi 48768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 48769 $as_echo "$ac_cv_sizeof_int_p" >&6; } 48770 48771 48772 48773 cat >>confdefs.h <<_ACEOF 48774 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 48775 _ACEOF 48776 48777 48778 48779 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 48780 48781 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 48782 { $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 48783 $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;} 48784 if test "x$COMPILE_TYPE" = xreduced; then 48785 48786 # Print a helpful message on how to acquire the necessary build dependency. 48787 # reduced is the help tag: freetype, cups, alsa etc 48788 MISSING_DEPENDENCY=reduced 48789 48790 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48791 cygwin_help $MISSING_DEPENDENCY 48792 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48793 msys_help $MISSING_DEPENDENCY 48794 else 48795 PKGHANDLER_COMMAND= 48796 48797 case $PKGHANDLER in 48798 apt-get) 48799 apt_help $MISSING_DEPENDENCY ;; 48800 yum) 48801 yum_help $MISSING_DEPENDENCY ;; 48802 port) 48803 port_help $MISSING_DEPENDENCY ;; 48804 pkgutil) 48805 pkgutil_help $MISSING_DEPENDENCY ;; 48806 pkgadd) 48807 pkgadd_help $MISSING_DEPENDENCY ;; 48808 esac 48809 48810 if test "x$PKGHANDLER_COMMAND" != x; then 48811 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 48812 fi 48813 fi 48814 48815 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 48816 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 48817 elif test "x$COMPILE_TYPE" = xcross; then 48818 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 48819 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 48820 fi 48821 as_fn_error $? "Cannot continue." "$LINENO" 5 48822 fi 48823 fi 48824 fi 48825 48826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 48827 $as_echo_n "checking for target address size... " >&6; } 48828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 48829 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 48830 48831 48832 ############################################################################### 48833 # 48834 # Is the target little of big endian? 48835 # 48836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 48837 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 48838 if ${ac_cv_c_bigendian+:} false; then : 48839 $as_echo_n "(cached) " >&6 48840 else 48841 ac_cv_c_bigendian=unknown 48842 # See if we're dealing with a universal compiler. 48843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48844 /* end confdefs.h. */ 48845 #ifndef __APPLE_CC__ 48846 not a universal capable compiler 48847 #endif 48848 typedef int dummy; 48849 48850 _ACEOF 48851 if ac_fn_cxx_try_compile "$LINENO"; then : 48852 48853 # Check for potential -arch flags. It is not universal unless 48854 # there are at least two -arch flags with different values. 48855 ac_arch= 48856 ac_prev= 48857 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 48858 if test -n "$ac_prev"; then 48859 case $ac_word in 48860 i?86 | x86_64 | ppc | ppc64) 48861 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 48862 ac_arch=$ac_word 48863 else 48864 ac_cv_c_bigendian=universal 48865 break 48866 fi 48867 ;; 48868 esac 48869 ac_prev= 48870 elif test "x$ac_word" = "x-arch"; then 48871 ac_prev=arch 48872 fi 48873 done 48874 fi 48875 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48876 if test $ac_cv_c_bigendian = unknown; then 48877 # See if sys/param.h defines the BYTE_ORDER macro. 48878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48879 /* end confdefs.h. */ 48880 #include <sys/types.h> 48881 #include <sys/param.h> 48882 48883 int 48884 main () 48885 { 48886 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 48887 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 48888 && LITTLE_ENDIAN) 48889 bogus endian macros 48890 #endif 48891 48892 ; 48893 return 0; 48894 } 48895 _ACEOF 48896 if ac_fn_cxx_try_compile "$LINENO"; then : 48897 # It does; now see whether it defined to BIG_ENDIAN or not. 48898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48899 /* end confdefs.h. */ 48900 #include <sys/types.h> 48901 #include <sys/param.h> 48902 48903 int 48904 main () 48905 { 48906 #if BYTE_ORDER != BIG_ENDIAN 48907 not big endian 48908 #endif 48909 48910 ; 48911 return 0; 48912 } 48913 _ACEOF 48914 if ac_fn_cxx_try_compile "$LINENO"; then : 48915 ac_cv_c_bigendian=yes 48916 else 48917 ac_cv_c_bigendian=no 48918 fi 48919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48920 fi 48921 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48922 fi 48923 if test $ac_cv_c_bigendian = unknown; then 48924 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 48925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48926 /* end confdefs.h. */ 48927 #include <limits.h> 48928 48929 int 48930 main () 48931 { 48932 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 48933 bogus endian macros 48934 #endif 48935 48936 ; 48937 return 0; 48938 } 48939 _ACEOF 48940 if ac_fn_cxx_try_compile "$LINENO"; then : 48941 # It does; now see whether it defined to _BIG_ENDIAN or not. 48942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48943 /* end confdefs.h. */ 48944 #include <limits.h> 48945 48946 int 48947 main () 48948 { 48949 #ifndef _BIG_ENDIAN 48950 not big endian 48951 #endif 48952 48953 ; 48954 return 0; 48955 } 48956 _ACEOF 48957 if ac_fn_cxx_try_compile "$LINENO"; then : 48958 ac_cv_c_bigendian=yes 48959 else 48960 ac_cv_c_bigendian=no 48961 fi 48962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48963 fi 48964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48965 fi 48966 if test $ac_cv_c_bigendian = unknown; then 48967 # Compile a test program. 48968 if test "$cross_compiling" = yes; then : 48969 # Try to guess by grepping values from an object file. 48970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48971 /* end confdefs.h. */ 48972 short int ascii_mm[] = 48973 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 48974 short int ascii_ii[] = 48975 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 48976 int use_ascii (int i) { 48977 return ascii_mm[i] + ascii_ii[i]; 48978 } 48979 short int ebcdic_ii[] = 48980 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 48981 short int ebcdic_mm[] = 48982 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 48983 int use_ebcdic (int i) { 48984 return ebcdic_mm[i] + ebcdic_ii[i]; 48985 } 48986 extern int foo; 48987 48988 int 48989 main () 48990 { 48991 return use_ascii (foo) == use_ebcdic (foo); 48992 ; 48993 return 0; 48994 } 48995 _ACEOF 48996 if ac_fn_cxx_try_compile "$LINENO"; then : 48997 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 48998 ac_cv_c_bigendian=yes 48999 fi 49000 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 49001 if test "$ac_cv_c_bigendian" = unknown; then 49002 ac_cv_c_bigendian=no 49003 else 49004 # finding both strings is unlikely to happen, but who knows? 49005 ac_cv_c_bigendian=unknown 49006 fi 49007 fi 49008 fi 49009 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49010 else 49011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49012 /* end confdefs.h. */ 49013 $ac_includes_default 49014 int 49015 main () 49016 { 49017 49018 /* Are we little or big endian? From Harbison&Steele. */ 49019 union 49020 { 49021 long int l; 49022 char c[sizeof (long int)]; 49023 } u; 49024 u.l = 1; 49025 return u.c[sizeof (long int) - 1] == 1; 49026 49027 ; 49028 return 0; 49029 } 49030 _ACEOF 49031 if ac_fn_cxx_try_run "$LINENO"; then : 49032 ac_cv_c_bigendian=no 49033 else 49034 ac_cv_c_bigendian=yes 49035 fi 49036 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 49037 conftest.$ac_objext conftest.beam conftest.$ac_ext 49038 fi 49039 49040 fi 49041 fi 49042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 49043 $as_echo "$ac_cv_c_bigendian" >&6; } 49044 case $ac_cv_c_bigendian in #( 49045 yes) 49046 ENDIAN="big";; #( 49047 no) 49048 ENDIAN="little" ;; #( 49049 universal) 49050 ENDIAN="universal_endianness" 49051 ;; #( 49052 *) 49053 ENDIAN="unknown" ;; 49054 esac 49055 49056 49057 if test "x$ENDIAN" = xuniversal_endianness; then 49058 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 49059 fi 49060 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 49061 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 49062 fi 49063 49064 49065 # Configure flags for the tools 49066 49067 ############################################################################### 49068 # 49069 # How to compile shared libraries. 49070 # 49071 49072 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49073 PICFLAG="-fPIC" 49074 C_FLAG_REORDER='' 49075 CXX_FLAG_REORDER='' 49076 49077 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49078 # Linking is different on MacOSX 49079 if test "x$STATIC_BUILD" = xtrue; then 49080 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 49081 else 49082 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49083 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49084 fi 49085 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 49086 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49087 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49088 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49089 else 49090 # Default works for linux, might work on other platforms as well. 49091 SHARED_LIBRARY_FLAGS='-shared' 49092 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49093 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49094 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49095 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49096 fi 49097 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49098 C_FLAG_REORDER='' 49099 CXX_FLAG_REORDER='' 49100 49101 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49102 # Linking is different on MacOSX 49103 PICFLAG='' 49104 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49105 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 49106 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49107 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49108 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49109 49110 if test "x$STATIC_BUILD" = xfalse; then 49111 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 49112 fi 49113 else 49114 # Default works for linux, might work on other platforms as well. 49115 PICFLAG='-fPIC' 49116 SHARED_LIBRARY_FLAGS='-shared' 49117 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49118 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49119 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49120 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49121 fi 49122 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49123 PICFLAG="-KPIC" 49124 C_FLAG_REORDER='-xF' 49125 CXX_FLAG_REORDER='-xF' 49126 SHARED_LIBRARY_FLAGS="-G" 49127 SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1' 49128 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49129 SET_SHARED_LIBRARY_NAME='-h $1' 49130 SET_SHARED_LIBRARY_MAPFILE='-M$1' 49131 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49132 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 49133 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 49134 # will have to patch this single instruction with a call to some out-of-order code which 49135 # does the load from the TOC. This is of course slow. But in that case we also would have 49136 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 49137 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 49138 # can be patched directly by the linker and does not require a jump to out-of-order code. 49139 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 49140 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 49141 # loads for accessing a global variable). But there are rumors that this may be seen as a 49142 # 'performance feature' because of improved code locality of the symbols used in a 49143 # compilation unit. 49144 PICFLAG="-qpic" 49145 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49146 C_FLAG_REORDER='' 49147 CXX_FLAG_REORDER='' 49148 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 49149 SET_EXECUTABLE_ORIGIN="" 49150 SET_SHARED_LIBRARY_ORIGIN='' 49151 SET_SHARED_LIBRARY_NAME='' 49152 SET_SHARED_LIBRARY_MAPFILE='' 49153 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49154 PICFLAG="" 49155 C_FLAG_REORDER='' 49156 CXX_FLAG_REORDER='' 49157 SHARED_LIBRARY_FLAGS="-dll" 49158 SET_EXECUTABLE_ORIGIN='' 49159 SET_SHARED_LIBRARY_ORIGIN='' 49160 SET_SHARED_LIBRARY_NAME='' 49161 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 49162 fi 49163 49164 49165 49166 49167 49168 49169 49170 49171 49172 # The (cross) compiler is now configured, we can now test capabilities 49173 # of the target platform. 49174 49175 49176 49177 ############################################################################### 49178 # 49179 # Setup the opt flags for different compilers 49180 # and different operating systems. 49181 # 49182 49183 # FIXME: this was indirectly the old default, but just inherited. 49184 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49185 # C_FLAG_DEPS="-MMD -MF" 49186 # fi 49187 49188 # Generate make dependency files 49189 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49190 C_FLAG_DEPS="-MMD -MF" 49191 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49192 C_FLAG_DEPS="-MMD -MF" 49193 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49194 C_FLAG_DEPS="-xMMD -xMF" 49195 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49196 C_FLAG_DEPS="-qmakedep=gcc -MF" 49197 fi 49198 CXX_FLAG_DEPS="$C_FLAG_DEPS" 49199 49200 49201 49202 # Debug symbols 49203 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49204 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 49205 # reduce from default "-g2" option to save space 49206 CFLAGS_DEBUG_SYMBOLS="-g1" 49207 CXXFLAGS_DEBUG_SYMBOLS="-g1" 49208 else 49209 CFLAGS_DEBUG_SYMBOLS="-g" 49210 CXXFLAGS_DEBUG_SYMBOLS="-g" 49211 fi 49212 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49213 CFLAGS_DEBUG_SYMBOLS="-g" 49214 CXXFLAGS_DEBUG_SYMBOLS="-g" 49215 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49216 CFLAGS_DEBUG_SYMBOLS="-g -xs" 49217 # -g0 enables debug symbols without disabling inlining. 49218 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 49219 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49220 CFLAGS_DEBUG_SYMBOLS="-g" 49221 CXXFLAGS_DEBUG_SYMBOLS="-g" 49222 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49223 CFLAGS_DEBUG_SYMBOLS="-Zi" 49224 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 49225 fi 49226 49227 49228 49229 # Debug symbols for JVM_CFLAGS 49230 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49231 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 49232 if test "x$DEBUG_LEVEL" = xslowdebug; then 49233 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49234 else 49235 # -g0 does not disable inlining, which -g does. 49236 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 49237 fi 49238 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49239 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 49240 else 49241 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49242 fi 49243 49244 49245 # bounds, memory and behavior checking options 49246 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49247 case $DEBUG_LEVEL in 49248 release ) 49249 # no adjustment 49250 ;; 49251 fastdebug ) 49252 # no adjustment 49253 ;; 49254 slowdebug ) 49255 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 49256 # get's added conditionally on whether we produce debug symbols or not. 49257 # This is most likely not really correct. 49258 49259 # Add runtime stack smashing and undefined behavior checks. 49260 # Not all versions of gcc support -fstack-protector 49261 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 49262 49263 49264 49265 49266 49267 49268 49269 49270 49271 49272 49273 49274 49275 49276 49277 49278 49279 49280 49281 49282 49283 49284 49285 49286 49287 49288 49289 49290 49291 49292 49293 49294 49295 49296 49297 49298 49299 49300 49301 49302 49303 49304 # Execute function body 49305 49306 49307 49308 49309 49310 49311 49312 49313 49314 49315 49316 49317 49318 49319 49320 49321 49322 49323 49324 49325 49326 49327 49328 49329 49330 49331 49332 49333 49334 49335 49336 49337 49338 49339 49340 49341 49342 49343 49344 49345 49346 49347 49348 49349 49350 49351 49352 49353 # Execute function body 49354 49355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49356 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49357 supports=yes 49358 49359 saved_cflags="$CFLAGS" 49360 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 49361 ac_ext=c 49362 ac_cpp='$CPP $CPPFLAGS' 49363 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49364 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49365 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49366 49367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49368 /* end confdefs.h. */ 49369 int i; 49370 _ACEOF 49371 if ac_fn_c_try_compile "$LINENO"; then : 49372 49373 else 49374 supports=no 49375 fi 49376 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49377 ac_ext=cpp 49378 ac_cpp='$CXXCPP $CPPFLAGS' 49379 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49380 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49381 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49382 49383 CFLAGS="$saved_cflags" 49384 49385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49386 $as_echo "$supports" >&6; } 49387 if test "x$supports" = "xyes" ; then 49388 : 49389 C_COMP_SUPPORTS="yes" 49390 else 49391 : 49392 C_COMP_SUPPORTS="no" 49393 fi 49394 49395 49396 49397 49398 49399 49400 49401 49402 49403 49404 49405 49406 49407 49408 49409 49410 49411 49412 49413 49414 49415 49416 49417 49418 49419 49420 49421 49422 49423 49424 49425 49426 49427 49428 49429 49430 49431 49432 49433 49434 49435 49436 49437 49438 49439 49440 49441 49442 49443 49444 49445 49446 49447 49448 49449 49450 49451 49452 49453 # Execute function body 49454 49455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49456 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49457 supports=yes 49458 49459 saved_cxxflags="$CXXFLAGS" 49460 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 49461 ac_ext=cpp 49462 ac_cpp='$CXXCPP $CPPFLAGS' 49463 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49464 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49465 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49466 49467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49468 /* end confdefs.h. */ 49469 int i; 49470 _ACEOF 49471 if ac_fn_cxx_try_compile "$LINENO"; then : 49472 49473 else 49474 supports=no 49475 fi 49476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49477 ac_ext=cpp 49478 ac_cpp='$CXXCPP $CPPFLAGS' 49479 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49480 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49481 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49482 49483 CXXFLAGS="$saved_cxxflags" 49484 49485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49486 $as_echo "$supports" >&6; } 49487 if test "x$supports" = "xyes" ; then 49488 : 49489 CXX_COMP_SUPPORTS="yes" 49490 else 49491 : 49492 CXX_COMP_SUPPORTS="no" 49493 fi 49494 49495 49496 49497 49498 49499 49500 49501 49502 49503 49504 49505 49506 49507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49508 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49509 supports=no 49510 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 49511 49512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49513 $as_echo "$supports" >&6; } 49514 if test "x$supports" = "xyes" ; then 49515 : 49516 49517 else 49518 : 49519 STACK_PROTECTOR_CFLAG="" 49520 fi 49521 49522 49523 49524 49525 49526 49527 49528 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49529 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49530 if test "x$STACK_PROTECTOR_CFLAG" != x; then 49531 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49532 fi 49533 ;; 49534 esac 49535 fi 49536 49537 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49538 if test "x$DEBUG_LEVEL" != xrelease; then 49539 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 49540 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 49541 fi 49542 fi 49543 fi 49544 49545 # Optimization levels 49546 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49547 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 49548 49549 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 49550 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 49551 C_O_FLAG_HIGHEST_JVM="-xO4" 49552 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 49553 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 49554 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 49555 C_O_FLAG_DEBUG="-xregs=no%frameptr" 49556 C_O_FLAG_DEBUG_JVM="" 49557 C_O_FLAG_NONE="-xregs=no%frameptr" 49558 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49559 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 49560 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 49561 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 49562 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 49563 CXX_O_FLAG_DEBUG_JVM="" 49564 CXX_O_FLAG_NONE="-xregs=no%frameptr" 49565 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 49566 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 49567 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 49568 fi 49569 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49570 C_O_FLAG_HIGHEST_JVM="-xO4" 49571 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 49572 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49573 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49574 C_O_FLAG_DEBUG="" 49575 C_O_FLAG_DEBUG_JVM="" 49576 C_O_FLAG_NONE="" 49577 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49578 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 49579 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49580 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49581 CXX_O_FLAG_DEBUG="" 49582 CXX_O_FLAG_DEBUG_JVM="" 49583 CXX_O_FLAG_NONE="" 49584 fi 49585 else 49586 # The remaining toolchains share opt flags between CC and CXX; 49587 # setup for C and duplicate afterwards. 49588 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49589 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49590 # On MacOSX we optimize for size, something 49591 # we should do for all platforms? 49592 C_O_FLAG_HIGHEST_JVM="-Os" 49593 C_O_FLAG_HIGHEST="-Os" 49594 C_O_FLAG_HI="-Os" 49595 C_O_FLAG_NORM="-Os" 49596 C_O_FLAG_SIZE="-Os" 49597 else 49598 C_O_FLAG_HIGHEST_JVM="-O3" 49599 C_O_FLAG_HIGHEST="-O3" 49600 C_O_FLAG_HI="-O3" 49601 C_O_FLAG_NORM="-O2" 49602 C_O_FLAG_SIZE="-Os" 49603 fi 49604 C_O_FLAG_DEBUG="-O0" 49605 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49606 C_O_FLAG_DEBUG_JVM="" 49607 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 49608 C_O_FLAG_DEBUG_JVM="-O0" 49609 fi 49610 C_O_FLAG_NONE="-O0" 49611 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49612 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49613 # On MacOSX we optimize for size, something 49614 # we should do for all platforms? 49615 C_O_FLAG_HIGHEST_JVM="-Os" 49616 C_O_FLAG_HIGHEST="-Os" 49617 C_O_FLAG_HI="-Os" 49618 C_O_FLAG_NORM="-Os" 49619 C_O_FLAG_SIZE="-Os" 49620 else 49621 C_O_FLAG_HIGHEST_JVM="-O3" 49622 C_O_FLAG_HIGHEST="-O3" 49623 C_O_FLAG_HI="-O3" 49624 C_O_FLAG_NORM="-O2" 49625 C_O_FLAG_SIZE="-Os" 49626 fi 49627 C_O_FLAG_DEBUG="-O0" 49628 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49629 C_O_FLAG_DEBUG_JVM="" 49630 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 49631 C_O_FLAG_DEBUG_JVM="-O0" 49632 fi 49633 C_O_FLAG_NONE="-O0" 49634 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49635 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 49636 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 49637 C_O_FLAG_HI="-O3 -qinline -qinlglue" 49638 C_O_FLAG_NORM="-O2" 49639 C_O_FLAG_DEBUG="-qnoopt" 49640 # FIXME: Value below not verified. 49641 C_O_FLAG_DEBUG_JVM="" 49642 C_O_FLAG_NONE="-qnoopt" 49643 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49644 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 49645 C_O_FLAG_HIGHEST="-O2" 49646 C_O_FLAG_HI="-O1" 49647 C_O_FLAG_NORM="-O1" 49648 C_O_FLAG_DEBUG="-Od" 49649 C_O_FLAG_DEBUG_JVM="" 49650 C_O_FLAG_NONE="-Od" 49651 C_O_FLAG_SIZE="-Os" 49652 fi 49653 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 49654 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 49655 CXX_O_FLAG_HI="$C_O_FLAG_HI" 49656 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 49657 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 49658 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 49659 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 49660 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 49661 fi 49662 49663 # Adjust optimization flags according to debug level. 49664 case $DEBUG_LEVEL in 49665 release ) 49666 # no adjustment 49667 ;; 49668 fastdebug ) 49669 # Not quite so much optimization 49670 C_O_FLAG_HI="$C_O_FLAG_NORM" 49671 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 49672 ;; 49673 slowdebug ) 49674 # Disable optimization 49675 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 49676 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 49677 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 49678 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 49679 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 49680 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 49681 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 49682 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 49683 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 49684 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 49685 ;; 49686 esac 49687 49688 49689 49690 49691 49692 49693 49694 49695 49696 49697 49698 49699 49700 49701 49702 49703 49704 49705 49706 # Special extras... 49707 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49708 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49709 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 49710 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 49711 fi 49712 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 49713 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 49714 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49715 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 49716 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 49717 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 49718 CXXSTD_CXXFLAG="-std=gnu++98" 49719 49720 49721 49722 49723 49724 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 49737 49738 49739 49740 49741 49742 49743 49744 49745 49746 49747 49748 49749 49750 49751 49752 49753 49754 49755 49756 49757 49758 49759 49760 49761 # Execute function body 49762 49763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 49764 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 49765 supports=yes 49766 49767 saved_cxxflags="$CXXFLAGS" 49768 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 49769 ac_ext=cpp 49770 ac_cpp='$CXXCPP $CPPFLAGS' 49771 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49772 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49773 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49774 49775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49776 /* end confdefs.h. */ 49777 int i; 49778 _ACEOF 49779 if ac_fn_cxx_try_compile "$LINENO"; then : 49780 49781 else 49782 supports=no 49783 fi 49784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49785 ac_ext=cpp 49786 ac_cpp='$CXXCPP $CPPFLAGS' 49787 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49788 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49789 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49790 49791 CXXFLAGS="$saved_cxxflags" 49792 49793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49794 $as_echo "$supports" >&6; } 49795 if test "x$supports" = "xyes" ; then 49796 : 49797 49798 else 49799 : 49800 CXXSTD_CXXFLAG="" 49801 fi 49802 49803 49804 49805 49806 49807 49808 49809 49810 49811 49812 49813 49814 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 49815 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 49816 49817 fi 49818 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 49819 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 49820 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 49821 fi 49822 49823 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 49824 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 49825 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 49826 fi 49827 49828 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 49829 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 49830 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 49831 49832 ############################################################################### 49833 # 49834 # Now setup the CFLAGS and LDFLAGS for the JDK build. 49835 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 49836 # 49837 49838 # Setup compiler/platform specific flags into 49839 # CFLAGS_JDK - C Compiler flags 49840 # CXXFLAGS_JDK - C++ Compiler flags 49841 # COMMON_CCXXFLAGS_JDK - common to C and C++ 49842 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49843 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49844 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 49845 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 49846 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49847 # Force compatibility with i586 on 32 bit intel platforms. 49848 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49849 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49850 fi 49851 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49852 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49853 case $OPENJDK_TARGET_CPU_ARCH in 49854 arm ) 49855 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49856 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49857 ;; 49858 ppc ) 49859 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49860 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49861 ;; 49862 s390 ) 49863 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 49864 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49865 ;; 49866 * ) 49867 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49868 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49869 ;; 49870 esac 49871 49872 49873 49874 49875 49876 49877 49878 49879 49880 49881 49882 49883 49884 49885 49886 49887 49888 49889 49890 49891 49892 49893 49894 49895 49896 49897 49898 49899 49900 49901 49902 49903 49904 49905 49906 49907 49908 49909 49910 49911 49912 49913 49914 49915 49916 49917 49918 49919 49920 49921 49922 49923 49924 49925 # Execute function body 49926 49927 # Need to assign to a variable since m4 is blocked from modifying parts in []. 49928 REFERENCE_VERSION=6 49929 49930 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 49931 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 49932 fi 49933 49934 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 49935 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 49936 fi 49937 49938 # Version comparison method inspired by http://stackoverflow.com/a/24067243 49939 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 49940 49941 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 49942 : 49943 49944 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 49945 # runs afoul of the more aggressive versions of these optimisations. 49946 # Notably, value range propagation now assumes that the this pointer of C++ 49947 # member functions is non-null. 49948 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 49949 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 49950 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 49951 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 49952 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49953 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49954 49955 else 49956 : 49957 49958 fi 49959 49960 49961 49962 49963 49964 49965 49966 49967 49968 49969 49970 49971 49972 49973 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49974 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49975 49976 # Restrict the debug information created by Clang to avoid 49977 # too big object files and speed the build up a little bit 49978 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 49979 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 49980 if test "x$OPENJDK_TARGET_OS" = xlinux; then 49981 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49982 # Force compatibility with i586 on 32 bit intel platforms. 49983 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49984 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49985 fi 49986 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 49987 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49988 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49989 case $OPENJDK_TARGET_CPU_ARCH in 49990 ppc ) 49991 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49992 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49993 ;; 49994 * ) 49995 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49996 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49997 ;; 49998 esac 49999 fi 50000 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50001 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 50002 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 50003 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 50004 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 50005 fi 50006 50007 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50008 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50009 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50010 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50011 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50012 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50013 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50014 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 50015 -MD -Zc:wchar_t- -W3 -wd4800 \ 50016 -DWIN32_LEAN_AND_MEAN \ 50017 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50018 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50019 -DWIN32 -DIAL" 50020 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50021 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50022 else 50023 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50024 fi 50025 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50026 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50027 # studio. 50028 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50029 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50030 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50031 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50032 fi 50033 fi 50034 50035 ############################################################################### 50036 50037 # Adjust flags according to debug level. 50038 case $DEBUG_LEVEL in 50039 fastdebug | slowdebug ) 50040 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50041 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50042 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50043 ;; 50044 release ) 50045 ;; 50046 * ) 50047 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50048 ;; 50049 esac 50050 50051 # Set some common defines. These works for all compilers, but assume 50052 # -D is universally accepted. 50053 50054 # Setup endianness 50055 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50056 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50057 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50058 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50059 # Note: -Dmacro is the same as #define macro 1 50060 # -Dmacro= is the same as #define macro 50061 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50062 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50063 else 50064 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50065 fi 50066 else 50067 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50068 # are defined in the system? 50069 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50070 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50071 else 50072 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50073 fi 50074 fi 50075 50076 # Setup target OS define. Use OS target name but in upper case. 50077 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50078 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 50079 50080 # Setup target CPU 50081 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50082 $OPENJDK_TARGET_ADD_LP64 \ 50083 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 50084 50085 # Setup debug/release defines 50086 if test "x$DEBUG_LEVEL" = xrelease; then 50087 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 50088 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50089 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 50090 fi 50091 else 50092 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 50093 fi 50094 50095 # Set some additional per-OS defines. 50096 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50097 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 50098 JVM_CFLAGS="$JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50099 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50100 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50101 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 50102 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50103 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50104 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50105 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50106 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 50107 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50108 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50109 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50110 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50111 -fno-omit-frame-pointer" 50112 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50113 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 50114 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50115 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 50116 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50117 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50118 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50119 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50120 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50121 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50122 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 50123 fi 50124 50125 # Set some additional per-CPU defines. 50126 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 50127 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 50128 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50129 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 50130 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 50131 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50132 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50133 # fixes `relocation truncated to fit' error for gcc 4.1. 50134 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 50135 # Use ppc64 instructions, but schedule for power5 50136 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50137 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50138 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 50139 fi 50140 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 50141 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50142 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50143 # Little endian machine uses ELFv2 ABI. 50144 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 50145 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50146 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power7 -mtune=power8" 50147 fi 50148 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 50149 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50150 JVM_CFLAGS="$JVM_CFLAGS -mbackchain -march=z10" 50151 fi 50152 fi 50153 50154 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50155 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50156 fi 50157 50158 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50159 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 50160 # Solaris does not have _LP64=1 in the old build. 50161 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50162 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 50163 fi 50164 fi 50165 50166 # Set JVM_CFLAGS warning handling 50167 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50168 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50169 -Wunused-value -Woverloaded-virtual" 50170 50171 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50172 50173 50174 50175 50176 50177 50178 50179 50180 50181 50182 50183 50184 50185 50186 50187 50188 50189 50190 50191 50192 50193 50194 50195 50196 50197 50198 50199 50200 50201 50202 50203 50204 50205 50206 50207 50208 50209 50210 50211 50212 50213 50214 50215 50216 50217 50218 50219 50220 50221 50222 50223 50224 50225 50226 # Execute function body 50227 50228 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50229 REFERENCE_VERSION=4.8 50230 50231 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50232 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 50233 fi 50234 50235 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50236 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 50237 fi 50238 50239 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50240 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50241 50242 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50243 : 50244 50245 # These flags either do not work or give spurious warnings prior to gcc 4.8. 50246 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 50247 50248 50249 else 50250 : 50251 50252 fi 50253 50254 50255 50256 50257 50258 50259 50260 50261 50262 50263 50264 50265 50266 50267 fi 50268 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 50269 # Non-zero builds have stricter warnings 50270 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 50271 else 50272 if test "x$TOOLCHAIN_TYPE" = xclang; then 50273 # Some versions of llvm do not like -Wundef 50274 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 50275 fi 50276 fi 50277 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50278 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 50279 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 50280 fi 50281 50282 # Additional macosx handling 50283 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50284 # Setting these parameters makes it an error to link to macosx APIs that are 50285 # newer than the given OS version and makes the linked binaries compatible 50286 # even if built on a newer version of the OS. 50287 # The expected format is X.Y.Z 50288 MACOSX_VERSION_MIN=10.7.0 50289 50290 50291 # The macro takes the version with no dots, ex: 1070 50292 # Let the flags variables get resolved in make for easier override on make 50293 # command line. 50294 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50295 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50296 fi 50297 50298 # Setup some hard coded includes 50299 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50300 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 50301 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 50302 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 50303 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 50304 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 50305 50306 # The shared libraries are compiled using the picflag. 50307 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50308 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 50309 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50310 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 50311 50312 # Executable flags 50313 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 50314 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 50315 50316 50317 50318 50319 50320 50321 # Setup LDFLAGS et al. 50322 # 50323 50324 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50325 LDFLAGS_MICROSOFT="-nologo -opt:ref" 50326 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 50327 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 50328 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50329 LDFLAGS_SAFESH="-safeseh" 50330 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 50331 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 50332 # NOTE: Old build added -machine. Probably not needed. 50333 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 50334 else 50335 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 50336 fi 50337 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50338 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 50339 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50340 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 50341 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50342 fi 50343 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50344 # If this is a --hash-style=gnu system, use --hash-style=both, why? 50345 # We have previously set HAS_GNU_HASH if this is the case 50346 if test -n "$HAS_GNU_HASH"; then 50347 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 50348 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 50349 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 50350 fi 50351 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50352 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50353 fi 50354 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50355 # And since we now know that the linker is gnu, then add -z defs, to forbid 50356 # undefined symbols in object files. 50357 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 50358 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 50359 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 50360 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 50361 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 50362 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50363 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 50364 fi 50365 case $DEBUG_LEVEL in 50366 release ) 50367 # tell linker to optimize libraries. 50368 # Should this be supplied to the OSS linker as well? 50369 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 50370 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 50371 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 50372 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50373 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50374 fi 50375 ;; 50376 slowdebug ) 50377 # Hotspot always let the linker optimize 50378 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50379 if test "x$HAS_LINKER_NOW" = "xtrue"; then 50380 # do relocations at load 50381 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 50382 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 50383 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 50384 fi 50385 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50386 # mark relocations read only 50387 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50388 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50389 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50390 fi 50391 ;; 50392 fastdebug ) 50393 # Hotspot always let the linker optimize 50394 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50395 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50396 # mark relocations read only 50397 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50398 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50399 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50400 fi 50401 ;; 50402 * ) 50403 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50404 ;; 50405 esac 50406 fi 50407 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50408 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 50409 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 50410 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 50411 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 50412 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 50413 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50414 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 50415 fi 50416 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50417 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 50418 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 50419 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 50420 fi 50421 50422 # Customize LDFLAGS for executables 50423 50424 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 50425 50426 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50427 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 50428 LDFLAGS_STACK_SIZE=1048576 50429 else 50430 LDFLAGS_STACK_SIZE=327680 50431 fi 50432 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 50433 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50434 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 50435 fi 50436 50437 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 50438 50439 # Customize LDFLAGS for libs 50440 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 50441 50442 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 50443 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50444 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50445 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 50446 JDKLIB_LIBS="" 50447 else 50448 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50449 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)" 50450 50451 if test "xTARGET" = "xTARGET"; then 50452 # On some platforms (mac) the linker warns about non existing -L dirs. 50453 # Add server first if available. Linking aginst client does not always produce the same results. 50454 # Only add client/minimal dir if client/minimal is being built. 50455 # Default to server for other variants. 50456 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 50457 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50458 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 50459 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/client" 50460 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 50461 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/minimal" 50462 else 50463 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50464 fi 50465 elif test "xTARGET" = "xBUILD"; then 50466 # When building a buildjdk, it's always only the server variant 50467 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50468 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50469 fi 50470 50471 JDKLIB_LIBS="-ljava -ljvm" 50472 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50473 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 50474 fi 50475 50476 fi 50477 50478 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 50479 50480 # Set JVM_LIBS (per os) 50481 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50482 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 50483 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50484 # FIXME: This hard-coded path is not really proper. 50485 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50486 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 50487 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50488 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 50489 fi 50490 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 50491 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 50492 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50493 JVM_LIBS="$JVM_LIBS -lm" 50494 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50495 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 50496 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50497 JVM_LIBS="$JVM_LIBS -lm" 50498 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50499 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 50500 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 50501 wsock32.lib winmm.lib version.lib psapi.lib" 50502 fi 50503 50504 # Set JVM_ASFLAGS 50505 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50506 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50507 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 50508 fi 50509 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50510 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 50511 fi 50512 50513 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 50514 50515 50516 50517 50518 50519 50520 50521 50522 50523 50524 50525 50526 50527 50528 50529 # Special extras... 50530 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50531 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 50532 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50533 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50534 fi 50535 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50536 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50537 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50538 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50539 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50540 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50541 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 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 50570 50571 50572 50573 50574 50575 50576 50577 50578 50579 50580 50581 50582 50583 50584 # Execute function body 50585 50586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 50587 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 50588 supports=yes 50589 50590 saved_cxxflags="$CXXFLAGS" 50591 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 50592 ac_ext=cpp 50593 ac_cpp='$CXXCPP $CPPFLAGS' 50594 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50595 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50596 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50597 50598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50599 /* end confdefs.h. */ 50600 int i; 50601 _ACEOF 50602 if ac_fn_cxx_try_compile "$LINENO"; then : 50603 50604 else 50605 supports=no 50606 fi 50607 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50608 ac_ext=cpp 50609 ac_cpp='$CXXCPP $CPPFLAGS' 50610 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50611 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50612 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50613 50614 CXXFLAGS="$saved_cxxflags" 50615 50616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50617 $as_echo "$supports" >&6; } 50618 if test "x$supports" = "xyes" ; then 50619 : 50620 50621 else 50622 : 50623 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 50624 fi 50625 50626 50627 50628 50629 50630 50631 50632 50633 50634 50635 50636 50637 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50638 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50639 50640 fi 50641 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50642 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50643 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50644 fi 50645 50646 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50647 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50648 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50649 fi 50650 50651 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 50652 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 50653 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 50654 50655 ############################################################################### 50656 # 50657 # Now setup the CFLAGS and LDFLAGS for the JDK build. 50658 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 50659 # 50660 50661 # Setup compiler/platform specific flags into 50662 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 50663 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 50664 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 50665 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50666 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50667 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 50668 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 50669 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50670 # Force compatibility with i586 on 32 bit intel platforms. 50671 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50672 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50673 fi 50674 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50675 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50676 case $OPENJDK_BUILD_CPU_ARCH in 50677 arm ) 50678 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50679 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50680 ;; 50681 ppc ) 50682 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50683 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50684 ;; 50685 s390 ) 50686 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 50687 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50688 ;; 50689 * ) 50690 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50691 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50692 ;; 50693 esac 50694 50695 50696 50697 50698 50699 50700 50701 50702 50703 50704 50705 50706 50707 50708 50709 50710 50711 50712 50713 50714 50715 50716 50717 50718 50719 50720 50721 50722 50723 50724 50725 50726 50727 50728 50729 50730 50731 50732 50733 50734 50735 50736 50737 50738 50739 50740 50741 50742 50743 50744 50745 50746 50747 50748 # Execute function body 50749 50750 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50751 REFERENCE_VERSION=6 50752 50753 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50754 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 50755 fi 50756 50757 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50758 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 50759 fi 50760 50761 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50762 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50763 50764 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50765 : 50766 50767 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 50768 # runs afoul of the more aggressive versions of these optimisations. 50769 # Notably, value range propagation now assumes that the this pointer of C++ 50770 # member functions is non-null. 50771 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 50772 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 50773 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 50774 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 50775 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50776 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50777 50778 else 50779 : 50780 50781 fi 50782 50783 50784 50785 50786 50787 50788 50789 50790 50791 50792 50793 50794 50795 50796 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50797 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50798 50799 # Restrict the debug information created by Clang to avoid 50800 # too big object files and speed the build up a little bit 50801 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 50802 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 50803 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50804 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50805 # Force compatibility with i586 on 32 bit intel platforms. 50806 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50807 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50808 fi 50809 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 50810 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50811 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50812 case $OPENJDK_BUILD_CPU_ARCH in 50813 ppc ) 50814 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50815 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50816 ;; 50817 * ) 50818 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50819 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50820 ;; 50821 esac 50822 fi 50823 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50824 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 50825 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 50826 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 50827 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 50828 fi 50829 50830 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50831 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50832 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50833 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50834 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50835 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50836 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50837 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50838 -MD -Zc:wchar_t- -W3 -wd4800 \ 50839 -DWIN32_LEAN_AND_MEAN \ 50840 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50841 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50842 -DWIN32 -DIAL" 50843 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 50844 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50845 else 50846 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50847 fi 50848 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50849 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50850 # studio. 50851 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50852 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50853 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50854 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50855 fi 50856 fi 50857 50858 ############################################################################### 50859 50860 # Adjust flags according to debug level. 50861 case $DEBUG_LEVEL in 50862 fastdebug | slowdebug ) 50863 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50864 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50865 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50866 ;; 50867 release ) 50868 ;; 50869 * ) 50870 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50871 ;; 50872 esac 50873 50874 # Set some common defines. These works for all compilers, but assume 50875 # -D is universally accepted. 50876 50877 # Setup endianness 50878 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50879 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50880 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50881 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50882 # Note: -Dmacro is the same as #define macro 1 50883 # -Dmacro= is the same as #define macro 50884 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50885 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50886 else 50887 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50888 fi 50889 else 50890 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50891 # are defined in the system? 50892 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50893 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50894 else 50895 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50896 fi 50897 fi 50898 50899 # Setup target OS define. Use OS target name but in upper case. 50900 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50901 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 50902 50903 # Setup target CPU 50904 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50905 $OPENJDK_BUILD_ADD_LP64 \ 50906 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 50907 50908 # Setup debug/release defines 50909 if test "x$DEBUG_LEVEL" = xrelease; then 50910 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 50911 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50912 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 50913 fi 50914 else 50915 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 50916 fi 50917 50918 # Set some additional per-OS defines. 50919 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50920 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 50921 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50922 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50923 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 50924 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 50925 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50926 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50927 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 50928 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50929 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 50930 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50931 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50932 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50933 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50934 -fno-omit-frame-pointer" 50935 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50936 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 50937 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50938 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 50939 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50940 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50941 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 50942 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50943 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 50944 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50945 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 50946 fi 50947 50948 # Set some additional per-CPU defines. 50949 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 50950 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 50951 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 50952 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 50953 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 50954 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50955 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50956 # fixes `relocation truncated to fit' error for gcc 4.1. 50957 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 50958 # Use ppc64 instructions, but schedule for power5 50959 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50960 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50961 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 50962 fi 50963 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 50964 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50965 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50966 # Little endian machine uses ELFv2 ABI. 50967 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 50968 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50969 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power7 -mtune=power8" 50970 fi 50971 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 50972 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50973 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mbackchain -march=z10" 50974 fi 50975 fi 50976 50977 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50978 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50979 fi 50980 50981 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 50982 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 50983 # Solaris does not have _LP64=1 in the old build. 50984 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50985 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 50986 fi 50987 fi 50988 50989 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 50990 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50991 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50992 -Wunused-value -Woverloaded-virtual" 50993 50994 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50995 50996 50997 50998 50999 51000 51001 51002 51003 51004 51005 51006 51007 51008 51009 51010 51011 51012 51013 51014 51015 51016 51017 51018 51019 51020 51021 51022 51023 51024 51025 51026 51027 51028 51029 51030 51031 51032 51033 51034 51035 51036 51037 51038 51039 51040 51041 51042 51043 51044 51045 51046 51047 51048 51049 # Execute function body 51050 51051 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51052 REFERENCE_VERSION=4.8 51053 51054 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 51055 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 51056 fi 51057 51058 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51059 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51060 fi 51061 51062 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51063 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 51064 51065 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51066 : 51067 51068 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51069 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51070 51071 51072 else 51073 : 51074 51075 fi 51076 51077 51078 51079 51080 51081 51082 51083 51084 51085 51086 51087 51088 51089 51090 fi 51091 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51092 # Non-zero builds have stricter warnings 51093 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51094 else 51095 if test "x$TOOLCHAIN_TYPE" = xclang; then 51096 # Some versions of llvm do not like -Wundef 51097 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 51098 fi 51099 fi 51100 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51101 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51102 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51103 fi 51104 51105 # Additional macosx handling 51106 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51107 # Setting these parameters makes it an error to link to macosx APIs that are 51108 # newer than the given OS version and makes the linked binaries compatible 51109 # even if built on a newer version of the OS. 51110 # The expected format is X.Y.Z 51111 MACOSX_VERSION_MIN=10.7.0 51112 51113 51114 # The macro takes the version with no dots, ex: 1070 51115 # Let the flags variables get resolved in make for easier override on make 51116 # command line. 51117 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51118 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51119 fi 51120 51121 # Setup some hard coded includes 51122 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51123 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 51124 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 51125 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 51126 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 51127 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 51128 51129 # The shared libraries are compiled using the picflag. 51130 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51131 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 51132 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51133 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 51134 51135 # Executable flags 51136 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 51137 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 51138 51139 51140 51141 51142 51143 51144 # Setup LDFLAGS et al. 51145 # 51146 51147 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51148 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51149 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51150 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51151 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 51152 LDFLAGS_SAFESH="-safeseh" 51153 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 51154 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 51155 # NOTE: Old build added -machine. Probably not needed. 51156 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 51157 else 51158 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 51159 fi 51160 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51161 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51162 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51163 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51164 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51165 fi 51166 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51167 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51168 # We have previously set HAS_GNU_HASH if this is the case 51169 if test -n "$HAS_GNU_HASH"; then 51170 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51171 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51172 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51173 fi 51174 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51175 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51176 fi 51177 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51178 # And since we now know that the linker is gnu, then add -z defs, to forbid 51179 # undefined symbols in object files. 51180 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51181 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51182 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51183 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51184 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51185 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51186 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 51187 fi 51188 case $DEBUG_LEVEL in 51189 release ) 51190 # tell linker to optimize libraries. 51191 # Should this be supplied to the OSS linker as well? 51192 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51193 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51194 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51195 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51196 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51197 fi 51198 ;; 51199 slowdebug ) 51200 # Hotspot always let the linker optimize 51201 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51202 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51203 # do relocations at load 51204 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 51205 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 51206 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 51207 fi 51208 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51209 # mark relocations read only 51210 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51211 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51212 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51213 fi 51214 ;; 51215 fastdebug ) 51216 # Hotspot always let the linker optimize 51217 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51218 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51219 # mark relocations read only 51220 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51221 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51222 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51223 fi 51224 ;; 51225 * ) 51226 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51227 ;; 51228 esac 51229 fi 51230 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51231 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 51232 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 51233 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 51234 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 51235 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 51236 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51237 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 51238 fi 51239 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51240 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 51241 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 51242 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 51243 fi 51244 51245 # Customize LDFLAGS for executables 51246 51247 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 51248 51249 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51250 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 51251 LDFLAGS_STACK_SIZE=1048576 51252 else 51253 LDFLAGS_STACK_SIZE=327680 51254 fi 51255 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 51256 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 51257 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 51258 fi 51259 51260 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51261 51262 # Customize LDFLAGS for libs 51263 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 51264 51265 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 51266 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51267 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51268 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 51269 OPENJDK_BUILD_JDKLIB_LIBS="" 51270 else 51271 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51272 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)" 51273 51274 if test "xBUILD" = "xTARGET"; then 51275 # On some platforms (mac) the linker warns about non existing -L dirs. 51276 # Add server first if available. Linking aginst client does not always produce the same results. 51277 # Only add client/minimal dir if client/minimal is being built. 51278 # Default to server for other variants. 51279 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 51280 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51281 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 51282 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/client" 51283 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 51284 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/minimal" 51285 else 51286 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51287 fi 51288 elif test "xBUILD" = "xBUILD"; then 51289 # When building a buildjdk, it's always only the server variant 51290 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51291 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51292 fi 51293 51294 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 51295 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51296 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 51297 fi 51298 51299 fi 51300 51301 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 51302 51303 # Set OPENJDK_BUILD_JVM_LIBS (per os) 51304 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51305 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 51306 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 51307 # FIXME: This hard-coded path is not really proper. 51308 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 51309 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 51310 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 51311 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 51312 fi 51313 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 51314 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 51315 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51316 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51317 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51318 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 51319 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 51320 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51321 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 51322 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51323 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51324 wsock32.lib winmm.lib version.lib psapi.lib" 51325 fi 51326 51327 # Set OPENJDK_BUILD_JVM_ASFLAGS 51328 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51329 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51330 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 51331 fi 51332 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51333 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51334 fi 51335 51336 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51337 51338 51339 51340 51341 51342 51343 51344 51345 51346 51347 51348 51349 51350 51351 51352 # Tests are only ever compiled for TARGET 51353 # Flags for compiling test libraries 51354 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51355 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51356 51357 # Flags for compiling test executables 51358 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 51359 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 51360 51361 51362 51363 51364 51365 51366 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 51367 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 51368 51369 51370 51371 51372 51373 51374 # Some Zero and Shark settings. 51375 # ZERO_ARCHFLAG tells the compiler which mode to build for 51376 case "${OPENJDK_TARGET_CPU}" in 51377 s390) 51378 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31" 51379 ;; 51380 *) 51381 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51382 esac 51383 51384 51385 51386 51387 51388 51389 51390 51391 51392 51393 51394 51395 51396 51397 51398 51399 51400 51401 51402 51403 51404 51405 51406 51407 51408 51409 51410 51411 51412 51413 51414 51415 51416 51417 51418 51419 51420 51421 51422 51423 51424 51425 # Execute function body 51426 51427 51428 51429 51430 51431 51432 51433 51434 51435 51436 51437 51438 51439 51440 51441 51442 51443 51444 51445 51446 51447 51448 51449 51450 51451 51452 51453 51454 51455 51456 51457 51458 51459 51460 51461 51462 51463 51464 51465 51466 51467 51468 51469 51470 51471 51472 51473 51474 # Execute function body 51475 51476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$ZERO_ARCHFLAG\"" >&5 51477 $as_echo_n "checking if the C compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51478 supports=yes 51479 51480 saved_cflags="$CFLAGS" 51481 CFLAGS="$CFLAGS $ZERO_ARCHFLAG" 51482 ac_ext=c 51483 ac_cpp='$CPP $CPPFLAGS' 51484 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51485 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51486 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51487 51488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51489 /* end confdefs.h. */ 51490 int i; 51491 _ACEOF 51492 if ac_fn_c_try_compile "$LINENO"; then : 51493 51494 else 51495 supports=no 51496 fi 51497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51498 ac_ext=cpp 51499 ac_cpp='$CXXCPP $CPPFLAGS' 51500 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51501 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51502 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51503 51504 CFLAGS="$saved_cflags" 51505 51506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51507 $as_echo "$supports" >&6; } 51508 if test "x$supports" = "xyes" ; then 51509 : 51510 C_COMP_SUPPORTS="yes" 51511 else 51512 : 51513 C_COMP_SUPPORTS="no" 51514 fi 51515 51516 51517 51518 51519 51520 51521 51522 51523 51524 51525 51526 51527 51528 51529 51530 51531 51532 51533 51534 51535 51536 51537 51538 51539 51540 51541 51542 51543 51544 51545 51546 51547 51548 51549 51550 51551 51552 51553 51554 51555 51556 51557 51558 51559 51560 51561 51562 51563 51564 51565 51566 51567 51568 51569 51570 51571 51572 51573 51574 # Execute function body 51575 51576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"" >&5 51577 $as_echo_n "checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51578 supports=yes 51579 51580 saved_cxxflags="$CXXFLAGS" 51581 CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG" 51582 ac_ext=cpp 51583 ac_cpp='$CXXCPP $CPPFLAGS' 51584 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51585 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51586 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51587 51588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51589 /* end confdefs.h. */ 51590 int i; 51591 _ACEOF 51592 if ac_fn_cxx_try_compile "$LINENO"; then : 51593 51594 else 51595 supports=no 51596 fi 51597 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51598 ac_ext=cpp 51599 ac_cpp='$CXXCPP $CPPFLAGS' 51600 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51601 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51602 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51603 51604 CXXFLAGS="$saved_cxxflags" 51605 51606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51607 $as_echo "$supports" >&6; } 51608 if test "x$supports" = "xyes" ; then 51609 : 51610 CXX_COMP_SUPPORTS="yes" 51611 else 51612 : 51613 CXX_COMP_SUPPORTS="no" 51614 fi 51615 51616 51617 51618 51619 51620 51621 51622 51623 51624 51625 51626 51627 51628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$ZERO_ARCHFLAG\"" >&5 51629 $as_echo_n "checking if both compilers support \"$ZERO_ARCHFLAG\"... " >&6; } 51630 supports=no 51631 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51632 51633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51634 $as_echo "$supports" >&6; } 51635 if test "x$supports" = "xyes" ; then 51636 : 51637 51638 else 51639 : 51640 ZERO_ARCHFLAG="" 51641 fi 51642 51643 51644 51645 51646 51647 51648 51649 51650 # Check that the compiler supports -mX (or -qX on AIX) flags 51651 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 51652 51653 51654 51655 51656 51657 51658 51659 51660 51661 51662 51663 51664 51665 51666 51667 51668 51669 51670 51671 51672 51673 51674 51675 51676 51677 51678 51679 51680 51681 51682 51683 51684 51685 51686 51687 51688 51689 51690 51691 51692 51693 51694 51695 51696 51697 51698 51699 # Execute function body 51700 51701 51702 51703 51704 51705 51706 51707 51708 51709 51710 51711 51712 51713 51714 51715 51716 51717 51718 51719 51720 51721 51722 51723 51724 51725 51726 51727 51728 51729 51730 51731 51732 51733 51734 51735 51736 51737 51738 51739 51740 51741 51742 51743 51744 51745 51746 51747 51748 # Execute function body 51749 51750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51751 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51752 supports=yes 51753 51754 saved_cflags="$CFLAGS" 51755 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51756 ac_ext=c 51757 ac_cpp='$CPP $CPPFLAGS' 51758 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51759 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51760 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51761 51762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51763 /* end confdefs.h. */ 51764 int i; 51765 _ACEOF 51766 if ac_fn_c_try_compile "$LINENO"; then : 51767 51768 else 51769 supports=no 51770 fi 51771 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51772 ac_ext=cpp 51773 ac_cpp='$CXXCPP $CPPFLAGS' 51774 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51775 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51776 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51777 51778 CFLAGS="$saved_cflags" 51779 51780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51781 $as_echo "$supports" >&6; } 51782 if test "x$supports" = "xyes" ; then 51783 : 51784 C_COMP_SUPPORTS="yes" 51785 else 51786 : 51787 C_COMP_SUPPORTS="no" 51788 fi 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 51808 51809 51810 51811 51812 51813 51814 51815 51816 51817 51818 51819 51820 51821 51822 51823 51824 51825 51826 51827 51828 51829 51830 51831 51832 51833 51834 51835 51836 51837 51838 51839 51840 51841 51842 51843 51844 51845 51846 51847 51848 # Execute function body 51849 51850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51851 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51852 supports=yes 51853 51854 saved_cxxflags="$CXXFLAGS" 51855 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51856 ac_ext=cpp 51857 ac_cpp='$CXXCPP $CPPFLAGS' 51858 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51859 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51860 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51861 51862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51863 /* end confdefs.h. */ 51864 int i; 51865 _ACEOF 51866 if ac_fn_cxx_try_compile "$LINENO"; then : 51867 51868 else 51869 supports=no 51870 fi 51871 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51872 ac_ext=cpp 51873 ac_cpp='$CXXCPP $CPPFLAGS' 51874 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51875 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51876 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51877 51878 CXXFLAGS="$saved_cxxflags" 51879 51880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51881 $as_echo "$supports" >&6; } 51882 if test "x$supports" = "xyes" ; then 51883 : 51884 CXX_COMP_SUPPORTS="yes" 51885 else 51886 : 51887 CXX_COMP_SUPPORTS="no" 51888 fi 51889 51890 51891 51892 51893 51894 51895 51896 51897 51898 51899 51900 51901 51902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51903 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51904 supports=no 51905 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51906 51907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51908 $as_echo "$supports" >&6; } 51909 if test "x$supports" = "xyes" ; then 51910 : 51911 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 51912 else 51913 : 51914 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 51915 fi 51916 51917 51918 51919 51920 51921 51922 51923 51924 # Check whether --enable-warnings-as-errors was given. 51925 if test "${enable_warnings_as_errors+set}" = set; then : 51926 enableval=$enable_warnings_as_errors; 51927 fi 51928 51929 51930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 51931 $as_echo_n "checking if native warnings are errors... " >&6; } 51932 if test "x$enable_warnings_as_errors" = "xyes"; then 51933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitely set)" >&5 51934 $as_echo "yes (explicitely set)" >&6; } 51935 WARNINGS_AS_ERRORS=true 51936 elif test "x$enable_warnings_as_errors" = "xno"; then 51937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 51938 $as_echo "no" >&6; } 51939 WARNINGS_AS_ERRORS=false 51940 elif test "x$enable_warnings_as_errors" = "x"; then 51941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 51942 $as_echo "yes (default)" >&6; } 51943 WARNINGS_AS_ERRORS=true 51944 else 51945 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 51946 fi 51947 51948 if test "x$WARNINGS_AS_ERRORS" = "xfalse"; then 51949 # Set legacy hotspot variable 51950 HOTSPOT_SET_WARNINGS_AS_ERRORS="WARNINGS_ARE_ERRORS=" 51951 else 51952 HOTSPOT_SET_WARNINGS_AS_ERRORS="" 51953 fi 51954 51955 51956 51957 51958 case "${TOOLCHAIN_TYPE}" in 51959 microsoft) 51960 DISABLE_WARNING_PREFIX="-wd" 51961 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 51962 ;; 51963 solstudio) 51964 DISABLE_WARNING_PREFIX="-erroff=" 51965 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 51966 ;; 51967 gcc) 51968 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 51969 51970 51971 51972 51973 51974 51975 51976 51977 51978 51979 51980 51981 51982 51983 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 # Execute function body 52017 52018 52019 52020 52021 52022 52023 52024 52025 52026 52027 52028 52029 52030 52031 52032 52033 52034 52035 52036 52037 52038 52039 52040 52041 52042 52043 52044 52045 52046 52047 52048 52049 52050 52051 52052 52053 52054 52055 52056 52057 52058 52059 52060 52061 52062 52063 52064 52065 # Execute function body 52066 52067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52068 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52069 supports=yes 52070 52071 saved_cflags="$CFLAGS" 52072 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52073 ac_ext=c 52074 ac_cpp='$CPP $CPPFLAGS' 52075 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52076 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52077 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52078 52079 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52080 /* end confdefs.h. */ 52081 int i; 52082 _ACEOF 52083 if ac_fn_c_try_compile "$LINENO"; then : 52084 52085 else 52086 supports=no 52087 fi 52088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52089 ac_ext=cpp 52090 ac_cpp='$CXXCPP $CPPFLAGS' 52091 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52092 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52093 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52094 52095 CFLAGS="$saved_cflags" 52096 52097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52098 $as_echo "$supports" >&6; } 52099 if test "x$supports" = "xyes" ; then 52100 : 52101 C_COMP_SUPPORTS="yes" 52102 else 52103 : 52104 C_COMP_SUPPORTS="no" 52105 fi 52106 52107 52108 52109 52110 52111 52112 52113 52114 52115 52116 52117 52118 52119 52120 52121 52122 52123 52124 52125 52126 52127 52128 52129 52130 52131 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 # Execute function body 52166 52167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52168 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52169 supports=yes 52170 52171 saved_cxxflags="$CXXFLAGS" 52172 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52173 ac_ext=cpp 52174 ac_cpp='$CXXCPP $CPPFLAGS' 52175 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52176 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52177 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52178 52179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52180 /* end confdefs.h. */ 52181 int i; 52182 _ACEOF 52183 if ac_fn_cxx_try_compile "$LINENO"; then : 52184 52185 else 52186 supports=no 52187 fi 52188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52189 ac_ext=cpp 52190 ac_cpp='$CXXCPP $CPPFLAGS' 52191 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52192 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52193 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52194 52195 CXXFLAGS="$saved_cxxflags" 52196 52197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52198 $as_echo "$supports" >&6; } 52199 if test "x$supports" = "xyes" ; then 52200 : 52201 CXX_COMP_SUPPORTS="yes" 52202 else 52203 : 52204 CXX_COMP_SUPPORTS="no" 52205 fi 52206 52207 52208 52209 52210 52211 52212 52213 52214 52215 52216 52217 52218 52219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52220 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52221 supports=no 52222 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52223 52224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52225 $as_echo "$supports" >&6; } 52226 if test "x$supports" = "xyes" ; then 52227 : 52228 GCC_CAN_DISABLE_WARNINGS=true 52229 else 52230 : 52231 GCC_CAN_DISABLE_WARNINGS=false 52232 52233 fi 52234 52235 52236 52237 52238 52239 52240 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52241 DISABLE_WARNING_PREFIX="-Wno-" 52242 else 52243 DISABLE_WARNING_PREFIX= 52244 fi 52245 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52246 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 52247 # CFLAGS since any target specific flags will likely not work with the 52248 # build compiler 52249 CC_OLD="$CC" 52250 CXX_OLD="$CXX" 52251 CC="$BUILD_CC" 52252 CXX="$BUILD_CXX" 52253 CFLAGS_OLD="$CFLAGS" 52254 CFLAGS="" 52255 52256 52257 52258 52259 52260 52261 52262 52263 52264 52265 52266 52267 52268 52269 52270 52271 52272 52273 52274 52275 52276 52277 52278 52279 52280 52281 52282 52283 52284 52285 52286 52287 52288 52289 52290 52291 52292 52293 52294 52295 52296 52297 52298 52299 52300 52301 52302 # Execute function body 52303 52304 52305 52306 52307 52308 52309 52310 52311 52312 52313 52314 52315 52316 52317 52318 52319 52320 52321 52322 52323 52324 52325 52326 52327 52328 52329 52330 52331 52332 52333 52334 52335 52336 52337 52338 52339 52340 52341 52342 52343 52344 52345 52346 52347 52348 52349 52350 52351 # Execute function body 52352 52353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52354 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52355 supports=yes 52356 52357 saved_cflags="$CFLAGS" 52358 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52359 ac_ext=c 52360 ac_cpp='$CPP $CPPFLAGS' 52361 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52362 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52363 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52364 52365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52366 /* end confdefs.h. */ 52367 int i; 52368 _ACEOF 52369 if ac_fn_c_try_compile "$LINENO"; then : 52370 52371 else 52372 supports=no 52373 fi 52374 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52375 ac_ext=cpp 52376 ac_cpp='$CXXCPP $CPPFLAGS' 52377 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52378 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52379 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52380 52381 CFLAGS="$saved_cflags" 52382 52383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52384 $as_echo "$supports" >&6; } 52385 if test "x$supports" = "xyes" ; then 52386 : 52387 C_COMP_SUPPORTS="yes" 52388 else 52389 : 52390 C_COMP_SUPPORTS="no" 52391 fi 52392 52393 52394 52395 52396 52397 52398 52399 52400 52401 52402 52403 52404 52405 52406 52407 52408 52409 52410 52411 52412 52413 52414 52415 52416 52417 52418 52419 52420 52421 52422 52423 52424 52425 52426 52427 52428 52429 52430 52431 52432 52433 52434 52435 52436 52437 52438 52439 52440 52441 52442 52443 52444 52445 52446 52447 52448 52449 52450 52451 # Execute function body 52452 52453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52454 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52455 supports=yes 52456 52457 saved_cxxflags="$CXXFLAGS" 52458 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52459 ac_ext=cpp 52460 ac_cpp='$CXXCPP $CPPFLAGS' 52461 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52462 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52463 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52464 52465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52466 /* end confdefs.h. */ 52467 int i; 52468 _ACEOF 52469 if ac_fn_cxx_try_compile "$LINENO"; then : 52470 52471 else 52472 supports=no 52473 fi 52474 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52475 ac_ext=cpp 52476 ac_cpp='$CXXCPP $CPPFLAGS' 52477 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52478 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52479 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52480 52481 CXXFLAGS="$saved_cxxflags" 52482 52483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52484 $as_echo "$supports" >&6; } 52485 if test "x$supports" = "xyes" ; then 52486 : 52487 CXX_COMP_SUPPORTS="yes" 52488 else 52489 : 52490 CXX_COMP_SUPPORTS="no" 52491 fi 52492 52493 52494 52495 52496 52497 52498 52499 52500 52501 52502 52503 52504 52505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52506 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52507 supports=no 52508 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52509 52510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52511 $as_echo "$supports" >&6; } 52512 if test "x$supports" = "xyes" ; then 52513 : 52514 BUILD_CC_CAN_DISABLE_WARNINGS=true 52515 else 52516 : 52517 BUILD_CC_CAN_DISABLE_WARNINGS=false 52518 52519 fi 52520 52521 52522 52523 52524 52525 52526 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52527 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 52528 else 52529 BUILD_CC_DISABLE_WARNING_PREFIX= 52530 fi 52531 CC="$CC_OLD" 52532 CXX="$CXX_OLD" 52533 CFLAGS="$CFLAGS_OLD" 52534 ;; 52535 clang) 52536 DISABLE_WARNING_PREFIX="-Wno-" 52537 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52538 ;; 52539 xlc) 52540 DISABLE_WARNING_PREFIX="-qsuppress=" 52541 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 52542 ;; 52543 esac 52544 52545 52546 52547 52548 52549 # Setup debug symbols (need objcopy from the toolchain for that) 52550 52551 # 52552 # NATIVE_DEBUG_SYMBOLS 52553 # This must be done after the toolchain is setup, since we're looking at objcopy. 52554 # 52555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 52556 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 52557 52558 # Check whether --with-native-debug-symbols was given. 52559 if test "${with_native_debug_symbols+set}" = set; then : 52560 withval=$with_native_debug_symbols; 52561 if test "x$OPENJDK_TARGET_OS" = xaix; then 52562 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 52563 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 52564 fi 52565 fi 52566 52567 else 52568 52569 if test "x$OPENJDK_TARGET_OS" = xaix; then 52570 # AIX doesn't support 'zipped' so use 'internal' as default 52571 with_native_debug_symbols="internal" 52572 else 52573 if test "x$STATIC_BUILD" = xtrue; then 52574 with_native_debug_symbols="none" 52575 else 52576 with_native_debug_symbols="zipped" 52577 fi 52578 fi 52579 52580 fi 52581 52582 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 52583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 52584 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 52585 52586 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 52587 52588 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52589 if test "x$OBJCOPY" = x; then 52590 # enabling of enable-debug-symbols and can't find objcopy 52591 # this is an error 52592 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52593 fi 52594 fi 52595 52596 COMPILE_WITH_DEBUG_SYMBOLS=true 52597 COPY_DEBUG_SYMBOLS=true 52598 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 52599 52600 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52601 DEBUG_BINARIES=false 52602 STRIP_POLICY=min_strip 52603 52604 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 52605 COMPILE_WITH_DEBUG_SYMBOLS=false 52606 COPY_DEBUG_SYMBOLS=false 52607 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52608 52609 DEBUG_BINARIES=false 52610 STRIP_POLICY=no_strip 52611 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 52612 COMPILE_WITH_DEBUG_SYMBOLS=true 52613 COPY_DEBUG_SYMBOLS=false 52614 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52615 52616 # Hotspot legacy support, will turn on -g when COPY_DEBUG_SYMBOLS=false 52617 DEBUG_BINARIES=true 52618 STRIP_POLICY=no_strip 52619 STRIP="" 52620 52621 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 52622 52623 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52624 if test "x$OBJCOPY" = x; then 52625 # enabling of enable-debug-symbols and can't find objcopy 52626 # this is an error 52627 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52628 fi 52629 fi 52630 52631 COMPILE_WITH_DEBUG_SYMBOLS=true 52632 COPY_DEBUG_SYMBOLS=true 52633 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52634 52635 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52636 DEBUG_BINARIES=false 52637 STRIP_POLICY=min_strip 52638 else 52639 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 52640 fi 52641 52642 # --enable-debug-symbols is deprecated. 52643 # Please use --with-native-debug-symbols=[internal,external,zipped] . 52644 52645 # Check whether --enable-debug-symbols was given. 52646 if test "${enable_debug_symbols+set}" = set; then : 52647 enableval=$enable_debug_symbols; 52648 fi 52649 52650 if test "x$enable_debug_symbols" != x; then 52651 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 52652 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 52653 52654 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 52655 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 52656 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 52657 fi 52658 52659 fi 52660 52661 52662 # --enable-zip-debug-info is deprecated. 52663 # Please use --with-native-debug-symbols=zipped . 52664 52665 # Check whether --enable-zip-debug-info was given. 52666 if test "${enable_zip_debug_info+set}" = set; then : 52667 enableval=$enable_zip_debug_info; 52668 fi 52669 52670 if test "x$enable_zip_debug_info" != x; then 52671 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 52672 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 52673 52674 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 52675 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 52676 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 52677 fi 52678 52679 fi 52680 52681 52682 52683 52684 52685 52686 # Legacy values 52687 52688 52689 52690 52691 # Check whether --enable-native-coverage was given. 52692 if test "${enable_native_coverage+set}" = set; then : 52693 enableval=$enable_native_coverage; 52694 fi 52695 52696 GCOV_ENABLED="false" 52697 if test "x$enable_native_coverage" = "xyes"; then 52698 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 52699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52700 $as_echo_n "checking if native coverage is enabled... " >&6; } 52701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52702 $as_echo "yes" >&6; } 52703 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 52704 GCOV_LDFLAGS="-fprofile-arcs" 52705 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS" 52706 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS" 52707 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS" 52708 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 52709 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 52710 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 52711 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 52712 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 52713 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 52714 GCOV_ENABLED="true" 52715 else 52716 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 52717 fi 52718 elif test "x$enable_native_coverage" = "xno"; then 52719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52720 $as_echo_n "checking if native coverage is enabled... " >&6; } 52721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52722 $as_echo "no" >&6; } 52723 elif test "x$enable_native_coverage" != "x"; then 52724 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 52725 fi 52726 52727 52728 52729 52730 # Need toolchain to setup dtrace 52731 52732 # Test for dtrace dependencies 52733 # Check whether --enable-dtrace was given. 52734 if test "${enable_dtrace+set}" = set; then : 52735 enableval=$enable_dtrace; 52736 fi 52737 52738 52739 DTRACE_DEP_MISSING=false 52740 52741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 52742 $as_echo_n "checking for dtrace tool... " >&6; } 52743 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 52744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 52745 $as_echo "$DTRACE" >&6; } 52746 else 52747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 52748 $as_echo "not found, cannot build dtrace" >&6; } 52749 DTRACE_DEP_MISSING=true 52750 fi 52751 52752 for ac_header in sys/sdt.h 52753 do : 52754 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 52755 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 52756 cat >>confdefs.h <<_ACEOF 52757 #define HAVE_SYS_SDT_H 1 52758 _ACEOF 52759 DTRACE_HEADERS_OK=yes 52760 else 52761 DTRACE_HEADERS_OK=no 52762 fi 52763 52764 done 52765 52766 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 52767 DTRACE_DEP_MISSING=true 52768 fi 52769 52770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 52771 $as_echo_n "checking if dtrace should be built... " >&6; } 52772 if test "x$enable_dtrace" = "xyes"; then 52773 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52775 $as_echo "no, missing dependencies" >&6; } 52776 52777 # Print a helpful message on how to acquire the necessary build dependency. 52778 # dtrace is the help tag: freetype, cups, alsa etc 52779 MISSING_DEPENDENCY=dtrace 52780 52781 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52782 cygwin_help $MISSING_DEPENDENCY 52783 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52784 msys_help $MISSING_DEPENDENCY 52785 else 52786 PKGHANDLER_COMMAND= 52787 52788 case $PKGHANDLER in 52789 apt-get) 52790 apt_help $MISSING_DEPENDENCY ;; 52791 yum) 52792 yum_help $MISSING_DEPENDENCY ;; 52793 port) 52794 port_help $MISSING_DEPENDENCY ;; 52795 pkgutil) 52796 pkgutil_help $MISSING_DEPENDENCY ;; 52797 pkgadd) 52798 pkgadd_help $MISSING_DEPENDENCY ;; 52799 esac 52800 52801 if test "x$PKGHANDLER_COMMAND" != x; then 52802 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 52803 fi 52804 fi 52805 52806 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 52807 else 52808 INCLUDE_DTRACE=true 52809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52810 $as_echo "yes, forced" >&6; } 52811 fi 52812 elif test "x$enable_dtrace" = "xno"; then 52813 INCLUDE_DTRACE=false 52814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52815 $as_echo "no, forced" >&6; } 52816 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 52817 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52818 INCLUDE_DTRACE=false 52819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52820 $as_echo "no, missing dependencies" >&6; } 52821 else 52822 INCLUDE_DTRACE=true 52823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 52824 $as_echo "yes, dependencies present" >&6; } 52825 fi 52826 else 52827 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 52828 fi 52829 52830 52831 52832 # The user can in some cases supply additional jvm features. For the custom 52833 # variant, this defines the entire variant. 52834 52835 # Check whether --with-jvm-features was given. 52836 if test "${with_jvm_features+set}" = set; then : 52837 withval=$with_jvm_features; 52838 fi 52839 52840 if test "x$with_jvm_features" != x; then 52841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 52842 $as_echo_n "checking additional JVM features... " >&6; } 52843 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 52844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 52845 $as_echo "$JVM_FEATURES" >&6; } 52846 fi 52847 52848 # Verify that dependencies are met for explicitly set features. 52849 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 52850 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 52851 fi 52852 52853 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 52854 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 52855 fi 52856 52857 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 52858 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 52859 fi 52860 52861 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52862 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 52863 fi 52864 52865 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52866 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 52867 fi 52868 52869 # Turn on additional features based on other parts of configure 52870 if test "x$INCLUDE_DTRACE" = "xtrue"; then 52871 JVM_FEATURES="$JVM_FEATURES dtrace" 52872 else 52873 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 52874 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 52875 fi 52876 fi 52877 52878 if test "x$STATIC_BUILD" = "xtrue"; then 52879 JVM_FEATURES="$JVM_FEATURES static-build" 52880 else 52881 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 52882 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 52883 fi 52884 fi 52885 52886 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52887 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 52888 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 52889 fi 52890 fi 52891 52892 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52893 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 52894 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 52895 fi 52896 fi 52897 52898 # Only enable jvmci on x86_64, sparcv9 and aarch64. 52899 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 52900 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 52901 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 52902 JVM_FEATURES_jvmci="jvmci" 52903 else 52904 JVM_FEATURES_jvmci="" 52905 fi 52906 52907 # All variants but minimal (and custom) get these features 52908 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti fprof vm-structs jni-check services management all-gcs nmt cds" 52909 52910 # Enable features depending on variant. 52911 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52912 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52913 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 52914 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES" 52915 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 52916 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 52917 JVM_FEATURES_custom="$JVM_FEATURES" 52918 52919 52920 52921 52922 52923 52924 52925 52926 52927 # Used for verification of Makefiles by check-jvm-feature 52928 52929 52930 # We don't support --with-jvm-interpreter anymore, use zero instead. 52931 52932 52933 # Check whether --with-jvm-interpreter was given. 52934 if test "${with_jvm_interpreter+set}" = set; then : 52935 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 52936 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 52937 fi 52938 52939 52940 52941 52942 # Check whether --enable-hotspot-gtest was given. 52943 if test "${enable_hotspot_gtest+set}" = set; then : 52944 enableval=$enable_hotspot_gtest; 52945 fi 52946 52947 52948 if test -e "$HOTSPOT_TOPDIR/test/native"; then 52949 GTEST_DIR_EXISTS="true" 52950 else 52951 GTEST_DIR_EXISTS="false" 52952 fi 52953 52954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 52955 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 52956 if test "x$enable_hotspot_gtest" = "xyes"; then 52957 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 52958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52959 $as_echo "yes, forced" >&6; } 52960 BUILD_GTEST="true" 52961 else 52962 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 52963 fi 52964 elif test "x$enable_hotspot_gtest" = "xno"; then 52965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52966 $as_echo "no, forced" >&6; } 52967 BUILD_GTEST="false" 52968 elif test "x$enable_hotspot_gtest" = "x"; then 52969 if test "x$GTEST_DIR_EXISTS" = "xtrue" && test "x$OPENJDK_TARGET_OS" != "xaix"; then 52970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52971 $as_echo "yes" >&6; } 52972 BUILD_GTEST="true" 52973 else 52974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52975 $as_echo "no" >&6; } 52976 BUILD_GTEST="false" 52977 fi 52978 else 52979 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 52980 fi 52981 52982 52983 52984 52985 ############################################################################### 52986 # 52987 # Check dependencies for external and internal libraries. 52988 # 52989 ############################################################################### 52990 52991 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 52992 52993 # When using cygwin or msys, we need a wrapper binary that renames 52994 # /cygdrive/c/ arguments into c:/ arguments and peeks into 52995 # @files and rewrites these too! This wrapper binary is 52996 # called fixpath. 52997 FIXPATH= 52998 if test "x$OPENJDK_BUILD_OS" = xwindows; then 52999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 53000 $as_echo_n "checking if fixpath can be created... " >&6; } 53001 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 53002 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 53003 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 53004 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 53005 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 53006 FIXPATH="$FIXPATH_BIN -c" 53007 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 53008 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 53009 # @ was chosen as separator to minimize risk of other tools messing around with it 53010 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 53011 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 53012 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 53013 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 53014 fi 53015 FIXPATH_SRC_W="$FIXPATH_SRC" 53016 FIXPATH_BIN_W="$FIXPATH_BIN" 53017 53018 unix_path="$FIXPATH_SRC_W" 53019 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53020 windows_path=`$CYGPATH -m "$unix_path"` 53021 FIXPATH_SRC_W="$windows_path" 53022 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53023 windows_path=`cmd //c echo $unix_path` 53024 FIXPATH_SRC_W="$windows_path" 53025 fi 53026 53027 53028 unix_path="$FIXPATH_BIN_W" 53029 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53030 windows_path=`$CYGPATH -m "$unix_path"` 53031 FIXPATH_BIN_W="$windows_path" 53032 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53033 windows_path=`cmd //c echo $unix_path` 53034 FIXPATH_BIN_W="$windows_path" 53035 fi 53036 53037 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 53038 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 53039 cd $FIXPATH_DIR 53040 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 53041 cd $CURDIR 53042 53043 if test ! -x $FIXPATH_BIN; then 53044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53045 $as_echo "no" >&6; } 53046 cat $FIXPATH_DIR/fixpath1.log 53047 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 53048 fi 53049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53050 $as_echo "yes" >&6; } 53051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 53052 $as_echo_n "checking if fixpath.exe works... " >&6; } 53053 cd $FIXPATH_DIR 53054 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 53055 > $FIXPATH_DIR/fixpath2.log 2>&1 53056 cd $CURDIR 53057 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 53058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53059 $as_echo "no" >&6; } 53060 cat $FIXPATH_DIR/fixpath2.log 53061 as_fn_error $? "fixpath did not work!" "$LINENO" 5 53062 fi 53063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53064 $as_echo "yes" >&6; } 53065 53066 FIXPATH_DETACH_FLAG="--detach" 53067 fi 53068 53069 53070 53071 53072 53073 53074 # Check if X11 is needed 53075 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 53076 # No X11 support on windows or macosx 53077 NEEDS_LIB_X11=false 53078 else 53079 if test "x$SUPPORT_HEADFUL" = xno; then 53080 # No X11 support if building headless-only 53081 NEEDS_LIB_X11=false 53082 else 53083 # All other instances need X11 53084 NEEDS_LIB_X11=true 53085 fi 53086 fi 53087 53088 # Check if cups is needed 53089 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53090 # Windows have a separate print system 53091 NEEDS_LIB_CUPS=false 53092 else 53093 NEEDS_LIB_CUPS=true 53094 fi 53095 53096 # A custom hook may have set this already 53097 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 53098 NEEDS_LIB_FREETYPE=true 53099 fi 53100 53101 # Check if alsa is needed 53102 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53103 NEEDS_LIB_ALSA=true 53104 else 53105 NEEDS_LIB_ALSA=false 53106 fi 53107 53108 # Check if ffi is needed 53109 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53110 NEEDS_LIB_FFI=true 53111 else 53112 NEEDS_LIB_FFI=false 53113 fi 53114 53115 53116 # statically link libstdc++ before C++ ABI is stablized on Linux unless 53117 # dynamic build is configured on command line. 53118 53119 # Check whether --with-stdc++lib was given. 53120 if test "${with_stdc__lib+set}" = set; then : 53121 withval=$with_stdc__lib; 53122 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 53123 && test "x$with_stdc__lib" != xdefault; then 53124 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 53125 fi 53126 53127 else 53128 with_stdc__lib=default 53129 53130 fi 53131 53132 53133 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53134 # Test if -lstdc++ works. 53135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5 53136 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; } 53137 ac_ext=cpp 53138 ac_cpp='$CXXCPP $CPPFLAGS' 53139 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53140 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53141 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53142 53143 OLD_CXXFLAGS="$CXXFLAGS" 53144 CXXFLAGS="$CXXFLAGS -lstdc++" 53145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53146 /* end confdefs.h. */ 53147 53148 int 53149 main () 53150 { 53151 return 0; 53152 ; 53153 return 0; 53154 } 53155 _ACEOF 53156 if ac_fn_cxx_try_link "$LINENO"; then : 53157 has_dynamic_libstdcxx=yes 53158 else 53159 has_dynamic_libstdcxx=no 53160 fi 53161 rm -f core conftest.err conftest.$ac_objext \ 53162 conftest$ac_exeext conftest.$ac_ext 53163 CXXFLAGS="$OLD_CXXFLAGS" 53164 ac_ext=cpp 53165 ac_cpp='$CXXCPP $CPPFLAGS' 53166 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53167 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53168 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53169 53170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5 53171 $as_echo "$has_dynamic_libstdcxx" >&6; } 53172 53173 # Test if stdc++ can be linked statically. 53174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 53175 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 53176 STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic" 53177 ac_ext=cpp 53178 ac_cpp='$CXXCPP $CPPFLAGS' 53179 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53180 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53181 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53182 53183 OLD_LIBS="$LIBS" 53184 OLD_CXX="$CXX" 53185 LIBS="$STATIC_STDCXX_FLAGS" 53186 CXX="$CC" 53187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53188 /* end confdefs.h. */ 53189 53190 int 53191 main () 53192 { 53193 return 0; 53194 ; 53195 return 0; 53196 } 53197 _ACEOF 53198 if ac_fn_cxx_try_link "$LINENO"; then : 53199 has_static_libstdcxx=yes 53200 else 53201 has_static_libstdcxx=no 53202 fi 53203 rm -f core conftest.err conftest.$ac_objext \ 53204 conftest$ac_exeext conftest.$ac_ext 53205 LIBS="$OLD_LIBS" 53206 CXX="$OLD_CXX" 53207 ac_ext=cpp 53208 ac_cpp='$CXXCPP $CPPFLAGS' 53209 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53210 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53211 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53212 53213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 53214 $as_echo "$has_static_libstdcxx" >&6; } 53215 53216 if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then 53217 as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5 53218 fi 53219 53220 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 53221 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 53222 fi 53223 53224 if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then 53225 as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5 53226 fi 53227 53228 # If dynamic was requested, it's available since it would fail above otherwise. 53229 # If dynamic wasn't requested, go with static unless it isn't available. 53230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 53231 $as_echo_n "checking how to link with libstdc++... " >&6; } 53232 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53233 LIBCXX="$LIBCXX -lstdc++" 53234 # To help comparisons with old build, put stdc++ first in JVM_LIBS 53235 JVM_LIBS="-lstdc++ $JVM_LIBS" 53236 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53237 # just use the same setting as for the TARGET toolchain. 53238 OPENJDK_BUILD_JVM_LIBS="-lstdc++ $OPENJDK_BUILD_JVM_LIBS" 53239 LDCXX="$CXX" 53240 STATIC_CXX_SETTING="STATIC_CXX=false" 53241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 53242 $as_echo "dynamic" >&6; } 53243 else 53244 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 53245 JVM_LDFLAGS="$JVM_LDFLAGS -static-libgcc" 53246 # To help comparisons with old build, put stdc++ first in JVM_LIBS 53247 JVM_LIBS="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic $JVM_LIBS" 53248 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53249 # just use the same setting as for the TARGET toolchain. 53250 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -static-libgcc" 53251 OPENJDK_BUILD_JVM_LIBS="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic $OPENJDK_BUILD_JVM_LIBS" 53252 LDCXX="$CC" 53253 STATIC_CXX_SETTING="STATIC_CXX=true" 53254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 53255 $as_echo "static" >&6; } 53256 fi 53257 fi 53258 53259 53260 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 53261 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 53262 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 53263 fi 53264 53265 # TODO better (platform agnostic) test 53266 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then 53267 LIBCXX="-lstdc++" 53268 fi 53269 53270 53271 # Setup Windows runtime dlls 53272 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 53273 53274 53275 # Check whether --with-msvcr-dll was given. 53276 if test "${with_msvcr_dll+set}" = set; then : 53277 withval=$with_msvcr_dll; 53278 fi 53279 53280 53281 if test "x$with_msvcr_dll" != x; then 53282 # If given explicitely by user, do not probe. If not present, fail directly. 53283 53284 DLL_NAME="$MSVCR_NAME" 53285 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 53286 METHOD="--with-msvcr-dll" 53287 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53288 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53289 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53290 53291 # Need to check if the found msvcr is correct architecture 53292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53293 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53294 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53295 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53296 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53297 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53298 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53299 CORRECT_MSVCR_ARCH="PE32 executable" 53300 else 53301 CORRECT_MSVCR_ARCH="PE32+ executable" 53302 fi 53303 else 53304 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53305 CORRECT_MSVCR_ARCH=386 53306 else 53307 CORRECT_MSVCR_ARCH=x86-64 53308 fi 53309 fi 53310 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53312 $as_echo "ok" >&6; } 53313 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53314 53315 # Only process if variable expands to non-empty 53316 53317 if test "x$MSVC_DLL" != x; then 53318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53319 53320 # Input might be given as Windows format, start by converting to 53321 # unix format. 53322 path="$MSVC_DLL" 53323 new_path=`$CYGPATH -u "$path"` 53324 53325 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53326 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53327 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53328 # "foo.exe" is OK but "foo" is an error. 53329 # 53330 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53331 # It is also a way to make sure we got the proper file name for the real test later on. 53332 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53333 if test "x$test_shortpath" = x; then 53334 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53335 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53336 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53337 fi 53338 53339 # Call helper function which possibly converts this using DOS-style short mode. 53340 # If so, the updated path is stored in $new_path. 53341 53342 input_path="$new_path" 53343 # Check if we need to convert this using DOS-style short mode. If the path 53344 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53345 # take no chances and rewrite it. 53346 # Note: m4 eats our [], so we need to use [ and ] instead. 53347 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53348 if test "x$has_forbidden_chars" != x; then 53349 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53350 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53351 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53352 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53353 # Going to short mode and back again did indeed matter. Since short mode is 53354 # case insensitive, let's make it lowercase to improve readability. 53355 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53356 # Now convert it back to Unix-style (cygpath) 53357 input_path=`$CYGPATH -u "$shortmode_path"` 53358 new_path="$input_path" 53359 fi 53360 fi 53361 53362 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53363 if test "x$test_cygdrive_prefix" = x; then 53364 # As a simple fix, exclude /usr/bin since it's not a real path. 53365 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53366 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53367 # a path prefixed by /cygdrive for fixpath to work. 53368 new_path="$CYGWIN_ROOT_PATH$input_path" 53369 fi 53370 fi 53371 53372 53373 if test "x$path" != "x$new_path"; then 53374 MSVC_DLL="$new_path" 53375 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53376 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53377 fi 53378 53379 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53380 53381 path="$MSVC_DLL" 53382 has_colon=`$ECHO $path | $GREP ^.:` 53383 new_path="$path" 53384 if test "x$has_colon" = x; then 53385 # Not in mixed or Windows style, start by that. 53386 new_path=`cmd //c echo $path` 53387 fi 53388 53389 53390 input_path="$new_path" 53391 # Check if we need to convert this using DOS-style short mode. If the path 53392 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53393 # take no chances and rewrite it. 53394 # Note: m4 eats our [], so we need to use [ and ] instead. 53395 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53396 if test "x$has_forbidden_chars" != x; then 53397 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53398 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53399 fi 53400 53401 53402 windows_path="$new_path" 53403 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53404 unix_path=`$CYGPATH -u "$windows_path"` 53405 new_path="$unix_path" 53406 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53407 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53408 new_path="$unix_path" 53409 fi 53410 53411 if test "x$path" != "x$new_path"; then 53412 MSVC_DLL="$new_path" 53413 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53414 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53415 fi 53416 53417 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53418 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53419 53420 else 53421 # We're on a unix platform. Hooray! :) 53422 path="$MSVC_DLL" 53423 has_space=`$ECHO "$path" | $GREP " "` 53424 if test "x$has_space" != x; then 53425 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53426 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53427 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53428 fi 53429 53430 # Use eval to expand a potential ~ 53431 eval path="$path" 53432 if test ! -f "$path" && test ! -d "$path"; then 53433 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53434 fi 53435 53436 if test -d "$path"; then 53437 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53438 else 53439 dir="`$DIRNAME "$path"`" 53440 base="`$BASENAME "$path"`" 53441 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53442 fi 53443 fi 53444 fi 53445 53446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53447 $as_echo_n "checking for $DLL_NAME... " >&6; } 53448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53449 $as_echo "$MSVC_DLL" >&6; } 53450 else 53451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53452 $as_echo "incorrect, ignoring" >&6; } 53453 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53454 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53455 fi 53456 fi 53457 53458 if test "x$MSVC_DLL" = x; then 53459 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 53460 fi 53461 MSVCR_DLL="$MSVC_DLL" 53462 elif test "x$DEVKIT_MSVCR_DLL" != x; then 53463 53464 DLL_NAME="$MSVCR_NAME" 53465 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 53466 METHOD="devkit" 53467 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53468 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53469 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53470 53471 # Need to check if the found msvcr is correct architecture 53472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53473 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53474 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53475 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53476 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53477 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53478 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53479 CORRECT_MSVCR_ARCH="PE32 executable" 53480 else 53481 CORRECT_MSVCR_ARCH="PE32+ executable" 53482 fi 53483 else 53484 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53485 CORRECT_MSVCR_ARCH=386 53486 else 53487 CORRECT_MSVCR_ARCH=x86-64 53488 fi 53489 fi 53490 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53492 $as_echo "ok" >&6; } 53493 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53494 53495 # Only process if variable expands to non-empty 53496 53497 if test "x$MSVC_DLL" != x; then 53498 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53499 53500 # Input might be given as Windows format, start by converting to 53501 # unix format. 53502 path="$MSVC_DLL" 53503 new_path=`$CYGPATH -u "$path"` 53504 53505 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53506 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53507 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53508 # "foo.exe" is OK but "foo" is an error. 53509 # 53510 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53511 # It is also a way to make sure we got the proper file name for the real test later on. 53512 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53513 if test "x$test_shortpath" = x; then 53514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53515 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53516 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53517 fi 53518 53519 # Call helper function which possibly converts this using DOS-style short mode. 53520 # If so, the updated path is stored in $new_path. 53521 53522 input_path="$new_path" 53523 # Check if we need to convert this using DOS-style short mode. If the path 53524 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53525 # take no chances and rewrite it. 53526 # Note: m4 eats our [], so we need to use [ and ] instead. 53527 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53528 if test "x$has_forbidden_chars" != x; then 53529 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53530 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53531 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53532 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53533 # Going to short mode and back again did indeed matter. Since short mode is 53534 # case insensitive, let's make it lowercase to improve readability. 53535 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53536 # Now convert it back to Unix-style (cygpath) 53537 input_path=`$CYGPATH -u "$shortmode_path"` 53538 new_path="$input_path" 53539 fi 53540 fi 53541 53542 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53543 if test "x$test_cygdrive_prefix" = x; then 53544 # As a simple fix, exclude /usr/bin since it's not a real path. 53545 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53546 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53547 # a path prefixed by /cygdrive for fixpath to work. 53548 new_path="$CYGWIN_ROOT_PATH$input_path" 53549 fi 53550 fi 53551 53552 53553 if test "x$path" != "x$new_path"; then 53554 MSVC_DLL="$new_path" 53555 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53556 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53557 fi 53558 53559 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53560 53561 path="$MSVC_DLL" 53562 has_colon=`$ECHO $path | $GREP ^.:` 53563 new_path="$path" 53564 if test "x$has_colon" = x; then 53565 # Not in mixed or Windows style, start by that. 53566 new_path=`cmd //c echo $path` 53567 fi 53568 53569 53570 input_path="$new_path" 53571 # Check if we need to convert this using DOS-style short mode. If the path 53572 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53573 # take no chances and rewrite it. 53574 # Note: m4 eats our [], so we need to use [ and ] instead. 53575 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53576 if test "x$has_forbidden_chars" != x; then 53577 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53578 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53579 fi 53580 53581 53582 windows_path="$new_path" 53583 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53584 unix_path=`$CYGPATH -u "$windows_path"` 53585 new_path="$unix_path" 53586 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53587 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53588 new_path="$unix_path" 53589 fi 53590 53591 if test "x$path" != "x$new_path"; then 53592 MSVC_DLL="$new_path" 53593 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53594 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53595 fi 53596 53597 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53598 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53599 53600 else 53601 # We're on a unix platform. Hooray! :) 53602 path="$MSVC_DLL" 53603 has_space=`$ECHO "$path" | $GREP " "` 53604 if test "x$has_space" != x; then 53605 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53606 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53607 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53608 fi 53609 53610 # Use eval to expand a potential ~ 53611 eval path="$path" 53612 if test ! -f "$path" && test ! -d "$path"; then 53613 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53614 fi 53615 53616 if test -d "$path"; then 53617 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53618 else 53619 dir="`$DIRNAME "$path"`" 53620 base="`$BASENAME "$path"`" 53621 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53622 fi 53623 fi 53624 fi 53625 53626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53627 $as_echo_n "checking for $DLL_NAME... " >&6; } 53628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53629 $as_echo "$MSVC_DLL" >&6; } 53630 else 53631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53632 $as_echo "incorrect, ignoring" >&6; } 53633 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53634 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53635 fi 53636 fi 53637 53638 if test "x$MSVC_DLL" = x; then 53639 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 53640 fi 53641 MSVCR_DLL="$MSVC_DLL" 53642 else 53643 53644 DLL_NAME="${MSVCR_NAME}" 53645 MSVC_DLL= 53646 53647 if test "x$MSVC_DLL" = x; then 53648 # Probe: Using well-known location from Visual Studio 10.0 53649 if test "x$VCINSTALLDIR" != x; then 53650 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 53651 53652 windows_path="$CYGWIN_VC_INSTALL_DIR" 53653 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53654 unix_path=`$CYGPATH -u "$windows_path"` 53655 CYGWIN_VC_INSTALL_DIR="$unix_path" 53656 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53657 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53658 CYGWIN_VC_INSTALL_DIR="$unix_path" 53659 fi 53660 53661 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 53662 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53663 else 53664 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53665 fi 53666 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 53667 53668 DLL_NAME="$DLL_NAME" 53669 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53670 METHOD="well-known location in VCINSTALLDIR" 53671 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53672 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53673 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53674 53675 # Need to check if the found msvcr is correct architecture 53676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53677 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53678 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53680 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53681 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53682 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53683 CORRECT_MSVCR_ARCH="PE32 executable" 53684 else 53685 CORRECT_MSVCR_ARCH="PE32+ executable" 53686 fi 53687 else 53688 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53689 CORRECT_MSVCR_ARCH=386 53690 else 53691 CORRECT_MSVCR_ARCH=x86-64 53692 fi 53693 fi 53694 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53696 $as_echo "ok" >&6; } 53697 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53698 53699 # Only process if variable expands to non-empty 53700 53701 if test "x$MSVC_DLL" != x; then 53702 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53703 53704 # Input might be given as Windows format, start by converting to 53705 # unix format. 53706 path="$MSVC_DLL" 53707 new_path=`$CYGPATH -u "$path"` 53708 53709 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53710 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53711 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53712 # "foo.exe" is OK but "foo" is an error. 53713 # 53714 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53715 # It is also a way to make sure we got the proper file name for the real test later on. 53716 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53717 if test "x$test_shortpath" = x; then 53718 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53719 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53720 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53721 fi 53722 53723 # Call helper function which possibly converts this using DOS-style short mode. 53724 # If so, the updated path is stored in $new_path. 53725 53726 input_path="$new_path" 53727 # Check if we need to convert this using DOS-style short mode. If the path 53728 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53729 # take no chances and rewrite it. 53730 # Note: m4 eats our [], so we need to use [ and ] instead. 53731 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53732 if test "x$has_forbidden_chars" != x; then 53733 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53734 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53735 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53736 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53737 # Going to short mode and back again did indeed matter. Since short mode is 53738 # case insensitive, let's make it lowercase to improve readability. 53739 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53740 # Now convert it back to Unix-style (cygpath) 53741 input_path=`$CYGPATH -u "$shortmode_path"` 53742 new_path="$input_path" 53743 fi 53744 fi 53745 53746 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53747 if test "x$test_cygdrive_prefix" = x; then 53748 # As a simple fix, exclude /usr/bin since it's not a real path. 53749 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53750 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53751 # a path prefixed by /cygdrive for fixpath to work. 53752 new_path="$CYGWIN_ROOT_PATH$input_path" 53753 fi 53754 fi 53755 53756 53757 if test "x$path" != "x$new_path"; then 53758 MSVC_DLL="$new_path" 53759 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53760 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53761 fi 53762 53763 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53764 53765 path="$MSVC_DLL" 53766 has_colon=`$ECHO $path | $GREP ^.:` 53767 new_path="$path" 53768 if test "x$has_colon" = x; then 53769 # Not in mixed or Windows style, start by that. 53770 new_path=`cmd //c echo $path` 53771 fi 53772 53773 53774 input_path="$new_path" 53775 # Check if we need to convert this using DOS-style short mode. If the path 53776 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53777 # take no chances and rewrite it. 53778 # Note: m4 eats our [], so we need to use [ and ] instead. 53779 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53780 if test "x$has_forbidden_chars" != x; then 53781 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53782 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53783 fi 53784 53785 53786 windows_path="$new_path" 53787 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53788 unix_path=`$CYGPATH -u "$windows_path"` 53789 new_path="$unix_path" 53790 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53791 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53792 new_path="$unix_path" 53793 fi 53794 53795 if test "x$path" != "x$new_path"; then 53796 MSVC_DLL="$new_path" 53797 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53798 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53799 fi 53800 53801 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53802 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53803 53804 else 53805 # We're on a unix platform. Hooray! :) 53806 path="$MSVC_DLL" 53807 has_space=`$ECHO "$path" | $GREP " "` 53808 if test "x$has_space" != x; then 53809 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53810 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53811 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53812 fi 53813 53814 # Use eval to expand a potential ~ 53815 eval path="$path" 53816 if test ! -f "$path" && test ! -d "$path"; then 53817 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53818 fi 53819 53820 if test -d "$path"; then 53821 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53822 else 53823 dir="`$DIRNAME "$path"`" 53824 base="`$BASENAME "$path"`" 53825 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53826 fi 53827 fi 53828 fi 53829 53830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53831 $as_echo_n "checking for $DLL_NAME... " >&6; } 53832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53833 $as_echo "$MSVC_DLL" >&6; } 53834 else 53835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53836 $as_echo "incorrect, ignoring" >&6; } 53837 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53838 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53839 fi 53840 fi 53841 53842 fi 53843 fi 53844 53845 if test "x$MSVC_DLL" = x; then 53846 # Probe: Check in the Boot JDK directory. 53847 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 53848 53849 DLL_NAME="$DLL_NAME" 53850 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53851 METHOD="well-known location in Boot JDK" 53852 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53853 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53854 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53855 53856 # Need to check if the found msvcr is correct architecture 53857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53858 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53859 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53860 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53861 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53862 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53863 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53864 CORRECT_MSVCR_ARCH="PE32 executable" 53865 else 53866 CORRECT_MSVCR_ARCH="PE32+ executable" 53867 fi 53868 else 53869 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53870 CORRECT_MSVCR_ARCH=386 53871 else 53872 CORRECT_MSVCR_ARCH=x86-64 53873 fi 53874 fi 53875 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53877 $as_echo "ok" >&6; } 53878 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53879 53880 # Only process if variable expands to non-empty 53881 53882 if test "x$MSVC_DLL" != x; then 53883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53884 53885 # Input might be given as Windows format, start by converting to 53886 # unix format. 53887 path="$MSVC_DLL" 53888 new_path=`$CYGPATH -u "$path"` 53889 53890 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53891 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53892 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53893 # "foo.exe" is OK but "foo" is an error. 53894 # 53895 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53896 # It is also a way to make sure we got the proper file name for the real test later on. 53897 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53898 if test "x$test_shortpath" = x; then 53899 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53900 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53901 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53902 fi 53903 53904 # Call helper function which possibly converts this using DOS-style short mode. 53905 # If so, the updated path is stored in $new_path. 53906 53907 input_path="$new_path" 53908 # Check if we need to convert this using DOS-style short mode. If the path 53909 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53910 # take no chances and rewrite it. 53911 # Note: m4 eats our [], so we need to use [ and ] instead. 53912 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53913 if test "x$has_forbidden_chars" != x; then 53914 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53915 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53916 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53917 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53918 # Going to short mode and back again did indeed matter. Since short mode is 53919 # case insensitive, let's make it lowercase to improve readability. 53920 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53921 # Now convert it back to Unix-style (cygpath) 53922 input_path=`$CYGPATH -u "$shortmode_path"` 53923 new_path="$input_path" 53924 fi 53925 fi 53926 53927 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53928 if test "x$test_cygdrive_prefix" = x; then 53929 # As a simple fix, exclude /usr/bin since it's not a real path. 53930 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53931 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53932 # a path prefixed by /cygdrive for fixpath to work. 53933 new_path="$CYGWIN_ROOT_PATH$input_path" 53934 fi 53935 fi 53936 53937 53938 if test "x$path" != "x$new_path"; then 53939 MSVC_DLL="$new_path" 53940 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53941 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53942 fi 53943 53944 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53945 53946 path="$MSVC_DLL" 53947 has_colon=`$ECHO $path | $GREP ^.:` 53948 new_path="$path" 53949 if test "x$has_colon" = x; then 53950 # Not in mixed or Windows style, start by that. 53951 new_path=`cmd //c echo $path` 53952 fi 53953 53954 53955 input_path="$new_path" 53956 # Check if we need to convert this using DOS-style short mode. If the path 53957 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53958 # take no chances and rewrite it. 53959 # Note: m4 eats our [], so we need to use [ and ] instead. 53960 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53961 if test "x$has_forbidden_chars" != x; then 53962 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53963 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53964 fi 53965 53966 53967 windows_path="$new_path" 53968 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53969 unix_path=`$CYGPATH -u "$windows_path"` 53970 new_path="$unix_path" 53971 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53972 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53973 new_path="$unix_path" 53974 fi 53975 53976 if test "x$path" != "x$new_path"; then 53977 MSVC_DLL="$new_path" 53978 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53979 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53980 fi 53981 53982 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53983 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53984 53985 else 53986 # We're on a unix platform. Hooray! :) 53987 path="$MSVC_DLL" 53988 has_space=`$ECHO "$path" | $GREP " "` 53989 if test "x$has_space" != x; then 53990 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53991 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53992 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53993 fi 53994 53995 # Use eval to expand a potential ~ 53996 eval path="$path" 53997 if test ! -f "$path" && test ! -d "$path"; then 53998 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53999 fi 54000 54001 if test -d "$path"; then 54002 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54003 else 54004 dir="`$DIRNAME "$path"`" 54005 base="`$BASENAME "$path"`" 54006 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54007 fi 54008 fi 54009 fi 54010 54011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54012 $as_echo_n "checking for $DLL_NAME... " >&6; } 54013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54014 $as_echo "$MSVC_DLL" >&6; } 54015 else 54016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54017 $as_echo "incorrect, ignoring" >&6; } 54018 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54019 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54020 fi 54021 fi 54022 54023 fi 54024 54025 if test "x$MSVC_DLL" = x; then 54026 # Probe: Look in the Windows system32 directory 54027 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 54028 54029 windows_path="$CYGWIN_SYSTEMROOT" 54030 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54031 unix_path=`$CYGPATH -u "$windows_path"` 54032 CYGWIN_SYSTEMROOT="$unix_path" 54033 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54034 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54035 CYGWIN_SYSTEMROOT="$unix_path" 54036 fi 54037 54038 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 54039 54040 DLL_NAME="$DLL_NAME" 54041 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54042 METHOD="well-known location in SYSTEMROOT" 54043 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54044 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54045 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54046 54047 # Need to check if the found msvcr is correct architecture 54048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54049 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54050 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54051 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54052 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54053 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54054 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54055 CORRECT_MSVCR_ARCH="PE32 executable" 54056 else 54057 CORRECT_MSVCR_ARCH="PE32+ executable" 54058 fi 54059 else 54060 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54061 CORRECT_MSVCR_ARCH=386 54062 else 54063 CORRECT_MSVCR_ARCH=x86-64 54064 fi 54065 fi 54066 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54068 $as_echo "ok" >&6; } 54069 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54070 54071 # Only process if variable expands to non-empty 54072 54073 if test "x$MSVC_DLL" != x; then 54074 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54075 54076 # Input might be given as Windows format, start by converting to 54077 # unix format. 54078 path="$MSVC_DLL" 54079 new_path=`$CYGPATH -u "$path"` 54080 54081 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54082 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54083 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54084 # "foo.exe" is OK but "foo" is an error. 54085 # 54086 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54087 # It is also a way to make sure we got the proper file name for the real test later on. 54088 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54089 if test "x$test_shortpath" = x; then 54090 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54091 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54092 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54093 fi 54094 54095 # Call helper function which possibly converts this using DOS-style short mode. 54096 # If so, the updated path is stored in $new_path. 54097 54098 input_path="$new_path" 54099 # Check if we need to convert this using DOS-style short mode. If the path 54100 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54101 # take no chances and rewrite it. 54102 # Note: m4 eats our [], so we need to use [ and ] instead. 54103 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54104 if test "x$has_forbidden_chars" != x; then 54105 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54106 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54107 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54108 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54109 # Going to short mode and back again did indeed matter. Since short mode is 54110 # case insensitive, let's make it lowercase to improve readability. 54111 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54112 # Now convert it back to Unix-style (cygpath) 54113 input_path=`$CYGPATH -u "$shortmode_path"` 54114 new_path="$input_path" 54115 fi 54116 fi 54117 54118 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54119 if test "x$test_cygdrive_prefix" = x; then 54120 # As a simple fix, exclude /usr/bin since it's not a real path. 54121 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54122 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54123 # a path prefixed by /cygdrive for fixpath to work. 54124 new_path="$CYGWIN_ROOT_PATH$input_path" 54125 fi 54126 fi 54127 54128 54129 if test "x$path" != "x$new_path"; then 54130 MSVC_DLL="$new_path" 54131 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54132 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54133 fi 54134 54135 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54136 54137 path="$MSVC_DLL" 54138 has_colon=`$ECHO $path | $GREP ^.:` 54139 new_path="$path" 54140 if test "x$has_colon" = x; then 54141 # Not in mixed or Windows style, start by that. 54142 new_path=`cmd //c echo $path` 54143 fi 54144 54145 54146 input_path="$new_path" 54147 # Check if we need to convert this using DOS-style short mode. If the path 54148 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54149 # take no chances and rewrite it. 54150 # Note: m4 eats our [], so we need to use [ and ] instead. 54151 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54152 if test "x$has_forbidden_chars" != x; then 54153 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54154 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54155 fi 54156 54157 54158 windows_path="$new_path" 54159 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54160 unix_path=`$CYGPATH -u "$windows_path"` 54161 new_path="$unix_path" 54162 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54163 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54164 new_path="$unix_path" 54165 fi 54166 54167 if test "x$path" != "x$new_path"; then 54168 MSVC_DLL="$new_path" 54169 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54170 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54171 fi 54172 54173 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54174 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54175 54176 else 54177 # We're on a unix platform. Hooray! :) 54178 path="$MSVC_DLL" 54179 has_space=`$ECHO "$path" | $GREP " "` 54180 if test "x$has_space" != x; then 54181 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54182 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54183 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54184 fi 54185 54186 # Use eval to expand a potential ~ 54187 eval path="$path" 54188 if test ! -f "$path" && test ! -d "$path"; then 54189 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54190 fi 54191 54192 if test -d "$path"; then 54193 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54194 else 54195 dir="`$DIRNAME "$path"`" 54196 base="`$BASENAME "$path"`" 54197 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54198 fi 54199 fi 54200 fi 54201 54202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54203 $as_echo_n "checking for $DLL_NAME... " >&6; } 54204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54205 $as_echo "$MSVC_DLL" >&6; } 54206 else 54207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54208 $as_echo "incorrect, ignoring" >&6; } 54209 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54210 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54211 fi 54212 fi 54213 54214 fi 54215 54216 if test "x$MSVC_DLL" = x; then 54217 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 54218 if test "x$VS100COMNTOOLS" != x; then 54219 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 54220 54221 windows_path="$CYGWIN_VS_TOOLS_DIR" 54222 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54223 unix_path=`$CYGPATH -u "$windows_path"` 54224 CYGWIN_VS_TOOLS_DIR="$unix_path" 54225 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54226 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54227 CYGWIN_VS_TOOLS_DIR="$unix_path" 54228 fi 54229 54230 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54231 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54232 | $GREP -i /x64/ | $HEAD --lines 1` 54233 else 54234 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54235 | $GREP -i /x86/ | $HEAD --lines 1` 54236 fi 54237 54238 DLL_NAME="$DLL_NAME" 54239 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54240 METHOD="search of VS100COMNTOOLS" 54241 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54242 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54243 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54244 54245 # Need to check if the found msvcr is correct architecture 54246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54247 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54248 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54249 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54250 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54251 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54252 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54253 CORRECT_MSVCR_ARCH="PE32 executable" 54254 else 54255 CORRECT_MSVCR_ARCH="PE32+ executable" 54256 fi 54257 else 54258 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54259 CORRECT_MSVCR_ARCH=386 54260 else 54261 CORRECT_MSVCR_ARCH=x86-64 54262 fi 54263 fi 54264 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54266 $as_echo "ok" >&6; } 54267 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54268 54269 # Only process if variable expands to non-empty 54270 54271 if test "x$MSVC_DLL" != x; then 54272 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54273 54274 # Input might be given as Windows format, start by converting to 54275 # unix format. 54276 path="$MSVC_DLL" 54277 new_path=`$CYGPATH -u "$path"` 54278 54279 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54280 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54281 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54282 # "foo.exe" is OK but "foo" is an error. 54283 # 54284 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54285 # It is also a way to make sure we got the proper file name for the real test later on. 54286 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54287 if test "x$test_shortpath" = x; then 54288 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54289 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54290 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54291 fi 54292 54293 # Call helper function which possibly converts this using DOS-style short mode. 54294 # If so, the updated path is stored in $new_path. 54295 54296 input_path="$new_path" 54297 # Check if we need to convert this using DOS-style short mode. If the path 54298 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54299 # take no chances and rewrite it. 54300 # Note: m4 eats our [], so we need to use [ and ] instead. 54301 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54302 if test "x$has_forbidden_chars" != x; then 54303 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54304 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54305 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54306 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54307 # Going to short mode and back again did indeed matter. Since short mode is 54308 # case insensitive, let's make it lowercase to improve readability. 54309 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54310 # Now convert it back to Unix-style (cygpath) 54311 input_path=`$CYGPATH -u "$shortmode_path"` 54312 new_path="$input_path" 54313 fi 54314 fi 54315 54316 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54317 if test "x$test_cygdrive_prefix" = x; then 54318 # As a simple fix, exclude /usr/bin since it's not a real path. 54319 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54320 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54321 # a path prefixed by /cygdrive for fixpath to work. 54322 new_path="$CYGWIN_ROOT_PATH$input_path" 54323 fi 54324 fi 54325 54326 54327 if test "x$path" != "x$new_path"; then 54328 MSVC_DLL="$new_path" 54329 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54330 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54331 fi 54332 54333 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54334 54335 path="$MSVC_DLL" 54336 has_colon=`$ECHO $path | $GREP ^.:` 54337 new_path="$path" 54338 if test "x$has_colon" = x; then 54339 # Not in mixed or Windows style, start by that. 54340 new_path=`cmd //c echo $path` 54341 fi 54342 54343 54344 input_path="$new_path" 54345 # Check if we need to convert this using DOS-style short mode. If the path 54346 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54347 # take no chances and rewrite it. 54348 # Note: m4 eats our [], so we need to use [ and ] instead. 54349 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54350 if test "x$has_forbidden_chars" != x; then 54351 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54352 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54353 fi 54354 54355 54356 windows_path="$new_path" 54357 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54358 unix_path=`$CYGPATH -u "$windows_path"` 54359 new_path="$unix_path" 54360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54361 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54362 new_path="$unix_path" 54363 fi 54364 54365 if test "x$path" != "x$new_path"; then 54366 MSVC_DLL="$new_path" 54367 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54368 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54369 fi 54370 54371 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54372 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54373 54374 else 54375 # We're on a unix platform. Hooray! :) 54376 path="$MSVC_DLL" 54377 has_space=`$ECHO "$path" | $GREP " "` 54378 if test "x$has_space" != x; then 54379 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54380 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54381 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54382 fi 54383 54384 # Use eval to expand a potential ~ 54385 eval path="$path" 54386 if test ! -f "$path" && test ! -d "$path"; then 54387 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54388 fi 54389 54390 if test -d "$path"; then 54391 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54392 else 54393 dir="`$DIRNAME "$path"`" 54394 base="`$BASENAME "$path"`" 54395 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54396 fi 54397 fi 54398 fi 54399 54400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54401 $as_echo_n "checking for $DLL_NAME... " >&6; } 54402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54403 $as_echo "$MSVC_DLL" >&6; } 54404 else 54405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54406 $as_echo "incorrect, ignoring" >&6; } 54407 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54408 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54409 fi 54410 fi 54411 54412 fi 54413 fi 54414 54415 if test "x$MSVC_DLL" = x; then 54416 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 54417 # (This was the original behaviour; kept since it might turn something up) 54418 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 54419 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54420 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54421 | $GREP x64 | $HEAD --lines 1` 54422 else 54423 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54424 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 54425 if test "x$POSSIBLE_MSVC_DLL" = x; then 54426 # We're grasping at straws now... 54427 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54428 | $HEAD --lines 1` 54429 fi 54430 fi 54431 54432 54433 DLL_NAME="$DLL_NAME" 54434 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54435 METHOD="search of VCINSTALLDIR" 54436 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54437 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54438 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54439 54440 # Need to check if the found msvcr is correct architecture 54441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54442 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54443 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54445 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54446 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54447 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54448 CORRECT_MSVCR_ARCH="PE32 executable" 54449 else 54450 CORRECT_MSVCR_ARCH="PE32+ executable" 54451 fi 54452 else 54453 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54454 CORRECT_MSVCR_ARCH=386 54455 else 54456 CORRECT_MSVCR_ARCH=x86-64 54457 fi 54458 fi 54459 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54461 $as_echo "ok" >&6; } 54462 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54463 54464 # Only process if variable expands to non-empty 54465 54466 if test "x$MSVC_DLL" != x; then 54467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54468 54469 # Input might be given as Windows format, start by converting to 54470 # unix format. 54471 path="$MSVC_DLL" 54472 new_path=`$CYGPATH -u "$path"` 54473 54474 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54475 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54476 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54477 # "foo.exe" is OK but "foo" is an error. 54478 # 54479 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54480 # It is also a way to make sure we got the proper file name for the real test later on. 54481 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54482 if test "x$test_shortpath" = x; then 54483 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54484 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54485 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54486 fi 54487 54488 # Call helper function which possibly converts this using DOS-style short mode. 54489 # If so, the updated path is stored in $new_path. 54490 54491 input_path="$new_path" 54492 # Check if we need to convert this using DOS-style short mode. If the path 54493 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54494 # take no chances and rewrite it. 54495 # Note: m4 eats our [], so we need to use [ and ] instead. 54496 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54497 if test "x$has_forbidden_chars" != x; then 54498 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54499 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54500 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54501 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54502 # Going to short mode and back again did indeed matter. Since short mode is 54503 # case insensitive, let's make it lowercase to improve readability. 54504 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54505 # Now convert it back to Unix-style (cygpath) 54506 input_path=`$CYGPATH -u "$shortmode_path"` 54507 new_path="$input_path" 54508 fi 54509 fi 54510 54511 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54512 if test "x$test_cygdrive_prefix" = x; then 54513 # As a simple fix, exclude /usr/bin since it's not a real path. 54514 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54515 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54516 # a path prefixed by /cygdrive for fixpath to work. 54517 new_path="$CYGWIN_ROOT_PATH$input_path" 54518 fi 54519 fi 54520 54521 54522 if test "x$path" != "x$new_path"; then 54523 MSVC_DLL="$new_path" 54524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54525 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54526 fi 54527 54528 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54529 54530 path="$MSVC_DLL" 54531 has_colon=`$ECHO $path | $GREP ^.:` 54532 new_path="$path" 54533 if test "x$has_colon" = x; then 54534 # Not in mixed or Windows style, start by that. 54535 new_path=`cmd //c echo $path` 54536 fi 54537 54538 54539 input_path="$new_path" 54540 # Check if we need to convert this using DOS-style short mode. If the path 54541 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54542 # take no chances and rewrite it. 54543 # Note: m4 eats our [], so we need to use [ and ] instead. 54544 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54545 if test "x$has_forbidden_chars" != x; then 54546 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54547 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54548 fi 54549 54550 54551 windows_path="$new_path" 54552 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54553 unix_path=`$CYGPATH -u "$windows_path"` 54554 new_path="$unix_path" 54555 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54556 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54557 new_path="$unix_path" 54558 fi 54559 54560 if test "x$path" != "x$new_path"; then 54561 MSVC_DLL="$new_path" 54562 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54563 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54564 fi 54565 54566 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54567 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54568 54569 else 54570 # We're on a unix platform. Hooray! :) 54571 path="$MSVC_DLL" 54572 has_space=`$ECHO "$path" | $GREP " "` 54573 if test "x$has_space" != x; then 54574 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54575 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54576 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54577 fi 54578 54579 # Use eval to expand a potential ~ 54580 eval path="$path" 54581 if test ! -f "$path" && test ! -d "$path"; then 54582 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54583 fi 54584 54585 if test -d "$path"; then 54586 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54587 else 54588 dir="`$DIRNAME "$path"`" 54589 base="`$BASENAME "$path"`" 54590 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54591 fi 54592 fi 54593 fi 54594 54595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54596 $as_echo_n "checking for $DLL_NAME... " >&6; } 54597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54598 $as_echo "$MSVC_DLL" >&6; } 54599 else 54600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54601 $as_echo "incorrect, ignoring" >&6; } 54602 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54603 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54604 fi 54605 fi 54606 54607 fi 54608 fi 54609 54610 if test "x$MSVC_DLL" = x; then 54611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54612 $as_echo_n "checking for $DLL_NAME... " >&6; } 54613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54614 $as_echo "no" >&6; } 54615 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 54616 fi 54617 54618 MSVCR_DLL="$MSVC_DLL" 54619 fi 54620 54621 54622 54623 # Check whether --with-msvcp-dll was given. 54624 if test "${with_msvcp_dll+set}" = set; then : 54625 withval=$with_msvcp_dll; 54626 fi 54627 54628 54629 if test "x$MSVCP_NAME" != "x"; then 54630 if test "x$with_msvcp_dll" != x; then 54631 # If given explicitely by user, do not probe. If not present, fail directly. 54632 54633 DLL_NAME="$MSVCP_NAME" 54634 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 54635 METHOD="--with-msvcp-dll" 54636 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54637 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54638 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54639 54640 # Need to check if the found msvcr is correct architecture 54641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54642 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54643 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54644 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54645 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54646 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54647 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54648 CORRECT_MSVCR_ARCH="PE32 executable" 54649 else 54650 CORRECT_MSVCR_ARCH="PE32+ executable" 54651 fi 54652 else 54653 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54654 CORRECT_MSVCR_ARCH=386 54655 else 54656 CORRECT_MSVCR_ARCH=x86-64 54657 fi 54658 fi 54659 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54661 $as_echo "ok" >&6; } 54662 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54663 54664 # Only process if variable expands to non-empty 54665 54666 if test "x$MSVC_DLL" != x; then 54667 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54668 54669 # Input might be given as Windows format, start by converting to 54670 # unix format. 54671 path="$MSVC_DLL" 54672 new_path=`$CYGPATH -u "$path"` 54673 54674 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54675 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54676 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54677 # "foo.exe" is OK but "foo" is an error. 54678 # 54679 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54680 # It is also a way to make sure we got the proper file name for the real test later on. 54681 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54682 if test "x$test_shortpath" = x; then 54683 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54684 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54685 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54686 fi 54687 54688 # Call helper function which possibly converts this using DOS-style short mode. 54689 # If so, the updated path is stored in $new_path. 54690 54691 input_path="$new_path" 54692 # Check if we need to convert this using DOS-style short mode. If the path 54693 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54694 # take no chances and rewrite it. 54695 # Note: m4 eats our [], so we need to use [ and ] instead. 54696 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54697 if test "x$has_forbidden_chars" != x; then 54698 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54699 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54700 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54701 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54702 # Going to short mode and back again did indeed matter. Since short mode is 54703 # case insensitive, let's make it lowercase to improve readability. 54704 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54705 # Now convert it back to Unix-style (cygpath) 54706 input_path=`$CYGPATH -u "$shortmode_path"` 54707 new_path="$input_path" 54708 fi 54709 fi 54710 54711 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54712 if test "x$test_cygdrive_prefix" = x; then 54713 # As a simple fix, exclude /usr/bin since it's not a real path. 54714 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54715 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54716 # a path prefixed by /cygdrive for fixpath to work. 54717 new_path="$CYGWIN_ROOT_PATH$input_path" 54718 fi 54719 fi 54720 54721 54722 if test "x$path" != "x$new_path"; then 54723 MSVC_DLL="$new_path" 54724 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54725 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54726 fi 54727 54728 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54729 54730 path="$MSVC_DLL" 54731 has_colon=`$ECHO $path | $GREP ^.:` 54732 new_path="$path" 54733 if test "x$has_colon" = x; then 54734 # Not in mixed or Windows style, start by that. 54735 new_path=`cmd //c echo $path` 54736 fi 54737 54738 54739 input_path="$new_path" 54740 # Check if we need to convert this using DOS-style short mode. If the path 54741 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54742 # take no chances and rewrite it. 54743 # Note: m4 eats our [], so we need to use [ and ] instead. 54744 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54745 if test "x$has_forbidden_chars" != x; then 54746 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54747 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54748 fi 54749 54750 54751 windows_path="$new_path" 54752 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54753 unix_path=`$CYGPATH -u "$windows_path"` 54754 new_path="$unix_path" 54755 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54756 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54757 new_path="$unix_path" 54758 fi 54759 54760 if test "x$path" != "x$new_path"; then 54761 MSVC_DLL="$new_path" 54762 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54763 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54764 fi 54765 54766 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54767 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54768 54769 else 54770 # We're on a unix platform. Hooray! :) 54771 path="$MSVC_DLL" 54772 has_space=`$ECHO "$path" | $GREP " "` 54773 if test "x$has_space" != x; then 54774 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54775 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54776 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54777 fi 54778 54779 # Use eval to expand a potential ~ 54780 eval path="$path" 54781 if test ! -f "$path" && test ! -d "$path"; then 54782 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54783 fi 54784 54785 if test -d "$path"; then 54786 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54787 else 54788 dir="`$DIRNAME "$path"`" 54789 base="`$BASENAME "$path"`" 54790 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54791 fi 54792 fi 54793 fi 54794 54795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54796 $as_echo_n "checking for $DLL_NAME... " >&6; } 54797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54798 $as_echo "$MSVC_DLL" >&6; } 54799 else 54800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54801 $as_echo "incorrect, ignoring" >&6; } 54802 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54803 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54804 fi 54805 fi 54806 54807 if test "x$MSVC_DLL" = x; then 54808 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 54809 fi 54810 MSVCP_DLL="$MSVC_DLL" 54811 elif test "x$DEVKIT_MSVCP_DLL" != x; then 54812 54813 DLL_NAME="$MSVCP_NAME" 54814 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 54815 METHOD="devkit" 54816 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54817 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54818 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54819 54820 # Need to check if the found msvcr is correct architecture 54821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54822 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54823 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54825 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54826 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54827 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54828 CORRECT_MSVCR_ARCH="PE32 executable" 54829 else 54830 CORRECT_MSVCR_ARCH="PE32+ executable" 54831 fi 54832 else 54833 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54834 CORRECT_MSVCR_ARCH=386 54835 else 54836 CORRECT_MSVCR_ARCH=x86-64 54837 fi 54838 fi 54839 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54841 $as_echo "ok" >&6; } 54842 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54843 54844 # Only process if variable expands to non-empty 54845 54846 if test "x$MSVC_DLL" != x; then 54847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54848 54849 # Input might be given as Windows format, start by converting to 54850 # unix format. 54851 path="$MSVC_DLL" 54852 new_path=`$CYGPATH -u "$path"` 54853 54854 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54855 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54856 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54857 # "foo.exe" is OK but "foo" is an error. 54858 # 54859 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54860 # It is also a way to make sure we got the proper file name for the real test later on. 54861 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54862 if test "x$test_shortpath" = x; then 54863 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54864 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54865 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54866 fi 54867 54868 # Call helper function which possibly converts this using DOS-style short mode. 54869 # If so, the updated path is stored in $new_path. 54870 54871 input_path="$new_path" 54872 # Check if we need to convert this using DOS-style short mode. If the path 54873 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54874 # take no chances and rewrite it. 54875 # Note: m4 eats our [], so we need to use [ and ] instead. 54876 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54877 if test "x$has_forbidden_chars" != x; then 54878 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54879 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54880 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54881 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54882 # Going to short mode and back again did indeed matter. Since short mode is 54883 # case insensitive, let's make it lowercase to improve readability. 54884 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54885 # Now convert it back to Unix-style (cygpath) 54886 input_path=`$CYGPATH -u "$shortmode_path"` 54887 new_path="$input_path" 54888 fi 54889 fi 54890 54891 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54892 if test "x$test_cygdrive_prefix" = x; then 54893 # As a simple fix, exclude /usr/bin since it's not a real path. 54894 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54895 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54896 # a path prefixed by /cygdrive for fixpath to work. 54897 new_path="$CYGWIN_ROOT_PATH$input_path" 54898 fi 54899 fi 54900 54901 54902 if test "x$path" != "x$new_path"; then 54903 MSVC_DLL="$new_path" 54904 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54905 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54906 fi 54907 54908 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54909 54910 path="$MSVC_DLL" 54911 has_colon=`$ECHO $path | $GREP ^.:` 54912 new_path="$path" 54913 if test "x$has_colon" = x; then 54914 # Not in mixed or Windows style, start by that. 54915 new_path=`cmd //c echo $path` 54916 fi 54917 54918 54919 input_path="$new_path" 54920 # Check if we need to convert this using DOS-style short mode. If the path 54921 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54922 # take no chances and rewrite it. 54923 # Note: m4 eats our [], so we need to use [ and ] instead. 54924 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54925 if test "x$has_forbidden_chars" != x; then 54926 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54927 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54928 fi 54929 54930 54931 windows_path="$new_path" 54932 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54933 unix_path=`$CYGPATH -u "$windows_path"` 54934 new_path="$unix_path" 54935 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54936 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54937 new_path="$unix_path" 54938 fi 54939 54940 if test "x$path" != "x$new_path"; then 54941 MSVC_DLL="$new_path" 54942 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54943 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54944 fi 54945 54946 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54947 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54948 54949 else 54950 # We're on a unix platform. Hooray! :) 54951 path="$MSVC_DLL" 54952 has_space=`$ECHO "$path" | $GREP " "` 54953 if test "x$has_space" != x; then 54954 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54955 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54956 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54957 fi 54958 54959 # Use eval to expand a potential ~ 54960 eval path="$path" 54961 if test ! -f "$path" && test ! -d "$path"; then 54962 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54963 fi 54964 54965 if test -d "$path"; then 54966 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54967 else 54968 dir="`$DIRNAME "$path"`" 54969 base="`$BASENAME "$path"`" 54970 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54971 fi 54972 fi 54973 fi 54974 54975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54976 $as_echo_n "checking for $DLL_NAME... " >&6; } 54977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54978 $as_echo "$MSVC_DLL" >&6; } 54979 else 54980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54981 $as_echo "incorrect, ignoring" >&6; } 54982 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54983 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54984 fi 54985 fi 54986 54987 if test "x$MSVC_DLL" = x; then 54988 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 54989 fi 54990 MSVCP_DLL="$MSVC_DLL" 54991 else 54992 54993 DLL_NAME="${MSVCP_NAME}" 54994 MSVC_DLL= 54995 54996 if test "x$MSVC_DLL" = x; then 54997 # Probe: Using well-known location from Visual Studio 10.0 54998 if test "x$VCINSTALLDIR" != x; then 54999 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 55000 55001 windows_path="$CYGWIN_VC_INSTALL_DIR" 55002 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55003 unix_path=`$CYGPATH -u "$windows_path"` 55004 CYGWIN_VC_INSTALL_DIR="$unix_path" 55005 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55006 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55007 CYGWIN_VC_INSTALL_DIR="$unix_path" 55008 fi 55009 55010 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55011 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 55012 else 55013 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 55014 fi 55015 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 55016 55017 DLL_NAME="$DLL_NAME" 55018 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55019 METHOD="well-known location in VCINSTALLDIR" 55020 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55021 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55022 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55023 55024 # Need to check if the found msvcr is correct architecture 55025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55026 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55027 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55028 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55029 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55030 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55031 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55032 CORRECT_MSVCR_ARCH="PE32 executable" 55033 else 55034 CORRECT_MSVCR_ARCH="PE32+ executable" 55035 fi 55036 else 55037 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55038 CORRECT_MSVCR_ARCH=386 55039 else 55040 CORRECT_MSVCR_ARCH=x86-64 55041 fi 55042 fi 55043 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55045 $as_echo "ok" >&6; } 55046 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55047 55048 # Only process if variable expands to non-empty 55049 55050 if test "x$MSVC_DLL" != x; then 55051 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55052 55053 # Input might be given as Windows format, start by converting to 55054 # unix format. 55055 path="$MSVC_DLL" 55056 new_path=`$CYGPATH -u "$path"` 55057 55058 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55059 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55060 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55061 # "foo.exe" is OK but "foo" is an error. 55062 # 55063 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55064 # It is also a way to make sure we got the proper file name for the real test later on. 55065 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55066 if test "x$test_shortpath" = 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 $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55070 fi 55071 55072 # Call helper function which possibly converts this using DOS-style short mode. 55073 # If so, the updated path is stored in $new_path. 55074 55075 input_path="$new_path" 55076 # Check if we need to convert this using DOS-style short mode. If the path 55077 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55078 # take no chances and rewrite it. 55079 # Note: m4 eats our [], so we need to use [ and ] instead. 55080 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55081 if test "x$has_forbidden_chars" != x; then 55082 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55083 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55084 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55085 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55086 # Going to short mode and back again did indeed matter. Since short mode is 55087 # case insensitive, let's make it lowercase to improve readability. 55088 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55089 # Now convert it back to Unix-style (cygpath) 55090 input_path=`$CYGPATH -u "$shortmode_path"` 55091 new_path="$input_path" 55092 fi 55093 fi 55094 55095 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55096 if test "x$test_cygdrive_prefix" = x; then 55097 # As a simple fix, exclude /usr/bin since it's not a real path. 55098 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55099 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55100 # a path prefixed by /cygdrive for fixpath to work. 55101 new_path="$CYGWIN_ROOT_PATH$input_path" 55102 fi 55103 fi 55104 55105 55106 if test "x$path" != "x$new_path"; then 55107 MSVC_DLL="$new_path" 55108 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55109 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55110 fi 55111 55112 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55113 55114 path="$MSVC_DLL" 55115 has_colon=`$ECHO $path | $GREP ^.:` 55116 new_path="$path" 55117 if test "x$has_colon" = x; then 55118 # Not in mixed or Windows style, start by that. 55119 new_path=`cmd //c echo $path` 55120 fi 55121 55122 55123 input_path="$new_path" 55124 # Check if we need to convert this using DOS-style short mode. If the path 55125 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55126 # take no chances and rewrite it. 55127 # Note: m4 eats our [], so we need to use [ and ] instead. 55128 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55129 if test "x$has_forbidden_chars" != x; then 55130 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55131 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55132 fi 55133 55134 55135 windows_path="$new_path" 55136 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55137 unix_path=`$CYGPATH -u "$windows_path"` 55138 new_path="$unix_path" 55139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55140 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55141 new_path="$unix_path" 55142 fi 55143 55144 if test "x$path" != "x$new_path"; then 55145 MSVC_DLL="$new_path" 55146 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55147 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55148 fi 55149 55150 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55151 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55152 55153 else 55154 # We're on a unix platform. Hooray! :) 55155 path="$MSVC_DLL" 55156 has_space=`$ECHO "$path" | $GREP " "` 55157 if test "x$has_space" != x; then 55158 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55159 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55160 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55161 fi 55162 55163 # Use eval to expand a potential ~ 55164 eval path="$path" 55165 if test ! -f "$path" && test ! -d "$path"; then 55166 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55167 fi 55168 55169 if test -d "$path"; then 55170 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55171 else 55172 dir="`$DIRNAME "$path"`" 55173 base="`$BASENAME "$path"`" 55174 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55175 fi 55176 fi 55177 fi 55178 55179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55180 $as_echo_n "checking for $DLL_NAME... " >&6; } 55181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55182 $as_echo "$MSVC_DLL" >&6; } 55183 else 55184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55185 $as_echo "incorrect, ignoring" >&6; } 55186 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55187 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55188 fi 55189 fi 55190 55191 fi 55192 fi 55193 55194 if test "x$MSVC_DLL" = x; then 55195 # Probe: Check in the Boot JDK directory. 55196 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 55197 55198 DLL_NAME="$DLL_NAME" 55199 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55200 METHOD="well-known location in Boot JDK" 55201 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55202 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55203 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55204 55205 # Need to check if the found msvcr is correct architecture 55206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55207 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55208 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55209 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55210 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55211 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55212 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55213 CORRECT_MSVCR_ARCH="PE32 executable" 55214 else 55215 CORRECT_MSVCR_ARCH="PE32+ executable" 55216 fi 55217 else 55218 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55219 CORRECT_MSVCR_ARCH=386 55220 else 55221 CORRECT_MSVCR_ARCH=x86-64 55222 fi 55223 fi 55224 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55226 $as_echo "ok" >&6; } 55227 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55228 55229 # Only process if variable expands to non-empty 55230 55231 if test "x$MSVC_DLL" != x; then 55232 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55233 55234 # Input might be given as Windows format, start by converting to 55235 # unix format. 55236 path="$MSVC_DLL" 55237 new_path=`$CYGPATH -u "$path"` 55238 55239 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55240 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55241 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55242 # "foo.exe" is OK but "foo" is an error. 55243 # 55244 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55245 # It is also a way to make sure we got the proper file name for the real test later on. 55246 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55247 if test "x$test_shortpath" = x; then 55248 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55249 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55250 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55251 fi 55252 55253 # Call helper function which possibly converts this using DOS-style short mode. 55254 # If so, the updated path is stored in $new_path. 55255 55256 input_path="$new_path" 55257 # Check if we need to convert this using DOS-style short mode. If the path 55258 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55259 # take no chances and rewrite it. 55260 # Note: m4 eats our [], so we need to use [ and ] instead. 55261 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55262 if test "x$has_forbidden_chars" != x; then 55263 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55264 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55265 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55266 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55267 # Going to short mode and back again did indeed matter. Since short mode is 55268 # case insensitive, let's make it lowercase to improve readability. 55269 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55270 # Now convert it back to Unix-style (cygpath) 55271 input_path=`$CYGPATH -u "$shortmode_path"` 55272 new_path="$input_path" 55273 fi 55274 fi 55275 55276 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55277 if test "x$test_cygdrive_prefix" = x; then 55278 # As a simple fix, exclude /usr/bin since it's not a real path. 55279 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55280 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55281 # a path prefixed by /cygdrive for fixpath to work. 55282 new_path="$CYGWIN_ROOT_PATH$input_path" 55283 fi 55284 fi 55285 55286 55287 if test "x$path" != "x$new_path"; then 55288 MSVC_DLL="$new_path" 55289 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55290 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55291 fi 55292 55293 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55294 55295 path="$MSVC_DLL" 55296 has_colon=`$ECHO $path | $GREP ^.:` 55297 new_path="$path" 55298 if test "x$has_colon" = x; then 55299 # Not in mixed or Windows style, start by that. 55300 new_path=`cmd //c echo $path` 55301 fi 55302 55303 55304 input_path="$new_path" 55305 # Check if we need to convert this using DOS-style short mode. If the path 55306 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55307 # take no chances and rewrite it. 55308 # Note: m4 eats our [], so we need to use [ and ] instead. 55309 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55310 if test "x$has_forbidden_chars" != x; then 55311 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55312 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55313 fi 55314 55315 55316 windows_path="$new_path" 55317 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55318 unix_path=`$CYGPATH -u "$windows_path"` 55319 new_path="$unix_path" 55320 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55321 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55322 new_path="$unix_path" 55323 fi 55324 55325 if test "x$path" != "x$new_path"; then 55326 MSVC_DLL="$new_path" 55327 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55328 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55329 fi 55330 55331 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55332 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55333 55334 else 55335 # We're on a unix platform. Hooray! :) 55336 path="$MSVC_DLL" 55337 has_space=`$ECHO "$path" | $GREP " "` 55338 if test "x$has_space" != x; then 55339 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55340 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55341 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55342 fi 55343 55344 # Use eval to expand a potential ~ 55345 eval path="$path" 55346 if test ! -f "$path" && test ! -d "$path"; then 55347 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55348 fi 55349 55350 if test -d "$path"; then 55351 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55352 else 55353 dir="`$DIRNAME "$path"`" 55354 base="`$BASENAME "$path"`" 55355 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55356 fi 55357 fi 55358 fi 55359 55360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55361 $as_echo_n "checking for $DLL_NAME... " >&6; } 55362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55363 $as_echo "$MSVC_DLL" >&6; } 55364 else 55365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55366 $as_echo "incorrect, ignoring" >&6; } 55367 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55368 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55369 fi 55370 fi 55371 55372 fi 55373 55374 if test "x$MSVC_DLL" = x; then 55375 # Probe: Look in the Windows system32 directory 55376 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55377 55378 windows_path="$CYGWIN_SYSTEMROOT" 55379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55380 unix_path=`$CYGPATH -u "$windows_path"` 55381 CYGWIN_SYSTEMROOT="$unix_path" 55382 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55383 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55384 CYGWIN_SYSTEMROOT="$unix_path" 55385 fi 55386 55387 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55388 55389 DLL_NAME="$DLL_NAME" 55390 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55391 METHOD="well-known location in SYSTEMROOT" 55392 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55393 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55394 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55395 55396 # Need to check if the found msvcr is correct architecture 55397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55398 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55399 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55401 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55402 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55403 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55404 CORRECT_MSVCR_ARCH="PE32 executable" 55405 else 55406 CORRECT_MSVCR_ARCH="PE32+ executable" 55407 fi 55408 else 55409 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55410 CORRECT_MSVCR_ARCH=386 55411 else 55412 CORRECT_MSVCR_ARCH=x86-64 55413 fi 55414 fi 55415 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55417 $as_echo "ok" >&6; } 55418 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55419 55420 # Only process if variable expands to non-empty 55421 55422 if test "x$MSVC_DLL" != x; then 55423 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55424 55425 # Input might be given as Windows format, start by converting to 55426 # unix format. 55427 path="$MSVC_DLL" 55428 new_path=`$CYGPATH -u "$path"` 55429 55430 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55431 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55432 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55433 # "foo.exe" is OK but "foo" is an error. 55434 # 55435 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55436 # It is also a way to make sure we got the proper file name for the real test later on. 55437 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55438 if test "x$test_shortpath" = x; then 55439 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55440 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55441 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55442 fi 55443 55444 # Call helper function which possibly converts this using DOS-style short mode. 55445 # If so, the updated path is stored in $new_path. 55446 55447 input_path="$new_path" 55448 # Check if we need to convert this using DOS-style short mode. If the path 55449 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55450 # take no chances and rewrite it. 55451 # Note: m4 eats our [], so we need to use [ and ] instead. 55452 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55453 if test "x$has_forbidden_chars" != x; then 55454 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55455 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55456 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55457 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55458 # Going to short mode and back again did indeed matter. Since short mode is 55459 # case insensitive, let's make it lowercase to improve readability. 55460 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55461 # Now convert it back to Unix-style (cygpath) 55462 input_path=`$CYGPATH -u "$shortmode_path"` 55463 new_path="$input_path" 55464 fi 55465 fi 55466 55467 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55468 if test "x$test_cygdrive_prefix" = x; then 55469 # As a simple fix, exclude /usr/bin since it's not a real path. 55470 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55471 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55472 # a path prefixed by /cygdrive for fixpath to work. 55473 new_path="$CYGWIN_ROOT_PATH$input_path" 55474 fi 55475 fi 55476 55477 55478 if test "x$path" != "x$new_path"; then 55479 MSVC_DLL="$new_path" 55480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55481 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55482 fi 55483 55484 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55485 55486 path="$MSVC_DLL" 55487 has_colon=`$ECHO $path | $GREP ^.:` 55488 new_path="$path" 55489 if test "x$has_colon" = x; then 55490 # Not in mixed or Windows style, start by that. 55491 new_path=`cmd //c echo $path` 55492 fi 55493 55494 55495 input_path="$new_path" 55496 # Check if we need to convert this using DOS-style short mode. If the path 55497 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55498 # take no chances and rewrite it. 55499 # Note: m4 eats our [], so we need to use [ and ] instead. 55500 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55501 if test "x$has_forbidden_chars" != x; then 55502 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55503 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55504 fi 55505 55506 55507 windows_path="$new_path" 55508 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55509 unix_path=`$CYGPATH -u "$windows_path"` 55510 new_path="$unix_path" 55511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55512 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55513 new_path="$unix_path" 55514 fi 55515 55516 if test "x$path" != "x$new_path"; then 55517 MSVC_DLL="$new_path" 55518 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55519 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55520 fi 55521 55522 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55523 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55524 55525 else 55526 # We're on a unix platform. Hooray! :) 55527 path="$MSVC_DLL" 55528 has_space=`$ECHO "$path" | $GREP " "` 55529 if test "x$has_space" != x; then 55530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55531 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55532 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55533 fi 55534 55535 # Use eval to expand a potential ~ 55536 eval path="$path" 55537 if test ! -f "$path" && test ! -d "$path"; then 55538 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55539 fi 55540 55541 if test -d "$path"; then 55542 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55543 else 55544 dir="`$DIRNAME "$path"`" 55545 base="`$BASENAME "$path"`" 55546 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55547 fi 55548 fi 55549 fi 55550 55551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55552 $as_echo_n "checking for $DLL_NAME... " >&6; } 55553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55554 $as_echo "$MSVC_DLL" >&6; } 55555 else 55556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55557 $as_echo "incorrect, ignoring" >&6; } 55558 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55559 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55560 fi 55561 fi 55562 55563 fi 55564 55565 if test "x$MSVC_DLL" = x; then 55566 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55567 if test "x$VS100COMNTOOLS" != x; then 55568 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55569 55570 windows_path="$CYGWIN_VS_TOOLS_DIR" 55571 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55572 unix_path=`$CYGPATH -u "$windows_path"` 55573 CYGWIN_VS_TOOLS_DIR="$unix_path" 55574 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55575 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55576 CYGWIN_VS_TOOLS_DIR="$unix_path" 55577 fi 55578 55579 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55580 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55581 | $GREP -i /x64/ | $HEAD --lines 1` 55582 else 55583 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55584 | $GREP -i /x86/ | $HEAD --lines 1` 55585 fi 55586 55587 DLL_NAME="$DLL_NAME" 55588 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55589 METHOD="search of VS100COMNTOOLS" 55590 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55591 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55592 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55593 55594 # Need to check if the found msvcr is correct architecture 55595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55596 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55597 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55598 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55599 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55600 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55601 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55602 CORRECT_MSVCR_ARCH="PE32 executable" 55603 else 55604 CORRECT_MSVCR_ARCH="PE32+ executable" 55605 fi 55606 else 55607 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55608 CORRECT_MSVCR_ARCH=386 55609 else 55610 CORRECT_MSVCR_ARCH=x86-64 55611 fi 55612 fi 55613 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55615 $as_echo "ok" >&6; } 55616 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55617 55618 # Only process if variable expands to non-empty 55619 55620 if test "x$MSVC_DLL" != x; then 55621 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55622 55623 # Input might be given as Windows format, start by converting to 55624 # unix format. 55625 path="$MSVC_DLL" 55626 new_path=`$CYGPATH -u "$path"` 55627 55628 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55629 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55630 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55631 # "foo.exe" is OK but "foo" is an error. 55632 # 55633 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55634 # It is also a way to make sure we got the proper file name for the real test later on. 55635 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55636 if test "x$test_shortpath" = x; then 55637 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55638 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55639 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55640 fi 55641 55642 # Call helper function which possibly converts this using DOS-style short mode. 55643 # If so, the updated path is stored in $new_path. 55644 55645 input_path="$new_path" 55646 # Check if we need to convert this using DOS-style short mode. If the path 55647 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55648 # take no chances and rewrite it. 55649 # Note: m4 eats our [], so we need to use [ and ] instead. 55650 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55651 if test "x$has_forbidden_chars" != x; then 55652 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55653 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55654 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55655 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55656 # Going to short mode and back again did indeed matter. Since short mode is 55657 # case insensitive, let's make it lowercase to improve readability. 55658 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55659 # Now convert it back to Unix-style (cygpath) 55660 input_path=`$CYGPATH -u "$shortmode_path"` 55661 new_path="$input_path" 55662 fi 55663 fi 55664 55665 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55666 if test "x$test_cygdrive_prefix" = x; then 55667 # As a simple fix, exclude /usr/bin since it's not a real path. 55668 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55669 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55670 # a path prefixed by /cygdrive for fixpath to work. 55671 new_path="$CYGWIN_ROOT_PATH$input_path" 55672 fi 55673 fi 55674 55675 55676 if test "x$path" != "x$new_path"; then 55677 MSVC_DLL="$new_path" 55678 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55679 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55680 fi 55681 55682 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55683 55684 path="$MSVC_DLL" 55685 has_colon=`$ECHO $path | $GREP ^.:` 55686 new_path="$path" 55687 if test "x$has_colon" = x; then 55688 # Not in mixed or Windows style, start by that. 55689 new_path=`cmd //c echo $path` 55690 fi 55691 55692 55693 input_path="$new_path" 55694 # Check if we need to convert this using DOS-style short mode. If the path 55695 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55696 # take no chances and rewrite it. 55697 # Note: m4 eats our [], so we need to use [ and ] instead. 55698 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55699 if test "x$has_forbidden_chars" != x; then 55700 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55701 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55702 fi 55703 55704 55705 windows_path="$new_path" 55706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55707 unix_path=`$CYGPATH -u "$windows_path"` 55708 new_path="$unix_path" 55709 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55710 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55711 new_path="$unix_path" 55712 fi 55713 55714 if test "x$path" != "x$new_path"; then 55715 MSVC_DLL="$new_path" 55716 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55717 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55718 fi 55719 55720 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55721 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55722 55723 else 55724 # We're on a unix platform. Hooray! :) 55725 path="$MSVC_DLL" 55726 has_space=`$ECHO "$path" | $GREP " "` 55727 if test "x$has_space" != x; then 55728 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55729 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55730 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55731 fi 55732 55733 # Use eval to expand a potential ~ 55734 eval path="$path" 55735 if test ! -f "$path" && test ! -d "$path"; then 55736 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55737 fi 55738 55739 if test -d "$path"; then 55740 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55741 else 55742 dir="`$DIRNAME "$path"`" 55743 base="`$BASENAME "$path"`" 55744 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55745 fi 55746 fi 55747 fi 55748 55749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55750 $as_echo_n "checking for $DLL_NAME... " >&6; } 55751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55752 $as_echo "$MSVC_DLL" >&6; } 55753 else 55754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55755 $as_echo "incorrect, ignoring" >&6; } 55756 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55757 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55758 fi 55759 fi 55760 55761 fi 55762 fi 55763 55764 if test "x$MSVC_DLL" = x; then 55765 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55766 # (This was the original behaviour; kept since it might turn something up) 55767 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55768 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55769 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55770 | $GREP x64 | $HEAD --lines 1` 55771 else 55772 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55773 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55774 if test "x$POSSIBLE_MSVC_DLL" = x; then 55775 # We're grasping at straws now... 55776 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55777 | $HEAD --lines 1` 55778 fi 55779 fi 55780 55781 55782 DLL_NAME="$DLL_NAME" 55783 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55784 METHOD="search of VCINSTALLDIR" 55785 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55786 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55787 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55788 55789 # Need to check if the found msvcr is correct architecture 55790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55791 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55792 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55793 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55794 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55795 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55796 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55797 CORRECT_MSVCR_ARCH="PE32 executable" 55798 else 55799 CORRECT_MSVCR_ARCH="PE32+ executable" 55800 fi 55801 else 55802 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55803 CORRECT_MSVCR_ARCH=386 55804 else 55805 CORRECT_MSVCR_ARCH=x86-64 55806 fi 55807 fi 55808 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55810 $as_echo "ok" >&6; } 55811 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55812 55813 # Only process if variable expands to non-empty 55814 55815 if test "x$MSVC_DLL" != x; then 55816 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55817 55818 # Input might be given as Windows format, start by converting to 55819 # unix format. 55820 path="$MSVC_DLL" 55821 new_path=`$CYGPATH -u "$path"` 55822 55823 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55824 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55825 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55826 # "foo.exe" is OK but "foo" is an error. 55827 # 55828 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55829 # It is also a way to make sure we got the proper file name for the real test later on. 55830 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55831 if test "x$test_shortpath" = x; then 55832 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55833 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55834 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55835 fi 55836 55837 # Call helper function which possibly converts this using DOS-style short mode. 55838 # If so, the updated path is stored in $new_path. 55839 55840 input_path="$new_path" 55841 # Check if we need to convert this using DOS-style short mode. If the path 55842 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55843 # take no chances and rewrite it. 55844 # Note: m4 eats our [], so we need to use [ and ] instead. 55845 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55846 if test "x$has_forbidden_chars" != x; then 55847 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55848 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55849 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55850 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55851 # Going to short mode and back again did indeed matter. Since short mode is 55852 # case insensitive, let's make it lowercase to improve readability. 55853 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55854 # Now convert it back to Unix-style (cygpath) 55855 input_path=`$CYGPATH -u "$shortmode_path"` 55856 new_path="$input_path" 55857 fi 55858 fi 55859 55860 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55861 if test "x$test_cygdrive_prefix" = x; then 55862 # As a simple fix, exclude /usr/bin since it's not a real path. 55863 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55864 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55865 # a path prefixed by /cygdrive for fixpath to work. 55866 new_path="$CYGWIN_ROOT_PATH$input_path" 55867 fi 55868 fi 55869 55870 55871 if test "x$path" != "x$new_path"; then 55872 MSVC_DLL="$new_path" 55873 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55874 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55875 fi 55876 55877 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55878 55879 path="$MSVC_DLL" 55880 has_colon=`$ECHO $path | $GREP ^.:` 55881 new_path="$path" 55882 if test "x$has_colon" = x; then 55883 # Not in mixed or Windows style, start by that. 55884 new_path=`cmd //c echo $path` 55885 fi 55886 55887 55888 input_path="$new_path" 55889 # Check if we need to convert this using DOS-style short mode. If the path 55890 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55891 # take no chances and rewrite it. 55892 # Note: m4 eats our [], so we need to use [ and ] instead. 55893 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55894 if test "x$has_forbidden_chars" != x; then 55895 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55896 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55897 fi 55898 55899 55900 windows_path="$new_path" 55901 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55902 unix_path=`$CYGPATH -u "$windows_path"` 55903 new_path="$unix_path" 55904 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55905 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55906 new_path="$unix_path" 55907 fi 55908 55909 if test "x$path" != "x$new_path"; then 55910 MSVC_DLL="$new_path" 55911 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55912 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55913 fi 55914 55915 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55916 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55917 55918 else 55919 # We're on a unix platform. Hooray! :) 55920 path="$MSVC_DLL" 55921 has_space=`$ECHO "$path" | $GREP " "` 55922 if test "x$has_space" != x; then 55923 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55924 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55925 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55926 fi 55927 55928 # Use eval to expand a potential ~ 55929 eval path="$path" 55930 if test ! -f "$path" && test ! -d "$path"; then 55931 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55932 fi 55933 55934 if test -d "$path"; then 55935 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55936 else 55937 dir="`$DIRNAME "$path"`" 55938 base="`$BASENAME "$path"`" 55939 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55940 fi 55941 fi 55942 fi 55943 55944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55945 $as_echo_n "checking for $DLL_NAME... " >&6; } 55946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55947 $as_echo "$MSVC_DLL" >&6; } 55948 else 55949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55950 $as_echo "incorrect, ignoring" >&6; } 55951 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55952 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55953 fi 55954 fi 55955 55956 fi 55957 fi 55958 55959 if test "x$MSVC_DLL" = x; then 55960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55961 $as_echo_n "checking for $DLL_NAME... " >&6; } 55962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55963 $as_echo "no" >&6; } 55964 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 55965 fi 55966 55967 MSVCP_DLL="$MSVC_DLL" 55968 fi 55969 55970 fi 55971 55972 fi 55973 55974 55975 if test "x$NEEDS_LIB_X11" = xfalse; then 55976 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 55977 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 55978 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 55979 fi 55980 X_CFLAGS= 55981 X_LIBS= 55982 else 55983 55984 if test "x${with_x}" = xno; then 55985 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 55986 fi 55987 55988 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 55989 # The user has specified a X11 base directory. Use it for includes and 55990 # libraries, unless explicitely overridden. 55991 if test "x$x_includes" = xNONE; then 55992 x_includes="${with_x}/include" 55993 fi 55994 if test "x$x_libraries" = xNONE; then 55995 x_libraries="${with_x}/lib" 55996 fi 55997 else 55998 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 55999 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 56000 # --x-libraries for the sysroot, if that seems to be correct. 56001 if test "x$SYSROOT" != "x"; then 56002 if test "x$x_includes" = xNONE; then 56003 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 56004 x_includes="$SYSROOT/usr/X11R6/include" 56005 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 56006 x_includes="$SYSROOT/usr/include" 56007 fi 56008 fi 56009 if test "x$x_libraries" = xNONE; then 56010 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 56011 x_libraries="$SYSROOT/usr/X11R6/lib" 56012 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56013 x_libraries="$SYSROOT/usr/lib64" 56014 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 56015 x_libraries="$SYSROOT/usr/lib" 56016 fi 56017 fi 56018 fi 56019 fi 56020 56021 # Now let autoconf do it's magic 56022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 56023 $as_echo_n "checking for X... " >&6; } 56024 56025 56026 # Check whether --with-x was given. 56027 if test "${with_x+set}" = set; then : 56028 withval=$with_x; 56029 fi 56030 56031 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 56032 if test "x$with_x" = xno; then 56033 # The user explicitly disabled X. 56034 have_x=disabled 56035 else 56036 case $x_includes,$x_libraries in #( 56037 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 56038 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 56039 $as_echo_n "(cached) " >&6 56040 else 56041 # One or both of the vars are not set, and there is no cached value. 56042 ac_x_includes=no ac_x_libraries=no 56043 rm -f -r conftest.dir 56044 if mkdir conftest.dir; then 56045 cd conftest.dir 56046 cat >Imakefile <<'_ACEOF' 56047 incroot: 56048 @echo incroot='${INCROOT}' 56049 usrlibdir: 56050 @echo usrlibdir='${USRLIBDIR}' 56051 libdir: 56052 @echo libdir='${LIBDIR}' 56053 _ACEOF 56054 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 56055 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 56056 for ac_var in incroot usrlibdir libdir; do 56057 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 56058 done 56059 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 56060 for ac_extension in a so sl dylib la dll; do 56061 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 56062 test -f "$ac_im_libdir/libX11.$ac_extension"; then 56063 ac_im_usrlibdir=$ac_im_libdir; break 56064 fi 56065 done 56066 # Screen out bogus values from the imake configuration. They are 56067 # bogus both because they are the default anyway, and because 56068 # using them would break gcc on systems where it needs fixed includes. 56069 case $ac_im_incroot in 56070 /usr/include) ac_x_includes= ;; 56071 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 56072 esac 56073 case $ac_im_usrlibdir in 56074 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 56075 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 56076 esac 56077 fi 56078 cd .. 56079 rm -f -r conftest.dir 56080 fi 56081 56082 # Standard set of common directories for X headers. 56083 # Check X11 before X11Rn because it is often a symlink to the current release. 56084 ac_x_header_dirs=' 56085 /usr/X11/include 56086 /usr/X11R7/include 56087 /usr/X11R6/include 56088 /usr/X11R5/include 56089 /usr/X11R4/include 56090 56091 /usr/include/X11 56092 /usr/include/X11R7 56093 /usr/include/X11R6 56094 /usr/include/X11R5 56095 /usr/include/X11R4 56096 56097 /usr/local/X11/include 56098 /usr/local/X11R7/include 56099 /usr/local/X11R6/include 56100 /usr/local/X11R5/include 56101 /usr/local/X11R4/include 56102 56103 /usr/local/include/X11 56104 /usr/local/include/X11R7 56105 /usr/local/include/X11R6 56106 /usr/local/include/X11R5 56107 /usr/local/include/X11R4 56108 56109 /usr/X386/include 56110 /usr/x386/include 56111 /usr/XFree86/include/X11 56112 56113 /usr/include 56114 /usr/local/include 56115 /usr/unsupported/include 56116 /usr/athena/include 56117 /usr/local/x11r5/include 56118 /usr/lpp/Xamples/include 56119 56120 /usr/openwin/include 56121 /usr/openwin/share/include' 56122 56123 if test "$ac_x_includes" = no; then 56124 # Guess where to find include files, by looking for Xlib.h. 56125 # First, try using that file with no special directory specified. 56126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56127 /* end confdefs.h. */ 56128 #include <X11/Xlib.h> 56129 _ACEOF 56130 if ac_fn_cxx_try_cpp "$LINENO"; then : 56131 # We can compile using X headers with no special include directory. 56132 ac_x_includes= 56133 else 56134 for ac_dir in $ac_x_header_dirs; do 56135 if test -r "$ac_dir/X11/Xlib.h"; then 56136 ac_x_includes=$ac_dir 56137 break 56138 fi 56139 done 56140 fi 56141 rm -f conftest.err conftest.i conftest.$ac_ext 56142 fi # $ac_x_includes = no 56143 56144 if test "$ac_x_libraries" = no; then 56145 # Check for the libraries. 56146 # See if we find them without any special options. 56147 # Don't add to $LIBS permanently. 56148 ac_save_LIBS=$LIBS 56149 LIBS="-lX11 $LIBS" 56150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56151 /* end confdefs.h. */ 56152 #include <X11/Xlib.h> 56153 int 56154 main () 56155 { 56156 XrmInitialize () 56157 ; 56158 return 0; 56159 } 56160 _ACEOF 56161 if ac_fn_cxx_try_link "$LINENO"; then : 56162 LIBS=$ac_save_LIBS 56163 # We can link X programs with no special library path. 56164 ac_x_libraries= 56165 else 56166 LIBS=$ac_save_LIBS 56167 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 56168 do 56169 # Don't even attempt the hair of trying to link an X program! 56170 for ac_extension in a so sl dylib la dll; do 56171 if test -r "$ac_dir/libX11.$ac_extension"; then 56172 ac_x_libraries=$ac_dir 56173 break 2 56174 fi 56175 done 56176 done 56177 fi 56178 rm -f core conftest.err conftest.$ac_objext \ 56179 conftest$ac_exeext conftest.$ac_ext 56180 fi # $ac_x_libraries = no 56181 56182 case $ac_x_includes,$ac_x_libraries in #( 56183 no,* | *,no | *\'*) 56184 # Didn't find X, or a directory has "'" in its name. 56185 ac_cv_have_x="have_x=no";; #( 56186 *) 56187 # Record where we found X for the cache. 56188 ac_cv_have_x="have_x=yes\ 56189 ac_x_includes='$ac_x_includes'\ 56190 ac_x_libraries='$ac_x_libraries'" 56191 esac 56192 fi 56193 ;; #( 56194 *) have_x=yes;; 56195 esac 56196 eval "$ac_cv_have_x" 56197 fi # $with_x != no 56198 56199 if test "$have_x" != yes; then 56200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 56201 $as_echo "$have_x" >&6; } 56202 no_x=yes 56203 else 56204 # If each of the values was on the command line, it overrides each guess. 56205 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 56206 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 56207 # Update the cache value to reflect the command line values. 56208 ac_cv_have_x="have_x=yes\ 56209 ac_x_includes='$x_includes'\ 56210 ac_x_libraries='$x_libraries'" 56211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 56212 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 56213 fi 56214 56215 if test "$no_x" = yes; then 56216 # Not all programs may use this symbol, but it does not hurt to define it. 56217 56218 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 56219 56220 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 56221 else 56222 if test -n "$x_includes"; then 56223 X_CFLAGS="$X_CFLAGS -I$x_includes" 56224 fi 56225 56226 # It would also be nice to do this for all -L options, not just this one. 56227 if test -n "$x_libraries"; then 56228 X_LIBS="$X_LIBS -L$x_libraries" 56229 # For Solaris; some versions of Sun CC require a space after -R and 56230 # others require no space. Words are not sufficient . . . . 56231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 56232 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 56233 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 56234 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 56235 ac_cxx_werror_flag=yes 56236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56237 /* end confdefs.h. */ 56238 56239 int 56240 main () 56241 { 56242 56243 ; 56244 return 0; 56245 } 56246 _ACEOF 56247 if ac_fn_cxx_try_link "$LINENO"; then : 56248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56249 $as_echo "no" >&6; } 56250 X_LIBS="$X_LIBS -R$x_libraries" 56251 else 56252 LIBS="$ac_xsave_LIBS -R $x_libraries" 56253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56254 /* end confdefs.h. */ 56255 56256 int 56257 main () 56258 { 56259 56260 ; 56261 return 0; 56262 } 56263 _ACEOF 56264 if ac_fn_cxx_try_link "$LINENO"; then : 56265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56266 $as_echo "yes" >&6; } 56267 X_LIBS="$X_LIBS -R $x_libraries" 56268 else 56269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 56270 $as_echo "neither works" >&6; } 56271 fi 56272 rm -f core conftest.err conftest.$ac_objext \ 56273 conftest$ac_exeext conftest.$ac_ext 56274 fi 56275 rm -f core conftest.err conftest.$ac_objext \ 56276 conftest$ac_exeext conftest.$ac_ext 56277 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 56278 LIBS=$ac_xsave_LIBS 56279 fi 56280 56281 # Check for system-dependent libraries X programs must link with. 56282 # Do this before checking for the system-independent R6 libraries 56283 # (-lICE), since we may need -lsocket or whatever for X linking. 56284 56285 if test "$ISC" = yes; then 56286 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 56287 else 56288 # Martyn Johnson says this is needed for Ultrix, if the X 56289 # libraries were built with DECnet support. And Karl Berry says 56290 # the Alpha needs dnet_stub (dnet does not exist). 56291 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 56292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56293 /* end confdefs.h. */ 56294 56295 /* Override any GCC internal prototype to avoid an error. 56296 Use char because int might match the return type of a GCC 56297 builtin and then its argument prototype would still apply. */ 56298 #ifdef __cplusplus 56299 extern "C" 56300 #endif 56301 char XOpenDisplay (); 56302 int 56303 main () 56304 { 56305 return XOpenDisplay (); 56306 ; 56307 return 0; 56308 } 56309 _ACEOF 56310 if ac_fn_cxx_try_link "$LINENO"; then : 56311 56312 else 56313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 56314 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 56315 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 56316 $as_echo_n "(cached) " >&6 56317 else 56318 ac_check_lib_save_LIBS=$LIBS 56319 LIBS="-ldnet $LIBS" 56320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56321 /* end confdefs.h. */ 56322 56323 /* Override any GCC internal prototype to avoid an error. 56324 Use char because int might match the return type of a GCC 56325 builtin and then its argument prototype would still apply. */ 56326 #ifdef __cplusplus 56327 extern "C" 56328 #endif 56329 char dnet_ntoa (); 56330 int 56331 main () 56332 { 56333 return dnet_ntoa (); 56334 ; 56335 return 0; 56336 } 56337 _ACEOF 56338 if ac_fn_cxx_try_link "$LINENO"; then : 56339 ac_cv_lib_dnet_dnet_ntoa=yes 56340 else 56341 ac_cv_lib_dnet_dnet_ntoa=no 56342 fi 56343 rm -f core conftest.err conftest.$ac_objext \ 56344 conftest$ac_exeext conftest.$ac_ext 56345 LIBS=$ac_check_lib_save_LIBS 56346 fi 56347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 56348 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 56349 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 56350 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 56351 fi 56352 56353 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 56354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 56355 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 56356 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 56357 $as_echo_n "(cached) " >&6 56358 else 56359 ac_check_lib_save_LIBS=$LIBS 56360 LIBS="-ldnet_stub $LIBS" 56361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56362 /* end confdefs.h. */ 56363 56364 /* Override any GCC internal prototype to avoid an error. 56365 Use char because int might match the return type of a GCC 56366 builtin and then its argument prototype would still apply. */ 56367 #ifdef __cplusplus 56368 extern "C" 56369 #endif 56370 char dnet_ntoa (); 56371 int 56372 main () 56373 { 56374 return dnet_ntoa (); 56375 ; 56376 return 0; 56377 } 56378 _ACEOF 56379 if ac_fn_cxx_try_link "$LINENO"; then : 56380 ac_cv_lib_dnet_stub_dnet_ntoa=yes 56381 else 56382 ac_cv_lib_dnet_stub_dnet_ntoa=no 56383 fi 56384 rm -f core conftest.err conftest.$ac_objext \ 56385 conftest$ac_exeext conftest.$ac_ext 56386 LIBS=$ac_check_lib_save_LIBS 56387 fi 56388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 56389 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 56390 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 56391 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 56392 fi 56393 56394 fi 56395 fi 56396 rm -f core conftest.err conftest.$ac_objext \ 56397 conftest$ac_exeext conftest.$ac_ext 56398 LIBS="$ac_xsave_LIBS" 56399 56400 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 56401 # to get the SysV transport functions. 56402 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 56403 # needs -lnsl. 56404 # The nsl library prevents programs from opening the X display 56405 # on Irix 5.2, according to T.E. Dickey. 56406 # The functions gethostbyname, getservbyname, and inet_addr are 56407 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 56408 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 56409 if test "x$ac_cv_func_gethostbyname" = xyes; then : 56410 56411 fi 56412 56413 if test $ac_cv_func_gethostbyname = no; then 56414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 56415 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 56416 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 56417 $as_echo_n "(cached) " >&6 56418 else 56419 ac_check_lib_save_LIBS=$LIBS 56420 LIBS="-lnsl $LIBS" 56421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56422 /* end confdefs.h. */ 56423 56424 /* Override any GCC internal prototype to avoid an error. 56425 Use char because int might match the return type of a GCC 56426 builtin and then its argument prototype would still apply. */ 56427 #ifdef __cplusplus 56428 extern "C" 56429 #endif 56430 char gethostbyname (); 56431 int 56432 main () 56433 { 56434 return gethostbyname (); 56435 ; 56436 return 0; 56437 } 56438 _ACEOF 56439 if ac_fn_cxx_try_link "$LINENO"; then : 56440 ac_cv_lib_nsl_gethostbyname=yes 56441 else 56442 ac_cv_lib_nsl_gethostbyname=no 56443 fi 56444 rm -f core conftest.err conftest.$ac_objext \ 56445 conftest$ac_exeext conftest.$ac_ext 56446 LIBS=$ac_check_lib_save_LIBS 56447 fi 56448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 56449 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 56450 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 56451 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 56452 fi 56453 56454 if test $ac_cv_lib_nsl_gethostbyname = no; then 56455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 56456 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 56457 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 56458 $as_echo_n "(cached) " >&6 56459 else 56460 ac_check_lib_save_LIBS=$LIBS 56461 LIBS="-lbsd $LIBS" 56462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56463 /* end confdefs.h. */ 56464 56465 /* Override any GCC internal prototype to avoid an error. 56466 Use char because int might match the return type of a GCC 56467 builtin and then its argument prototype would still apply. */ 56468 #ifdef __cplusplus 56469 extern "C" 56470 #endif 56471 char gethostbyname (); 56472 int 56473 main () 56474 { 56475 return gethostbyname (); 56476 ; 56477 return 0; 56478 } 56479 _ACEOF 56480 if ac_fn_cxx_try_link "$LINENO"; then : 56481 ac_cv_lib_bsd_gethostbyname=yes 56482 else 56483 ac_cv_lib_bsd_gethostbyname=no 56484 fi 56485 rm -f core conftest.err conftest.$ac_objext \ 56486 conftest$ac_exeext conftest.$ac_ext 56487 LIBS=$ac_check_lib_save_LIBS 56488 fi 56489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 56490 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 56491 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 56492 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 56493 fi 56494 56495 fi 56496 fi 56497 56498 # lieder@skyler.mavd.honeywell.com says without -lsocket, 56499 # socket/setsockopt and other routines are undefined under SCO ODT 56500 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 56501 # on later versions), says Simon Leinen: it contains gethostby* 56502 # variants that don't use the name server (or something). -lsocket 56503 # must be given before -lnsl if both are needed. We assume that 56504 # if connect needs -lnsl, so does gethostbyname. 56505 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 56506 if test "x$ac_cv_func_connect" = xyes; then : 56507 56508 fi 56509 56510 if test $ac_cv_func_connect = no; then 56511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 56512 $as_echo_n "checking for connect in -lsocket... " >&6; } 56513 if ${ac_cv_lib_socket_connect+:} false; then : 56514 $as_echo_n "(cached) " >&6 56515 else 56516 ac_check_lib_save_LIBS=$LIBS 56517 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 56518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56519 /* end confdefs.h. */ 56520 56521 /* Override any GCC internal prototype to avoid an error. 56522 Use char because int might match the return type of a GCC 56523 builtin and then its argument prototype would still apply. */ 56524 #ifdef __cplusplus 56525 extern "C" 56526 #endif 56527 char connect (); 56528 int 56529 main () 56530 { 56531 return connect (); 56532 ; 56533 return 0; 56534 } 56535 _ACEOF 56536 if ac_fn_cxx_try_link "$LINENO"; then : 56537 ac_cv_lib_socket_connect=yes 56538 else 56539 ac_cv_lib_socket_connect=no 56540 fi 56541 rm -f core conftest.err conftest.$ac_objext \ 56542 conftest$ac_exeext conftest.$ac_ext 56543 LIBS=$ac_check_lib_save_LIBS 56544 fi 56545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 56546 $as_echo "$ac_cv_lib_socket_connect" >&6; } 56547 if test "x$ac_cv_lib_socket_connect" = xyes; then : 56548 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 56549 fi 56550 56551 fi 56552 56553 # Guillermo Gomez says -lposix is necessary on A/UX. 56554 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 56555 if test "x$ac_cv_func_remove" = xyes; then : 56556 56557 fi 56558 56559 if test $ac_cv_func_remove = no; then 56560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 56561 $as_echo_n "checking for remove in -lposix... " >&6; } 56562 if ${ac_cv_lib_posix_remove+:} false; then : 56563 $as_echo_n "(cached) " >&6 56564 else 56565 ac_check_lib_save_LIBS=$LIBS 56566 LIBS="-lposix $LIBS" 56567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56568 /* end confdefs.h. */ 56569 56570 /* Override any GCC internal prototype to avoid an error. 56571 Use char because int might match the return type of a GCC 56572 builtin and then its argument prototype would still apply. */ 56573 #ifdef __cplusplus 56574 extern "C" 56575 #endif 56576 char remove (); 56577 int 56578 main () 56579 { 56580 return remove (); 56581 ; 56582 return 0; 56583 } 56584 _ACEOF 56585 if ac_fn_cxx_try_link "$LINENO"; then : 56586 ac_cv_lib_posix_remove=yes 56587 else 56588 ac_cv_lib_posix_remove=no 56589 fi 56590 rm -f core conftest.err conftest.$ac_objext \ 56591 conftest$ac_exeext conftest.$ac_ext 56592 LIBS=$ac_check_lib_save_LIBS 56593 fi 56594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 56595 $as_echo "$ac_cv_lib_posix_remove" >&6; } 56596 if test "x$ac_cv_lib_posix_remove" = xyes; then : 56597 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 56598 fi 56599 56600 fi 56601 56602 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 56603 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 56604 if test "x$ac_cv_func_shmat" = xyes; then : 56605 56606 fi 56607 56608 if test $ac_cv_func_shmat = no; then 56609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 56610 $as_echo_n "checking for shmat in -lipc... " >&6; } 56611 if ${ac_cv_lib_ipc_shmat+:} false; then : 56612 $as_echo_n "(cached) " >&6 56613 else 56614 ac_check_lib_save_LIBS=$LIBS 56615 LIBS="-lipc $LIBS" 56616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56617 /* end confdefs.h. */ 56618 56619 /* Override any GCC internal prototype to avoid an error. 56620 Use char because int might match the return type of a GCC 56621 builtin and then its argument prototype would still apply. */ 56622 #ifdef __cplusplus 56623 extern "C" 56624 #endif 56625 char shmat (); 56626 int 56627 main () 56628 { 56629 return shmat (); 56630 ; 56631 return 0; 56632 } 56633 _ACEOF 56634 if ac_fn_cxx_try_link "$LINENO"; then : 56635 ac_cv_lib_ipc_shmat=yes 56636 else 56637 ac_cv_lib_ipc_shmat=no 56638 fi 56639 rm -f core conftest.err conftest.$ac_objext \ 56640 conftest$ac_exeext conftest.$ac_ext 56641 LIBS=$ac_check_lib_save_LIBS 56642 fi 56643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 56644 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 56645 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 56646 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 56647 fi 56648 56649 fi 56650 fi 56651 56652 # Check for libraries that X11R6 Xt/Xaw programs need. 56653 ac_save_LDFLAGS=$LDFLAGS 56654 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 56655 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 56656 # check for ICE first), but we must link in the order -lSM -lICE or 56657 # we get undefined symbols. So assume we have SM if we have ICE. 56658 # These have to be linked with before -lX11, unlike the other 56659 # libraries we check for below, so use a different variable. 56660 # John Interrante, Karl Berry 56661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 56662 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 56663 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 56664 $as_echo_n "(cached) " >&6 56665 else 56666 ac_check_lib_save_LIBS=$LIBS 56667 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 56668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56669 /* end confdefs.h. */ 56670 56671 /* Override any GCC internal prototype to avoid an error. 56672 Use char because int might match the return type of a GCC 56673 builtin and then its argument prototype would still apply. */ 56674 #ifdef __cplusplus 56675 extern "C" 56676 #endif 56677 char IceConnectionNumber (); 56678 int 56679 main () 56680 { 56681 return IceConnectionNumber (); 56682 ; 56683 return 0; 56684 } 56685 _ACEOF 56686 if ac_fn_cxx_try_link "$LINENO"; then : 56687 ac_cv_lib_ICE_IceConnectionNumber=yes 56688 else 56689 ac_cv_lib_ICE_IceConnectionNumber=no 56690 fi 56691 rm -f core conftest.err conftest.$ac_objext \ 56692 conftest$ac_exeext conftest.$ac_ext 56693 LIBS=$ac_check_lib_save_LIBS 56694 fi 56695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 56696 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 56697 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 56698 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 56699 fi 56700 56701 LDFLAGS=$ac_save_LDFLAGS 56702 56703 fi 56704 56705 56706 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 56707 # this doesn't make sense so we remove it. 56708 if test "x$COMPILE_TYPE" = xcross; then 56709 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 56710 fi 56711 56712 if test "x$no_x" = xyes; then 56713 56714 # Print a helpful message on how to acquire the necessary build dependency. 56715 # x11 is the help tag: freetype, cups, alsa etc 56716 MISSING_DEPENDENCY=x11 56717 56718 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56719 cygwin_help $MISSING_DEPENDENCY 56720 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56721 msys_help $MISSING_DEPENDENCY 56722 else 56723 PKGHANDLER_COMMAND= 56724 56725 case $PKGHANDLER in 56726 apt-get) 56727 apt_help $MISSING_DEPENDENCY ;; 56728 yum) 56729 yum_help $MISSING_DEPENDENCY ;; 56730 port) 56731 port_help $MISSING_DEPENDENCY ;; 56732 pkgutil) 56733 pkgutil_help $MISSING_DEPENDENCY ;; 56734 pkgadd) 56735 pkgadd_help $MISSING_DEPENDENCY ;; 56736 esac 56737 56738 if test "x$PKGHANDLER_COMMAND" != x; then 56739 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56740 fi 56741 fi 56742 56743 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 56744 fi 56745 56746 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 56747 OPENWIN_HOME="/usr/openwin" 56748 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 56749 X_LIBS="-L$SYSROOT$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \ 56750 -L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 56751 -R$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \ 56752 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 56753 fi 56754 56755 ac_ext=c 56756 ac_cpp='$CPP $CPPFLAGS' 56757 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56758 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56759 ac_compiler_gnu=$ac_cv_c_compiler_gnu 56760 56761 OLD_CFLAGS="$CFLAGS" 56762 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 56763 56764 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 56765 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 56766 do : 56767 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56768 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 56769 # include <X11/Xlib.h> 56770 # include <X11/Xutil.h> 56771 56772 56773 " 56774 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56775 cat >>confdefs.h <<_ACEOF 56776 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56777 _ACEOF 56778 X11_HEADERS_OK=yes 56779 else 56780 X11_HEADERS_OK=no; break 56781 fi 56782 56783 done 56784 56785 56786 if test "x$X11_HEADERS_OK" = xno; then 56787 56788 # Print a helpful message on how to acquire the necessary build dependency. 56789 # x11 is the help tag: freetype, cups, alsa etc 56790 MISSING_DEPENDENCY=x11 56791 56792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56793 cygwin_help $MISSING_DEPENDENCY 56794 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56795 msys_help $MISSING_DEPENDENCY 56796 else 56797 PKGHANDLER_COMMAND= 56798 56799 case $PKGHANDLER in 56800 apt-get) 56801 apt_help $MISSING_DEPENDENCY ;; 56802 yum) 56803 yum_help $MISSING_DEPENDENCY ;; 56804 port) 56805 port_help $MISSING_DEPENDENCY ;; 56806 pkgutil) 56807 pkgutil_help $MISSING_DEPENDENCY ;; 56808 pkgadd) 56809 pkgadd_help $MISSING_DEPENDENCY ;; 56810 esac 56811 56812 if test "x$PKGHANDLER_COMMAND" != x; then 56813 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56814 fi 56815 fi 56816 56817 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 56818 fi 56819 56820 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 56821 # defined in libawt_xawt. 56822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 56823 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 56824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56825 /* end confdefs.h. */ 56826 #include <X11/extensions/Xrender.h> 56827 int 56828 main () 56829 { 56830 XLinearGradient x; 56831 ; 56832 return 0; 56833 } 56834 _ACEOF 56835 if ac_fn_c_try_compile "$LINENO"; then : 56836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56837 $as_echo "yes" >&6; } 56838 else 56839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56840 $as_echo "no" >&6; } 56841 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 56842 fi 56843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 56844 56845 CFLAGS="$OLD_CFLAGS" 56846 ac_ext=cpp 56847 ac_cpp='$CXXCPP $CPPFLAGS' 56848 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56849 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56850 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 56851 56852 fi # NEEDS_LIB_X11 56853 56854 56855 56856 56857 56858 56859 # Check whether --with-cups was given. 56860 if test "${with_cups+set}" = set; then : 56861 withval=$with_cups; 56862 fi 56863 56864 56865 # Check whether --with-cups-include was given. 56866 if test "${with_cups_include+set}" = set; then : 56867 withval=$with_cups_include; 56868 fi 56869 56870 56871 if test "x$NEEDS_LIB_CUPS" = xfalse; then 56872 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 56873 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 56874 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 56875 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 56876 fi 56877 CUPS_CFLAGS= 56878 else 56879 CUPS_FOUND=no 56880 56881 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 56882 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 56883 fi 56884 56885 if test "x${with_cups}" != x; then 56886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56887 $as_echo_n "checking for cups headers... " >&6; } 56888 if test -s "${with_cups}/include/cups/cups.h"; then 56889 CUPS_CFLAGS="-I${with_cups}/include" 56890 CUPS_FOUND=yes 56891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56892 $as_echo "$CUPS_FOUND" >&6; } 56893 else 56894 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 56895 fi 56896 fi 56897 if test "x${with_cups_include}" != x; then 56898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56899 $as_echo_n "checking for cups headers... " >&6; } 56900 if test -s "${with_cups_include}/cups/cups.h"; then 56901 CUPS_CFLAGS="-I${with_cups_include}" 56902 CUPS_FOUND=yes 56903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56904 $as_echo "$CUPS_FOUND" >&6; } 56905 else 56906 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 56907 fi 56908 fi 56909 if test "x$CUPS_FOUND" = xno; then 56910 # Are the cups headers installed in the default /usr/include location? 56911 for ac_header in cups/cups.h cups/ppd.h 56912 do : 56913 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56914 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 56915 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56916 cat >>confdefs.h <<_ACEOF 56917 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56918 _ACEOF 56919 56920 CUPS_FOUND=yes 56921 CUPS_CFLAGS= 56922 DEFAULT_CUPS=yes 56923 56924 fi 56925 56926 done 56927 56928 fi 56929 if test "x$CUPS_FOUND" = xno; then 56930 # Getting nervous now? Lets poke around for standard Solaris third-party 56931 # package installation locations. 56932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56933 $as_echo_n "checking for cups headers... " >&6; } 56934 if test -s $SYSROOT/opt/sfw/cups/include/cups/cups.h; then 56935 # An SFW package seems to be installed! 56936 CUPS_FOUND=yes 56937 CUPS_CFLAGS="-I$SYSROOT/opt/sfw/cups/include" 56938 elif test -s $SYSROOT/opt/csw/include/cups/cups.h; then 56939 # A CSW package seems to be installed! 56940 CUPS_FOUND=yes 56941 CUPS_CFLAGS="-I$SYSROOT/opt/csw/include" 56942 fi 56943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56944 $as_echo "$CUPS_FOUND" >&6; } 56945 fi 56946 if test "x$CUPS_FOUND" = xno; then 56947 56948 # Print a helpful message on how to acquire the necessary build dependency. 56949 # cups is the help tag: freetype, cups, alsa etc 56950 MISSING_DEPENDENCY=cups 56951 56952 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56953 cygwin_help $MISSING_DEPENDENCY 56954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56955 msys_help $MISSING_DEPENDENCY 56956 else 56957 PKGHANDLER_COMMAND= 56958 56959 case $PKGHANDLER in 56960 apt-get) 56961 apt_help $MISSING_DEPENDENCY ;; 56962 yum) 56963 yum_help $MISSING_DEPENDENCY ;; 56964 port) 56965 port_help $MISSING_DEPENDENCY ;; 56966 pkgutil) 56967 pkgutil_help $MISSING_DEPENDENCY ;; 56968 pkgadd) 56969 pkgadd_help $MISSING_DEPENDENCY ;; 56970 esac 56971 56972 if test "x$PKGHANDLER_COMMAND" != x; then 56973 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56974 fi 56975 fi 56976 56977 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 56978 fi 56979 fi 56980 56981 56982 56983 56984 56985 # Check whether --with-freetype was given. 56986 if test "${with_freetype+set}" = set; then : 56987 withval=$with_freetype; 56988 fi 56989 56990 56991 # Check whether --with-freetype-include was given. 56992 if test "${with_freetype_include+set}" = set; then : 56993 withval=$with_freetype_include; 56994 fi 56995 56996 56997 # Check whether --with-freetype-lib was given. 56998 if test "${with_freetype_lib+set}" = set; then : 56999 withval=$with_freetype_lib; 57000 fi 57001 57002 57003 # Check whether --with-freetype-src was given. 57004 if test "${with_freetype_src+set}" = set; then : 57005 withval=$with_freetype_src; 57006 fi 57007 57008 # Check whether --enable-freetype-bundling was given. 57009 if test "${enable_freetype_bundling+set}" = set; then : 57010 enableval=$enable_freetype_bundling; 57011 fi 57012 57013 57014 # Need to specify explicitly since it needs to be overridden on some versions of macosx 57015 FREETYPE_BASE_NAME=freetype 57016 FREETYPE_CFLAGS= 57017 FREETYPE_LIBS= 57018 FREETYPE_BUNDLE_LIB_PATH= 57019 57020 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 57021 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 57022 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 57023 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 57024 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 57025 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 57026 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 57027 fi 57028 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 57029 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 57030 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 57031 fi 57032 else 57033 # freetype is needed to build; go get it! 57034 57035 BUNDLE_FREETYPE="$enable_freetype_bundling" 57036 57037 if test "x$with_freetype_src" != x; then 57038 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57039 # Try to build freetype if --with-freetype-src was given on Windows 57040 57041 FREETYPE_SRC_PATH="$with_freetype_src" 57042 BUILD_FREETYPE=yes 57043 57044 # Check if the freetype sources are acessible.. 57045 if ! test -d $FREETYPE_SRC_PATH; then 57046 { $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 57047 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 57048 BUILD_FREETYPE=no 57049 fi 57050 # ..and contain a vc2010 project file 57051 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 57052 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 57053 { $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 57054 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 57055 BUILD_FREETYPE=no 57056 fi 57057 # Now check if configure found a version of 'msbuild.exe' 57058 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 57059 { $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 57060 $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;} 57061 BUILD_FREETYPE=no 57062 fi 57063 57064 # Ready to go.. 57065 if test "x$BUILD_FREETYPE" = xyes; then 57066 # msbuild requires trailing slashes for output directories 57067 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 57068 freetype_lib_path_unix="$freetype_lib_path" 57069 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 57070 57071 unix_path="$vcxproj_path" 57072 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57073 windows_path=`$CYGPATH -m "$unix_path"` 57074 vcxproj_path="$windows_path" 57075 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57076 windows_path=`cmd //c echo $unix_path` 57077 vcxproj_path="$windows_path" 57078 fi 57079 57080 57081 unix_path="$freetype_lib_path" 57082 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57083 windows_path=`$CYGPATH -m "$unix_path"` 57084 freetype_lib_path="$windows_path" 57085 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57086 windows_path=`cmd //c echo $unix_path` 57087 freetype_lib_path="$windows_path" 57088 fi 57089 57090 57091 unix_path="$freetype_obj_path" 57092 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57093 windows_path=`$CYGPATH -m "$unix_path"` 57094 freetype_obj_path="$windows_path" 57095 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57096 windows_path=`cmd //c echo $unix_path` 57097 freetype_obj_path="$windows_path" 57098 fi 57099 57100 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57101 freetype_platform=x64 57102 else 57103 freetype_platform=win32 57104 fi 57105 57106 # The original freetype project file is for VS 2010 (i.e. 'v100'), 57107 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 57108 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 57109 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 57110 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 57111 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 57112 57113 # First we try to build the freetype.dll 57114 $ECHO -e "@echo off\n"\ 57115 "$MSBUILD $vcxproj_path "\ 57116 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57117 "/p:Configuration=\"Release Multithreaded\" "\ 57118 "/p:Platform=$freetype_platform "\ 57119 "/p:ConfigurationType=DynamicLibrary "\ 57120 "/p:TargetName=freetype "\ 57121 "/p:OutDir=\"$freetype_lib_path\" "\ 57122 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 57123 cmd /c freetype.bat 57124 57125 if test -s "$freetype_lib_path_unix/freetype.dll"; then 57126 # If that succeeds we also build freetype.lib 57127 $ECHO -e "@echo off\n"\ 57128 "$MSBUILD $vcxproj_path "\ 57129 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57130 "/p:Configuration=\"Release Multithreaded\" "\ 57131 "/p:Platform=$freetype_platform "\ 57132 "/p:ConfigurationType=StaticLibrary "\ 57133 "/p:TargetName=freetype "\ 57134 "/p:OutDir=\"$freetype_lib_path\" "\ 57135 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 57136 cmd /c freetype.bat 57137 57138 if test -s "$freetype_lib_path_unix/freetype.lib"; then 57139 # Once we build both, lib and dll, set freetype lib and include path appropriately 57140 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 57141 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 57142 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 57143 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 57144 else 57145 BUILD_FREETYPE=no 57146 fi 57147 else 57148 BUILD_FREETYPE=no 57149 fi 57150 fi 57151 57152 if test "x$BUILD_FREETYPE" = xyes; then 57153 # Okay, we built it. Check that it works. 57154 57155 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57156 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57157 METHOD="--with-freetype-src" 57158 57159 # Let's start with an optimistic view of the world :-) 57160 FOUND_FREETYPE=yes 57161 57162 # First look for the canonical freetype main include file ft2build.h. 57163 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57164 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57165 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57166 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57167 # Fail. 57168 FOUND_FREETYPE=no 57169 fi 57170 fi 57171 57172 if test "x$FOUND_FREETYPE" = xyes; then 57173 # Include file found, let's continue the sanity check. 57174 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57175 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57176 57177 # Reset to default value 57178 FREETYPE_BASE_NAME=freetype 57179 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57180 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57181 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57182 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57183 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57184 # for the .6 version explicitly. 57185 FREETYPE_BASE_NAME=freetype.6 57186 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57187 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57188 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57189 else 57190 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57191 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57192 FOUND_FREETYPE=no 57193 fi 57194 else 57195 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57196 # On Windows, we will need both .lib and .dll file. 57197 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57198 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57199 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57200 FOUND_FREETYPE=no 57201 fi 57202 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57203 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57204 # Found lib in isa dir, use that instead. 57205 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57206 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57207 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57208 fi 57209 fi 57210 fi 57211 57212 if test "x$FOUND_FREETYPE" = xyes; then 57213 57214 # Only process if variable expands to non-empty 57215 57216 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57217 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57218 57219 # Input might be given as Windows format, start by converting to 57220 # unix format. 57221 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57222 new_path=`$CYGPATH -u "$path"` 57223 57224 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57225 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57226 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57227 # "foo.exe" is OK but "foo" is an error. 57228 # 57229 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57230 # It is also a way to make sure we got the proper file name for the real test later on. 57231 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57232 if test "x$test_shortpath" = x; then 57233 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57234 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57235 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57236 fi 57237 57238 # Call helper function which possibly converts this using DOS-style short mode. 57239 # If so, the updated path is stored in $new_path. 57240 57241 input_path="$new_path" 57242 # Check if we need to convert this using DOS-style short mode. If the path 57243 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57244 # take no chances and rewrite it. 57245 # Note: m4 eats our [], so we need to use [ and ] instead. 57246 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57247 if test "x$has_forbidden_chars" != x; then 57248 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57249 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57250 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57251 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57252 # Going to short mode and back again did indeed matter. Since short mode is 57253 # case insensitive, let's make it lowercase to improve readability. 57254 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57255 # Now convert it back to Unix-style (cygpath) 57256 input_path=`$CYGPATH -u "$shortmode_path"` 57257 new_path="$input_path" 57258 fi 57259 fi 57260 57261 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57262 if test "x$test_cygdrive_prefix" = x; then 57263 # As a simple fix, exclude /usr/bin since it's not a real path. 57264 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57265 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57266 # a path prefixed by /cygdrive for fixpath to work. 57267 new_path="$CYGWIN_ROOT_PATH$input_path" 57268 fi 57269 fi 57270 57271 57272 if test "x$path" != "x$new_path"; then 57273 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57274 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57275 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57276 fi 57277 57278 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57279 57280 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57281 has_colon=`$ECHO $path | $GREP ^.:` 57282 new_path="$path" 57283 if test "x$has_colon" = x; then 57284 # Not in mixed or Windows style, start by that. 57285 new_path=`cmd //c echo $path` 57286 fi 57287 57288 57289 input_path="$new_path" 57290 # Check if we need to convert this using DOS-style short mode. If the path 57291 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57292 # take no chances and rewrite it. 57293 # Note: m4 eats our [], so we need to use [ and ] instead. 57294 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57295 if test "x$has_forbidden_chars" != x; then 57296 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57297 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57298 fi 57299 57300 57301 windows_path="$new_path" 57302 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57303 unix_path=`$CYGPATH -u "$windows_path"` 57304 new_path="$unix_path" 57305 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57306 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57307 new_path="$unix_path" 57308 fi 57309 57310 if test "x$path" != "x$new_path"; then 57311 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57312 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57313 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57314 fi 57315 57316 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57317 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57318 57319 else 57320 # We're on a unix platform. Hooray! :) 57321 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57322 has_space=`$ECHO "$path" | $GREP " "` 57323 if test "x$has_space" != x; then 57324 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57325 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57326 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57327 fi 57328 57329 # Use eval to expand a potential ~ 57330 eval path="$path" 57331 if test ! -f "$path" && test ! -d "$path"; then 57332 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57333 fi 57334 57335 if test -d "$path"; then 57336 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57337 else 57338 dir="`$DIRNAME "$path"`" 57339 base="`$BASENAME "$path"`" 57340 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57341 fi 57342 fi 57343 fi 57344 57345 57346 # Only process if variable expands to non-empty 57347 57348 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57349 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57350 57351 # Input might be given as Windows format, start by converting to 57352 # unix format. 57353 path="$POTENTIAL_FREETYPE_LIB_PATH" 57354 new_path=`$CYGPATH -u "$path"` 57355 57356 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57357 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57358 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57359 # "foo.exe" is OK but "foo" is an error. 57360 # 57361 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57362 # It is also a way to make sure we got the proper file name for the real test later on. 57363 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57364 if test "x$test_shortpath" = x; then 57365 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57366 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57367 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57368 fi 57369 57370 # Call helper function which possibly converts this using DOS-style short mode. 57371 # If so, the updated path is stored in $new_path. 57372 57373 input_path="$new_path" 57374 # Check if we need to convert this using DOS-style short mode. If the path 57375 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57376 # take no chances and rewrite it. 57377 # Note: m4 eats our [], so we need to use [ and ] instead. 57378 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57379 if test "x$has_forbidden_chars" != x; then 57380 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57381 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57382 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57383 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57384 # Going to short mode and back again did indeed matter. Since short mode is 57385 # case insensitive, let's make it lowercase to improve readability. 57386 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57387 # Now convert it back to Unix-style (cygpath) 57388 input_path=`$CYGPATH -u "$shortmode_path"` 57389 new_path="$input_path" 57390 fi 57391 fi 57392 57393 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57394 if test "x$test_cygdrive_prefix" = x; then 57395 # As a simple fix, exclude /usr/bin since it's not a real path. 57396 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57397 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57398 # a path prefixed by /cygdrive for fixpath to work. 57399 new_path="$CYGWIN_ROOT_PATH$input_path" 57400 fi 57401 fi 57402 57403 57404 if test "x$path" != "x$new_path"; then 57405 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57406 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57407 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57408 fi 57409 57410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57411 57412 path="$POTENTIAL_FREETYPE_LIB_PATH" 57413 has_colon=`$ECHO $path | $GREP ^.:` 57414 new_path="$path" 57415 if test "x$has_colon" = x; then 57416 # Not in mixed or Windows style, start by that. 57417 new_path=`cmd //c echo $path` 57418 fi 57419 57420 57421 input_path="$new_path" 57422 # Check if we need to convert this using DOS-style short mode. If the path 57423 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57424 # take no chances and rewrite it. 57425 # Note: m4 eats our [], so we need to use [ and ] instead. 57426 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57427 if test "x$has_forbidden_chars" != x; then 57428 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57429 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57430 fi 57431 57432 57433 windows_path="$new_path" 57434 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57435 unix_path=`$CYGPATH -u "$windows_path"` 57436 new_path="$unix_path" 57437 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57438 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57439 new_path="$unix_path" 57440 fi 57441 57442 if test "x$path" != "x$new_path"; then 57443 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57444 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57445 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57446 fi 57447 57448 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57449 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57450 57451 else 57452 # We're on a unix platform. Hooray! :) 57453 path="$POTENTIAL_FREETYPE_LIB_PATH" 57454 has_space=`$ECHO "$path" | $GREP " "` 57455 if test "x$has_space" != x; then 57456 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57457 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57458 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57459 fi 57460 57461 # Use eval to expand a potential ~ 57462 eval path="$path" 57463 if test ! -f "$path" && test ! -d "$path"; then 57464 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57465 fi 57466 57467 if test -d "$path"; then 57468 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57469 else 57470 dir="`$DIRNAME "$path"`" 57471 base="`$BASENAME "$path"`" 57472 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57473 fi 57474 fi 57475 fi 57476 57477 57478 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57480 $as_echo_n "checking for freetype includes... " >&6; } 57481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57482 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57483 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57485 $as_echo_n "checking for freetype libraries... " >&6; } 57486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57487 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57488 fi 57489 57490 if test "x$FOUND_FREETYPE" != xyes; then 57491 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 57492 fi 57493 else 57494 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 57495 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 57496 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 57497 fi 57498 else 57499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 57500 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 57501 fi 57502 fi 57503 57504 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 57505 # User has specified settings 57506 57507 if test "x$BUNDLE_FREETYPE" = x; then 57508 # If not specified, default is to bundle freetype 57509 BUNDLE_FREETYPE=yes 57510 fi 57511 57512 if test "x$with_freetype" != x; then 57513 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 57514 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 57515 fi 57516 57517 # Allow --with-freetype-lib and --with-freetype-include to override 57518 if test "x$with_freetype_include" != x; then 57519 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 57520 fi 57521 if test "x$with_freetype_lib" != x; then 57522 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 57523 fi 57524 57525 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57526 # Okay, we got it. Check that it works. 57527 57528 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57529 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57530 METHOD="--with-freetype" 57531 57532 # Let's start with an optimistic view of the world :-) 57533 FOUND_FREETYPE=yes 57534 57535 # First look for the canonical freetype main include file ft2build.h. 57536 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57537 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57538 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57539 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57540 # Fail. 57541 FOUND_FREETYPE=no 57542 fi 57543 fi 57544 57545 if test "x$FOUND_FREETYPE" = xyes; then 57546 # Include file found, let's continue the sanity check. 57547 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57548 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57549 57550 # Reset to default value 57551 FREETYPE_BASE_NAME=freetype 57552 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57553 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57554 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57555 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57556 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57557 # for the .6 version explicitly. 57558 FREETYPE_BASE_NAME=freetype.6 57559 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57560 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57561 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57562 else 57563 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57564 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57565 FOUND_FREETYPE=no 57566 fi 57567 else 57568 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57569 # On Windows, we will need both .lib and .dll file. 57570 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57571 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57572 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57573 FOUND_FREETYPE=no 57574 fi 57575 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57576 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57577 # Found lib in isa dir, use that instead. 57578 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57579 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57580 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57581 fi 57582 fi 57583 fi 57584 57585 if test "x$FOUND_FREETYPE" = xyes; then 57586 57587 # Only process if variable expands to non-empty 57588 57589 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57590 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57591 57592 # Input might be given as Windows format, start by converting to 57593 # unix format. 57594 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57595 new_path=`$CYGPATH -u "$path"` 57596 57597 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57598 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57599 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57600 # "foo.exe" is OK but "foo" is an error. 57601 # 57602 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57603 # It is also a way to make sure we got the proper file name for the real test later on. 57604 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57605 if test "x$test_shortpath" = x; then 57606 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57607 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57608 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57609 fi 57610 57611 # Call helper function which possibly converts this using DOS-style short mode. 57612 # If so, the updated path is stored in $new_path. 57613 57614 input_path="$new_path" 57615 # Check if we need to convert this using DOS-style short mode. If the path 57616 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57617 # take no chances and rewrite it. 57618 # Note: m4 eats our [], so we need to use [ and ] instead. 57619 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57620 if test "x$has_forbidden_chars" != x; then 57621 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57622 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57623 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57624 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57625 # Going to short mode and back again did indeed matter. Since short mode is 57626 # case insensitive, let's make it lowercase to improve readability. 57627 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57628 # Now convert it back to Unix-style (cygpath) 57629 input_path=`$CYGPATH -u "$shortmode_path"` 57630 new_path="$input_path" 57631 fi 57632 fi 57633 57634 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57635 if test "x$test_cygdrive_prefix" = x; then 57636 # As a simple fix, exclude /usr/bin since it's not a real path. 57637 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57638 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57639 # a path prefixed by /cygdrive for fixpath to work. 57640 new_path="$CYGWIN_ROOT_PATH$input_path" 57641 fi 57642 fi 57643 57644 57645 if test "x$path" != "x$new_path"; then 57646 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57647 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57648 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57649 fi 57650 57651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57652 57653 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57654 has_colon=`$ECHO $path | $GREP ^.:` 57655 new_path="$path" 57656 if test "x$has_colon" = x; then 57657 # Not in mixed or Windows style, start by that. 57658 new_path=`cmd //c echo $path` 57659 fi 57660 57661 57662 input_path="$new_path" 57663 # Check if we need to convert this using DOS-style short mode. If the path 57664 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57665 # take no chances and rewrite it. 57666 # Note: m4 eats our [], so we need to use [ and ] instead. 57667 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57668 if test "x$has_forbidden_chars" != x; then 57669 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57670 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57671 fi 57672 57673 57674 windows_path="$new_path" 57675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57676 unix_path=`$CYGPATH -u "$windows_path"` 57677 new_path="$unix_path" 57678 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57679 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57680 new_path="$unix_path" 57681 fi 57682 57683 if test "x$path" != "x$new_path"; then 57684 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57685 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57686 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57687 fi 57688 57689 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57690 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57691 57692 else 57693 # We're on a unix platform. Hooray! :) 57694 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57695 has_space=`$ECHO "$path" | $GREP " "` 57696 if test "x$has_space" != x; then 57697 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57698 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57699 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57700 fi 57701 57702 # Use eval to expand a potential ~ 57703 eval path="$path" 57704 if test ! -f "$path" && test ! -d "$path"; then 57705 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57706 fi 57707 57708 if test -d "$path"; then 57709 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57710 else 57711 dir="`$DIRNAME "$path"`" 57712 base="`$BASENAME "$path"`" 57713 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57714 fi 57715 fi 57716 fi 57717 57718 57719 # Only process if variable expands to non-empty 57720 57721 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57722 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57723 57724 # Input might be given as Windows format, start by converting to 57725 # unix format. 57726 path="$POTENTIAL_FREETYPE_LIB_PATH" 57727 new_path=`$CYGPATH -u "$path"` 57728 57729 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57730 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57731 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57732 # "foo.exe" is OK but "foo" is an error. 57733 # 57734 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57735 # It is also a way to make sure we got the proper file name for the real test later on. 57736 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57737 if test "x$test_shortpath" = x; then 57738 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57739 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57740 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57741 fi 57742 57743 # Call helper function which possibly converts this using DOS-style short mode. 57744 # If so, the updated path is stored in $new_path. 57745 57746 input_path="$new_path" 57747 # Check if we need to convert this using DOS-style short mode. If the path 57748 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57749 # take no chances and rewrite it. 57750 # Note: m4 eats our [], so we need to use [ and ] instead. 57751 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57752 if test "x$has_forbidden_chars" != x; then 57753 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57754 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57755 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57756 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57757 # Going to short mode and back again did indeed matter. Since short mode is 57758 # case insensitive, let's make it lowercase to improve readability. 57759 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57760 # Now convert it back to Unix-style (cygpath) 57761 input_path=`$CYGPATH -u "$shortmode_path"` 57762 new_path="$input_path" 57763 fi 57764 fi 57765 57766 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57767 if test "x$test_cygdrive_prefix" = x; then 57768 # As a simple fix, exclude /usr/bin since it's not a real path. 57769 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57770 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57771 # a path prefixed by /cygdrive for fixpath to work. 57772 new_path="$CYGWIN_ROOT_PATH$input_path" 57773 fi 57774 fi 57775 57776 57777 if test "x$path" != "x$new_path"; then 57778 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57779 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57780 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57781 fi 57782 57783 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57784 57785 path="$POTENTIAL_FREETYPE_LIB_PATH" 57786 has_colon=`$ECHO $path | $GREP ^.:` 57787 new_path="$path" 57788 if test "x$has_colon" = x; then 57789 # Not in mixed or Windows style, start by that. 57790 new_path=`cmd //c echo $path` 57791 fi 57792 57793 57794 input_path="$new_path" 57795 # Check if we need to convert this using DOS-style short mode. If the path 57796 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57797 # take no chances and rewrite it. 57798 # Note: m4 eats our [], so we need to use [ and ] instead. 57799 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57800 if test "x$has_forbidden_chars" != x; then 57801 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57802 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57803 fi 57804 57805 57806 windows_path="$new_path" 57807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57808 unix_path=`$CYGPATH -u "$windows_path"` 57809 new_path="$unix_path" 57810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57811 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57812 new_path="$unix_path" 57813 fi 57814 57815 if test "x$path" != "x$new_path"; then 57816 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57817 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57818 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57819 fi 57820 57821 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57822 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57823 57824 else 57825 # We're on a unix platform. Hooray! :) 57826 path="$POTENTIAL_FREETYPE_LIB_PATH" 57827 has_space=`$ECHO "$path" | $GREP " "` 57828 if test "x$has_space" != x; then 57829 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57830 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57831 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57832 fi 57833 57834 # Use eval to expand a potential ~ 57835 eval path="$path" 57836 if test ! -f "$path" && test ! -d "$path"; then 57837 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57838 fi 57839 57840 if test -d "$path"; then 57841 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57842 else 57843 dir="`$DIRNAME "$path"`" 57844 base="`$BASENAME "$path"`" 57845 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57846 fi 57847 fi 57848 fi 57849 57850 57851 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57853 $as_echo_n "checking for freetype includes... " >&6; } 57854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57855 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57856 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57858 $as_echo_n "checking for freetype libraries... " >&6; } 57859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57860 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57861 fi 57862 57863 if test "x$FOUND_FREETYPE" != xyes; then 57864 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 57865 fi 57866 else 57867 # User specified only one of lib or include. This is an error. 57868 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 57869 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 57870 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 57871 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57872 else 57873 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 57874 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 57875 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57876 fi 57877 fi 57878 else 57879 # User did not specify settings, but we need freetype. Try to locate it. 57880 57881 if test "x$BUNDLE_FREETYPE" = x; then 57882 # If not specified, default is to bundle freetype only on windows 57883 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57884 BUNDLE_FREETYPE=yes 57885 else 57886 BUNDLE_FREETYPE=no 57887 fi 57888 fi 57889 57890 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 57891 if test "x$SYSROOT" = x; then 57892 if test "x$FOUND_FREETYPE" != xyes; then 57893 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 57894 if test "x$PKG_CONFIG" != x; then 57895 57896 pkg_failed=no 57897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 57898 $as_echo_n "checking for FREETYPE... " >&6; } 57899 57900 if test -n "$FREETYPE_CFLAGS"; then 57901 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 57902 elif test -n "$PKG_CONFIG"; then 57903 if test -n "$PKG_CONFIG" && \ 57904 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57905 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57906 ac_status=$? 57907 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57908 test $ac_status = 0; }; then 57909 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 57910 else 57911 pkg_failed=yes 57912 fi 57913 else 57914 pkg_failed=untried 57915 fi 57916 if test -n "$FREETYPE_LIBS"; then 57917 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 57918 elif test -n "$PKG_CONFIG"; then 57919 if test -n "$PKG_CONFIG" && \ 57920 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57921 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57922 ac_status=$? 57923 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57924 test $ac_status = 0; }; then 57925 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 57926 else 57927 pkg_failed=yes 57928 fi 57929 else 57930 pkg_failed=untried 57931 fi 57932 57933 57934 57935 if test $pkg_failed = yes; then 57936 57937 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57938 _pkg_short_errors_supported=yes 57939 else 57940 _pkg_short_errors_supported=no 57941 fi 57942 if test $_pkg_short_errors_supported = yes; then 57943 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 57944 else 57945 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 57946 fi 57947 # Put the nasty error message in config.log where it belongs 57948 echo "$FREETYPE_PKG_ERRORS" >&5 57949 57950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57951 $as_echo "no" >&6; } 57952 FOUND_FREETYPE=no 57953 elif test $pkg_failed = untried; then 57954 FOUND_FREETYPE=no 57955 else 57956 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 57957 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 57958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57959 $as_echo "yes" >&6; } 57960 FOUND_FREETYPE=yes 57961 fi 57962 if test "x$FOUND_FREETYPE" = xyes; then 57963 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 57964 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 57965 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 57966 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 57967 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 57968 fi 57969 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 57970 if test "x$BUNDLE_FREETYPE" = xyes; then 57971 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 57972 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 57973 FOUND_FREETYPE=no 57974 else 57975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 57976 $as_echo_n "checking for freetype... " >&6; } 57977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 57978 $as_echo "yes (using pkg-config)" >&6; } 57979 fi 57980 fi 57981 fi 57982 fi 57983 fi 57984 57985 if test "x$FOUND_FREETYPE" != xyes; then 57986 # Check in well-known locations 57987 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57988 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 57989 57990 windows_path="$FREETYPE_BASE_DIR" 57991 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57992 unix_path=`$CYGPATH -u "$windows_path"` 57993 FREETYPE_BASE_DIR="$unix_path" 57994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57995 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57996 FREETYPE_BASE_DIR="$unix_path" 57997 fi 57998 57999 58000 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58001 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58002 METHOD="well-known location" 58003 58004 # Let's start with an optimistic view of the world :-) 58005 FOUND_FREETYPE=yes 58006 58007 # First look for the canonical freetype main include file ft2build.h. 58008 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58009 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58010 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58011 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58012 # Fail. 58013 FOUND_FREETYPE=no 58014 fi 58015 fi 58016 58017 if test "x$FOUND_FREETYPE" = xyes; then 58018 # Include file found, let's continue the sanity check. 58019 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58020 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58021 58022 # Reset to default value 58023 FREETYPE_BASE_NAME=freetype 58024 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58025 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58026 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58027 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58028 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58029 # for the .6 version explicitly. 58030 FREETYPE_BASE_NAME=freetype.6 58031 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58032 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58033 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58034 else 58035 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58036 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58037 FOUND_FREETYPE=no 58038 fi 58039 else 58040 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58041 # On Windows, we will need both .lib and .dll file. 58042 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58043 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58044 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58045 FOUND_FREETYPE=no 58046 fi 58047 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58048 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58049 # Found lib in isa dir, use that instead. 58050 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58051 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58052 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58053 fi 58054 fi 58055 fi 58056 58057 if test "x$FOUND_FREETYPE" = xyes; then 58058 58059 # Only process if variable expands to non-empty 58060 58061 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58062 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58063 58064 # Input might be given as Windows format, start by converting to 58065 # unix format. 58066 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58067 new_path=`$CYGPATH -u "$path"` 58068 58069 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58070 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58071 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58072 # "foo.exe" is OK but "foo" is an error. 58073 # 58074 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58075 # It is also a way to make sure we got the proper file name for the real test later on. 58076 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58077 if test "x$test_shortpath" = x; then 58078 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58079 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58080 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58081 fi 58082 58083 # Call helper function which possibly converts this using DOS-style short mode. 58084 # If so, the updated path is stored in $new_path. 58085 58086 input_path="$new_path" 58087 # Check if we need to convert this using DOS-style short mode. If the path 58088 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58089 # take no chances and rewrite it. 58090 # Note: m4 eats our [], so we need to use [ and ] instead. 58091 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58092 if test "x$has_forbidden_chars" != x; then 58093 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58094 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58095 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58096 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58097 # Going to short mode and back again did indeed matter. Since short mode is 58098 # case insensitive, let's make it lowercase to improve readability. 58099 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58100 # Now convert it back to Unix-style (cygpath) 58101 input_path=`$CYGPATH -u "$shortmode_path"` 58102 new_path="$input_path" 58103 fi 58104 fi 58105 58106 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58107 if test "x$test_cygdrive_prefix" = x; then 58108 # As a simple fix, exclude /usr/bin since it's not a real path. 58109 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58110 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58111 # a path prefixed by /cygdrive for fixpath to work. 58112 new_path="$CYGWIN_ROOT_PATH$input_path" 58113 fi 58114 fi 58115 58116 58117 if test "x$path" != "x$new_path"; then 58118 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58119 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58120 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58121 fi 58122 58123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58124 58125 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58126 has_colon=`$ECHO $path | $GREP ^.:` 58127 new_path="$path" 58128 if test "x$has_colon" = x; then 58129 # Not in mixed or Windows style, start by that. 58130 new_path=`cmd //c echo $path` 58131 fi 58132 58133 58134 input_path="$new_path" 58135 # Check if we need to convert this using DOS-style short mode. If the path 58136 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58137 # take no chances and rewrite it. 58138 # Note: m4 eats our [], so we need to use [ and ] instead. 58139 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58140 if test "x$has_forbidden_chars" != x; then 58141 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58142 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58143 fi 58144 58145 58146 windows_path="$new_path" 58147 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58148 unix_path=`$CYGPATH -u "$windows_path"` 58149 new_path="$unix_path" 58150 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58151 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58152 new_path="$unix_path" 58153 fi 58154 58155 if test "x$path" != "x$new_path"; then 58156 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58157 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58158 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58159 fi 58160 58161 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58162 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58163 58164 else 58165 # We're on a unix platform. Hooray! :) 58166 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58167 has_space=`$ECHO "$path" | $GREP " "` 58168 if test "x$has_space" != x; then 58169 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58170 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58171 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58172 fi 58173 58174 # Use eval to expand a potential ~ 58175 eval path="$path" 58176 if test ! -f "$path" && test ! -d "$path"; then 58177 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58178 fi 58179 58180 if test -d "$path"; then 58181 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58182 else 58183 dir="`$DIRNAME "$path"`" 58184 base="`$BASENAME "$path"`" 58185 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58186 fi 58187 fi 58188 fi 58189 58190 58191 # Only process if variable expands to non-empty 58192 58193 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58194 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58195 58196 # Input might be given as Windows format, start by converting to 58197 # unix format. 58198 path="$POTENTIAL_FREETYPE_LIB_PATH" 58199 new_path=`$CYGPATH -u "$path"` 58200 58201 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58202 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58203 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58204 # "foo.exe" is OK but "foo" is an error. 58205 # 58206 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58207 # It is also a way to make sure we got the proper file name for the real test later on. 58208 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58209 if test "x$test_shortpath" = x; then 58210 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58211 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58212 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58213 fi 58214 58215 # Call helper function which possibly converts this using DOS-style short mode. 58216 # If so, the updated path is stored in $new_path. 58217 58218 input_path="$new_path" 58219 # Check if we need to convert this using DOS-style short mode. If the path 58220 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58221 # take no chances and rewrite it. 58222 # Note: m4 eats our [], so we need to use [ and ] instead. 58223 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58224 if test "x$has_forbidden_chars" != x; then 58225 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58226 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58227 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58228 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58229 # Going to short mode and back again did indeed matter. Since short mode is 58230 # case insensitive, let's make it lowercase to improve readability. 58231 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58232 # Now convert it back to Unix-style (cygpath) 58233 input_path=`$CYGPATH -u "$shortmode_path"` 58234 new_path="$input_path" 58235 fi 58236 fi 58237 58238 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58239 if test "x$test_cygdrive_prefix" = x; then 58240 # As a simple fix, exclude /usr/bin since it's not a real path. 58241 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58242 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58243 # a path prefixed by /cygdrive for fixpath to work. 58244 new_path="$CYGWIN_ROOT_PATH$input_path" 58245 fi 58246 fi 58247 58248 58249 if test "x$path" != "x$new_path"; then 58250 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58251 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58252 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58253 fi 58254 58255 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58256 58257 path="$POTENTIAL_FREETYPE_LIB_PATH" 58258 has_colon=`$ECHO $path | $GREP ^.:` 58259 new_path="$path" 58260 if test "x$has_colon" = x; then 58261 # Not in mixed or Windows style, start by that. 58262 new_path=`cmd //c echo $path` 58263 fi 58264 58265 58266 input_path="$new_path" 58267 # Check if we need to convert this using DOS-style short mode. If the path 58268 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58269 # take no chances and rewrite it. 58270 # Note: m4 eats our [], so we need to use [ and ] instead. 58271 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58272 if test "x$has_forbidden_chars" != x; then 58273 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58274 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58275 fi 58276 58277 58278 windows_path="$new_path" 58279 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58280 unix_path=`$CYGPATH -u "$windows_path"` 58281 new_path="$unix_path" 58282 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58283 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58284 new_path="$unix_path" 58285 fi 58286 58287 if test "x$path" != "x$new_path"; then 58288 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58289 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58290 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58291 fi 58292 58293 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58294 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58295 58296 else 58297 # We're on a unix platform. Hooray! :) 58298 path="$POTENTIAL_FREETYPE_LIB_PATH" 58299 has_space=`$ECHO "$path" | $GREP " "` 58300 if test "x$has_space" != x; then 58301 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58302 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58303 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58304 fi 58305 58306 # Use eval to expand a potential ~ 58307 eval path="$path" 58308 if test ! -f "$path" && test ! -d "$path"; then 58309 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58310 fi 58311 58312 if test -d "$path"; then 58313 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58314 else 58315 dir="`$DIRNAME "$path"`" 58316 base="`$BASENAME "$path"`" 58317 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58318 fi 58319 fi 58320 fi 58321 58322 58323 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58325 $as_echo_n "checking for freetype includes... " >&6; } 58326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58327 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58328 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58330 $as_echo_n "checking for freetype libraries... " >&6; } 58331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58332 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58333 fi 58334 58335 if test "x$FOUND_FREETYPE" != xyes; then 58336 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 58337 58338 windows_path="$FREETYPE_BASE_DIR" 58339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58340 unix_path=`$CYGPATH -u "$windows_path"` 58341 FREETYPE_BASE_DIR="$unix_path" 58342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58344 FREETYPE_BASE_DIR="$unix_path" 58345 fi 58346 58347 58348 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58349 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58350 METHOD="well-known location" 58351 58352 # Let's start with an optimistic view of the world :-) 58353 FOUND_FREETYPE=yes 58354 58355 # First look for the canonical freetype main include file ft2build.h. 58356 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58357 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58358 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58359 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58360 # Fail. 58361 FOUND_FREETYPE=no 58362 fi 58363 fi 58364 58365 if test "x$FOUND_FREETYPE" = xyes; then 58366 # Include file found, let's continue the sanity check. 58367 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58368 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58369 58370 # Reset to default value 58371 FREETYPE_BASE_NAME=freetype 58372 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58373 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58374 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58375 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58376 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58377 # for the .6 version explicitly. 58378 FREETYPE_BASE_NAME=freetype.6 58379 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58380 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58381 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58382 else 58383 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58384 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58385 FOUND_FREETYPE=no 58386 fi 58387 else 58388 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58389 # On Windows, we will need both .lib and .dll file. 58390 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58391 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58392 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58393 FOUND_FREETYPE=no 58394 fi 58395 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58396 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58397 # Found lib in isa dir, use that instead. 58398 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58399 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58400 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58401 fi 58402 fi 58403 fi 58404 58405 if test "x$FOUND_FREETYPE" = xyes; then 58406 58407 # Only process if variable expands to non-empty 58408 58409 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58410 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58411 58412 # Input might be given as Windows format, start by converting to 58413 # unix format. 58414 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58415 new_path=`$CYGPATH -u "$path"` 58416 58417 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58418 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58419 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58420 # "foo.exe" is OK but "foo" is an error. 58421 # 58422 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58423 # It is also a way to make sure we got the proper file name for the real test later on. 58424 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58425 if test "x$test_shortpath" = x; then 58426 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58427 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58428 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58429 fi 58430 58431 # Call helper function which possibly converts this using DOS-style short mode. 58432 # If so, the updated path is stored in $new_path. 58433 58434 input_path="$new_path" 58435 # Check if we need to convert this using DOS-style short mode. If the path 58436 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58437 # take no chances and rewrite it. 58438 # Note: m4 eats our [], so we need to use [ and ] instead. 58439 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58440 if test "x$has_forbidden_chars" != x; then 58441 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58442 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58443 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58444 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58445 # Going to short mode and back again did indeed matter. Since short mode is 58446 # case insensitive, let's make it lowercase to improve readability. 58447 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58448 # Now convert it back to Unix-style (cygpath) 58449 input_path=`$CYGPATH -u "$shortmode_path"` 58450 new_path="$input_path" 58451 fi 58452 fi 58453 58454 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58455 if test "x$test_cygdrive_prefix" = x; then 58456 # As a simple fix, exclude /usr/bin since it's not a real path. 58457 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58458 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58459 # a path prefixed by /cygdrive for fixpath to work. 58460 new_path="$CYGWIN_ROOT_PATH$input_path" 58461 fi 58462 fi 58463 58464 58465 if test "x$path" != "x$new_path"; then 58466 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58467 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58468 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58469 fi 58470 58471 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58472 58473 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58474 has_colon=`$ECHO $path | $GREP ^.:` 58475 new_path="$path" 58476 if test "x$has_colon" = x; then 58477 # Not in mixed or Windows style, start by that. 58478 new_path=`cmd //c echo $path` 58479 fi 58480 58481 58482 input_path="$new_path" 58483 # Check if we need to convert this using DOS-style short mode. If the path 58484 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58485 # take no chances and rewrite it. 58486 # Note: m4 eats our [], so we need to use [ and ] instead. 58487 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58488 if test "x$has_forbidden_chars" != x; then 58489 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58490 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58491 fi 58492 58493 58494 windows_path="$new_path" 58495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58496 unix_path=`$CYGPATH -u "$windows_path"` 58497 new_path="$unix_path" 58498 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58499 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58500 new_path="$unix_path" 58501 fi 58502 58503 if test "x$path" != "x$new_path"; then 58504 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58505 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58506 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58507 fi 58508 58509 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58510 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58511 58512 else 58513 # We're on a unix platform. Hooray! :) 58514 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58515 has_space=`$ECHO "$path" | $GREP " "` 58516 if test "x$has_space" != x; then 58517 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58518 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58519 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58520 fi 58521 58522 # Use eval to expand a potential ~ 58523 eval path="$path" 58524 if test ! -f "$path" && test ! -d "$path"; then 58525 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58526 fi 58527 58528 if test -d "$path"; then 58529 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58530 else 58531 dir="`$DIRNAME "$path"`" 58532 base="`$BASENAME "$path"`" 58533 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58534 fi 58535 fi 58536 fi 58537 58538 58539 # Only process if variable expands to non-empty 58540 58541 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58542 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58543 58544 # Input might be given as Windows format, start by converting to 58545 # unix format. 58546 path="$POTENTIAL_FREETYPE_LIB_PATH" 58547 new_path=`$CYGPATH -u "$path"` 58548 58549 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58550 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58551 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58552 # "foo.exe" is OK but "foo" is an error. 58553 # 58554 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58555 # It is also a way to make sure we got the proper file name for the real test later on. 58556 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58557 if test "x$test_shortpath" = x; then 58558 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58559 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58560 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58561 fi 58562 58563 # Call helper function which possibly converts this using DOS-style short mode. 58564 # If so, the updated path is stored in $new_path. 58565 58566 input_path="$new_path" 58567 # Check if we need to convert this using DOS-style short mode. If the path 58568 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58569 # take no chances and rewrite it. 58570 # Note: m4 eats our [], so we need to use [ and ] instead. 58571 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58572 if test "x$has_forbidden_chars" != x; then 58573 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58574 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58575 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58576 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58577 # Going to short mode and back again did indeed matter. Since short mode is 58578 # case insensitive, let's make it lowercase to improve readability. 58579 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58580 # Now convert it back to Unix-style (cygpath) 58581 input_path=`$CYGPATH -u "$shortmode_path"` 58582 new_path="$input_path" 58583 fi 58584 fi 58585 58586 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58587 if test "x$test_cygdrive_prefix" = x; then 58588 # As a simple fix, exclude /usr/bin since it's not a real path. 58589 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58590 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58591 # a path prefixed by /cygdrive for fixpath to work. 58592 new_path="$CYGWIN_ROOT_PATH$input_path" 58593 fi 58594 fi 58595 58596 58597 if test "x$path" != "x$new_path"; then 58598 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58599 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58600 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58601 fi 58602 58603 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58604 58605 path="$POTENTIAL_FREETYPE_LIB_PATH" 58606 has_colon=`$ECHO $path | $GREP ^.:` 58607 new_path="$path" 58608 if test "x$has_colon" = x; then 58609 # Not in mixed or Windows style, start by that. 58610 new_path=`cmd //c echo $path` 58611 fi 58612 58613 58614 input_path="$new_path" 58615 # Check if we need to convert this using DOS-style short mode. If the path 58616 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58617 # take no chances and rewrite it. 58618 # Note: m4 eats our [], so we need to use [ and ] instead. 58619 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58620 if test "x$has_forbidden_chars" != x; then 58621 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58622 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58623 fi 58624 58625 58626 windows_path="$new_path" 58627 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58628 unix_path=`$CYGPATH -u "$windows_path"` 58629 new_path="$unix_path" 58630 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58631 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58632 new_path="$unix_path" 58633 fi 58634 58635 if test "x$path" != "x$new_path"; then 58636 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58637 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58638 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58639 fi 58640 58641 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58642 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58643 58644 else 58645 # We're on a unix platform. Hooray! :) 58646 path="$POTENTIAL_FREETYPE_LIB_PATH" 58647 has_space=`$ECHO "$path" | $GREP " "` 58648 if test "x$has_space" != x; then 58649 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58650 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58651 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58652 fi 58653 58654 # Use eval to expand a potential ~ 58655 eval path="$path" 58656 if test ! -f "$path" && test ! -d "$path"; then 58657 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58658 fi 58659 58660 if test -d "$path"; then 58661 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58662 else 58663 dir="`$DIRNAME "$path"`" 58664 base="`$BASENAME "$path"`" 58665 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58666 fi 58667 fi 58668 fi 58669 58670 58671 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58673 $as_echo_n "checking for freetype includes... " >&6; } 58674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58675 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58676 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58678 $as_echo_n "checking for freetype libraries... " >&6; } 58679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58680 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58681 fi 58682 58683 fi 58684 if test "x$FOUND_FREETYPE" != xyes; then 58685 FREETYPE_BASE_DIR="$HOME/freetype" 58686 58687 windows_path="$FREETYPE_BASE_DIR" 58688 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58689 unix_path=`$CYGPATH -u "$windows_path"` 58690 FREETYPE_BASE_DIR="$unix_path" 58691 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58692 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58693 FREETYPE_BASE_DIR="$unix_path" 58694 fi 58695 58696 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58697 58698 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58699 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 58700 METHOD="well-known location" 58701 58702 # Let's start with an optimistic view of the world :-) 58703 FOUND_FREETYPE=yes 58704 58705 # First look for the canonical freetype main include file ft2build.h. 58706 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58707 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58708 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58709 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58710 # Fail. 58711 FOUND_FREETYPE=no 58712 fi 58713 fi 58714 58715 if test "x$FOUND_FREETYPE" = xyes; then 58716 # Include file found, let's continue the sanity check. 58717 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58718 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58719 58720 # Reset to default value 58721 FREETYPE_BASE_NAME=freetype 58722 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58723 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58724 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58725 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58726 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58727 # for the .6 version explicitly. 58728 FREETYPE_BASE_NAME=freetype.6 58729 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58730 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58731 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58732 else 58733 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58734 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58735 FOUND_FREETYPE=no 58736 fi 58737 else 58738 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58739 # On Windows, we will need both .lib and .dll file. 58740 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58741 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58742 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58743 FOUND_FREETYPE=no 58744 fi 58745 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58746 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58747 # Found lib in isa dir, use that instead. 58748 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58749 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58750 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58751 fi 58752 fi 58753 fi 58754 58755 if test "x$FOUND_FREETYPE" = xyes; then 58756 58757 # Only process if variable expands to non-empty 58758 58759 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58760 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58761 58762 # Input might be given as Windows format, start by converting to 58763 # unix format. 58764 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58765 new_path=`$CYGPATH -u "$path"` 58766 58767 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58768 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58769 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58770 # "foo.exe" is OK but "foo" is an error. 58771 # 58772 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58773 # It is also a way to make sure we got the proper file name for the real test later on. 58774 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58775 if test "x$test_shortpath" = x; then 58776 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58777 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58778 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58779 fi 58780 58781 # Call helper function which possibly converts this using DOS-style short mode. 58782 # If so, the updated path is stored in $new_path. 58783 58784 input_path="$new_path" 58785 # Check if we need to convert this using DOS-style short mode. If the path 58786 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58787 # take no chances and rewrite it. 58788 # Note: m4 eats our [], so we need to use [ and ] instead. 58789 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58790 if test "x$has_forbidden_chars" != x; then 58791 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58792 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58793 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58794 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58795 # Going to short mode and back again did indeed matter. Since short mode is 58796 # case insensitive, let's make it lowercase to improve readability. 58797 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58798 # Now convert it back to Unix-style (cygpath) 58799 input_path=`$CYGPATH -u "$shortmode_path"` 58800 new_path="$input_path" 58801 fi 58802 fi 58803 58804 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58805 if test "x$test_cygdrive_prefix" = x; then 58806 # As a simple fix, exclude /usr/bin since it's not a real path. 58807 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58808 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58809 # a path prefixed by /cygdrive for fixpath to work. 58810 new_path="$CYGWIN_ROOT_PATH$input_path" 58811 fi 58812 fi 58813 58814 58815 if test "x$path" != "x$new_path"; then 58816 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58817 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58818 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58819 fi 58820 58821 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58822 58823 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58824 has_colon=`$ECHO $path | $GREP ^.:` 58825 new_path="$path" 58826 if test "x$has_colon" = x; then 58827 # Not in mixed or Windows style, start by that. 58828 new_path=`cmd //c echo $path` 58829 fi 58830 58831 58832 input_path="$new_path" 58833 # Check if we need to convert this using DOS-style short mode. If the path 58834 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58835 # take no chances and rewrite it. 58836 # Note: m4 eats our [], so we need to use [ and ] instead. 58837 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58838 if test "x$has_forbidden_chars" != x; then 58839 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58840 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58841 fi 58842 58843 58844 windows_path="$new_path" 58845 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58846 unix_path=`$CYGPATH -u "$windows_path"` 58847 new_path="$unix_path" 58848 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58849 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58850 new_path="$unix_path" 58851 fi 58852 58853 if test "x$path" != "x$new_path"; then 58854 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58855 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58856 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58857 fi 58858 58859 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58860 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58861 58862 else 58863 # We're on a unix platform. Hooray! :) 58864 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58865 has_space=`$ECHO "$path" | $GREP " "` 58866 if test "x$has_space" != x; then 58867 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58868 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58869 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58870 fi 58871 58872 # Use eval to expand a potential ~ 58873 eval path="$path" 58874 if test ! -f "$path" && test ! -d "$path"; then 58875 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58876 fi 58877 58878 if test -d "$path"; then 58879 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58880 else 58881 dir="`$DIRNAME "$path"`" 58882 base="`$BASENAME "$path"`" 58883 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58884 fi 58885 fi 58886 fi 58887 58888 58889 # Only process if variable expands to non-empty 58890 58891 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58892 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58893 58894 # Input might be given as Windows format, start by converting to 58895 # unix format. 58896 path="$POTENTIAL_FREETYPE_LIB_PATH" 58897 new_path=`$CYGPATH -u "$path"` 58898 58899 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58900 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58901 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58902 # "foo.exe" is OK but "foo" is an error. 58903 # 58904 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58905 # It is also a way to make sure we got the proper file name for the real test later on. 58906 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58907 if test "x$test_shortpath" = x; then 58908 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58909 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58910 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58911 fi 58912 58913 # Call helper function which possibly converts this using DOS-style short mode. 58914 # If so, the updated path is stored in $new_path. 58915 58916 input_path="$new_path" 58917 # Check if we need to convert this using DOS-style short mode. If the path 58918 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58919 # take no chances and rewrite it. 58920 # Note: m4 eats our [], so we need to use [ and ] instead. 58921 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58922 if test "x$has_forbidden_chars" != x; then 58923 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58924 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58925 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58926 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58927 # Going to short mode and back again did indeed matter. Since short mode is 58928 # case insensitive, let's make it lowercase to improve readability. 58929 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58930 # Now convert it back to Unix-style (cygpath) 58931 input_path=`$CYGPATH -u "$shortmode_path"` 58932 new_path="$input_path" 58933 fi 58934 fi 58935 58936 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58937 if test "x$test_cygdrive_prefix" = x; then 58938 # As a simple fix, exclude /usr/bin since it's not a real path. 58939 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58940 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58941 # a path prefixed by /cygdrive for fixpath to work. 58942 new_path="$CYGWIN_ROOT_PATH$input_path" 58943 fi 58944 fi 58945 58946 58947 if test "x$path" != "x$new_path"; then 58948 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58949 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58950 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58951 fi 58952 58953 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58954 58955 path="$POTENTIAL_FREETYPE_LIB_PATH" 58956 has_colon=`$ECHO $path | $GREP ^.:` 58957 new_path="$path" 58958 if test "x$has_colon" = x; then 58959 # Not in mixed or Windows style, start by that. 58960 new_path=`cmd //c echo $path` 58961 fi 58962 58963 58964 input_path="$new_path" 58965 # Check if we need to convert this using DOS-style short mode. If the path 58966 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58967 # take no chances and rewrite it. 58968 # Note: m4 eats our [], so we need to use [ and ] instead. 58969 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58970 if test "x$has_forbidden_chars" != x; then 58971 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58972 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58973 fi 58974 58975 58976 windows_path="$new_path" 58977 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58978 unix_path=`$CYGPATH -u "$windows_path"` 58979 new_path="$unix_path" 58980 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58981 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58982 new_path="$unix_path" 58983 fi 58984 58985 if test "x$path" != "x$new_path"; then 58986 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58987 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58988 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58989 fi 58990 58991 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58992 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58993 58994 else 58995 # We're on a unix platform. Hooray! :) 58996 path="$POTENTIAL_FREETYPE_LIB_PATH" 58997 has_space=`$ECHO "$path" | $GREP " "` 58998 if test "x$has_space" != x; then 58999 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59000 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59001 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59002 fi 59003 59004 # Use eval to expand a potential ~ 59005 eval path="$path" 59006 if test ! -f "$path" && test ! -d "$path"; then 59007 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59008 fi 59009 59010 if test -d "$path"; then 59011 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59012 else 59013 dir="`$DIRNAME "$path"`" 59014 base="`$BASENAME "$path"`" 59015 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59016 fi 59017 fi 59018 fi 59019 59020 59021 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59023 $as_echo_n "checking for freetype includes... " >&6; } 59024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59025 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59026 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59028 $as_echo_n "checking for freetype libraries... " >&6; } 59029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59030 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59031 fi 59032 59033 else 59034 59035 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59036 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59037 METHOD="well-known location" 59038 59039 # Let's start with an optimistic view of the world :-) 59040 FOUND_FREETYPE=yes 59041 59042 # First look for the canonical freetype main include file ft2build.h. 59043 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59044 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59045 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59046 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59047 # Fail. 59048 FOUND_FREETYPE=no 59049 fi 59050 fi 59051 59052 if test "x$FOUND_FREETYPE" = xyes; then 59053 # Include file found, let's continue the sanity check. 59054 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59055 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59056 59057 # Reset to default value 59058 FREETYPE_BASE_NAME=freetype 59059 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59060 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59061 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59062 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59063 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59064 # for the .6 version explicitly. 59065 FREETYPE_BASE_NAME=freetype.6 59066 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59067 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59068 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59069 else 59070 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59071 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59072 FOUND_FREETYPE=no 59073 fi 59074 else 59075 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59076 # On Windows, we will need both .lib and .dll file. 59077 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59078 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59079 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59080 FOUND_FREETYPE=no 59081 fi 59082 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59083 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59084 # Found lib in isa dir, use that instead. 59085 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59086 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59087 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59088 fi 59089 fi 59090 fi 59091 59092 if test "x$FOUND_FREETYPE" = xyes; then 59093 59094 # Only process if variable expands to non-empty 59095 59096 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59097 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59098 59099 # Input might be given as Windows format, start by converting to 59100 # unix format. 59101 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59102 new_path=`$CYGPATH -u "$path"` 59103 59104 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59105 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59106 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59107 # "foo.exe" is OK but "foo" is an error. 59108 # 59109 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59110 # It is also a way to make sure we got the proper file name for the real test later on. 59111 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59112 if test "x$test_shortpath" = x; then 59113 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59114 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59115 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59116 fi 59117 59118 # Call helper function which possibly converts this using DOS-style short mode. 59119 # If so, the updated path is stored in $new_path. 59120 59121 input_path="$new_path" 59122 # Check if we need to convert this using DOS-style short mode. If the path 59123 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59124 # take no chances and rewrite it. 59125 # Note: m4 eats our [], so we need to use [ and ] instead. 59126 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59127 if test "x$has_forbidden_chars" != x; then 59128 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59129 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59130 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59131 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59132 # Going to short mode and back again did indeed matter. Since short mode is 59133 # case insensitive, let's make it lowercase to improve readability. 59134 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59135 # Now convert it back to Unix-style (cygpath) 59136 input_path=`$CYGPATH -u "$shortmode_path"` 59137 new_path="$input_path" 59138 fi 59139 fi 59140 59141 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59142 if test "x$test_cygdrive_prefix" = x; then 59143 # As a simple fix, exclude /usr/bin since it's not a real path. 59144 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59145 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59146 # a path prefixed by /cygdrive for fixpath to work. 59147 new_path="$CYGWIN_ROOT_PATH$input_path" 59148 fi 59149 fi 59150 59151 59152 if test "x$path" != "x$new_path"; then 59153 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59154 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59155 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59156 fi 59157 59158 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59159 59160 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59161 has_colon=`$ECHO $path | $GREP ^.:` 59162 new_path="$path" 59163 if test "x$has_colon" = x; then 59164 # Not in mixed or Windows style, start by that. 59165 new_path=`cmd //c echo $path` 59166 fi 59167 59168 59169 input_path="$new_path" 59170 # Check if we need to convert this using DOS-style short mode. If the path 59171 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59172 # take no chances and rewrite it. 59173 # Note: m4 eats our [], so we need to use [ and ] instead. 59174 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59175 if test "x$has_forbidden_chars" != x; then 59176 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59177 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59178 fi 59179 59180 59181 windows_path="$new_path" 59182 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59183 unix_path=`$CYGPATH -u "$windows_path"` 59184 new_path="$unix_path" 59185 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59186 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59187 new_path="$unix_path" 59188 fi 59189 59190 if test "x$path" != "x$new_path"; then 59191 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59192 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59193 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59194 fi 59195 59196 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59197 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59198 59199 else 59200 # We're on a unix platform. Hooray! :) 59201 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59202 has_space=`$ECHO "$path" | $GREP " "` 59203 if test "x$has_space" != x; then 59204 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59205 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59206 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59207 fi 59208 59209 # Use eval to expand a potential ~ 59210 eval path="$path" 59211 if test ! -f "$path" && test ! -d "$path"; then 59212 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59213 fi 59214 59215 if test -d "$path"; then 59216 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59217 else 59218 dir="`$DIRNAME "$path"`" 59219 base="`$BASENAME "$path"`" 59220 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59221 fi 59222 fi 59223 fi 59224 59225 59226 # Only process if variable expands to non-empty 59227 59228 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59230 59231 # Input might be given as Windows format, start by converting to 59232 # unix format. 59233 path="$POTENTIAL_FREETYPE_LIB_PATH" 59234 new_path=`$CYGPATH -u "$path"` 59235 59236 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59237 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59238 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59239 # "foo.exe" is OK but "foo" is an error. 59240 # 59241 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59242 # It is also a way to make sure we got the proper file name for the real test later on. 59243 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59244 if test "x$test_shortpath" = x; then 59245 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59246 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59247 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59248 fi 59249 59250 # Call helper function which possibly converts this using DOS-style short mode. 59251 # If so, the updated path is stored in $new_path. 59252 59253 input_path="$new_path" 59254 # Check if we need to convert this using DOS-style short mode. If the path 59255 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59256 # take no chances and rewrite it. 59257 # Note: m4 eats our [], so we need to use [ and ] instead. 59258 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59259 if test "x$has_forbidden_chars" != x; then 59260 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59261 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59262 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59263 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59264 # Going to short mode and back again did indeed matter. Since short mode is 59265 # case insensitive, let's make it lowercase to improve readability. 59266 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59267 # Now convert it back to Unix-style (cygpath) 59268 input_path=`$CYGPATH -u "$shortmode_path"` 59269 new_path="$input_path" 59270 fi 59271 fi 59272 59273 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59274 if test "x$test_cygdrive_prefix" = x; then 59275 # As a simple fix, exclude /usr/bin since it's not a real path. 59276 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59277 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59278 # a path prefixed by /cygdrive for fixpath to work. 59279 new_path="$CYGWIN_ROOT_PATH$input_path" 59280 fi 59281 fi 59282 59283 59284 if test "x$path" != "x$new_path"; then 59285 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59286 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59287 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59288 fi 59289 59290 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59291 59292 path="$POTENTIAL_FREETYPE_LIB_PATH" 59293 has_colon=`$ECHO $path | $GREP ^.:` 59294 new_path="$path" 59295 if test "x$has_colon" = x; then 59296 # Not in mixed or Windows style, start by that. 59297 new_path=`cmd //c echo $path` 59298 fi 59299 59300 59301 input_path="$new_path" 59302 # Check if we need to convert this using DOS-style short mode. If the path 59303 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59304 # take no chances and rewrite it. 59305 # Note: m4 eats our [], so we need to use [ and ] instead. 59306 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59307 if test "x$has_forbidden_chars" != x; then 59308 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59309 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59310 fi 59311 59312 59313 windows_path="$new_path" 59314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59315 unix_path=`$CYGPATH -u "$windows_path"` 59316 new_path="$unix_path" 59317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59319 new_path="$unix_path" 59320 fi 59321 59322 if test "x$path" != "x$new_path"; then 59323 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59324 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59325 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59326 fi 59327 59328 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59329 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59330 59331 else 59332 # We're on a unix platform. Hooray! :) 59333 path="$POTENTIAL_FREETYPE_LIB_PATH" 59334 has_space=`$ECHO "$path" | $GREP " "` 59335 if test "x$has_space" != x; then 59336 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59337 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59338 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59339 fi 59340 59341 # Use eval to expand a potential ~ 59342 eval path="$path" 59343 if test ! -f "$path" && test ! -d "$path"; then 59344 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59345 fi 59346 59347 if test -d "$path"; then 59348 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59349 else 59350 dir="`$DIRNAME "$path"`" 59351 base="`$BASENAME "$path"`" 59352 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59353 fi 59354 fi 59355 fi 59356 59357 59358 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59360 $as_echo_n "checking for freetype includes... " >&6; } 59361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59362 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59363 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59365 $as_echo_n "checking for freetype libraries... " >&6; } 59366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59367 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59368 fi 59369 59370 fi 59371 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 59372 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 59373 # Source is available, as a last resort try to build freetype in default location 59374 59375 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 59376 BUILD_FREETYPE=yes 59377 59378 # Check if the freetype sources are acessible.. 59379 if ! test -d $FREETYPE_SRC_PATH; then 59380 { $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 59381 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 59382 BUILD_FREETYPE=no 59383 fi 59384 # ..and contain a vc2010 project file 59385 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 59386 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 59387 { $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 59388 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 59389 BUILD_FREETYPE=no 59390 fi 59391 # Now check if configure found a version of 'msbuild.exe' 59392 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 59393 { $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 59394 $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;} 59395 BUILD_FREETYPE=no 59396 fi 59397 59398 # Ready to go.. 59399 if test "x$BUILD_FREETYPE" = xyes; then 59400 # msbuild requires trailing slashes for output directories 59401 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 59402 freetype_lib_path_unix="$freetype_lib_path" 59403 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 59404 59405 unix_path="$vcxproj_path" 59406 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59407 windows_path=`$CYGPATH -m "$unix_path"` 59408 vcxproj_path="$windows_path" 59409 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59410 windows_path=`cmd //c echo $unix_path` 59411 vcxproj_path="$windows_path" 59412 fi 59413 59414 59415 unix_path="$freetype_lib_path" 59416 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59417 windows_path=`$CYGPATH -m "$unix_path"` 59418 freetype_lib_path="$windows_path" 59419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59420 windows_path=`cmd //c echo $unix_path` 59421 freetype_lib_path="$windows_path" 59422 fi 59423 59424 59425 unix_path="$freetype_obj_path" 59426 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59427 windows_path=`$CYGPATH -m "$unix_path"` 59428 freetype_obj_path="$windows_path" 59429 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59430 windows_path=`cmd //c echo $unix_path` 59431 freetype_obj_path="$windows_path" 59432 fi 59433 59434 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59435 freetype_platform=x64 59436 else 59437 freetype_platform=win32 59438 fi 59439 59440 # The original freetype project file is for VS 2010 (i.e. 'v100'), 59441 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 59442 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 59443 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 59444 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 59445 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 59446 59447 # First we try to build the freetype.dll 59448 $ECHO -e "@echo off\n"\ 59449 "$MSBUILD $vcxproj_path "\ 59450 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59451 "/p:Configuration=\"Release Multithreaded\" "\ 59452 "/p:Platform=$freetype_platform "\ 59453 "/p:ConfigurationType=DynamicLibrary "\ 59454 "/p:TargetName=freetype "\ 59455 "/p:OutDir=\"$freetype_lib_path\" "\ 59456 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 59457 cmd /c freetype.bat 59458 59459 if test -s "$freetype_lib_path_unix/freetype.dll"; then 59460 # If that succeeds we also build freetype.lib 59461 $ECHO -e "@echo off\n"\ 59462 "$MSBUILD $vcxproj_path "\ 59463 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59464 "/p:Configuration=\"Release Multithreaded\" "\ 59465 "/p:Platform=$freetype_platform "\ 59466 "/p:ConfigurationType=StaticLibrary "\ 59467 "/p:TargetName=freetype "\ 59468 "/p:OutDir=\"$freetype_lib_path\" "\ 59469 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 59470 cmd /c freetype.bat 59471 59472 if test -s "$freetype_lib_path_unix/freetype.lib"; then 59473 # Once we build both, lib and dll, set freetype lib and include path appropriately 59474 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 59475 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 59476 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 59477 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 59478 else 59479 BUILD_FREETYPE=no 59480 fi 59481 else 59482 BUILD_FREETYPE=no 59483 fi 59484 fi 59485 59486 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59487 59488 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59489 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59490 METHOD="well-known location" 59491 59492 # Let's start with an optimistic view of the world :-) 59493 FOUND_FREETYPE=yes 59494 59495 # First look for the canonical freetype main include file ft2build.h. 59496 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59497 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59498 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59499 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59500 # Fail. 59501 FOUND_FREETYPE=no 59502 fi 59503 fi 59504 59505 if test "x$FOUND_FREETYPE" = xyes; then 59506 # Include file found, let's continue the sanity check. 59507 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59508 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59509 59510 # Reset to default value 59511 FREETYPE_BASE_NAME=freetype 59512 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59513 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59514 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59515 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59516 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59517 # for the .6 version explicitly. 59518 FREETYPE_BASE_NAME=freetype.6 59519 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59520 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59521 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59522 else 59523 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59524 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59525 FOUND_FREETYPE=no 59526 fi 59527 else 59528 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59529 # On Windows, we will need both .lib and .dll file. 59530 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59531 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59532 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59533 FOUND_FREETYPE=no 59534 fi 59535 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59536 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59537 # Found lib in isa dir, use that instead. 59538 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59539 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59540 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59541 fi 59542 fi 59543 fi 59544 59545 if test "x$FOUND_FREETYPE" = xyes; then 59546 59547 # Only process if variable expands to non-empty 59548 59549 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59550 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59551 59552 # Input might be given as Windows format, start by converting to 59553 # unix format. 59554 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59555 new_path=`$CYGPATH -u "$path"` 59556 59557 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59558 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59559 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59560 # "foo.exe" is OK but "foo" is an error. 59561 # 59562 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59563 # It is also a way to make sure we got the proper file name for the real test later on. 59564 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59565 if test "x$test_shortpath" = x; then 59566 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59567 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59568 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59569 fi 59570 59571 # Call helper function which possibly converts this using DOS-style short mode. 59572 # If so, the updated path is stored in $new_path. 59573 59574 input_path="$new_path" 59575 # Check if we need to convert this using DOS-style short mode. If the path 59576 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59577 # take no chances and rewrite it. 59578 # Note: m4 eats our [], so we need to use [ and ] instead. 59579 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59580 if test "x$has_forbidden_chars" != x; then 59581 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59582 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59583 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59584 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59585 # Going to short mode and back again did indeed matter. Since short mode is 59586 # case insensitive, let's make it lowercase to improve readability. 59587 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59588 # Now convert it back to Unix-style (cygpath) 59589 input_path=`$CYGPATH -u "$shortmode_path"` 59590 new_path="$input_path" 59591 fi 59592 fi 59593 59594 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59595 if test "x$test_cygdrive_prefix" = x; then 59596 # As a simple fix, exclude /usr/bin since it's not a real path. 59597 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59598 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59599 # a path prefixed by /cygdrive for fixpath to work. 59600 new_path="$CYGWIN_ROOT_PATH$input_path" 59601 fi 59602 fi 59603 59604 59605 if test "x$path" != "x$new_path"; then 59606 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59607 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59608 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59609 fi 59610 59611 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59612 59613 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59614 has_colon=`$ECHO $path | $GREP ^.:` 59615 new_path="$path" 59616 if test "x$has_colon" = x; then 59617 # Not in mixed or Windows style, start by that. 59618 new_path=`cmd //c echo $path` 59619 fi 59620 59621 59622 input_path="$new_path" 59623 # Check if we need to convert this using DOS-style short mode. If the path 59624 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59625 # take no chances and rewrite it. 59626 # Note: m4 eats our [], so we need to use [ and ] instead. 59627 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59628 if test "x$has_forbidden_chars" != x; then 59629 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59630 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59631 fi 59632 59633 59634 windows_path="$new_path" 59635 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59636 unix_path=`$CYGPATH -u "$windows_path"` 59637 new_path="$unix_path" 59638 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59639 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59640 new_path="$unix_path" 59641 fi 59642 59643 if test "x$path" != "x$new_path"; then 59644 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59645 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59646 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59647 fi 59648 59649 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59650 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59651 59652 else 59653 # We're on a unix platform. Hooray! :) 59654 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59655 has_space=`$ECHO "$path" | $GREP " "` 59656 if test "x$has_space" != x; then 59657 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59658 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59659 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59660 fi 59661 59662 # Use eval to expand a potential ~ 59663 eval path="$path" 59664 if test ! -f "$path" && test ! -d "$path"; then 59665 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59666 fi 59667 59668 if test -d "$path"; then 59669 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59670 else 59671 dir="`$DIRNAME "$path"`" 59672 base="`$BASENAME "$path"`" 59673 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59674 fi 59675 fi 59676 fi 59677 59678 59679 # Only process if variable expands to non-empty 59680 59681 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59682 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59683 59684 # Input might be given as Windows format, start by converting to 59685 # unix format. 59686 path="$POTENTIAL_FREETYPE_LIB_PATH" 59687 new_path=`$CYGPATH -u "$path"` 59688 59689 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59690 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59691 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59692 # "foo.exe" is OK but "foo" is an error. 59693 # 59694 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59695 # It is also a way to make sure we got the proper file name for the real test later on. 59696 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59697 if test "x$test_shortpath" = x; then 59698 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59699 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59700 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59701 fi 59702 59703 # Call helper function which possibly converts this using DOS-style short mode. 59704 # If so, the updated path is stored in $new_path. 59705 59706 input_path="$new_path" 59707 # Check if we need to convert this using DOS-style short mode. If the path 59708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59709 # take no chances and rewrite it. 59710 # Note: m4 eats our [], so we need to use [ and ] instead. 59711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59712 if test "x$has_forbidden_chars" != x; then 59713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59714 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59715 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59716 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59717 # Going to short mode and back again did indeed matter. Since short mode is 59718 # case insensitive, let's make it lowercase to improve readability. 59719 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59720 # Now convert it back to Unix-style (cygpath) 59721 input_path=`$CYGPATH -u "$shortmode_path"` 59722 new_path="$input_path" 59723 fi 59724 fi 59725 59726 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59727 if test "x$test_cygdrive_prefix" = x; then 59728 # As a simple fix, exclude /usr/bin since it's not a real path. 59729 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59730 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59731 # a path prefixed by /cygdrive for fixpath to work. 59732 new_path="$CYGWIN_ROOT_PATH$input_path" 59733 fi 59734 fi 59735 59736 59737 if test "x$path" != "x$new_path"; then 59738 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59739 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59740 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59741 fi 59742 59743 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59744 59745 path="$POTENTIAL_FREETYPE_LIB_PATH" 59746 has_colon=`$ECHO $path | $GREP ^.:` 59747 new_path="$path" 59748 if test "x$has_colon" = x; then 59749 # Not in mixed or Windows style, start by that. 59750 new_path=`cmd //c echo $path` 59751 fi 59752 59753 59754 input_path="$new_path" 59755 # Check if we need to convert this using DOS-style short mode. If the path 59756 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59757 # take no chances and rewrite it. 59758 # Note: m4 eats our [], so we need to use [ and ] instead. 59759 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59760 if test "x$has_forbidden_chars" != x; then 59761 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59762 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59763 fi 59764 59765 59766 windows_path="$new_path" 59767 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59768 unix_path=`$CYGPATH -u "$windows_path"` 59769 new_path="$unix_path" 59770 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59771 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59772 new_path="$unix_path" 59773 fi 59774 59775 if test "x$path" != "x$new_path"; then 59776 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59777 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59778 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59779 fi 59780 59781 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59782 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59783 59784 else 59785 # We're on a unix platform. Hooray! :) 59786 path="$POTENTIAL_FREETYPE_LIB_PATH" 59787 has_space=`$ECHO "$path" | $GREP " "` 59788 if test "x$has_space" != x; then 59789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59790 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59791 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59792 fi 59793 59794 # Use eval to expand a potential ~ 59795 eval path="$path" 59796 if test ! -f "$path" && test ! -d "$path"; then 59797 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59798 fi 59799 59800 if test -d "$path"; then 59801 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59802 else 59803 dir="`$DIRNAME "$path"`" 59804 base="`$BASENAME "$path"`" 59805 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59806 fi 59807 fi 59808 fi 59809 59810 59811 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59813 $as_echo_n "checking for freetype includes... " >&6; } 59814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59815 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59816 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59818 $as_echo_n "checking for freetype libraries... " >&6; } 59819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59820 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59821 fi 59822 59823 else 59824 59825 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59826 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59827 METHOD="well-known location" 59828 59829 # Let's start with an optimistic view of the world :-) 59830 FOUND_FREETYPE=yes 59831 59832 # First look for the canonical freetype main include file ft2build.h. 59833 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59834 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59835 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59836 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59837 # Fail. 59838 FOUND_FREETYPE=no 59839 fi 59840 fi 59841 59842 if test "x$FOUND_FREETYPE" = xyes; then 59843 # Include file found, let's continue the sanity check. 59844 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59845 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59846 59847 # Reset to default value 59848 FREETYPE_BASE_NAME=freetype 59849 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59850 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59851 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59852 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59853 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59854 # for the .6 version explicitly. 59855 FREETYPE_BASE_NAME=freetype.6 59856 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59857 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59858 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59859 else 59860 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59861 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59862 FOUND_FREETYPE=no 59863 fi 59864 else 59865 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59866 # On Windows, we will need both .lib and .dll file. 59867 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59868 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59869 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59870 FOUND_FREETYPE=no 59871 fi 59872 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59873 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59874 # Found lib in isa dir, use that instead. 59875 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59876 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59877 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59878 fi 59879 fi 59880 fi 59881 59882 if test "x$FOUND_FREETYPE" = xyes; then 59883 59884 # Only process if variable expands to non-empty 59885 59886 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59887 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59888 59889 # Input might be given as Windows format, start by converting to 59890 # unix format. 59891 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59892 new_path=`$CYGPATH -u "$path"` 59893 59894 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59895 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59896 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59897 # "foo.exe" is OK but "foo" is an error. 59898 # 59899 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59900 # It is also a way to make sure we got the proper file name for the real test later on. 59901 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59902 if test "x$test_shortpath" = x; then 59903 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59904 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59905 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59906 fi 59907 59908 # Call helper function which possibly converts this using DOS-style short mode. 59909 # If so, the updated path is stored in $new_path. 59910 59911 input_path="$new_path" 59912 # Check if we need to convert this using DOS-style short mode. If the path 59913 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59914 # take no chances and rewrite it. 59915 # Note: m4 eats our [], so we need to use [ and ] instead. 59916 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59917 if test "x$has_forbidden_chars" != x; then 59918 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59919 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59920 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59921 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59922 # Going to short mode and back again did indeed matter. Since short mode is 59923 # case insensitive, let's make it lowercase to improve readability. 59924 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59925 # Now convert it back to Unix-style (cygpath) 59926 input_path=`$CYGPATH -u "$shortmode_path"` 59927 new_path="$input_path" 59928 fi 59929 fi 59930 59931 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59932 if test "x$test_cygdrive_prefix" = x; then 59933 # As a simple fix, exclude /usr/bin since it's not a real path. 59934 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59935 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59936 # a path prefixed by /cygdrive for fixpath to work. 59937 new_path="$CYGWIN_ROOT_PATH$input_path" 59938 fi 59939 fi 59940 59941 59942 if test "x$path" != "x$new_path"; then 59943 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59944 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59945 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59946 fi 59947 59948 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59949 59950 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59951 has_colon=`$ECHO $path | $GREP ^.:` 59952 new_path="$path" 59953 if test "x$has_colon" = x; then 59954 # Not in mixed or Windows style, start by that. 59955 new_path=`cmd //c echo $path` 59956 fi 59957 59958 59959 input_path="$new_path" 59960 # Check if we need to convert this using DOS-style short mode. If the path 59961 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59962 # take no chances and rewrite it. 59963 # Note: m4 eats our [], so we need to use [ and ] instead. 59964 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59965 if test "x$has_forbidden_chars" != x; then 59966 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59967 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59968 fi 59969 59970 59971 windows_path="$new_path" 59972 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59973 unix_path=`$CYGPATH -u "$windows_path"` 59974 new_path="$unix_path" 59975 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59976 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59977 new_path="$unix_path" 59978 fi 59979 59980 if test "x$path" != "x$new_path"; then 59981 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59982 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59983 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59984 fi 59985 59986 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59987 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59988 59989 else 59990 # We're on a unix platform. Hooray! :) 59991 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59992 has_space=`$ECHO "$path" | $GREP " "` 59993 if test "x$has_space" != x; then 59994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59995 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59996 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59997 fi 59998 59999 # Use eval to expand a potential ~ 60000 eval path="$path" 60001 if test ! -f "$path" && test ! -d "$path"; then 60002 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60003 fi 60004 60005 if test -d "$path"; then 60006 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60007 else 60008 dir="`$DIRNAME "$path"`" 60009 base="`$BASENAME "$path"`" 60010 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60011 fi 60012 fi 60013 fi 60014 60015 60016 # Only process if variable expands to non-empty 60017 60018 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60019 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60020 60021 # Input might be given as Windows format, start by converting to 60022 # unix format. 60023 path="$POTENTIAL_FREETYPE_LIB_PATH" 60024 new_path=`$CYGPATH -u "$path"` 60025 60026 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60027 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60028 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60029 # "foo.exe" is OK but "foo" is an error. 60030 # 60031 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60032 # It is also a way to make sure we got the proper file name for the real test later on. 60033 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60034 if test "x$test_shortpath" = x; then 60035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60036 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60037 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60038 fi 60039 60040 # Call helper function which possibly converts this using DOS-style short mode. 60041 # If so, the updated path is stored in $new_path. 60042 60043 input_path="$new_path" 60044 # Check if we need to convert this using DOS-style short mode. If the path 60045 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60046 # take no chances and rewrite it. 60047 # Note: m4 eats our [], so we need to use [ and ] instead. 60048 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60049 if test "x$has_forbidden_chars" != x; then 60050 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60051 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60052 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60053 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60054 # Going to short mode and back again did indeed matter. Since short mode is 60055 # case insensitive, let's make it lowercase to improve readability. 60056 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60057 # Now convert it back to Unix-style (cygpath) 60058 input_path=`$CYGPATH -u "$shortmode_path"` 60059 new_path="$input_path" 60060 fi 60061 fi 60062 60063 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60064 if test "x$test_cygdrive_prefix" = x; then 60065 # As a simple fix, exclude /usr/bin since it's not a real path. 60066 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60067 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60068 # a path prefixed by /cygdrive for fixpath to work. 60069 new_path="$CYGWIN_ROOT_PATH$input_path" 60070 fi 60071 fi 60072 60073 60074 if test "x$path" != "x$new_path"; then 60075 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60076 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60077 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60078 fi 60079 60080 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60081 60082 path="$POTENTIAL_FREETYPE_LIB_PATH" 60083 has_colon=`$ECHO $path | $GREP ^.:` 60084 new_path="$path" 60085 if test "x$has_colon" = x; then 60086 # Not in mixed or Windows style, start by that. 60087 new_path=`cmd //c echo $path` 60088 fi 60089 60090 60091 input_path="$new_path" 60092 # Check if we need to convert this using DOS-style short mode. If the path 60093 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60094 # take no chances and rewrite it. 60095 # Note: m4 eats our [], so we need to use [ and ] instead. 60096 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60097 if test "x$has_forbidden_chars" != x; then 60098 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60099 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60100 fi 60101 60102 60103 windows_path="$new_path" 60104 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60105 unix_path=`$CYGPATH -u "$windows_path"` 60106 new_path="$unix_path" 60107 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60108 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60109 new_path="$unix_path" 60110 fi 60111 60112 if test "x$path" != "x$new_path"; then 60113 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60114 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60115 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60116 fi 60117 60118 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60119 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60120 60121 else 60122 # We're on a unix platform. Hooray! :) 60123 path="$POTENTIAL_FREETYPE_LIB_PATH" 60124 has_space=`$ECHO "$path" | $GREP " "` 60125 if test "x$has_space" != x; then 60126 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60127 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60128 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60129 fi 60130 60131 # Use eval to expand a potential ~ 60132 eval path="$path" 60133 if test ! -f "$path" && test ! -d "$path"; then 60134 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60135 fi 60136 60137 if test -d "$path"; then 60138 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60139 else 60140 dir="`$DIRNAME "$path"`" 60141 base="`$BASENAME "$path"`" 60142 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60143 fi 60144 fi 60145 fi 60146 60147 60148 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60150 $as_echo_n "checking for freetype includes... " >&6; } 60151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60152 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60153 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60155 $as_echo_n "checking for freetype libraries... " >&6; } 60156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60157 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60158 fi 60159 60160 fi 60161 fi 60162 fi 60163 else 60164 FREETYPE_BASE_DIR="$SYSROOT/usr" 60165 60166 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60167 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60168 METHOD="well-known location" 60169 60170 # Let's start with an optimistic view of the world :-) 60171 FOUND_FREETYPE=yes 60172 60173 # First look for the canonical freetype main include file ft2build.h. 60174 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60175 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60176 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60177 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60178 # Fail. 60179 FOUND_FREETYPE=no 60180 fi 60181 fi 60182 60183 if test "x$FOUND_FREETYPE" = xyes; then 60184 # Include file found, let's continue the sanity check. 60185 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60186 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60187 60188 # Reset to default value 60189 FREETYPE_BASE_NAME=freetype 60190 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60191 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60192 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60193 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60194 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60195 # for the .6 version explicitly. 60196 FREETYPE_BASE_NAME=freetype.6 60197 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60198 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60199 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60200 else 60201 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60202 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60203 FOUND_FREETYPE=no 60204 fi 60205 else 60206 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60207 # On Windows, we will need both .lib and .dll file. 60208 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60209 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60210 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60211 FOUND_FREETYPE=no 60212 fi 60213 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60214 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60215 # Found lib in isa dir, use that instead. 60216 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60217 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60218 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60219 fi 60220 fi 60221 fi 60222 60223 if test "x$FOUND_FREETYPE" = xyes; then 60224 60225 # Only process if variable expands to non-empty 60226 60227 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60228 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60229 60230 # Input might be given as Windows format, start by converting to 60231 # unix format. 60232 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60233 new_path=`$CYGPATH -u "$path"` 60234 60235 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60236 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60237 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60238 # "foo.exe" is OK but "foo" is an error. 60239 # 60240 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60241 # It is also a way to make sure we got the proper file name for the real test later on. 60242 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60243 if test "x$test_shortpath" = x; then 60244 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60245 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60246 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60247 fi 60248 60249 # Call helper function which possibly converts this using DOS-style short mode. 60250 # If so, the updated path is stored in $new_path. 60251 60252 input_path="$new_path" 60253 # Check if we need to convert this using DOS-style short mode. If the path 60254 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60255 # take no chances and rewrite it. 60256 # Note: m4 eats our [], so we need to use [ and ] instead. 60257 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60258 if test "x$has_forbidden_chars" != x; then 60259 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60260 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60261 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60262 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60263 # Going to short mode and back again did indeed matter. Since short mode is 60264 # case insensitive, let's make it lowercase to improve readability. 60265 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60266 # Now convert it back to Unix-style (cygpath) 60267 input_path=`$CYGPATH -u "$shortmode_path"` 60268 new_path="$input_path" 60269 fi 60270 fi 60271 60272 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60273 if test "x$test_cygdrive_prefix" = x; then 60274 # As a simple fix, exclude /usr/bin since it's not a real path. 60275 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60276 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60277 # a path prefixed by /cygdrive for fixpath to work. 60278 new_path="$CYGWIN_ROOT_PATH$input_path" 60279 fi 60280 fi 60281 60282 60283 if test "x$path" != "x$new_path"; then 60284 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60285 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60286 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60287 fi 60288 60289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60290 60291 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60292 has_colon=`$ECHO $path | $GREP ^.:` 60293 new_path="$path" 60294 if test "x$has_colon" = x; then 60295 # Not in mixed or Windows style, start by that. 60296 new_path=`cmd //c echo $path` 60297 fi 60298 60299 60300 input_path="$new_path" 60301 # Check if we need to convert this using DOS-style short mode. If the path 60302 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60303 # take no chances and rewrite it. 60304 # Note: m4 eats our [], so we need to use [ and ] instead. 60305 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60306 if test "x$has_forbidden_chars" != x; then 60307 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60308 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60309 fi 60310 60311 60312 windows_path="$new_path" 60313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60314 unix_path=`$CYGPATH -u "$windows_path"` 60315 new_path="$unix_path" 60316 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60317 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60318 new_path="$unix_path" 60319 fi 60320 60321 if test "x$path" != "x$new_path"; then 60322 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60323 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60324 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60325 fi 60326 60327 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60328 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60329 60330 else 60331 # We're on a unix platform. Hooray! :) 60332 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60333 has_space=`$ECHO "$path" | $GREP " "` 60334 if test "x$has_space" != x; then 60335 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60336 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60337 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60338 fi 60339 60340 # Use eval to expand a potential ~ 60341 eval path="$path" 60342 if test ! -f "$path" && test ! -d "$path"; then 60343 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60344 fi 60345 60346 if test -d "$path"; then 60347 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60348 else 60349 dir="`$DIRNAME "$path"`" 60350 base="`$BASENAME "$path"`" 60351 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60352 fi 60353 fi 60354 fi 60355 60356 60357 # Only process if variable expands to non-empty 60358 60359 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60360 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60361 60362 # Input might be given as Windows format, start by converting to 60363 # unix format. 60364 path="$POTENTIAL_FREETYPE_LIB_PATH" 60365 new_path=`$CYGPATH -u "$path"` 60366 60367 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60368 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60369 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60370 # "foo.exe" is OK but "foo" is an error. 60371 # 60372 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60373 # It is also a way to make sure we got the proper file name for the real test later on. 60374 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60375 if test "x$test_shortpath" = x; then 60376 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60377 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60378 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60379 fi 60380 60381 # Call helper function which possibly converts this using DOS-style short mode. 60382 # If so, the updated path is stored in $new_path. 60383 60384 input_path="$new_path" 60385 # Check if we need to convert this using DOS-style short mode. If the path 60386 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60387 # take no chances and rewrite it. 60388 # Note: m4 eats our [], so we need to use [ and ] instead. 60389 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60390 if test "x$has_forbidden_chars" != x; then 60391 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60392 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60393 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60394 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60395 # Going to short mode and back again did indeed matter. Since short mode is 60396 # case insensitive, let's make it lowercase to improve readability. 60397 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60398 # Now convert it back to Unix-style (cygpath) 60399 input_path=`$CYGPATH -u "$shortmode_path"` 60400 new_path="$input_path" 60401 fi 60402 fi 60403 60404 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60405 if test "x$test_cygdrive_prefix" = x; then 60406 # As a simple fix, exclude /usr/bin since it's not a real path. 60407 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60408 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60409 # a path prefixed by /cygdrive for fixpath to work. 60410 new_path="$CYGWIN_ROOT_PATH$input_path" 60411 fi 60412 fi 60413 60414 60415 if test "x$path" != "x$new_path"; then 60416 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60417 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60418 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60419 fi 60420 60421 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60422 60423 path="$POTENTIAL_FREETYPE_LIB_PATH" 60424 has_colon=`$ECHO $path | $GREP ^.:` 60425 new_path="$path" 60426 if test "x$has_colon" = x; then 60427 # Not in mixed or Windows style, start by that. 60428 new_path=`cmd //c echo $path` 60429 fi 60430 60431 60432 input_path="$new_path" 60433 # Check if we need to convert this using DOS-style short mode. If the path 60434 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60435 # take no chances and rewrite it. 60436 # Note: m4 eats our [], so we need to use [ and ] instead. 60437 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60438 if test "x$has_forbidden_chars" != x; then 60439 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60440 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60441 fi 60442 60443 60444 windows_path="$new_path" 60445 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60446 unix_path=`$CYGPATH -u "$windows_path"` 60447 new_path="$unix_path" 60448 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60449 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60450 new_path="$unix_path" 60451 fi 60452 60453 if test "x$path" != "x$new_path"; then 60454 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60455 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60456 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60457 fi 60458 60459 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60460 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60461 60462 else 60463 # We're on a unix platform. Hooray! :) 60464 path="$POTENTIAL_FREETYPE_LIB_PATH" 60465 has_space=`$ECHO "$path" | $GREP " "` 60466 if test "x$has_space" != x; then 60467 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60468 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60469 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60470 fi 60471 60472 # Use eval to expand a potential ~ 60473 eval path="$path" 60474 if test ! -f "$path" && test ! -d "$path"; then 60475 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60476 fi 60477 60478 if test -d "$path"; then 60479 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60480 else 60481 dir="`$DIRNAME "$path"`" 60482 base="`$BASENAME "$path"`" 60483 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60484 fi 60485 fi 60486 fi 60487 60488 60489 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60491 $as_echo_n "checking for freetype includes... " >&6; } 60492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60493 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60494 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60496 $as_echo_n "checking for freetype libraries... " >&6; } 60497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60498 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60499 fi 60500 60501 60502 if test "x$FOUND_FREETYPE" != xyes; then 60503 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 60504 60505 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60506 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60507 METHOD="well-known location" 60508 60509 # Let's start with an optimistic view of the world :-) 60510 FOUND_FREETYPE=yes 60511 60512 # First look for the canonical freetype main include file ft2build.h. 60513 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60514 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60515 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60516 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60517 # Fail. 60518 FOUND_FREETYPE=no 60519 fi 60520 fi 60521 60522 if test "x$FOUND_FREETYPE" = xyes; then 60523 # Include file found, let's continue the sanity check. 60524 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60525 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60526 60527 # Reset to default value 60528 FREETYPE_BASE_NAME=freetype 60529 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60530 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60531 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60532 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60533 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60534 # for the .6 version explicitly. 60535 FREETYPE_BASE_NAME=freetype.6 60536 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60537 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60538 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60539 else 60540 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60541 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60542 FOUND_FREETYPE=no 60543 fi 60544 else 60545 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60546 # On Windows, we will need both .lib and .dll file. 60547 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60548 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60549 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60550 FOUND_FREETYPE=no 60551 fi 60552 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60553 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60554 # Found lib in isa dir, use that instead. 60555 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60556 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60557 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60558 fi 60559 fi 60560 fi 60561 60562 if test "x$FOUND_FREETYPE" = xyes; then 60563 60564 # Only process if variable expands to non-empty 60565 60566 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60567 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60568 60569 # Input might be given as Windows format, start by converting to 60570 # unix format. 60571 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60572 new_path=`$CYGPATH -u "$path"` 60573 60574 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60575 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60576 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60577 # "foo.exe" is OK but "foo" is an error. 60578 # 60579 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60580 # It is also a way to make sure we got the proper file name for the real test later on. 60581 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60582 if test "x$test_shortpath" = x; then 60583 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60584 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60585 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60586 fi 60587 60588 # Call helper function which possibly converts this using DOS-style short mode. 60589 # If so, the updated path is stored in $new_path. 60590 60591 input_path="$new_path" 60592 # Check if we need to convert this using DOS-style short mode. If the path 60593 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60594 # take no chances and rewrite it. 60595 # Note: m4 eats our [], so we need to use [ and ] instead. 60596 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60597 if test "x$has_forbidden_chars" != x; then 60598 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60599 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60600 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60601 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60602 # Going to short mode and back again did indeed matter. Since short mode is 60603 # case insensitive, let's make it lowercase to improve readability. 60604 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60605 # Now convert it back to Unix-style (cygpath) 60606 input_path=`$CYGPATH -u "$shortmode_path"` 60607 new_path="$input_path" 60608 fi 60609 fi 60610 60611 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60612 if test "x$test_cygdrive_prefix" = x; then 60613 # As a simple fix, exclude /usr/bin since it's not a real path. 60614 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60615 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60616 # a path prefixed by /cygdrive for fixpath to work. 60617 new_path="$CYGWIN_ROOT_PATH$input_path" 60618 fi 60619 fi 60620 60621 60622 if test "x$path" != "x$new_path"; then 60623 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60624 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60625 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60626 fi 60627 60628 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60629 60630 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60631 has_colon=`$ECHO $path | $GREP ^.:` 60632 new_path="$path" 60633 if test "x$has_colon" = x; then 60634 # Not in mixed or Windows style, start by that. 60635 new_path=`cmd //c echo $path` 60636 fi 60637 60638 60639 input_path="$new_path" 60640 # Check if we need to convert this using DOS-style short mode. If the path 60641 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60642 # take no chances and rewrite it. 60643 # Note: m4 eats our [], so we need to use [ and ] instead. 60644 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60645 if test "x$has_forbidden_chars" != x; then 60646 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60647 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60648 fi 60649 60650 60651 windows_path="$new_path" 60652 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60653 unix_path=`$CYGPATH -u "$windows_path"` 60654 new_path="$unix_path" 60655 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60656 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60657 new_path="$unix_path" 60658 fi 60659 60660 if test "x$path" != "x$new_path"; then 60661 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60662 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60663 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60664 fi 60665 60666 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60667 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60668 60669 else 60670 # We're on a unix platform. Hooray! :) 60671 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60672 has_space=`$ECHO "$path" | $GREP " "` 60673 if test "x$has_space" != x; then 60674 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60675 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60676 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60677 fi 60678 60679 # Use eval to expand a potential ~ 60680 eval path="$path" 60681 if test ! -f "$path" && test ! -d "$path"; then 60682 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60683 fi 60684 60685 if test -d "$path"; then 60686 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60687 else 60688 dir="`$DIRNAME "$path"`" 60689 base="`$BASENAME "$path"`" 60690 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60691 fi 60692 fi 60693 fi 60694 60695 60696 # Only process if variable expands to non-empty 60697 60698 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60699 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60700 60701 # Input might be given as Windows format, start by converting to 60702 # unix format. 60703 path="$POTENTIAL_FREETYPE_LIB_PATH" 60704 new_path=`$CYGPATH -u "$path"` 60705 60706 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60707 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60708 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60709 # "foo.exe" is OK but "foo" is an error. 60710 # 60711 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60712 # It is also a way to make sure we got the proper file name for the real test later on. 60713 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60714 if test "x$test_shortpath" = x; then 60715 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60716 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60717 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60718 fi 60719 60720 # Call helper function which possibly converts this using DOS-style short mode. 60721 # If so, the updated path is stored in $new_path. 60722 60723 input_path="$new_path" 60724 # Check if we need to convert this using DOS-style short mode. If the path 60725 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60726 # take no chances and rewrite it. 60727 # Note: m4 eats our [], so we need to use [ and ] instead. 60728 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60729 if test "x$has_forbidden_chars" != x; then 60730 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60731 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60732 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60733 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60734 # Going to short mode and back again did indeed matter. Since short mode is 60735 # case insensitive, let's make it lowercase to improve readability. 60736 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60737 # Now convert it back to Unix-style (cygpath) 60738 input_path=`$CYGPATH -u "$shortmode_path"` 60739 new_path="$input_path" 60740 fi 60741 fi 60742 60743 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60744 if test "x$test_cygdrive_prefix" = x; then 60745 # As a simple fix, exclude /usr/bin since it's not a real path. 60746 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60747 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60748 # a path prefixed by /cygdrive for fixpath to work. 60749 new_path="$CYGWIN_ROOT_PATH$input_path" 60750 fi 60751 fi 60752 60753 60754 if test "x$path" != "x$new_path"; then 60755 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60756 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60757 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60758 fi 60759 60760 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60761 60762 path="$POTENTIAL_FREETYPE_LIB_PATH" 60763 has_colon=`$ECHO $path | $GREP ^.:` 60764 new_path="$path" 60765 if test "x$has_colon" = x; then 60766 # Not in mixed or Windows style, start by that. 60767 new_path=`cmd //c echo $path` 60768 fi 60769 60770 60771 input_path="$new_path" 60772 # Check if we need to convert this using DOS-style short mode. If the path 60773 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60774 # take no chances and rewrite it. 60775 # Note: m4 eats our [], so we need to use [ and ] instead. 60776 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60777 if test "x$has_forbidden_chars" != x; then 60778 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60779 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60780 fi 60781 60782 60783 windows_path="$new_path" 60784 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60785 unix_path=`$CYGPATH -u "$windows_path"` 60786 new_path="$unix_path" 60787 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60788 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60789 new_path="$unix_path" 60790 fi 60791 60792 if test "x$path" != "x$new_path"; then 60793 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60794 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60795 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60796 fi 60797 60798 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60799 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60800 60801 else 60802 # We're on a unix platform. Hooray! :) 60803 path="$POTENTIAL_FREETYPE_LIB_PATH" 60804 has_space=`$ECHO "$path" | $GREP " "` 60805 if test "x$has_space" != x; then 60806 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60807 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60808 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60809 fi 60810 60811 # Use eval to expand a potential ~ 60812 eval path="$path" 60813 if test ! -f "$path" && test ! -d "$path"; then 60814 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60815 fi 60816 60817 if test -d "$path"; then 60818 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60819 else 60820 dir="`$DIRNAME "$path"`" 60821 base="`$BASENAME "$path"`" 60822 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60823 fi 60824 fi 60825 fi 60826 60827 60828 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60830 $as_echo_n "checking for freetype includes... " >&6; } 60831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60832 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60833 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60835 $as_echo_n "checking for freetype libraries... " >&6; } 60836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60837 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60838 fi 60839 60840 fi 60841 60842 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 60843 if test "x$FOUND_FREETYPE" != xyes; then 60844 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 60845 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 60846 60847 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60848 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60849 METHOD="well-known location" 60850 60851 # Let's start with an optimistic view of the world :-) 60852 FOUND_FREETYPE=yes 60853 60854 # First look for the canonical freetype main include file ft2build.h. 60855 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60856 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60857 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60858 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60859 # Fail. 60860 FOUND_FREETYPE=no 60861 fi 60862 fi 60863 60864 if test "x$FOUND_FREETYPE" = xyes; then 60865 # Include file found, let's continue the sanity check. 60866 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60867 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60868 60869 # Reset to default value 60870 FREETYPE_BASE_NAME=freetype 60871 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60872 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60873 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60874 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60875 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60876 # for the .6 version explicitly. 60877 FREETYPE_BASE_NAME=freetype.6 60878 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60879 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60880 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60881 else 60882 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60883 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60884 FOUND_FREETYPE=no 60885 fi 60886 else 60887 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60888 # On Windows, we will need both .lib and .dll file. 60889 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60890 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60891 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60892 FOUND_FREETYPE=no 60893 fi 60894 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60895 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60896 # Found lib in isa dir, use that instead. 60897 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60898 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60899 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60900 fi 60901 fi 60902 fi 60903 60904 if test "x$FOUND_FREETYPE" = xyes; then 60905 60906 # Only process if variable expands to non-empty 60907 60908 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60909 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60910 60911 # Input might be given as Windows format, start by converting to 60912 # unix format. 60913 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60914 new_path=`$CYGPATH -u "$path"` 60915 60916 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60917 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60918 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60919 # "foo.exe" is OK but "foo" is an error. 60920 # 60921 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60922 # It is also a way to make sure we got the proper file name for the real test later on. 60923 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60924 if test "x$test_shortpath" = x; then 60925 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60926 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60927 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60928 fi 60929 60930 # Call helper function which possibly converts this using DOS-style short mode. 60931 # If so, the updated path is stored in $new_path. 60932 60933 input_path="$new_path" 60934 # Check if we need to convert this using DOS-style short mode. If the path 60935 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60936 # take no chances and rewrite it. 60937 # Note: m4 eats our [], so we need to use [ and ] instead. 60938 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60939 if test "x$has_forbidden_chars" != x; then 60940 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60941 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60942 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60943 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60944 # Going to short mode and back again did indeed matter. Since short mode is 60945 # case insensitive, let's make it lowercase to improve readability. 60946 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60947 # Now convert it back to Unix-style (cygpath) 60948 input_path=`$CYGPATH -u "$shortmode_path"` 60949 new_path="$input_path" 60950 fi 60951 fi 60952 60953 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60954 if test "x$test_cygdrive_prefix" = x; then 60955 # As a simple fix, exclude /usr/bin since it's not a real path. 60956 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60957 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60958 # a path prefixed by /cygdrive for fixpath to work. 60959 new_path="$CYGWIN_ROOT_PATH$input_path" 60960 fi 60961 fi 60962 60963 60964 if test "x$path" != "x$new_path"; then 60965 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60966 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60967 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60968 fi 60969 60970 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60971 60972 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60973 has_colon=`$ECHO $path | $GREP ^.:` 60974 new_path="$path" 60975 if test "x$has_colon" = x; then 60976 # Not in mixed or Windows style, start by that. 60977 new_path=`cmd //c echo $path` 60978 fi 60979 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 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60990 fi 60991 60992 60993 windows_path="$new_path" 60994 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60995 unix_path=`$CYGPATH -u "$windows_path"` 60996 new_path="$unix_path" 60997 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60998 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60999 new_path="$unix_path" 61000 fi 61001 61002 if test "x$path" != "x$new_path"; then 61003 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61004 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61005 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61006 fi 61007 61008 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61009 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61010 61011 else 61012 # We're on a unix platform. Hooray! :) 61013 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61014 has_space=`$ECHO "$path" | $GREP " "` 61015 if test "x$has_space" != x; then 61016 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61017 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61018 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61019 fi 61020 61021 # Use eval to expand a potential ~ 61022 eval path="$path" 61023 if test ! -f "$path" && test ! -d "$path"; then 61024 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61025 fi 61026 61027 if test -d "$path"; then 61028 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61029 else 61030 dir="`$DIRNAME "$path"`" 61031 base="`$BASENAME "$path"`" 61032 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61033 fi 61034 fi 61035 fi 61036 61037 61038 # Only process if variable expands to non-empty 61039 61040 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61041 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61042 61043 # Input might be given as Windows format, start by converting to 61044 # unix format. 61045 path="$POTENTIAL_FREETYPE_LIB_PATH" 61046 new_path=`$CYGPATH -u "$path"` 61047 61048 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61049 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61050 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61051 # "foo.exe" is OK but "foo" is an error. 61052 # 61053 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61054 # It is also a way to make sure we got the proper file name for the real test later on. 61055 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61056 if test "x$test_shortpath" = x; then 61057 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61058 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61059 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61060 fi 61061 61062 # Call helper function which possibly converts this using DOS-style short mode. 61063 # If so, the updated path is stored in $new_path. 61064 61065 input_path="$new_path" 61066 # Check if we need to convert this using DOS-style short mode. If the path 61067 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61068 # take no chances and rewrite it. 61069 # Note: m4 eats our [], so we need to use [ and ] instead. 61070 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61071 if test "x$has_forbidden_chars" != x; then 61072 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61073 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61074 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61075 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61076 # Going to short mode and back again did indeed matter. Since short mode is 61077 # case insensitive, let's make it lowercase to improve readability. 61078 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61079 # Now convert it back to Unix-style (cygpath) 61080 input_path=`$CYGPATH -u "$shortmode_path"` 61081 new_path="$input_path" 61082 fi 61083 fi 61084 61085 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61086 if test "x$test_cygdrive_prefix" = x; then 61087 # As a simple fix, exclude /usr/bin since it's not a real path. 61088 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61089 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61090 # a path prefixed by /cygdrive for fixpath to work. 61091 new_path="$CYGWIN_ROOT_PATH$input_path" 61092 fi 61093 fi 61094 61095 61096 if test "x$path" != "x$new_path"; then 61097 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61098 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61099 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61100 fi 61101 61102 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61103 61104 path="$POTENTIAL_FREETYPE_LIB_PATH" 61105 has_colon=`$ECHO $path | $GREP ^.:` 61106 new_path="$path" 61107 if test "x$has_colon" = x; then 61108 # Not in mixed or Windows style, start by that. 61109 new_path=`cmd //c echo $path` 61110 fi 61111 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 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61122 fi 61123 61124 61125 windows_path="$new_path" 61126 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61127 unix_path=`$CYGPATH -u "$windows_path"` 61128 new_path="$unix_path" 61129 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61130 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61131 new_path="$unix_path" 61132 fi 61133 61134 if test "x$path" != "x$new_path"; then 61135 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61136 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61137 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61138 fi 61139 61140 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61141 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61142 61143 else 61144 # We're on a unix platform. Hooray! :) 61145 path="$POTENTIAL_FREETYPE_LIB_PATH" 61146 has_space=`$ECHO "$path" | $GREP " "` 61147 if test "x$has_space" != x; then 61148 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61149 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61150 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61151 fi 61152 61153 # Use eval to expand a potential ~ 61154 eval path="$path" 61155 if test ! -f "$path" && test ! -d "$path"; then 61156 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61157 fi 61158 61159 if test -d "$path"; then 61160 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61161 else 61162 dir="`$DIRNAME "$path"`" 61163 base="`$BASENAME "$path"`" 61164 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61165 fi 61166 fi 61167 fi 61168 61169 61170 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61172 $as_echo_n "checking for freetype includes... " >&6; } 61173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61174 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61175 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61177 $as_echo_n "checking for freetype libraries... " >&6; } 61178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61179 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61180 fi 61181 61182 fi 61183 fi 61184 61185 if test "x$FOUND_FREETYPE" != xyes; then 61186 FREETYPE_BASE_DIR="$SYSROOT/usr/sfw" 61187 61188 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61189 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61190 METHOD="well-known location" 61191 61192 # Let's start with an optimistic view of the world :-) 61193 FOUND_FREETYPE=yes 61194 61195 # First look for the canonical freetype main include file ft2build.h. 61196 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61197 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61198 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61199 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61200 # Fail. 61201 FOUND_FREETYPE=no 61202 fi 61203 fi 61204 61205 if test "x$FOUND_FREETYPE" = xyes; then 61206 # Include file found, let's continue the sanity check. 61207 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61208 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61209 61210 # Reset to default value 61211 FREETYPE_BASE_NAME=freetype 61212 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61213 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61214 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61215 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61216 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61217 # for the .6 version explicitly. 61218 FREETYPE_BASE_NAME=freetype.6 61219 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61220 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61221 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61222 else 61223 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61224 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61225 FOUND_FREETYPE=no 61226 fi 61227 else 61228 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61229 # On Windows, we will need both .lib and .dll file. 61230 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61231 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61232 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61233 FOUND_FREETYPE=no 61234 fi 61235 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61236 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61237 # Found lib in isa dir, use that instead. 61238 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61239 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61240 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61241 fi 61242 fi 61243 fi 61244 61245 if test "x$FOUND_FREETYPE" = xyes; then 61246 61247 # Only process if variable expands to non-empty 61248 61249 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61250 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61251 61252 # Input might be given as Windows format, start by converting to 61253 # unix format. 61254 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61255 new_path=`$CYGPATH -u "$path"` 61256 61257 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61258 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61259 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61260 # "foo.exe" is OK but "foo" is an error. 61261 # 61262 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61263 # It is also a way to make sure we got the proper file name for the real test later on. 61264 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61265 if test "x$test_shortpath" = x; then 61266 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61267 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61268 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61269 fi 61270 61271 # Call helper function which possibly converts this using DOS-style short mode. 61272 # If so, the updated path is stored in $new_path. 61273 61274 input_path="$new_path" 61275 # Check if we need to convert this using DOS-style short mode. If the path 61276 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61277 # take no chances and rewrite it. 61278 # Note: m4 eats our [], so we need to use [ and ] instead. 61279 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61280 if test "x$has_forbidden_chars" != x; then 61281 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61282 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61283 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61284 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61285 # Going to short mode and back again did indeed matter. Since short mode is 61286 # case insensitive, let's make it lowercase to improve readability. 61287 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61288 # Now convert it back to Unix-style (cygpath) 61289 input_path=`$CYGPATH -u "$shortmode_path"` 61290 new_path="$input_path" 61291 fi 61292 fi 61293 61294 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61295 if test "x$test_cygdrive_prefix" = x; then 61296 # As a simple fix, exclude /usr/bin since it's not a real path. 61297 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61298 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61299 # a path prefixed by /cygdrive for fixpath to work. 61300 new_path="$CYGWIN_ROOT_PATH$input_path" 61301 fi 61302 fi 61303 61304 61305 if test "x$path" != "x$new_path"; then 61306 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61307 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61308 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61309 fi 61310 61311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61312 61313 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61314 has_colon=`$ECHO $path | $GREP ^.:` 61315 new_path="$path" 61316 if test "x$has_colon" = x; then 61317 # Not in mixed or Windows style, start by that. 61318 new_path=`cmd //c echo $path` 61319 fi 61320 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 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61331 fi 61332 61333 61334 windows_path="$new_path" 61335 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61336 unix_path=`$CYGPATH -u "$windows_path"` 61337 new_path="$unix_path" 61338 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61339 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61340 new_path="$unix_path" 61341 fi 61342 61343 if test "x$path" != "x$new_path"; then 61344 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61345 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61346 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61347 fi 61348 61349 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61350 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61351 61352 else 61353 # We're on a unix platform. Hooray! :) 61354 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61355 has_space=`$ECHO "$path" | $GREP " "` 61356 if test "x$has_space" != x; then 61357 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61358 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61359 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61360 fi 61361 61362 # Use eval to expand a potential ~ 61363 eval path="$path" 61364 if test ! -f "$path" && test ! -d "$path"; then 61365 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61366 fi 61367 61368 if test -d "$path"; then 61369 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61370 else 61371 dir="`$DIRNAME "$path"`" 61372 base="`$BASENAME "$path"`" 61373 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61374 fi 61375 fi 61376 fi 61377 61378 61379 # Only process if variable expands to non-empty 61380 61381 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61383 61384 # Input might be given as Windows format, start by converting to 61385 # unix format. 61386 path="$POTENTIAL_FREETYPE_LIB_PATH" 61387 new_path=`$CYGPATH -u "$path"` 61388 61389 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61390 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61391 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61392 # "foo.exe" is OK but "foo" is an error. 61393 # 61394 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61395 # It is also a way to make sure we got the proper file name for the real test later on. 61396 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61397 if test "x$test_shortpath" = x; then 61398 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61399 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61400 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61401 fi 61402 61403 # Call helper function which possibly converts this using DOS-style short mode. 61404 # If so, the updated path is stored in $new_path. 61405 61406 input_path="$new_path" 61407 # Check if we need to convert this using DOS-style short mode. If the path 61408 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61409 # take no chances and rewrite it. 61410 # Note: m4 eats our [], so we need to use [ and ] instead. 61411 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61412 if test "x$has_forbidden_chars" != x; then 61413 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61414 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61415 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61416 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61417 # Going to short mode and back again did indeed matter. Since short mode is 61418 # case insensitive, let's make it lowercase to improve readability. 61419 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61420 # Now convert it back to Unix-style (cygpath) 61421 input_path=`$CYGPATH -u "$shortmode_path"` 61422 new_path="$input_path" 61423 fi 61424 fi 61425 61426 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61427 if test "x$test_cygdrive_prefix" = x; then 61428 # As a simple fix, exclude /usr/bin since it's not a real path. 61429 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61430 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61431 # a path prefixed by /cygdrive for fixpath to work. 61432 new_path="$CYGWIN_ROOT_PATH$input_path" 61433 fi 61434 fi 61435 61436 61437 if test "x$path" != "x$new_path"; then 61438 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61439 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61440 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61441 fi 61442 61443 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61444 61445 path="$POTENTIAL_FREETYPE_LIB_PATH" 61446 has_colon=`$ECHO $path | $GREP ^.:` 61447 new_path="$path" 61448 if test "x$has_colon" = x; then 61449 # Not in mixed or Windows style, start by that. 61450 new_path=`cmd //c echo $path` 61451 fi 61452 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 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61463 fi 61464 61465 61466 windows_path="$new_path" 61467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61468 unix_path=`$CYGPATH -u "$windows_path"` 61469 new_path="$unix_path" 61470 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61471 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61472 new_path="$unix_path" 61473 fi 61474 61475 if test "x$path" != "x$new_path"; then 61476 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61477 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61478 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61479 fi 61480 61481 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61482 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61483 61484 else 61485 # We're on a unix platform. Hooray! :) 61486 path="$POTENTIAL_FREETYPE_LIB_PATH" 61487 has_space=`$ECHO "$path" | $GREP " "` 61488 if test "x$has_space" != x; then 61489 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61490 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61491 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61492 fi 61493 61494 # Use eval to expand a potential ~ 61495 eval path="$path" 61496 if test ! -f "$path" && test ! -d "$path"; then 61497 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61498 fi 61499 61500 if test -d "$path"; then 61501 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61502 else 61503 dir="`$DIRNAME "$path"`" 61504 base="`$BASENAME "$path"`" 61505 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61506 fi 61507 fi 61508 fi 61509 61510 61511 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61513 $as_echo_n "checking for freetype includes... " >&6; } 61514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61515 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61516 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61518 $as_echo_n "checking for freetype libraries... " >&6; } 61519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61520 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61521 fi 61522 61523 fi 61524 61525 if test "x$FOUND_FREETYPE" != xyes; then 61526 FREETYPE_BASE_DIR="$SYSROOT/usr" 61527 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61528 61529 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61530 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu" 61531 METHOD="well-known location" 61532 61533 # Let's start with an optimistic view of the world :-) 61534 FOUND_FREETYPE=yes 61535 61536 # First look for the canonical freetype main include file ft2build.h. 61537 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61538 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61539 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61540 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61541 # Fail. 61542 FOUND_FREETYPE=no 61543 fi 61544 fi 61545 61546 if test "x$FOUND_FREETYPE" = xyes; then 61547 # Include file found, let's continue the sanity check. 61548 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61549 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61550 61551 # Reset to default value 61552 FREETYPE_BASE_NAME=freetype 61553 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61554 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61555 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61556 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61557 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61558 # for the .6 version explicitly. 61559 FREETYPE_BASE_NAME=freetype.6 61560 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61561 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61562 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61563 else 61564 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61565 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61566 FOUND_FREETYPE=no 61567 fi 61568 else 61569 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61570 # On Windows, we will need both .lib and .dll file. 61571 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61572 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61573 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61574 FOUND_FREETYPE=no 61575 fi 61576 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61577 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61578 # Found lib in isa dir, use that instead. 61579 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61580 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61581 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61582 fi 61583 fi 61584 fi 61585 61586 if test "x$FOUND_FREETYPE" = xyes; then 61587 61588 # Only process if variable expands to non-empty 61589 61590 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61591 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61592 61593 # Input might be given as Windows format, start by converting to 61594 # unix format. 61595 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61596 new_path=`$CYGPATH -u "$path"` 61597 61598 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61599 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61600 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61601 # "foo.exe" is OK but "foo" is an error. 61602 # 61603 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61604 # It is also a way to make sure we got the proper file name for the real test later on. 61605 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61606 if test "x$test_shortpath" = x; then 61607 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61608 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61609 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61610 fi 61611 61612 # Call helper function which possibly converts this using DOS-style short mode. 61613 # If so, the updated path is stored in $new_path. 61614 61615 input_path="$new_path" 61616 # Check if we need to convert this using DOS-style short mode. If the path 61617 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61618 # take no chances and rewrite it. 61619 # Note: m4 eats our [], so we need to use [ and ] instead. 61620 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61621 if test "x$has_forbidden_chars" != x; then 61622 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61623 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61624 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61625 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61626 # Going to short mode and back again did indeed matter. Since short mode is 61627 # case insensitive, let's make it lowercase to improve readability. 61628 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61629 # Now convert it back to Unix-style (cygpath) 61630 input_path=`$CYGPATH -u "$shortmode_path"` 61631 new_path="$input_path" 61632 fi 61633 fi 61634 61635 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61636 if test "x$test_cygdrive_prefix" = x; then 61637 # As a simple fix, exclude /usr/bin since it's not a real path. 61638 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61639 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61640 # a path prefixed by /cygdrive for fixpath to work. 61641 new_path="$CYGWIN_ROOT_PATH$input_path" 61642 fi 61643 fi 61644 61645 61646 if test "x$path" != "x$new_path"; then 61647 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61648 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61649 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61650 fi 61651 61652 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61653 61654 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61655 has_colon=`$ECHO $path | $GREP ^.:` 61656 new_path="$path" 61657 if test "x$has_colon" = x; then 61658 # Not in mixed or Windows style, start by that. 61659 new_path=`cmd //c echo $path` 61660 fi 61661 61662 61663 input_path="$new_path" 61664 # Check if we need to convert this using DOS-style short mode. If the path 61665 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61666 # take no chances and rewrite it. 61667 # Note: m4 eats our [], so we need to use [ and ] instead. 61668 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61669 if test "x$has_forbidden_chars" != x; then 61670 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61671 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61672 fi 61673 61674 61675 windows_path="$new_path" 61676 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61677 unix_path=`$CYGPATH -u "$windows_path"` 61678 new_path="$unix_path" 61679 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61680 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61681 new_path="$unix_path" 61682 fi 61683 61684 if test "x$path" != "x$new_path"; then 61685 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61686 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61687 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61688 fi 61689 61690 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61691 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61692 61693 else 61694 # We're on a unix platform. Hooray! :) 61695 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61696 has_space=`$ECHO "$path" | $GREP " "` 61697 if test "x$has_space" != x; then 61698 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61699 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61700 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61701 fi 61702 61703 # Use eval to expand a potential ~ 61704 eval path="$path" 61705 if test ! -f "$path" && test ! -d "$path"; then 61706 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61707 fi 61708 61709 if test -d "$path"; then 61710 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61711 else 61712 dir="`$DIRNAME "$path"`" 61713 base="`$BASENAME "$path"`" 61714 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61715 fi 61716 fi 61717 fi 61718 61719 61720 # Only process if variable expands to non-empty 61721 61722 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61723 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61724 61725 # Input might be given as Windows format, start by converting to 61726 # unix format. 61727 path="$POTENTIAL_FREETYPE_LIB_PATH" 61728 new_path=`$CYGPATH -u "$path"` 61729 61730 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61731 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61732 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61733 # "foo.exe" is OK but "foo" is an error. 61734 # 61735 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61736 # It is also a way to make sure we got the proper file name for the real test later on. 61737 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61738 if test "x$test_shortpath" = x; then 61739 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61740 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61741 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61742 fi 61743 61744 # Call helper function which possibly converts this using DOS-style short mode. 61745 # If so, the updated path is stored in $new_path. 61746 61747 input_path="$new_path" 61748 # Check if we need to convert this using DOS-style short mode. If the path 61749 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61750 # take no chances and rewrite it. 61751 # Note: m4 eats our [], so we need to use [ and ] instead. 61752 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61753 if test "x$has_forbidden_chars" != x; then 61754 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61755 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61756 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61757 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61758 # Going to short mode and back again did indeed matter. Since short mode is 61759 # case insensitive, let's make it lowercase to improve readability. 61760 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61761 # Now convert it back to Unix-style (cygpath) 61762 input_path=`$CYGPATH -u "$shortmode_path"` 61763 new_path="$input_path" 61764 fi 61765 fi 61766 61767 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61768 if test "x$test_cygdrive_prefix" = x; then 61769 # As a simple fix, exclude /usr/bin since it's not a real path. 61770 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61771 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61772 # a path prefixed by /cygdrive for fixpath to work. 61773 new_path="$CYGWIN_ROOT_PATH$input_path" 61774 fi 61775 fi 61776 61777 61778 if test "x$path" != "x$new_path"; then 61779 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61780 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61781 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61782 fi 61783 61784 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61785 61786 path="$POTENTIAL_FREETYPE_LIB_PATH" 61787 has_colon=`$ECHO $path | $GREP ^.:` 61788 new_path="$path" 61789 if test "x$has_colon" = x; then 61790 # Not in mixed or Windows style, start by that. 61791 new_path=`cmd //c echo $path` 61792 fi 61793 61794 61795 input_path="$new_path" 61796 # Check if we need to convert this using DOS-style short mode. If the path 61797 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61798 # take no chances and rewrite it. 61799 # Note: m4 eats our [], so we need to use [ and ] instead. 61800 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61801 if test "x$has_forbidden_chars" != x; then 61802 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61803 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61804 fi 61805 61806 61807 windows_path="$new_path" 61808 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61809 unix_path=`$CYGPATH -u "$windows_path"` 61810 new_path="$unix_path" 61811 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61812 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61813 new_path="$unix_path" 61814 fi 61815 61816 if test "x$path" != "x$new_path"; then 61817 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61818 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61819 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61820 fi 61821 61822 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61823 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61824 61825 else 61826 # We're on a unix platform. Hooray! :) 61827 path="$POTENTIAL_FREETYPE_LIB_PATH" 61828 has_space=`$ECHO "$path" | $GREP " "` 61829 if test "x$has_space" != x; then 61830 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61831 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61832 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61833 fi 61834 61835 # Use eval to expand a potential ~ 61836 eval path="$path" 61837 if test ! -f "$path" && test ! -d "$path"; then 61838 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61839 fi 61840 61841 if test -d "$path"; then 61842 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61843 else 61844 dir="`$DIRNAME "$path"`" 61845 base="`$BASENAME "$path"`" 61846 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61847 fi 61848 fi 61849 fi 61850 61851 61852 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61854 $as_echo_n "checking for freetype includes... " >&6; } 61855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61856 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61857 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61859 $as_echo_n "checking for freetype libraries... " >&6; } 61860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61861 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61862 fi 61863 61864 else 61865 61866 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61867 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 61868 METHOD="well-known location" 61869 61870 # Let's start with an optimistic view of the world :-) 61871 FOUND_FREETYPE=yes 61872 61873 # First look for the canonical freetype main include file ft2build.h. 61874 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61875 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61876 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61877 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61878 # Fail. 61879 FOUND_FREETYPE=no 61880 fi 61881 fi 61882 61883 if test "x$FOUND_FREETYPE" = xyes; then 61884 # Include file found, let's continue the sanity check. 61885 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61886 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61887 61888 # Reset to default value 61889 FREETYPE_BASE_NAME=freetype 61890 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61891 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61892 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61893 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61894 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61895 # for the .6 version explicitly. 61896 FREETYPE_BASE_NAME=freetype.6 61897 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61898 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61899 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61900 else 61901 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61902 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61903 FOUND_FREETYPE=no 61904 fi 61905 else 61906 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61907 # On Windows, we will need both .lib and .dll file. 61908 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61909 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61910 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61911 FOUND_FREETYPE=no 61912 fi 61913 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61914 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61915 # Found lib in isa dir, use that instead. 61916 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61917 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61918 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61919 fi 61920 fi 61921 fi 61922 61923 if test "x$FOUND_FREETYPE" = xyes; then 61924 61925 # Only process if variable expands to non-empty 61926 61927 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61929 61930 # Input might be given as Windows format, start by converting to 61931 # unix format. 61932 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61933 new_path=`$CYGPATH -u "$path"` 61934 61935 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61936 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61937 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61938 # "foo.exe" is OK but "foo" is an error. 61939 # 61940 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61941 # It is also a way to make sure we got the proper file name for the real test later on. 61942 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61943 if test "x$test_shortpath" = x; then 61944 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61945 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61946 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61947 fi 61948 61949 # Call helper function which possibly converts this using DOS-style short mode. 61950 # If so, the updated path is stored in $new_path. 61951 61952 input_path="$new_path" 61953 # Check if we need to convert this using DOS-style short mode. If the path 61954 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61955 # take no chances and rewrite it. 61956 # Note: m4 eats our [], so we need to use [ and ] instead. 61957 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61958 if test "x$has_forbidden_chars" != x; then 61959 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61960 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61961 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61962 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61963 # Going to short mode and back again did indeed matter. Since short mode is 61964 # case insensitive, let's make it lowercase to improve readability. 61965 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61966 # Now convert it back to Unix-style (cygpath) 61967 input_path=`$CYGPATH -u "$shortmode_path"` 61968 new_path="$input_path" 61969 fi 61970 fi 61971 61972 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61973 if test "x$test_cygdrive_prefix" = x; then 61974 # As a simple fix, exclude /usr/bin since it's not a real path. 61975 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61976 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61977 # a path prefixed by /cygdrive for fixpath to work. 61978 new_path="$CYGWIN_ROOT_PATH$input_path" 61979 fi 61980 fi 61981 61982 61983 if test "x$path" != "x$new_path"; then 61984 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61985 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61986 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61987 fi 61988 61989 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61990 61991 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61992 has_colon=`$ECHO $path | $GREP ^.:` 61993 new_path="$path" 61994 if test "x$has_colon" = x; then 61995 # Not in mixed or Windows style, start by that. 61996 new_path=`cmd //c echo $path` 61997 fi 61998 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 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62009 fi 62010 62011 62012 windows_path="$new_path" 62013 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62014 unix_path=`$CYGPATH -u "$windows_path"` 62015 new_path="$unix_path" 62016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62017 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62018 new_path="$unix_path" 62019 fi 62020 62021 if test "x$path" != "x$new_path"; then 62022 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62023 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62024 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62025 fi 62026 62027 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62028 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62029 62030 else 62031 # We're on a unix platform. Hooray! :) 62032 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62033 has_space=`$ECHO "$path" | $GREP " "` 62034 if test "x$has_space" != x; then 62035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62036 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62037 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62038 fi 62039 62040 # Use eval to expand a potential ~ 62041 eval path="$path" 62042 if test ! -f "$path" && test ! -d "$path"; then 62043 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62044 fi 62045 62046 if test -d "$path"; then 62047 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62048 else 62049 dir="`$DIRNAME "$path"`" 62050 base="`$BASENAME "$path"`" 62051 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62052 fi 62053 fi 62054 fi 62055 62056 62057 # Only process if variable expands to non-empty 62058 62059 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62060 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62061 62062 # Input might be given as Windows format, start by converting to 62063 # unix format. 62064 path="$POTENTIAL_FREETYPE_LIB_PATH" 62065 new_path=`$CYGPATH -u "$path"` 62066 62067 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62068 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62069 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62070 # "foo.exe" is OK but "foo" is an error. 62071 # 62072 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62073 # It is also a way to make sure we got the proper file name for the real test later on. 62074 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62075 if test "x$test_shortpath" = x; then 62076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62077 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62078 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62079 fi 62080 62081 # Call helper function which possibly converts this using DOS-style short mode. 62082 # If so, the updated path is stored in $new_path. 62083 62084 input_path="$new_path" 62085 # Check if we need to convert this using DOS-style short mode. If the path 62086 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62087 # take no chances and rewrite it. 62088 # Note: m4 eats our [], so we need to use [ and ] instead. 62089 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62090 if test "x$has_forbidden_chars" != x; then 62091 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62092 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62093 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62094 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62095 # Going to short mode and back again did indeed matter. Since short mode is 62096 # case insensitive, let's make it lowercase to improve readability. 62097 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62098 # Now convert it back to Unix-style (cygpath) 62099 input_path=`$CYGPATH -u "$shortmode_path"` 62100 new_path="$input_path" 62101 fi 62102 fi 62103 62104 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62105 if test "x$test_cygdrive_prefix" = x; then 62106 # As a simple fix, exclude /usr/bin since it's not a real path. 62107 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62108 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62109 # a path prefixed by /cygdrive for fixpath to work. 62110 new_path="$CYGWIN_ROOT_PATH$input_path" 62111 fi 62112 fi 62113 62114 62115 if test "x$path" != "x$new_path"; then 62116 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62117 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62118 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62119 fi 62120 62121 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62122 62123 path="$POTENTIAL_FREETYPE_LIB_PATH" 62124 has_colon=`$ECHO $path | $GREP ^.:` 62125 new_path="$path" 62126 if test "x$has_colon" = x; then 62127 # Not in mixed or Windows style, start by that. 62128 new_path=`cmd //c echo $path` 62129 fi 62130 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 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62141 fi 62142 62143 62144 windows_path="$new_path" 62145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62146 unix_path=`$CYGPATH -u "$windows_path"` 62147 new_path="$unix_path" 62148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62149 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62150 new_path="$unix_path" 62151 fi 62152 62153 if test "x$path" != "x$new_path"; then 62154 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62155 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62156 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62157 fi 62158 62159 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62160 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62161 62162 else 62163 # We're on a unix platform. Hooray! :) 62164 path="$POTENTIAL_FREETYPE_LIB_PATH" 62165 has_space=`$ECHO "$path" | $GREP " "` 62166 if test "x$has_space" != x; then 62167 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62168 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62169 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62170 fi 62171 62172 # Use eval to expand a potential ~ 62173 eval path="$path" 62174 if test ! -f "$path" && test ! -d "$path"; then 62175 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62176 fi 62177 62178 if test -d "$path"; then 62179 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62180 else 62181 dir="`$DIRNAME "$path"`" 62182 base="`$BASENAME "$path"`" 62183 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62184 fi 62185 fi 62186 fi 62187 62188 62189 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62191 $as_echo_n "checking for freetype includes... " >&6; } 62192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62193 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62194 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62196 $as_echo_n "checking for freetype libraries... " >&6; } 62197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62198 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62199 fi 62200 62201 if test "x$FOUND_FREETYPE" != xyes; then 62202 62203 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62204 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 62205 METHOD="well-known location" 62206 62207 # Let's start with an optimistic view of the world :-) 62208 FOUND_FREETYPE=yes 62209 62210 # First look for the canonical freetype main include file ft2build.h. 62211 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62212 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62213 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62214 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62215 # Fail. 62216 FOUND_FREETYPE=no 62217 fi 62218 fi 62219 62220 if test "x$FOUND_FREETYPE" = xyes; then 62221 # Include file found, let's continue the sanity check. 62222 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62223 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62224 62225 # Reset to default value 62226 FREETYPE_BASE_NAME=freetype 62227 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62228 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62229 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62230 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62231 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62232 # for the .6 version explicitly. 62233 FREETYPE_BASE_NAME=freetype.6 62234 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62235 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62236 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62237 else 62238 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62239 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62240 FOUND_FREETYPE=no 62241 fi 62242 else 62243 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62244 # On Windows, we will need both .lib and .dll file. 62245 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62246 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62247 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62248 FOUND_FREETYPE=no 62249 fi 62250 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62251 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62252 # Found lib in isa dir, use that instead. 62253 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62254 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62255 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62256 fi 62257 fi 62258 fi 62259 62260 if test "x$FOUND_FREETYPE" = xyes; then 62261 62262 # Only process if variable expands to non-empty 62263 62264 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62265 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62266 62267 # Input might be given as Windows format, start by converting to 62268 # unix format. 62269 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62270 new_path=`$CYGPATH -u "$path"` 62271 62272 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62273 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62274 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62275 # "foo.exe" is OK but "foo" is an error. 62276 # 62277 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62278 # It is also a way to make sure we got the proper file name for the real test later on. 62279 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62280 if test "x$test_shortpath" = x; then 62281 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62282 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62283 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62284 fi 62285 62286 # Call helper function which possibly converts this using DOS-style short mode. 62287 # If so, the updated path is stored in $new_path. 62288 62289 input_path="$new_path" 62290 # Check if we need to convert this using DOS-style short mode. If the path 62291 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62292 # take no chances and rewrite it. 62293 # Note: m4 eats our [], so we need to use [ and ] instead. 62294 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62295 if test "x$has_forbidden_chars" != x; then 62296 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62297 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62298 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62299 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62300 # Going to short mode and back again did indeed matter. Since short mode is 62301 # case insensitive, let's make it lowercase to improve readability. 62302 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62303 # Now convert it back to Unix-style (cygpath) 62304 input_path=`$CYGPATH -u "$shortmode_path"` 62305 new_path="$input_path" 62306 fi 62307 fi 62308 62309 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62310 if test "x$test_cygdrive_prefix" = x; then 62311 # As a simple fix, exclude /usr/bin since it's not a real path. 62312 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62313 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62314 # a path prefixed by /cygdrive for fixpath to work. 62315 new_path="$CYGWIN_ROOT_PATH$input_path" 62316 fi 62317 fi 62318 62319 62320 if test "x$path" != "x$new_path"; then 62321 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62322 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62323 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62324 fi 62325 62326 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62327 62328 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62329 has_colon=`$ECHO $path | $GREP ^.:` 62330 new_path="$path" 62331 if test "x$has_colon" = x; then 62332 # Not in mixed or Windows style, start by that. 62333 new_path=`cmd //c echo $path` 62334 fi 62335 62336 62337 input_path="$new_path" 62338 # Check if we need to convert this using DOS-style short mode. If the path 62339 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62340 # take no chances and rewrite it. 62341 # Note: m4 eats our [], so we need to use [ and ] instead. 62342 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62343 if test "x$has_forbidden_chars" != x; then 62344 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62345 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62346 fi 62347 62348 62349 windows_path="$new_path" 62350 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62351 unix_path=`$CYGPATH -u "$windows_path"` 62352 new_path="$unix_path" 62353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62354 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62355 new_path="$unix_path" 62356 fi 62357 62358 if test "x$path" != "x$new_path"; then 62359 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62360 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62361 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62362 fi 62363 62364 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62365 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62366 62367 else 62368 # We're on a unix platform. Hooray! :) 62369 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62370 has_space=`$ECHO "$path" | $GREP " "` 62371 if test "x$has_space" != x; then 62372 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62373 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62374 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62375 fi 62376 62377 # Use eval to expand a potential ~ 62378 eval path="$path" 62379 if test ! -f "$path" && test ! -d "$path"; then 62380 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62381 fi 62382 62383 if test -d "$path"; then 62384 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62385 else 62386 dir="`$DIRNAME "$path"`" 62387 base="`$BASENAME "$path"`" 62388 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62389 fi 62390 fi 62391 fi 62392 62393 62394 # Only process if variable expands to non-empty 62395 62396 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62398 62399 # Input might be given as Windows format, start by converting to 62400 # unix format. 62401 path="$POTENTIAL_FREETYPE_LIB_PATH" 62402 new_path=`$CYGPATH -u "$path"` 62403 62404 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62405 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62406 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62407 # "foo.exe" is OK but "foo" is an error. 62408 # 62409 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62410 # It is also a way to make sure we got the proper file name for the real test later on. 62411 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62412 if test "x$test_shortpath" = x; then 62413 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62414 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62415 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62416 fi 62417 62418 # Call helper function which possibly converts this using DOS-style short mode. 62419 # If so, the updated path is stored in $new_path. 62420 62421 input_path="$new_path" 62422 # Check if we need to convert this using DOS-style short mode. If the path 62423 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62424 # take no chances and rewrite it. 62425 # Note: m4 eats our [], so we need to use [ and ] instead. 62426 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62427 if test "x$has_forbidden_chars" != x; then 62428 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62429 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62430 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62431 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62432 # Going to short mode and back again did indeed matter. Since short mode is 62433 # case insensitive, let's make it lowercase to improve readability. 62434 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62435 # Now convert it back to Unix-style (cygpath) 62436 input_path=`$CYGPATH -u "$shortmode_path"` 62437 new_path="$input_path" 62438 fi 62439 fi 62440 62441 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62442 if test "x$test_cygdrive_prefix" = x; then 62443 # As a simple fix, exclude /usr/bin since it's not a real path. 62444 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62445 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62446 # a path prefixed by /cygdrive for fixpath to work. 62447 new_path="$CYGWIN_ROOT_PATH$input_path" 62448 fi 62449 fi 62450 62451 62452 if test "x$path" != "x$new_path"; then 62453 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62454 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62455 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62456 fi 62457 62458 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62459 62460 path="$POTENTIAL_FREETYPE_LIB_PATH" 62461 has_colon=`$ECHO $path | $GREP ^.:` 62462 new_path="$path" 62463 if test "x$has_colon" = x; then 62464 # Not in mixed or Windows style, start by that. 62465 new_path=`cmd //c echo $path` 62466 fi 62467 62468 62469 input_path="$new_path" 62470 # Check if we need to convert this using DOS-style short mode. If the path 62471 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62472 # take no chances and rewrite it. 62473 # Note: m4 eats our [], so we need to use [ and ] instead. 62474 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62475 if test "x$has_forbidden_chars" != x; then 62476 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62477 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62478 fi 62479 62480 62481 windows_path="$new_path" 62482 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62483 unix_path=`$CYGPATH -u "$windows_path"` 62484 new_path="$unix_path" 62485 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62486 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62487 new_path="$unix_path" 62488 fi 62489 62490 if test "x$path" != "x$new_path"; then 62491 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62492 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62493 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62494 fi 62495 62496 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62497 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62498 62499 else 62500 # We're on a unix platform. Hooray! :) 62501 path="$POTENTIAL_FREETYPE_LIB_PATH" 62502 has_space=`$ECHO "$path" | $GREP " "` 62503 if test "x$has_space" != x; then 62504 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62505 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62506 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62507 fi 62508 62509 # Use eval to expand a potential ~ 62510 eval path="$path" 62511 if test ! -f "$path" && test ! -d "$path"; then 62512 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62513 fi 62514 62515 if test -d "$path"; then 62516 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62517 else 62518 dir="`$DIRNAME "$path"`" 62519 base="`$BASENAME "$path"`" 62520 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62521 fi 62522 fi 62523 fi 62524 62525 62526 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62528 $as_echo_n "checking for freetype includes... " >&6; } 62529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62530 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62531 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62533 $as_echo_n "checking for freetype libraries... " >&6; } 62534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62535 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62536 fi 62537 62538 fi 62539 fi 62540 fi 62541 fi 62542 fi # end check in well-known locations 62543 62544 if test "x$FOUND_FREETYPE" != xyes; then 62545 62546 # Print a helpful message on how to acquire the necessary build dependency. 62547 # freetype is the help tag: freetype, cups, alsa etc 62548 MISSING_DEPENDENCY=freetype 62549 62550 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62551 cygwin_help $MISSING_DEPENDENCY 62552 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62553 msys_help $MISSING_DEPENDENCY 62554 else 62555 PKGHANDLER_COMMAND= 62556 62557 case $PKGHANDLER in 62558 apt-get) 62559 apt_help $MISSING_DEPENDENCY ;; 62560 yum) 62561 yum_help $MISSING_DEPENDENCY ;; 62562 port) 62563 port_help $MISSING_DEPENDENCY ;; 62564 pkgutil) 62565 pkgutil_help $MISSING_DEPENDENCY ;; 62566 pkgadd) 62567 pkgadd_help $MISSING_DEPENDENCY ;; 62568 esac 62569 62570 if test "x$PKGHANDLER_COMMAND" != x; then 62571 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62572 fi 62573 fi 62574 62575 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 62576 fi 62577 fi # end user specified settings 62578 62579 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 62580 if test "x$FREETYPE_CFLAGS" = x; then 62581 62582 # Only process if variable expands to non-empty 62583 62584 if test "x$FREETYPE_INCLUDE_PATH" != x; then 62585 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62586 62587 # Input might be given as Windows format, start by converting to 62588 # unix format. 62589 path="$FREETYPE_INCLUDE_PATH" 62590 new_path=`$CYGPATH -u "$path"` 62591 62592 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62593 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62594 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62595 # "foo.exe" is OK but "foo" is an error. 62596 # 62597 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62598 # It is also a way to make sure we got the proper file name for the real test later on. 62599 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62600 if test "x$test_shortpath" = x; then 62601 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62602 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62603 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 62604 fi 62605 62606 # Call helper function which possibly converts this using DOS-style short mode. 62607 # If so, the updated path is stored in $new_path. 62608 62609 input_path="$new_path" 62610 # Check if we need to convert this using DOS-style short mode. If the path 62611 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62612 # take no chances and rewrite it. 62613 # Note: m4 eats our [], so we need to use [ and ] instead. 62614 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62615 if test "x$has_forbidden_chars" != x; then 62616 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62617 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62618 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62619 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62620 # Going to short mode and back again did indeed matter. Since short mode is 62621 # case insensitive, let's make it lowercase to improve readability. 62622 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62623 # Now convert it back to Unix-style (cygpath) 62624 input_path=`$CYGPATH -u "$shortmode_path"` 62625 new_path="$input_path" 62626 fi 62627 fi 62628 62629 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62630 if test "x$test_cygdrive_prefix" = x; then 62631 # As a simple fix, exclude /usr/bin since it's not a real path. 62632 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62633 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62634 # a path prefixed by /cygdrive for fixpath to work. 62635 new_path="$CYGWIN_ROOT_PATH$input_path" 62636 fi 62637 fi 62638 62639 62640 if test "x$path" != "x$new_path"; then 62641 FREETYPE_INCLUDE_PATH="$new_path" 62642 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62643 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62644 fi 62645 62646 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62647 62648 path="$FREETYPE_INCLUDE_PATH" 62649 has_colon=`$ECHO $path | $GREP ^.:` 62650 new_path="$path" 62651 if test "x$has_colon" = x; then 62652 # Not in mixed or Windows style, start by that. 62653 new_path=`cmd //c echo $path` 62654 fi 62655 62656 62657 input_path="$new_path" 62658 # Check if we need to convert this using DOS-style short mode. If the path 62659 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62660 # take no chances and rewrite it. 62661 # Note: m4 eats our [], so we need to use [ and ] instead. 62662 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62663 if test "x$has_forbidden_chars" != x; then 62664 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62665 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62666 fi 62667 62668 62669 windows_path="$new_path" 62670 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62671 unix_path=`$CYGPATH -u "$windows_path"` 62672 new_path="$unix_path" 62673 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62674 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62675 new_path="$unix_path" 62676 fi 62677 62678 if test "x$path" != "x$new_path"; then 62679 FREETYPE_INCLUDE_PATH="$new_path" 62680 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62681 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62682 fi 62683 62684 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62685 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62686 62687 else 62688 # We're on a unix platform. Hooray! :) 62689 path="$FREETYPE_INCLUDE_PATH" 62690 has_space=`$ECHO "$path" | $GREP " "` 62691 if test "x$has_space" != x; then 62692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62693 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62694 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62695 fi 62696 62697 # Use eval to expand a potential ~ 62698 eval path="$path" 62699 if test ! -f "$path" && test ! -d "$path"; then 62700 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62701 fi 62702 62703 if test -d "$path"; then 62704 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62705 else 62706 dir="`$DIRNAME "$path"`" 62707 base="`$BASENAME "$path"`" 62708 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62709 fi 62710 fi 62711 fi 62712 62713 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 62714 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 62715 else 62716 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 62717 fi 62718 fi 62719 62720 if test "x$FREETYPE_LIBS" = x; then 62721 62722 # Only process if variable expands to non-empty 62723 62724 if test "x$FREETYPE_LIB_PATH" != x; then 62725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62726 62727 # Input might be given as Windows format, start by converting to 62728 # unix format. 62729 path="$FREETYPE_LIB_PATH" 62730 new_path=`$CYGPATH -u "$path"` 62731 62732 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62733 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62734 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62735 # "foo.exe" is OK but "foo" is an error. 62736 # 62737 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62738 # It is also a way to make sure we got the proper file name for the real test later on. 62739 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62740 if test "x$test_shortpath" = x; then 62741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62742 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62743 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 62744 fi 62745 62746 # Call helper function which possibly converts this using DOS-style short mode. 62747 # If so, the updated path is stored in $new_path. 62748 62749 input_path="$new_path" 62750 # Check if we need to convert this using DOS-style short mode. If the path 62751 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62752 # take no chances and rewrite it. 62753 # Note: m4 eats our [], so we need to use [ and ] instead. 62754 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62755 if test "x$has_forbidden_chars" != x; then 62756 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62757 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62758 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62759 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62760 # Going to short mode and back again did indeed matter. Since short mode is 62761 # case insensitive, let's make it lowercase to improve readability. 62762 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62763 # Now convert it back to Unix-style (cygpath) 62764 input_path=`$CYGPATH -u "$shortmode_path"` 62765 new_path="$input_path" 62766 fi 62767 fi 62768 62769 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62770 if test "x$test_cygdrive_prefix" = x; then 62771 # As a simple fix, exclude /usr/bin since it's not a real path. 62772 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62773 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62774 # a path prefixed by /cygdrive for fixpath to work. 62775 new_path="$CYGWIN_ROOT_PATH$input_path" 62776 fi 62777 fi 62778 62779 62780 if test "x$path" != "x$new_path"; then 62781 FREETYPE_LIB_PATH="$new_path" 62782 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62783 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62784 fi 62785 62786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62787 62788 path="$FREETYPE_LIB_PATH" 62789 has_colon=`$ECHO $path | $GREP ^.:` 62790 new_path="$path" 62791 if test "x$has_colon" = x; then 62792 # Not in mixed or Windows style, start by that. 62793 new_path=`cmd //c echo $path` 62794 fi 62795 62796 62797 input_path="$new_path" 62798 # Check if we need to convert this using DOS-style short mode. If the path 62799 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62800 # take no chances and rewrite it. 62801 # Note: m4 eats our [], so we need to use [ and ] instead. 62802 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62803 if test "x$has_forbidden_chars" != x; then 62804 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62805 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62806 fi 62807 62808 62809 windows_path="$new_path" 62810 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62811 unix_path=`$CYGPATH -u "$windows_path"` 62812 new_path="$unix_path" 62813 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62814 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62815 new_path="$unix_path" 62816 fi 62817 62818 if test "x$path" != "x$new_path"; then 62819 FREETYPE_LIB_PATH="$new_path" 62820 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62821 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62822 fi 62823 62824 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62825 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62826 62827 else 62828 # We're on a unix platform. Hooray! :) 62829 path="$FREETYPE_LIB_PATH" 62830 has_space=`$ECHO "$path" | $GREP " "` 62831 if test "x$has_space" != x; then 62832 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62833 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62834 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62835 fi 62836 62837 # Use eval to expand a potential ~ 62838 eval path="$path" 62839 if test ! -f "$path" && test ! -d "$path"; then 62840 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62841 fi 62842 62843 if test -d "$path"; then 62844 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62845 else 62846 dir="`$DIRNAME "$path"`" 62847 base="`$BASENAME "$path"`" 62848 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62849 fi 62850 fi 62851 fi 62852 62853 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62854 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 62855 else 62856 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 62857 fi 62858 fi 62859 62860 # Try to compile it 62861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 62862 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 62863 ac_ext=cpp 62864 ac_cpp='$CXXCPP $CPPFLAGS' 62865 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62866 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62867 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62868 62869 PREV_CXXCFLAGS="$CXXFLAGS" 62870 PREV_LIBS="$LIBS" 62871 PREV_CXX="$CXX" 62872 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 62873 LIBS="$LIBS $FREETYPE_LIBS" 62874 CXX="$FIXPATH $CXX" 62875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62876 /* end confdefs.h. */ 62877 62878 #include<ft2build.h> 62879 #include FT_FREETYPE_H 62880 int main () { 62881 FT_Init_FreeType(NULL); 62882 return 0; 62883 } 62884 62885 _ACEOF 62886 if ac_fn_cxx_try_link "$LINENO"; then : 62887 62888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62889 $as_echo "yes" >&6; } 62890 62891 else 62892 62893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62894 $as_echo "no" >&6; } 62895 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 62896 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 62897 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 62898 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 62899 62900 62901 # Print a helpful message on how to acquire the necessary build dependency. 62902 # freetype is the help tag: freetype, cups, alsa etc 62903 MISSING_DEPENDENCY=freetype 62904 62905 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62906 cygwin_help $MISSING_DEPENDENCY 62907 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62908 msys_help $MISSING_DEPENDENCY 62909 else 62910 PKGHANDLER_COMMAND= 62911 62912 case $PKGHANDLER in 62913 apt-get) 62914 apt_help $MISSING_DEPENDENCY ;; 62915 yum) 62916 yum_help $MISSING_DEPENDENCY ;; 62917 port) 62918 port_help $MISSING_DEPENDENCY ;; 62919 pkgutil) 62920 pkgutil_help $MISSING_DEPENDENCY ;; 62921 pkgadd) 62922 pkgadd_help $MISSING_DEPENDENCY ;; 62923 esac 62924 62925 if test "x$PKGHANDLER_COMMAND" != x; then 62926 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62927 fi 62928 fi 62929 62930 62931 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 62932 62933 62934 fi 62935 rm -f core conftest.err conftest.$ac_objext \ 62936 conftest$ac_exeext conftest.$ac_ext 62937 CXXCFLAGS="$PREV_CXXFLAGS" 62938 LIBS="$PREV_LIBS" 62939 CXX="$PREV_CXX" 62940 ac_ext=cpp 62941 ac_cpp='$CXXCPP $CPPFLAGS' 62942 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62943 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62944 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62945 62946 62947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 62948 $as_echo_n "checking if we should bundle freetype... " >&6; } 62949 if test "x$BUNDLE_FREETYPE" = xyes; then 62950 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 62951 fi 62952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 62953 $as_echo "$BUNDLE_FREETYPE" >&6; } 62954 62955 fi # end freetype needed 62956 62957 62958 62959 62960 62961 62962 62963 # Check whether --with-alsa was given. 62964 if test "${with_alsa+set}" = set; then : 62965 withval=$with_alsa; 62966 fi 62967 62968 62969 # Check whether --with-alsa-include was given. 62970 if test "${with_alsa_include+set}" = set; then : 62971 withval=$with_alsa_include; 62972 fi 62973 62974 62975 # Check whether --with-alsa-lib was given. 62976 if test "${with_alsa_lib+set}" = set; then : 62977 withval=$with_alsa_lib; 62978 fi 62979 62980 62981 if test "x$NEEDS_LIB_ALSA" = xfalse; then 62982 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 62983 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 62984 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 62985 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 62986 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 62987 fi 62988 ALSA_CFLAGS= 62989 ALSA_LIBS= 62990 else 62991 ALSA_FOUND=no 62992 62993 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 62994 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 62995 fi 62996 62997 if test "x${with_alsa}" != x; then 62998 ALSA_LIBS="-L${with_alsa}/lib -lasound" 62999 ALSA_CFLAGS="-I${with_alsa}/include" 63000 ALSA_FOUND=yes 63001 fi 63002 if test "x${with_alsa_include}" != x; then 63003 ALSA_CFLAGS="-I${with_alsa_include}" 63004 ALSA_FOUND=yes 63005 fi 63006 if test "x${with_alsa_lib}" != x; then 63007 ALSA_LIBS="-L${with_alsa_lib} -lasound" 63008 ALSA_FOUND=yes 63009 fi 63010 # Do not try pkg-config if we have a sysroot set. 63011 if test "x$SYSROOT" = x; then 63012 if test "x$ALSA_FOUND" = xno; then 63013 63014 pkg_failed=no 63015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 63016 $as_echo_n "checking for ALSA... " >&6; } 63017 63018 if test -n "$ALSA_CFLAGS"; then 63019 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 63020 elif test -n "$PKG_CONFIG"; then 63021 if test -n "$PKG_CONFIG" && \ 63022 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 63023 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 63024 ac_status=$? 63025 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63026 test $ac_status = 0; }; then 63027 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 63028 else 63029 pkg_failed=yes 63030 fi 63031 else 63032 pkg_failed=untried 63033 fi 63034 if test -n "$ALSA_LIBS"; then 63035 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 63036 elif test -n "$PKG_CONFIG"; then 63037 if test -n "$PKG_CONFIG" && \ 63038 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 63039 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 63040 ac_status=$? 63041 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63042 test $ac_status = 0; }; then 63043 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 63044 else 63045 pkg_failed=yes 63046 fi 63047 else 63048 pkg_failed=untried 63049 fi 63050 63051 63052 63053 if test $pkg_failed = yes; then 63054 63055 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63056 _pkg_short_errors_supported=yes 63057 else 63058 _pkg_short_errors_supported=no 63059 fi 63060 if test $_pkg_short_errors_supported = yes; then 63061 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 63062 else 63063 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 63064 fi 63065 # Put the nasty error message in config.log where it belongs 63066 echo "$ALSA_PKG_ERRORS" >&5 63067 63068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63069 $as_echo "no" >&6; } 63070 ALSA_FOUND=no 63071 elif test $pkg_failed = untried; then 63072 ALSA_FOUND=no 63073 else 63074 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 63075 ALSA_LIBS=$pkg_cv_ALSA_LIBS 63076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63077 $as_echo "yes" >&6; } 63078 ALSA_FOUND=yes 63079 fi 63080 fi 63081 fi 63082 if test "x$ALSA_FOUND" = xno; then 63083 for ac_header in alsa/asoundlib.h 63084 do : 63085 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 63086 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 63087 cat >>confdefs.h <<_ACEOF 63088 #define HAVE_ALSA_ASOUNDLIB_H 1 63089 _ACEOF 63090 63091 ALSA_FOUND=yes 63092 ALSA_CFLAGS=-Iignoreme 63093 ALSA_LIBS=-lasound 63094 DEFAULT_ALSA=yes 63095 63096 else 63097 ALSA_FOUND=no 63098 63099 fi 63100 63101 done 63102 63103 fi 63104 if test "x$ALSA_FOUND" = xno; then 63105 63106 # Print a helpful message on how to acquire the necessary build dependency. 63107 # alsa is the help tag: freetype, cups, alsa etc 63108 MISSING_DEPENDENCY=alsa 63109 63110 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63111 cygwin_help $MISSING_DEPENDENCY 63112 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63113 msys_help $MISSING_DEPENDENCY 63114 else 63115 PKGHANDLER_COMMAND= 63116 63117 case $PKGHANDLER in 63118 apt-get) 63119 apt_help $MISSING_DEPENDENCY ;; 63120 yum) 63121 yum_help $MISSING_DEPENDENCY ;; 63122 port) 63123 port_help $MISSING_DEPENDENCY ;; 63124 pkgutil) 63125 pkgutil_help $MISSING_DEPENDENCY ;; 63126 pkgadd) 63127 pkgadd_help $MISSING_DEPENDENCY ;; 63128 esac 63129 63130 if test "x$PKGHANDLER_COMMAND" != x; then 63131 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63132 fi 63133 fi 63134 63135 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 63136 fi 63137 fi 63138 63139 63140 63141 63142 63143 63144 # Check whether --with-libffi was given. 63145 if test "${with_libffi+set}" = set; then : 63146 withval=$with_libffi; 63147 fi 63148 63149 63150 # Check whether --with-libffi-include was given. 63151 if test "${with_libffi_include+set}" = set; then : 63152 withval=$with_libffi_include; 63153 fi 63154 63155 63156 # Check whether --with-libffi-lib was given. 63157 if test "${with_libffi_lib+set}" = set; then : 63158 withval=$with_libffi_lib; 63159 fi 63160 63161 63162 if test "x$NEEDS_LIB_FFI" = xfalse; then 63163 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 63164 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 63165 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 63166 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 63167 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 63168 fi 63169 LIBFFI_CFLAGS= 63170 LIBFFI_LIBS= 63171 else 63172 LIBFFI_FOUND=no 63173 63174 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 63175 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 63176 fi 63177 63178 if test "x${with_libffi}" != x; then 63179 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 63180 LIBFFI_CFLAGS="-I${with_libffi}/include" 63181 LIBFFI_FOUND=yes 63182 fi 63183 if test "x${with_libffi_include}" != x; then 63184 LIBFFI_CFLAGS="-I${with_libffi_include}" 63185 LIBFFI_FOUND=yes 63186 fi 63187 if test "x${with_libffi_lib}" != x; then 63188 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 63189 LIBFFI_FOUND=yes 63190 fi 63191 # Do not try pkg-config if we have a sysroot set. 63192 if test "x$SYSROOT" = x; then 63193 if test "x$LIBFFI_FOUND" = xno; then 63194 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 63195 63196 pkg_failed=no 63197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 63198 $as_echo_n "checking for LIBFFI... " >&6; } 63199 63200 if test -n "$LIBFFI_CFLAGS"; then 63201 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 63202 elif test -n "$PKG_CONFIG"; then 63203 if test -n "$PKG_CONFIG" && \ 63204 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 63205 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 63206 ac_status=$? 63207 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63208 test $ac_status = 0; }; then 63209 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 63210 else 63211 pkg_failed=yes 63212 fi 63213 else 63214 pkg_failed=untried 63215 fi 63216 if test -n "$LIBFFI_LIBS"; then 63217 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 63218 elif test -n "$PKG_CONFIG"; then 63219 if test -n "$PKG_CONFIG" && \ 63220 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 63221 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 63222 ac_status=$? 63223 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63224 test $ac_status = 0; }; then 63225 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 63226 else 63227 pkg_failed=yes 63228 fi 63229 else 63230 pkg_failed=untried 63231 fi 63232 63233 63234 63235 if test $pkg_failed = yes; then 63236 63237 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63238 _pkg_short_errors_supported=yes 63239 else 63240 _pkg_short_errors_supported=no 63241 fi 63242 if test $_pkg_short_errors_supported = yes; then 63243 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 63244 else 63245 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 63246 fi 63247 # Put the nasty error message in config.log where it belongs 63248 echo "$LIBFFI_PKG_ERRORS" >&5 63249 63250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63251 $as_echo "no" >&6; } 63252 LIBFFI_FOUND=no 63253 elif test $pkg_failed = untried; then 63254 LIBFFI_FOUND=no 63255 else 63256 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 63257 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 63258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63259 $as_echo "yes" >&6; } 63260 LIBFFI_FOUND=yes 63261 fi 63262 fi 63263 fi 63264 if test "x$LIBFFI_FOUND" = xno; then 63265 for ac_header in ffi.h 63266 do : 63267 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 63268 if test "x$ac_cv_header_ffi_h" = xyes; then : 63269 cat >>confdefs.h <<_ACEOF 63270 #define HAVE_FFI_H 1 63271 _ACEOF 63272 63273 LIBFFI_FOUND=yes 63274 LIBFFI_CFLAGS= 63275 LIBFFI_LIBS=-lffi 63276 63277 else 63278 LIBFFI_FOUND=no 63279 63280 fi 63281 63282 done 63283 63284 fi 63285 if test "x$LIBFFI_FOUND" = xno; then 63286 63287 # Print a helpful message on how to acquire the necessary build dependency. 63288 # ffi is the help tag: freetype, cups, alsa etc 63289 MISSING_DEPENDENCY=ffi 63290 63291 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63292 cygwin_help $MISSING_DEPENDENCY 63293 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63294 msys_help $MISSING_DEPENDENCY 63295 else 63296 PKGHANDLER_COMMAND= 63297 63298 case $PKGHANDLER in 63299 apt-get) 63300 apt_help $MISSING_DEPENDENCY ;; 63301 yum) 63302 yum_help $MISSING_DEPENDENCY ;; 63303 port) 63304 port_help $MISSING_DEPENDENCY ;; 63305 pkgutil) 63306 pkgutil_help $MISSING_DEPENDENCY ;; 63307 pkgadd) 63308 pkgadd_help $MISSING_DEPENDENCY ;; 63309 esac 63310 63311 if test "x$PKGHANDLER_COMMAND" != x; then 63312 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63313 fi 63314 fi 63315 63316 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 63317 fi 63318 63319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 63320 $as_echo_n "checking if libffi works... " >&6; } 63321 ac_ext=c 63322 ac_cpp='$CPP $CPPFLAGS' 63323 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63324 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63325 ac_compiler_gnu=$ac_cv_c_compiler_gnu 63326 63327 OLD_CFLAGS="$CFLAGS" 63328 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 63329 OLD_LIBS="$LIBS" 63330 LIBS="$LIBS $LIBFFI_LIBS" 63331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63332 /* end confdefs.h. */ 63333 #include <ffi.h> 63334 int 63335 main () 63336 { 63337 63338 ffi_call(NULL, NULL, NULL, NULL); 63339 return 0; 63340 63341 ; 63342 return 0; 63343 } 63344 _ACEOF 63345 if ac_fn_c_try_link "$LINENO"; then : 63346 LIBFFI_WORKS=yes 63347 else 63348 LIBFFI_WORKS=no 63349 63350 fi 63351 rm -f core conftest.err conftest.$ac_objext \ 63352 conftest$ac_exeext conftest.$ac_ext 63353 CFLAGS="$OLD_CFLAGS" 63354 LIBS="$OLD_LIBS" 63355 ac_ext=cpp 63356 ac_cpp='$CXXCPP $CPPFLAGS' 63357 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63358 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63359 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 63360 63361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 63362 $as_echo "$LIBFFI_WORKS" >&6; } 63363 63364 if test "x$LIBFFI_WORKS" = xno; then 63365 63366 # Print a helpful message on how to acquire the necessary build dependency. 63367 # ffi is the help tag: freetype, cups, alsa etc 63368 MISSING_DEPENDENCY=ffi 63369 63370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63371 cygwin_help $MISSING_DEPENDENCY 63372 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63373 msys_help $MISSING_DEPENDENCY 63374 else 63375 PKGHANDLER_COMMAND= 63376 63377 case $PKGHANDLER in 63378 apt-get) 63379 apt_help $MISSING_DEPENDENCY ;; 63380 yum) 63381 yum_help $MISSING_DEPENDENCY ;; 63382 port) 63383 port_help $MISSING_DEPENDENCY ;; 63384 pkgutil) 63385 pkgutil_help $MISSING_DEPENDENCY ;; 63386 pkgadd) 63387 pkgadd_help $MISSING_DEPENDENCY ;; 63388 esac 63389 63390 if test "x$PKGHANDLER_COMMAND" != x; then 63391 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63392 fi 63393 fi 63394 63395 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 63396 fi 63397 fi 63398 63399 63400 63401 63402 63403 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 63404 # Extract the first word of "llvm-config", so it can be a program name with args. 63405 set dummy llvm-config; ac_word=$2 63406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 63407 $as_echo_n "checking for $ac_word... " >&6; } 63408 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 63409 $as_echo_n "(cached) " >&6 63410 else 63411 if test -n "$LLVM_CONFIG"; then 63412 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 63413 else 63414 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 63415 for as_dir in $PATH 63416 do 63417 IFS=$as_save_IFS 63418 test -z "$as_dir" && as_dir=. 63419 for ac_exec_ext in '' $ac_executable_extensions; do 63420 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 63421 ac_cv_prog_LLVM_CONFIG="llvm-config" 63422 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 63423 break 2 63424 fi 63425 done 63426 done 63427 IFS=$as_save_IFS 63428 63429 fi 63430 fi 63431 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 63432 if test -n "$LLVM_CONFIG"; then 63433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 63434 $as_echo "$LLVM_CONFIG" >&6; } 63435 else 63436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63437 $as_echo "no" >&6; } 63438 fi 63439 63440 63441 63442 if test "x$LLVM_CONFIG" != xllvm-config; then 63443 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 63444 fi 63445 63446 llvm_components="jit mcjit engine nativecodegen native" 63447 unset LLVM_CFLAGS 63448 for flag in $("$LLVM_CONFIG" --cxxflags); do 63449 if echo "${flag}" | grep -q '^-[ID]'; then 63450 if test "${flag}" != "-D_DEBUG" ; then 63451 if test "${LLVM_CFLAGS}" != "" ; then 63452 LLVM_CFLAGS="${LLVM_CFLAGS} " 63453 fi 63454 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 63455 fi 63456 fi 63457 done 63458 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 63459 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 63460 63461 unset LLVM_LDFLAGS 63462 for flag in $("${LLVM_CONFIG}" --ldflags); do 63463 if echo "${flag}" | grep -q '^-L'; then 63464 if test "${LLVM_LDFLAGS}" != ""; then 63465 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 63466 fi 63467 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 63468 fi 63469 done 63470 63471 unset LLVM_LIBS 63472 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 63473 if echo "${flag}" | grep -q '^-l'; then 63474 if test "${LLVM_LIBS}" != ""; then 63475 LLVM_LIBS="${LLVM_LIBS} " 63476 fi 63477 LLVM_LIBS="${LLVM_LIBS}${flag}" 63478 fi 63479 done 63480 63481 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 63482 # always properly detect -ltinfo 63483 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 63484 63485 63486 63487 63488 fi 63489 63490 63491 63492 # Check whether --with-libjpeg was given. 63493 if test "${with_libjpeg+set}" = set; then : 63494 withval=$with_libjpeg; 63495 fi 63496 63497 63498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 63499 $as_echo_n "checking for which libjpeg to use... " >&6; } 63500 # default is bundled 63501 DEFAULT_LIBJPEG=bundled 63502 # if user didn't specify, use DEFAULT_LIBJPEG 63503 if test "x${with_libjpeg}" = "x"; then 63504 with_libjpeg=${DEFAULT_LIBJPEG} 63505 fi 63506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 63507 $as_echo "${with_libjpeg}" >&6; } 63508 63509 if test "x${with_libjpeg}" = "xbundled"; then 63510 USE_EXTERNAL_LIBJPEG=false 63511 elif test "x${with_libjpeg}" = "xsystem"; then 63512 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 63513 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 63514 63515 else 63516 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 63517 fi 63518 63519 63520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 63521 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 63522 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 63523 $as_echo_n "(cached) " >&6 63524 else 63525 ac_check_lib_save_LIBS=$LIBS 63526 LIBS="-ljpeg $LIBS" 63527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63528 /* end confdefs.h. */ 63529 63530 /* Override any GCC internal prototype to avoid an error. 63531 Use char because int might match the return type of a GCC 63532 builtin and then its argument prototype would still apply. */ 63533 #ifdef __cplusplus 63534 extern "C" 63535 #endif 63536 char jpeg_CreateDecompress (); 63537 int 63538 main () 63539 { 63540 return jpeg_CreateDecompress (); 63541 ; 63542 return 0; 63543 } 63544 _ACEOF 63545 if ac_fn_cxx_try_link "$LINENO"; then : 63546 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 63547 else 63548 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 63549 fi 63550 rm -f core conftest.err conftest.$ac_objext \ 63551 conftest$ac_exeext conftest.$ac_ext 63552 LIBS=$ac_check_lib_save_LIBS 63553 fi 63554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 63555 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 63556 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 63557 cat >>confdefs.h <<_ACEOF 63558 #define HAVE_LIBJPEG 1 63559 _ACEOF 63560 63561 LIBS="-ljpeg $LIBS" 63562 63563 else 63564 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 63565 fi 63566 63567 63568 USE_EXTERNAL_LIBJPEG=true 63569 else 63570 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 63571 fi 63572 63573 63574 63575 63576 63577 # Check whether --with-giflib was given. 63578 if test "${with_giflib+set}" = set; then : 63579 withval=$with_giflib; 63580 fi 63581 63582 63583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 63584 $as_echo_n "checking for which giflib to use... " >&6; } 63585 # default is bundled 63586 DEFAULT_GIFLIB=bundled 63587 # if user didn't specify, use DEFAULT_GIFLIB 63588 if test "x${with_giflib}" = "x"; then 63589 with_giflib=${DEFAULT_GIFLIB} 63590 fi 63591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 63592 $as_echo "${with_giflib}" >&6; } 63593 63594 if test "x${with_giflib}" = "xbundled"; then 63595 USE_EXTERNAL_LIBGIF=false 63596 elif test "x${with_giflib}" = "xsystem"; then 63597 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 63598 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 63599 63600 else 63601 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 63602 fi 63603 63604 63605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 63606 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 63607 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 63608 $as_echo_n "(cached) " >&6 63609 else 63610 ac_check_lib_save_LIBS=$LIBS 63611 LIBS="-lgif $LIBS" 63612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63613 /* end confdefs.h. */ 63614 63615 /* Override any GCC internal prototype to avoid an error. 63616 Use char because int might match the return type of a GCC 63617 builtin and then its argument prototype would still apply. */ 63618 #ifdef __cplusplus 63619 extern "C" 63620 #endif 63621 char DGifGetCode (); 63622 int 63623 main () 63624 { 63625 return DGifGetCode (); 63626 ; 63627 return 0; 63628 } 63629 _ACEOF 63630 if ac_fn_cxx_try_link "$LINENO"; then : 63631 ac_cv_lib_gif_DGifGetCode=yes 63632 else 63633 ac_cv_lib_gif_DGifGetCode=no 63634 fi 63635 rm -f core conftest.err conftest.$ac_objext \ 63636 conftest$ac_exeext conftest.$ac_ext 63637 LIBS=$ac_check_lib_save_LIBS 63638 fi 63639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 63640 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 63641 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 63642 cat >>confdefs.h <<_ACEOF 63643 #define HAVE_LIBGIF 1 63644 _ACEOF 63645 63646 LIBS="-lgif $LIBS" 63647 63648 else 63649 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 63650 fi 63651 63652 63653 USE_EXTERNAL_LIBGIF=true 63654 else 63655 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 63656 fi 63657 63658 63659 63660 63661 63662 # Check whether --with-libpng was given. 63663 if test "${with_libpng+set}" = set; then : 63664 withval=$with_libpng; 63665 fi 63666 63667 63668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 63669 $as_echo_n "checking for which libpng to use... " >&6; } 63670 63671 # default is bundled 63672 DEFAULT_LIBPNG=bundled 63673 # if user didn't specify, use DEFAULT_LIBPNG 63674 if test "x${with_libpng}" = "x"; then 63675 with_libpng=${DEFAULT_LIBPNG} 63676 fi 63677 63678 if test "x${with_libpng}" = "xbundled"; then 63679 USE_EXTERNAL_LIBPNG=false 63680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63681 $as_echo "bundled" >&6; } 63682 elif test "x${with_libpng}" = "xsystem"; then 63683 63684 pkg_failed=no 63685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 63686 $as_echo_n "checking for PNG... " >&6; } 63687 63688 if test -n "$PNG_CFLAGS"; then 63689 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 63690 elif test -n "$PKG_CONFIG"; then 63691 if test -n "$PKG_CONFIG" && \ 63692 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63693 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63694 ac_status=$? 63695 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63696 test $ac_status = 0; }; then 63697 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 63698 else 63699 pkg_failed=yes 63700 fi 63701 else 63702 pkg_failed=untried 63703 fi 63704 if test -n "$PNG_LIBS"; then 63705 pkg_cv_PNG_LIBS="$PNG_LIBS" 63706 elif test -n "$PKG_CONFIG"; then 63707 if test -n "$PKG_CONFIG" && \ 63708 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63709 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63710 ac_status=$? 63711 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63712 test $ac_status = 0; }; then 63713 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 63714 else 63715 pkg_failed=yes 63716 fi 63717 else 63718 pkg_failed=untried 63719 fi 63720 63721 63722 63723 if test $pkg_failed = yes; then 63724 63725 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63726 _pkg_short_errors_supported=yes 63727 else 63728 _pkg_short_errors_supported=no 63729 fi 63730 if test $_pkg_short_errors_supported = yes; then 63731 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 63732 else 63733 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 63734 fi 63735 # Put the nasty error message in config.log where it belongs 63736 echo "$PNG_PKG_ERRORS" >&5 63737 63738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63739 $as_echo "no" >&6; } 63740 LIBPNG_FOUND=no 63741 elif test $pkg_failed = untried; then 63742 LIBPNG_FOUND=no 63743 else 63744 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 63745 PNG_LIBS=$pkg_cv_PNG_LIBS 63746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63747 $as_echo "yes" >&6; } 63748 LIBPNG_FOUND=yes 63749 fi 63750 if test "x${LIBPNG_FOUND}" = "xyes"; then 63751 USE_EXTERNAL_LIBPNG=true 63752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63753 $as_echo "system" >&6; } 63754 else 63755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63756 $as_echo "system not found" >&6; } 63757 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 63758 fi 63759 else 63760 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 63761 fi 63762 63763 63764 63765 63766 63767 # Check whether --with-zlib was given. 63768 if test "${with_zlib+set}" = set; then : 63769 withval=$with_zlib; 63770 fi 63771 63772 63773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 63774 $as_echo_n "checking for compress in -lz... " >&6; } 63775 if ${ac_cv_lib_z_compress+:} false; then : 63776 $as_echo_n "(cached) " >&6 63777 else 63778 ac_check_lib_save_LIBS=$LIBS 63779 LIBS="-lz $LIBS" 63780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63781 /* end confdefs.h. */ 63782 63783 /* Override any GCC internal prototype to avoid an error. 63784 Use char because int might match the return type of a GCC 63785 builtin and then its argument prototype would still apply. */ 63786 #ifdef __cplusplus 63787 extern "C" 63788 #endif 63789 char compress (); 63790 int 63791 main () 63792 { 63793 return compress (); 63794 ; 63795 return 0; 63796 } 63797 _ACEOF 63798 if ac_fn_cxx_try_link "$LINENO"; then : 63799 ac_cv_lib_z_compress=yes 63800 else 63801 ac_cv_lib_z_compress=no 63802 fi 63803 rm -f core conftest.err conftest.$ac_objext \ 63804 conftest$ac_exeext conftest.$ac_ext 63805 LIBS=$ac_check_lib_save_LIBS 63806 fi 63807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 63808 $as_echo "$ac_cv_lib_z_compress" >&6; } 63809 if test "x$ac_cv_lib_z_compress" = xyes; then : 63810 ZLIB_FOUND=yes 63811 else 63812 ZLIB_FOUND=no 63813 fi 63814 63815 63816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 63817 $as_echo_n "checking for which zlib to use... " >&6; } 63818 63819 DEFAULT_ZLIB=system 63820 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63821 # On windows default is bundled...on others default is system 63822 DEFAULT_ZLIB=bundled 63823 fi 63824 63825 if test "x${ZLIB_FOUND}" != "xyes"; then 63826 # If we don't find any system...set default to bundled 63827 DEFAULT_ZLIB=bundled 63828 fi 63829 63830 # If user didn't specify, use DEFAULT_ZLIB 63831 if test "x${with_zlib}" = "x"; then 63832 with_zlib=${DEFAULT_ZLIB} 63833 fi 63834 63835 if test "x${with_zlib}" = "xbundled"; then 63836 USE_EXTERNAL_LIBZ=false 63837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63838 $as_echo "bundled" >&6; } 63839 elif test "x${with_zlib}" = "xsystem"; then 63840 if test "x${ZLIB_FOUND}" = "xyes"; then 63841 USE_EXTERNAL_LIBZ=true 63842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63843 $as_echo "system" >&6; } 63844 else 63845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63846 $as_echo "system not found" >&6; } 63847 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 63848 fi 63849 else 63850 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 63851 fi 63852 63853 63854 63855 63856 63857 # Check whether --with-lcms was given. 63858 if test "${with_lcms+set}" = set; then : 63859 withval=$with_lcms; 63860 fi 63861 63862 63863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 63864 $as_echo_n "checking for which lcms to use... " >&6; } 63865 63866 DEFAULT_LCMS=bundled 63867 # If user didn't specify, use DEFAULT_LCMS 63868 if test "x${with_lcms}" = "x"; then 63869 with_lcms=${DEFAULT_LCMS} 63870 fi 63871 63872 if test "x${with_lcms}" = "xbundled"; then 63873 USE_EXTERNAL_LCMS=false 63874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63875 $as_echo "bundled" >&6; } 63876 elif test "x${with_lcms}" = "xsystem"; then 63877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63878 $as_echo "system" >&6; } 63879 63880 pkg_failed=no 63881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 63882 $as_echo_n "checking for LCMS... " >&6; } 63883 63884 if test -n "$LCMS_CFLAGS"; then 63885 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 63886 elif test -n "$PKG_CONFIG"; then 63887 if test -n "$PKG_CONFIG" && \ 63888 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63889 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63890 ac_status=$? 63891 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63892 test $ac_status = 0; }; then 63893 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 63894 else 63895 pkg_failed=yes 63896 fi 63897 else 63898 pkg_failed=untried 63899 fi 63900 if test -n "$LCMS_LIBS"; then 63901 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 63902 elif test -n "$PKG_CONFIG"; then 63903 if test -n "$PKG_CONFIG" && \ 63904 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63905 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63906 ac_status=$? 63907 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63908 test $ac_status = 0; }; then 63909 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 63910 else 63911 pkg_failed=yes 63912 fi 63913 else 63914 pkg_failed=untried 63915 fi 63916 63917 63918 63919 if test $pkg_failed = yes; then 63920 63921 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63922 _pkg_short_errors_supported=yes 63923 else 63924 _pkg_short_errors_supported=no 63925 fi 63926 if test $_pkg_short_errors_supported = yes; then 63927 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 63928 else 63929 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 63930 fi 63931 # Put the nasty error message in config.log where it belongs 63932 echo "$LCMS_PKG_ERRORS" >&5 63933 63934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63935 $as_echo "no" >&6; } 63936 LCMS_FOUND=no 63937 elif test $pkg_failed = untried; then 63938 LCMS_FOUND=no 63939 else 63940 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 63941 LCMS_LIBS=$pkg_cv_LCMS_LIBS 63942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63943 $as_echo "yes" >&6; } 63944 LCMS_FOUND=yes 63945 fi 63946 if test "x${LCMS_FOUND}" = "xyes"; then 63947 USE_EXTERNAL_LCMS=true 63948 else 63949 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 63950 fi 63951 else 63952 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 63953 fi 63954 63955 63956 63957 63958 63959 63960 63961 63962 63963 63964 63965 # Setup libm (the maths library) 63966 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 63967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 63968 $as_echo_n "checking for cos in -lm... " >&6; } 63969 if ${ac_cv_lib_m_cos+:} false; then : 63970 $as_echo_n "(cached) " >&6 63971 else 63972 ac_check_lib_save_LIBS=$LIBS 63973 LIBS="-lm $LIBS" 63974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63975 /* end confdefs.h. */ 63976 63977 /* Override any GCC internal prototype to avoid an error. 63978 Use char because int might match the return type of a GCC 63979 builtin and then its argument prototype would still apply. */ 63980 #ifdef __cplusplus 63981 extern "C" 63982 #endif 63983 char cos (); 63984 int 63985 main () 63986 { 63987 return cos (); 63988 ; 63989 return 0; 63990 } 63991 _ACEOF 63992 if ac_fn_cxx_try_link "$LINENO"; then : 63993 ac_cv_lib_m_cos=yes 63994 else 63995 ac_cv_lib_m_cos=no 63996 fi 63997 rm -f core conftest.err conftest.$ac_objext \ 63998 conftest$ac_exeext conftest.$ac_ext 63999 LIBS=$ac_check_lib_save_LIBS 64000 fi 64001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 64002 $as_echo "$ac_cv_lib_m_cos" >&6; } 64003 if test "x$ac_cv_lib_m_cos" = xyes; then : 64004 cat >>confdefs.h <<_ACEOF 64005 #define HAVE_LIBM 1 64006 _ACEOF 64007 64008 LIBS="-lm $LIBS" 64009 64010 else 64011 64012 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 64013 $as_echo "$as_me: Maths library was not found" >&6;} 64014 64015 fi 64016 64017 LIBM="-lm" 64018 else 64019 LIBM="" 64020 fi 64021 64022 64023 # Setup libdl (for dynamic library loading) 64024 save_LIBS="$LIBS" 64025 LIBS="" 64026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 64027 $as_echo_n "checking for dlopen in -ldl... " >&6; } 64028 if ${ac_cv_lib_dl_dlopen+:} false; then : 64029 $as_echo_n "(cached) " >&6 64030 else 64031 ac_check_lib_save_LIBS=$LIBS 64032 LIBS="-ldl $LIBS" 64033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64034 /* end confdefs.h. */ 64035 64036 /* Override any GCC internal prototype to avoid an error. 64037 Use char because int might match the return type of a GCC 64038 builtin and then its argument prototype would still apply. */ 64039 #ifdef __cplusplus 64040 extern "C" 64041 #endif 64042 char dlopen (); 64043 int 64044 main () 64045 { 64046 return dlopen (); 64047 ; 64048 return 0; 64049 } 64050 _ACEOF 64051 if ac_fn_cxx_try_link "$LINENO"; then : 64052 ac_cv_lib_dl_dlopen=yes 64053 else 64054 ac_cv_lib_dl_dlopen=no 64055 fi 64056 rm -f core conftest.err conftest.$ac_objext \ 64057 conftest$ac_exeext conftest.$ac_ext 64058 LIBS=$ac_check_lib_save_LIBS 64059 fi 64060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 64061 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 64062 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 64063 cat >>confdefs.h <<_ACEOF 64064 #define HAVE_LIBDL 1 64065 _ACEOF 64066 64067 LIBS="-ldl $LIBS" 64068 64069 fi 64070 64071 LIBDL="$LIBS" 64072 64073 LIBS="$save_LIBS" 64074 64075 # Deprecated libraries, keep the flags for backwards compatibility 64076 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 64077 64078 64079 # Check whether --with-dxsdk was given. 64080 if test "${with_dxsdk+set}" = set; then : 64081 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 64082 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 64083 fi 64084 64085 64086 64087 64088 # Check whether --with-dxsdk-lib was given. 64089 if test "${with_dxsdk_lib+set}" = set; then : 64090 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 64091 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 64092 fi 64093 64094 64095 64096 64097 # Check whether --with-dxsdk-include was given. 64098 if test "${with_dxsdk_include+set}" = set; then : 64099 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 64100 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 64101 fi 64102 64103 64104 fi 64105 64106 # Control if libzip can use mmap. Available for purposes of overriding. 64107 LIBZIP_CAN_USE_MMAP=true 64108 64109 64110 64111 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 64112 # Find the root of the Solaris Studio installation from the compiler path 64113 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 64114 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 64115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 64116 $as_echo_n "checking for libstlport.so.1... " >&6; } 64117 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 64118 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 64119 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 64120 fi 64121 if test -f "$STLPORT_LIB"; then 64122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 64123 $as_echo "yes, $STLPORT_LIB" >&6; } 64124 64125 # Only process if variable expands to non-empty 64126 64127 if test "x$STLPORT_LIB" != x; then 64128 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64129 64130 # Input might be given as Windows format, start by converting to 64131 # unix format. 64132 path="$STLPORT_LIB" 64133 new_path=`$CYGPATH -u "$path"` 64134 64135 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64136 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64137 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64138 # "foo.exe" is OK but "foo" is an error. 64139 # 64140 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64141 # It is also a way to make sure we got the proper file name for the real test later on. 64142 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64143 if test "x$test_shortpath" = x; then 64144 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 64145 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 64146 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 64147 fi 64148 64149 # Call helper function which possibly converts this using DOS-style short mode. 64150 # If so, the updated path is stored in $new_path. 64151 64152 input_path="$new_path" 64153 # Check if we need to convert this using DOS-style short mode. If the path 64154 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64155 # take no chances and rewrite it. 64156 # Note: m4 eats our [], so we need to use [ and ] instead. 64157 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64158 if test "x$has_forbidden_chars" != x; then 64159 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64160 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64161 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64162 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64163 # Going to short mode and back again did indeed matter. Since short mode is 64164 # case insensitive, let's make it lowercase to improve readability. 64165 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64166 # Now convert it back to Unix-style (cygpath) 64167 input_path=`$CYGPATH -u "$shortmode_path"` 64168 new_path="$input_path" 64169 fi 64170 fi 64171 64172 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64173 if test "x$test_cygdrive_prefix" = x; then 64174 # As a simple fix, exclude /usr/bin since it's not a real path. 64175 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64176 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64177 # a path prefixed by /cygdrive for fixpath to work. 64178 new_path="$CYGWIN_ROOT_PATH$input_path" 64179 fi 64180 fi 64181 64182 64183 if test "x$path" != "x$new_path"; then 64184 STLPORT_LIB="$new_path" 64185 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 64186 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 64187 fi 64188 64189 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64190 64191 path="$STLPORT_LIB" 64192 has_colon=`$ECHO $path | $GREP ^.:` 64193 new_path="$path" 64194 if test "x$has_colon" = x; then 64195 # Not in mixed or Windows style, start by that. 64196 new_path=`cmd //c echo $path` 64197 fi 64198 64199 64200 input_path="$new_path" 64201 # Check if we need to convert this using DOS-style short mode. If the path 64202 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64203 # take no chances and rewrite it. 64204 # Note: m4 eats our [], so we need to use [ and ] instead. 64205 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64206 if test "x$has_forbidden_chars" != x; then 64207 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64208 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64209 fi 64210 64211 64212 windows_path="$new_path" 64213 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64214 unix_path=`$CYGPATH -u "$windows_path"` 64215 new_path="$unix_path" 64216 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64217 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64218 new_path="$unix_path" 64219 fi 64220 64221 if test "x$path" != "x$new_path"; then 64222 STLPORT_LIB="$new_path" 64223 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 64224 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 64225 fi 64226 64227 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64228 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64229 64230 else 64231 # We're on a unix platform. Hooray! :) 64232 path="$STLPORT_LIB" 64233 has_space=`$ECHO "$path" | $GREP " "` 64234 if test "x$has_space" != x; then 64235 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 64236 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 64237 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64238 fi 64239 64240 # Use eval to expand a potential ~ 64241 eval path="$path" 64242 if test ! -f "$path" && test ! -d "$path"; then 64243 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 64244 fi 64245 64246 if test -d "$path"; then 64247 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 64248 else 64249 dir="`$DIRNAME "$path"`" 64250 base="`$BASENAME "$path"`" 64251 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 64252 fi 64253 fi 64254 fi 64255 64256 else 64257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 64258 $as_echo "no, not found at $STLPORT_LIB" >&6; } 64259 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 64260 fi 64261 64262 fi 64263 64264 64265 64266 64267 64268 64269 64270 64271 64272 64273 64274 64275 64276 64277 ############################################################################### 64278 # 64279 # We need to do some final tweaking, when everything else is done. 64280 # 64281 ############################################################################### 64282 64283 64284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 64285 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 64286 64287 if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then 64288 ENABLE_INTREE_EC=yes 64289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64290 $as_echo "yes" >&6; } 64291 else 64292 ENABLE_INTREE_EC=no 64293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64294 $as_echo "no" >&6; } 64295 fi 64296 64297 64298 64299 64300 # Check whether --enable-jtreg-failure-handler was given. 64301 if test "${enable_jtreg_failure_handler+set}" = set; then : 64302 enableval=$enable_jtreg_failure_handler; 64303 fi 64304 64305 64306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 64307 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 64308 64309 if test "x$enable_jtreg_failure_handler" = "xyes"; then 64310 if test "x$JT_HOME" = "x"; then 64311 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 64312 else 64313 BUILD_FAILURE_HANDLER=true 64314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64315 $as_echo "yes, forced" >&6; } 64316 fi 64317 elif test "x$enable_jtreg_failure_handler" = "xno"; then 64318 BUILD_FAILURE_HANDLER=false 64319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64320 $as_echo "no, forced" >&6; } 64321 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 64322 || test "x$enable_jtreg_failure_handler" = "x"; then 64323 if test "x$JT_HOME" = "x"; then 64324 BUILD_FAILURE_HANDLER=false 64325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 64326 $as_echo "no, missing jtreg" >&6; } 64327 else 64328 BUILD_FAILURE_HANDLER=true 64329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 64330 $as_echo "yes, jtreg present" >&6; } 64331 fi 64332 else 64333 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 64334 fi 64335 64336 64337 64338 64339 # Check whether --enable-generate-classlist was given. 64340 if test "${enable_generate_classlist+set}" = set; then : 64341 enableval=$enable_generate_classlist; 64342 fi 64343 64344 64345 # Check if it's likely that it's possible to generate the classlist. Depending 64346 # on exact jvm configuration it could be possible anyway. 64347 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ; then 64348 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 64349 else 64350 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 64351 fi 64352 64353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 64354 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 64355 if test "x$enable_generate_classlist" = "xyes"; then 64356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64357 $as_echo "yes, forced" >&6; } 64358 ENABLE_GENERATE_CLASSLIST="true" 64359 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 64360 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&5 64361 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&2;} 64362 fi 64363 elif test "x$enable_generate_classlist" = "xno"; then 64364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64365 $as_echo "no, forced" >&6; } 64366 ENABLE_GENERATE_CLASSLIST="false" 64367 elif test "x$enable_generate_classlist" = "x"; then 64368 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 64369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64370 $as_echo "yes" >&6; } 64371 ENABLE_GENERATE_CLASSLIST="true" 64372 else 64373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64374 $as_echo "no" >&6; } 64375 ENABLE_GENERATE_CLASSLIST="false" 64376 fi 64377 else 64378 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 64379 fi 64380 64381 64382 64383 64384 ############################################################################### 64385 # 64386 # Configure parts of the build that only affect the build performance, 64387 # not the result. 64388 # 64389 ############################################################################### 64390 64391 64392 # How many cores do we have on this build system? 64393 64394 # Check whether --with-num-cores was given. 64395 if test "${with_num_cores+set}" = set; then : 64396 withval=$with_num_cores; 64397 fi 64398 64399 if test "x$with_num_cores" = x; then 64400 # The number of cores were not specified, try to probe them. 64401 64402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 64403 $as_echo_n "checking for number of cores... " >&6; } 64404 NUM_CORES=1 64405 FOUND_CORES=no 64406 64407 if test -f /proc/cpuinfo; then 64408 # Looks like a Linux (or cygwin) system 64409 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 64410 FOUND_CORES=yes 64411 elif test -x /usr/sbin/psrinfo; then 64412 # Looks like a Solaris system 64413 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 64414 FOUND_CORES=yes 64415 elif test -x /usr/sbin/sysctl; then 64416 # Looks like a MacOSX system 64417 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 64418 FOUND_CORES=yes 64419 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 64420 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 64421 FOUND_CORES=yes 64422 elif test -n "$NUMBER_OF_PROCESSORS"; then 64423 # On windows, look in the env 64424 NUM_CORES=$NUMBER_OF_PROCESSORS 64425 FOUND_CORES=yes 64426 fi 64427 64428 if test "x$FOUND_CORES" = xyes; then 64429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 64430 $as_echo "$NUM_CORES" >&6; } 64431 else 64432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 64433 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 64434 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 64435 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 64436 fi 64437 64438 else 64439 NUM_CORES=$with_num_cores 64440 fi 64441 64442 64443 64444 # How much memory do we have on this build system? 64445 64446 # Check whether --with-memory-size was given. 64447 if test "${with_memory_size+set}" = set; then : 64448 withval=$with_memory_size; 64449 fi 64450 64451 if test "x$with_memory_size" = x; then 64452 # The memory size was not specified, try to probe it. 64453 64454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 64455 $as_echo_n "checking for memory size... " >&6; } 64456 # Default to 1024 MB 64457 MEMORY_SIZE=1024 64458 FOUND_MEM=no 64459 64460 if test -f /proc/meminfo; then 64461 # Looks like a Linux (or cygwin) system 64462 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 64463 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 64464 FOUND_MEM=yes 64465 elif test -x /usr/sbin/prtconf; then 64466 # Looks like a Solaris or AIX system 64467 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 64468 FOUND_MEM=yes 64469 elif test -x /usr/sbin/sysctl; then 64470 # Looks like a MacOSX system 64471 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 64472 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64473 FOUND_MEM=yes 64474 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 64475 # Windows, but without cygwin 64476 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 64477 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64478 FOUND_MEM=yes 64479 fi 64480 64481 if test "x$FOUND_MEM" = xyes; then 64482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 64483 $as_echo "$MEMORY_SIZE MB" >&6; } 64484 else 64485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 64486 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 64487 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 64488 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 64489 fi 64490 64491 else 64492 MEMORY_SIZE=$with_memory_size 64493 fi 64494 64495 64496 64497 # Provide a decent default number of parallel jobs for make depending on 64498 # number of cores, amount of memory and machine architecture. 64499 64500 # Check whether --with-jobs was given. 64501 if test "${with_jobs+set}" = set; then : 64502 withval=$with_jobs; 64503 fi 64504 64505 if test "x$with_jobs" = x; then 64506 # Number of jobs was not specified, calculate. 64507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 64508 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 64509 # Approximate memory in GB. 64510 memory_gb=`expr $MEMORY_SIZE / 1024` 64511 # Pick the lowest of memory in gb and number of cores. 64512 if test "$memory_gb" -lt "$NUM_CORES"; then 64513 JOBS="$memory_gb" 64514 else 64515 JOBS="$NUM_CORES" 64516 fi 64517 if test "$JOBS" -eq "0"; then 64518 JOBS=1 64519 fi 64520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 64521 $as_echo "$JOBS" >&6; } 64522 else 64523 JOBS=$with_jobs 64524 fi 64525 64526 64527 64528 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 64529 64530 # Check whether --with-test-jobs was given. 64531 if test "${with_test_jobs+set}" = set; then : 64532 withval=$with_test_jobs; 64533 fi 64534 64535 if test "x$with_test_jobs" = x; then 64536 TEST_JOBS=0 64537 else 64538 TEST_JOBS=$with_test_jobs 64539 fi 64540 64541 64542 64543 # Setup arguments for the boot jdk (after cores and memory have been setup) 64544 64545 ############################################################################## 64546 # 64547 # Specify jvm options for anything that is run with the Boot JDK. 64548 # Not all JVM:s accept the same arguments on the command line. 64549 # 64550 64551 # Check whether --with-boot-jdk-jvmargs was given. 64552 if test "${with_boot_jdk_jvmargs+set}" = set; then : 64553 withval=$with_boot_jdk_jvmargs; 64554 fi 64555 64556 64557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 64558 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 64559 64560 # Disable special log output when a debug build is used as Boot JDK... 64561 64562 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 64563 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 64564 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 64565 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64566 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64567 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64568 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 64569 JVM_ARG_OK=true 64570 else 64571 $ECHO "Arg failed:" >&5 64572 $ECHO "$OUTPUT" >&5 64573 JVM_ARG_OK=false 64574 fi 64575 64576 64577 # Force en-US environment 64578 64579 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 64580 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 64581 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 64582 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64583 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64584 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64585 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 64586 JVM_ARG_OK=true 64587 else 64588 $ECHO "Arg failed:" >&5 64589 $ECHO "$OUTPUT" >&5 64590 JVM_ARG_OK=false 64591 fi 64592 64593 64594 # Apply user provided options. 64595 64596 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 64597 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 64598 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 64599 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64600 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64601 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64602 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 64603 JVM_ARG_OK=true 64604 else 64605 $ECHO "Arg failed:" >&5 64606 $ECHO "$OUTPUT" >&5 64607 JVM_ARG_OK=false 64608 fi 64609 64610 64611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 64612 $as_echo "$boot_jdk_jvmargs" >&6; } 64613 64614 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 64615 JAVA_FLAGS=$boot_jdk_jvmargs 64616 64617 64618 64619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 64620 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 64621 64622 # Starting amount of heap memory. 64623 64624 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 64625 $ECHO "Command: $JAVA -Xms64M -version" >&5 64626 OUTPUT=`$JAVA -Xms64M -version 2>&1` 64627 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64628 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64629 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64630 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 64631 JVM_ARG_OK=true 64632 else 64633 $ECHO "Arg failed:" >&5 64634 $ECHO "$OUTPUT" >&5 64635 JVM_ARG_OK=false 64636 fi 64637 64638 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 64639 64640 # Maximum amount of heap memory and stack size. 64641 JVM_HEAP_LIMIT_32="1024" 64642 # Running a 64 bit JVM allows for and requires a bigger heap 64643 JVM_HEAP_LIMIT_64="1600" 64644 STACK_SIZE_32=768 64645 STACK_SIZE_64=1536 64646 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 64647 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 64648 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 64649 fi 64650 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 64651 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 64652 fi 64653 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 64654 JVM_HEAP_LIMIT_32=512 64655 JVM_HEAP_LIMIT_64=512 64656 fi 64657 64658 if test "x$BOOT_JDK_BITS" = "x32"; then 64659 STACK_SIZE=$STACK_SIZE_32 64660 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 64661 else 64662 STACK_SIZE=$STACK_SIZE_64 64663 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 64664 fi 64665 64666 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 64667 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 64668 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 64669 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64670 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64671 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64672 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 64673 JVM_ARG_OK=true 64674 else 64675 $ECHO "Arg failed:" >&5 64676 $ECHO "$OUTPUT" >&5 64677 JVM_ARG_OK=false 64678 fi 64679 64680 64681 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 64682 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 64683 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 64684 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64685 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64686 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64687 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 64688 JVM_ARG_OK=true 64689 else 64690 $ECHO "Arg failed:" >&5 64691 $ECHO "$OUTPUT" >&5 64692 JVM_ARG_OK=false 64693 fi 64694 64695 64696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 64697 $as_echo "$boot_jdk_jvmargs_big" >&6; } 64698 64699 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 64700 64701 64702 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 64703 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 64704 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 64705 else 64706 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 64707 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 64708 fi 64709 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 64710 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 64711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 64712 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 64713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 64714 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 64715 64716 64717 # By default, the main javac compilations use big 64718 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 64719 64720 64721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 64722 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 64723 64724 # Use serial gc for small short lived tools if possible 64725 64726 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 64727 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 64728 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 64729 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64730 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64731 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64732 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 64733 JVM_ARG_OK=true 64734 else 64735 $ECHO "Arg failed:" >&5 64736 $ECHO "$OUTPUT" >&5 64737 JVM_ARG_OK=false 64738 fi 64739 64740 64741 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 64742 $ECHO "Command: $JAVA -Xms32M -version" >&5 64743 OUTPUT=`$JAVA -Xms32M -version 2>&1` 64744 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64745 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64746 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64747 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 64748 JVM_ARG_OK=true 64749 else 64750 $ECHO "Arg failed:" >&5 64751 $ECHO "$OUTPUT" >&5 64752 JVM_ARG_OK=false 64753 fi 64754 64755 64756 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 64757 $ECHO "Command: $JAVA -Xmx512M -version" >&5 64758 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 64759 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64760 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64761 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64762 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 64763 JVM_ARG_OK=true 64764 else 64765 $ECHO "Arg failed:" >&5 64766 $ECHO "$OUTPUT" >&5 64767 JVM_ARG_OK=false 64768 fi 64769 64770 64771 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 64772 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 64773 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 64774 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64775 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64776 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64777 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 64778 JVM_ARG_OK=true 64779 else 64780 $ECHO "Arg failed:" >&5 64781 $ECHO "$OUTPUT" >&5 64782 JVM_ARG_OK=false 64783 fi 64784 64785 64786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 64787 $as_echo "$boot_jdk_jvmargs_small" >&6; } 64788 64789 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 64790 64791 64792 JAVA_TOOL_FLAGS_SMALL="" 64793 for f in $JAVA_FLAGS_SMALL; do 64794 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 64795 done 64796 64797 64798 64799 # Setup smart javac (after cores and memory have been setup) 64800 64801 64802 # Check whether --with-sjavac-server-java was given. 64803 if test "${with_sjavac_server_java+set}" = set; then : 64804 withval=$with_sjavac_server_java; 64805 fi 64806 64807 64808 if test "x$with_sjavac_server_java" != x; then 64809 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 64810 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 64811 if test "x$FOUND_VERSION" = x; then 64812 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 64813 fi 64814 else 64815 SJAVAC_SERVER_JAVA="$JAVA" 64816 fi 64817 64818 64819 if test "$MEMORY_SIZE" -gt "3000"; then 64820 64821 $ECHO "Check if jvm arg is ok: -d64" >&5 64822 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 64823 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 64824 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64825 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64826 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64827 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" 64828 JVM_ARG_OK=true 64829 else 64830 $ECHO "Arg failed:" >&5 64831 $ECHO "$OUTPUT" >&5 64832 JVM_ARG_OK=false 64833 fi 64834 64835 if test "$JVM_ARG_OK" = true; then 64836 JVM_64BIT=true 64837 JVM_ARG_OK=false 64838 fi 64839 fi 64840 64841 MX_VALUE=`expr $MEMORY_SIZE / 2` 64842 if test "$JVM_64BIT" = true; then 64843 # Set ms lower than mx since more than one instance of the server might 64844 # get launched at the same time before they figure out which instance won. 64845 MS_VALUE=512 64846 if test "$MX_VALUE" -gt "2048"; then 64847 MX_VALUE=2048 64848 fi 64849 else 64850 MS_VALUE=256 64851 if test "$MX_VALUE" -gt "1500"; then 64852 MX_VALUE=1500 64853 fi 64854 fi 64855 if test "$MX_VALUE" -lt "512"; then 64856 MX_VALUE=512 64857 fi 64858 64859 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 64860 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 64861 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 64862 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64863 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64864 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64865 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 64866 JVM_ARG_OK=true 64867 else 64868 $ECHO "Arg failed:" >&5 64869 $ECHO "$OUTPUT" >&5 64870 JVM_ARG_OK=false 64871 fi 64872 64873 64874 64875 # Check whether --enable-sjavac was given. 64876 if test "${enable_sjavac+set}" = set; then : 64877 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 64878 else 64879 ENABLE_SJAVAC="no" 64880 fi 64881 64882 if test "x$JVM_ARG_OK" = "xfalse"; then 64883 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 64884 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 64885 ENABLE_SJAVAC="no" 64886 fi 64887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 64888 $as_echo_n "checking whether to use sjavac... " >&6; } 64889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 64890 $as_echo "$ENABLE_SJAVAC" >&6; } 64891 64892 64893 # Check whether --enable-javac-server was given. 64894 if test "${enable_javac_server+set}" = set; then : 64895 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 64896 else 64897 ENABLE_JAVAC_SERVER="yes" 64898 fi 64899 64900 if test "x$JVM_ARG_OK" = "xfalse"; then 64901 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 64902 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 64903 ENABLE_JAVAC_SERVER="no" 64904 fi 64905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 64906 $as_echo_n "checking whether to use javac server... " >&6; } 64907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 64908 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 64909 64910 64911 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 64912 # When using a server javac, the small client instances do not need much 64913 # resources. 64914 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 64915 fi 64916 64917 64918 # Setup use of icecc if requested 64919 64920 # Check whether --enable-icecc was given. 64921 if test "${enable_icecc+set}" = set; then : 64922 enableval=$enable_icecc; 64923 fi 64924 64925 64926 if test "x${enable_icecc}" = "xyes"; then 64927 64928 64929 64930 # Publish this variable in the help. 64931 64932 64933 if [ -z "${ICECC_CMD+x}" ]; then 64934 # The variable is not set by user, try to locate tool using the code snippet 64935 for ac_prog in icecc 64936 do 64937 # Extract the first word of "$ac_prog", so it can be a program name with args. 64938 set dummy $ac_prog; ac_word=$2 64939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64940 $as_echo_n "checking for $ac_word... " >&6; } 64941 if ${ac_cv_path_ICECC_CMD+:} false; then : 64942 $as_echo_n "(cached) " >&6 64943 else 64944 case $ICECC_CMD in 64945 [\\/]* | ?:[\\/]*) 64946 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64947 ;; 64948 *) 64949 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64950 for as_dir in $PATH 64951 do 64952 IFS=$as_save_IFS 64953 test -z "$as_dir" && as_dir=. 64954 for ac_exec_ext in '' $ac_executable_extensions; do 64955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64956 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64958 break 2 64959 fi 64960 done 64961 done 64962 IFS=$as_save_IFS 64963 64964 ;; 64965 esac 64966 fi 64967 ICECC_CMD=$ac_cv_path_ICECC_CMD 64968 if test -n "$ICECC_CMD"; then 64969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64970 $as_echo "$ICECC_CMD" >&6; } 64971 else 64972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64973 $as_echo "no" >&6; } 64974 fi 64975 64976 64977 test -n "$ICECC_CMD" && break 64978 done 64979 64980 else 64981 # The variable is set, but is it from the command line or the environment? 64982 64983 # Try to remove the string !ICECC_CMD! from our list. 64984 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 64985 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64986 # If it failed, the variable was not from the command line. Ignore it, 64987 # but warn the user (except for BASH, which is always set by the calling BASH). 64988 if test "xICECC_CMD" != xBASH; then 64989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 64990 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 64991 fi 64992 # Try to locate tool using the code snippet 64993 for ac_prog in icecc 64994 do 64995 # Extract the first word of "$ac_prog", so it can be a program name with args. 64996 set dummy $ac_prog; ac_word=$2 64997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64998 $as_echo_n "checking for $ac_word... " >&6; } 64999 if ${ac_cv_path_ICECC_CMD+:} false; then : 65000 $as_echo_n "(cached) " >&6 65001 else 65002 case $ICECC_CMD in 65003 [\\/]* | ?:[\\/]*) 65004 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 65005 ;; 65006 *) 65007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65008 for as_dir in $PATH 65009 do 65010 IFS=$as_save_IFS 65011 test -z "$as_dir" && as_dir=. 65012 for ac_exec_ext in '' $ac_executable_extensions; do 65013 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65014 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 65015 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65016 break 2 65017 fi 65018 done 65019 done 65020 IFS=$as_save_IFS 65021 65022 ;; 65023 esac 65024 fi 65025 ICECC_CMD=$ac_cv_path_ICECC_CMD 65026 if test -n "$ICECC_CMD"; then 65027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65028 $as_echo "$ICECC_CMD" >&6; } 65029 else 65030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65031 $as_echo "no" >&6; } 65032 fi 65033 65034 65035 test -n "$ICECC_CMD" && break 65036 done 65037 65038 else 65039 # If it succeeded, then it was overridden by the user. We will use it 65040 # for the tool. 65041 65042 # First remove it from the list of overridden variables, so we can test 65043 # for unknown variables in the end. 65044 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65045 65046 # Check if we try to supply an empty value 65047 if test "x$ICECC_CMD" = x; then 65048 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 65049 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 65050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 65051 $as_echo_n "checking for ICECC_CMD... " >&6; } 65052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65053 $as_echo "disabled" >&6; } 65054 else 65055 # Check if the provided tool contains a complete path. 65056 tool_specified="$ICECC_CMD" 65057 tool_basename="${tool_specified##*/}" 65058 if test "x$tool_basename" = "x$tool_specified"; then 65059 # A command without a complete path is provided, search $PATH. 65060 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 65061 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 65062 # Extract the first word of "$tool_basename", so it can be a program name with args. 65063 set dummy $tool_basename; ac_word=$2 65064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65065 $as_echo_n "checking for $ac_word... " >&6; } 65066 if ${ac_cv_path_ICECC_CMD+:} false; then : 65067 $as_echo_n "(cached) " >&6 65068 else 65069 case $ICECC_CMD in 65070 [\\/]* | ?:[\\/]*) 65071 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 65072 ;; 65073 *) 65074 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65075 for as_dir in $PATH 65076 do 65077 IFS=$as_save_IFS 65078 test -z "$as_dir" && as_dir=. 65079 for ac_exec_ext in '' $ac_executable_extensions; do 65080 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65081 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 65082 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65083 break 2 65084 fi 65085 done 65086 done 65087 IFS=$as_save_IFS 65088 65089 ;; 65090 esac 65091 fi 65092 ICECC_CMD=$ac_cv_path_ICECC_CMD 65093 if test -n "$ICECC_CMD"; then 65094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65095 $as_echo "$ICECC_CMD" >&6; } 65096 else 65097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65098 $as_echo "no" >&6; } 65099 fi 65100 65101 65102 if test "x$ICECC_CMD" = x; then 65103 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65104 fi 65105 else 65106 # Otherwise we believe it is a complete path. Use it as it is. 65107 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 65108 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 65109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 65110 $as_echo_n "checking for ICECC_CMD... " >&6; } 65111 if test ! -x "$tool_specified"; then 65112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65113 $as_echo "not found" >&6; } 65114 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 65115 fi 65116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65117 $as_echo "$tool_specified" >&6; } 65118 fi 65119 fi 65120 fi 65121 65122 fi 65123 65124 65125 65126 if test "x$ICECC_CMD" = x; then 65127 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 65128 fi 65129 65130 65131 old_path="$PATH" 65132 65133 # Look for icecc-create-env in some known places 65134 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 65135 65136 65137 65138 # Publish this variable in the help. 65139 65140 65141 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 65142 # The variable is not set by user, try to locate tool using the code snippet 65143 for ac_prog in icecc-create-env 65144 do 65145 # Extract the first word of "$ac_prog", so it can be a program name with args. 65146 set dummy $ac_prog; ac_word=$2 65147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65148 $as_echo_n "checking for $ac_word... " >&6; } 65149 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65150 $as_echo_n "(cached) " >&6 65151 else 65152 case $ICECC_CREATE_ENV in 65153 [\\/]* | ?:[\\/]*) 65154 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65155 ;; 65156 *) 65157 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65158 for as_dir in $PATH 65159 do 65160 IFS=$as_save_IFS 65161 test -z "$as_dir" && as_dir=. 65162 for ac_exec_ext in '' $ac_executable_extensions; do 65163 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65164 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65165 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65166 break 2 65167 fi 65168 done 65169 done 65170 IFS=$as_save_IFS 65171 65172 ;; 65173 esac 65174 fi 65175 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65176 if test -n "$ICECC_CREATE_ENV"; then 65177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65178 $as_echo "$ICECC_CREATE_ENV" >&6; } 65179 else 65180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65181 $as_echo "no" >&6; } 65182 fi 65183 65184 65185 test -n "$ICECC_CREATE_ENV" && break 65186 done 65187 65188 else 65189 # The variable is set, but is it from the command line or the environment? 65190 65191 # Try to remove the string !ICECC_CREATE_ENV! from our list. 65192 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 65193 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65194 # If it failed, the variable was not from the command line. Ignore it, 65195 # but warn the user (except for BASH, which is always set by the calling BASH). 65196 if test "xICECC_CREATE_ENV" != xBASH; then 65197 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 65198 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 65199 fi 65200 # Try to locate tool using the code snippet 65201 for ac_prog in icecc-create-env 65202 do 65203 # Extract the first word of "$ac_prog", so it can be a program name with args. 65204 set dummy $ac_prog; ac_word=$2 65205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65206 $as_echo_n "checking for $ac_word... " >&6; } 65207 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65208 $as_echo_n "(cached) " >&6 65209 else 65210 case $ICECC_CREATE_ENV in 65211 [\\/]* | ?:[\\/]*) 65212 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65213 ;; 65214 *) 65215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65216 for as_dir in $PATH 65217 do 65218 IFS=$as_save_IFS 65219 test -z "$as_dir" && as_dir=. 65220 for ac_exec_ext in '' $ac_executable_extensions; do 65221 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65222 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65224 break 2 65225 fi 65226 done 65227 done 65228 IFS=$as_save_IFS 65229 65230 ;; 65231 esac 65232 fi 65233 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65234 if test -n "$ICECC_CREATE_ENV"; then 65235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65236 $as_echo "$ICECC_CREATE_ENV" >&6; } 65237 else 65238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65239 $as_echo "no" >&6; } 65240 fi 65241 65242 65243 test -n "$ICECC_CREATE_ENV" && break 65244 done 65245 65246 else 65247 # If it succeeded, then it was overridden by the user. We will use it 65248 # for the tool. 65249 65250 # First remove it from the list of overridden variables, so we can test 65251 # for unknown variables in the end. 65252 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65253 65254 # Check if we try to supply an empty value 65255 if test "x$ICECC_CREATE_ENV" = x; then 65256 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 65257 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 65258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 65259 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 65260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65261 $as_echo "disabled" >&6; } 65262 else 65263 # Check if the provided tool contains a complete path. 65264 tool_specified="$ICECC_CREATE_ENV" 65265 tool_basename="${tool_specified##*/}" 65266 if test "x$tool_basename" = "x$tool_specified"; then 65267 # A command without a complete path is provided, search $PATH. 65268 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 65269 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 65270 # Extract the first word of "$tool_basename", so it can be a program name with args. 65271 set dummy $tool_basename; ac_word=$2 65272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65273 $as_echo_n "checking for $ac_word... " >&6; } 65274 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65275 $as_echo_n "(cached) " >&6 65276 else 65277 case $ICECC_CREATE_ENV in 65278 [\\/]* | ?:[\\/]*) 65279 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65280 ;; 65281 *) 65282 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65283 for as_dir in $PATH 65284 do 65285 IFS=$as_save_IFS 65286 test -z "$as_dir" && as_dir=. 65287 for ac_exec_ext in '' $ac_executable_extensions; do 65288 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65289 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65290 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65291 break 2 65292 fi 65293 done 65294 done 65295 IFS=$as_save_IFS 65296 65297 ;; 65298 esac 65299 fi 65300 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65301 if test -n "$ICECC_CREATE_ENV"; then 65302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65303 $as_echo "$ICECC_CREATE_ENV" >&6; } 65304 else 65305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65306 $as_echo "no" >&6; } 65307 fi 65308 65309 65310 if test "x$ICECC_CREATE_ENV" = x; then 65311 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65312 fi 65313 else 65314 # Otherwise we believe it is a complete path. Use it as it is. 65315 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 65316 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 65317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 65318 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 65319 if test ! -x "$tool_specified"; then 65320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65321 $as_echo "not found" >&6; } 65322 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 65323 fi 65324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65325 $as_echo "$tool_specified" >&6; } 65326 fi 65327 fi 65328 fi 65329 65330 fi 65331 65332 65333 65334 if test "x$ICECC_CREATE_ENV" = x; then 65335 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 65336 fi 65337 65338 65339 # Use icecc-create-env to create a minimal compilation environment that can 65340 # be sent to the other hosts in the icecream cluster. 65341 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 65342 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 65343 # Older versions of icecc does not have the --gcc parameter 65344 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 65345 icecc_gcc_arg="--gcc" 65346 fi 65347 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 65348 65349 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65350 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 65351 ${icecc_create_env_log} 2>&1 ) 65352 if test "$?" != "0"; then 65353 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65354 $as_echo "$as_me: icecc-create-env output:" >&6;} 65355 cat \ 65356 ${icecc_create_env_log} 65357 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65358 fi 65359 65360 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 65361 # For clang, the icecc compilerwrapper is needed. It usually resides next 65362 # to icecc-create-env. 65363 65364 65365 65366 # Publish this variable in the help. 65367 65368 65369 if [ -z "${ICECC_WRAPPER+x}" ]; then 65370 # The variable is not set by user, try to locate tool using the code snippet 65371 for ac_prog in compilerwrapper 65372 do 65373 # Extract the first word of "$ac_prog", so it can be a program name with args. 65374 set dummy $ac_prog; ac_word=$2 65375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65376 $as_echo_n "checking for $ac_word... " >&6; } 65377 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65378 $as_echo_n "(cached) " >&6 65379 else 65380 case $ICECC_WRAPPER in 65381 [\\/]* | ?:[\\/]*) 65382 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65383 ;; 65384 *) 65385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65386 for as_dir in $PATH 65387 do 65388 IFS=$as_save_IFS 65389 test -z "$as_dir" && as_dir=. 65390 for ac_exec_ext in '' $ac_executable_extensions; do 65391 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65392 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65394 break 2 65395 fi 65396 done 65397 done 65398 IFS=$as_save_IFS 65399 65400 ;; 65401 esac 65402 fi 65403 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65404 if test -n "$ICECC_WRAPPER"; then 65405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65406 $as_echo "$ICECC_WRAPPER" >&6; } 65407 else 65408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65409 $as_echo "no" >&6; } 65410 fi 65411 65412 65413 test -n "$ICECC_WRAPPER" && break 65414 done 65415 65416 else 65417 # The variable is set, but is it from the command line or the environment? 65418 65419 # Try to remove the string !ICECC_WRAPPER! from our list. 65420 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 65421 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65422 # If it failed, the variable was not from the command line. Ignore it, 65423 # but warn the user (except for BASH, which is always set by the calling BASH). 65424 if test "xICECC_WRAPPER" != xBASH; then 65425 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 65426 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 65427 fi 65428 # Try to locate tool using the code snippet 65429 for ac_prog in compilerwrapper 65430 do 65431 # Extract the first word of "$ac_prog", so it can be a program name with args. 65432 set dummy $ac_prog; ac_word=$2 65433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65434 $as_echo_n "checking for $ac_word... " >&6; } 65435 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65436 $as_echo_n "(cached) " >&6 65437 else 65438 case $ICECC_WRAPPER in 65439 [\\/]* | ?:[\\/]*) 65440 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65441 ;; 65442 *) 65443 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65444 for as_dir in $PATH 65445 do 65446 IFS=$as_save_IFS 65447 test -z "$as_dir" && as_dir=. 65448 for ac_exec_ext in '' $ac_executable_extensions; do 65449 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65450 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65451 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65452 break 2 65453 fi 65454 done 65455 done 65456 IFS=$as_save_IFS 65457 65458 ;; 65459 esac 65460 fi 65461 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65462 if test -n "$ICECC_WRAPPER"; then 65463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65464 $as_echo "$ICECC_WRAPPER" >&6; } 65465 else 65466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65467 $as_echo "no" >&6; } 65468 fi 65469 65470 65471 test -n "$ICECC_WRAPPER" && break 65472 done 65473 65474 else 65475 # If it succeeded, then it was overridden by the user. We will use it 65476 # for the tool. 65477 65478 # First remove it from the list of overridden variables, so we can test 65479 # for unknown variables in the end. 65480 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65481 65482 # Check if we try to supply an empty value 65483 if test "x$ICECC_WRAPPER" = x; then 65484 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 65485 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 65486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65487 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65489 $as_echo "disabled" >&6; } 65490 else 65491 # Check if the provided tool contains a complete path. 65492 tool_specified="$ICECC_WRAPPER" 65493 tool_basename="${tool_specified##*/}" 65494 if test "x$tool_basename" = "x$tool_specified"; then 65495 # A command without a complete path is provided, search $PATH. 65496 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 65497 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 65498 # Extract the first word of "$tool_basename", so it can be a program name with args. 65499 set dummy $tool_basename; ac_word=$2 65500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65501 $as_echo_n "checking for $ac_word... " >&6; } 65502 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65503 $as_echo_n "(cached) " >&6 65504 else 65505 case $ICECC_WRAPPER in 65506 [\\/]* | ?:[\\/]*) 65507 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65508 ;; 65509 *) 65510 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65511 for as_dir in $PATH 65512 do 65513 IFS=$as_save_IFS 65514 test -z "$as_dir" && as_dir=. 65515 for ac_exec_ext in '' $ac_executable_extensions; do 65516 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65517 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65518 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65519 break 2 65520 fi 65521 done 65522 done 65523 IFS=$as_save_IFS 65524 65525 ;; 65526 esac 65527 fi 65528 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65529 if test -n "$ICECC_WRAPPER"; then 65530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65531 $as_echo "$ICECC_WRAPPER" >&6; } 65532 else 65533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65534 $as_echo "no" >&6; } 65535 fi 65536 65537 65538 if test "x$ICECC_WRAPPER" = x; then 65539 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65540 fi 65541 else 65542 # Otherwise we believe it is a complete path. Use it as it is. 65543 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 65544 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 65545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65546 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65547 if test ! -x "$tool_specified"; then 65548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65549 $as_echo "not found" >&6; } 65550 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 65551 fi 65552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65553 $as_echo "$tool_specified" >&6; } 65554 fi 65555 fi 65556 fi 65557 65558 fi 65559 65560 65561 65562 if test "x$ICECC_WRAPPER" = x; then 65563 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 65564 fi 65565 65566 65567 65568 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65569 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 65570 if test "$?" != "0"; then 65571 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65572 $as_echo "$as_me: icecc-create-env output:" >&6;} 65573 cat ${icecc_create_env_log} 65574 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65575 fi 65576 65577 else 65578 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 65579 fi 65580 PATH="$old_path" 65581 # The bundle with the compiler gets a name based on checksums. Parse log file 65582 # to find it. 65583 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 65584 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65585 if test ! -f ${ICECC_ENV_BUNDLE}; then 65586 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65587 fi 65588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 65589 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 65590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65591 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65592 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 65593 65594 if test "x${COMPILE_TYPE}" = "xcross"; then 65595 # If cross compiling, create a separate env package for the build compiler 65596 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 65597 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 65598 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 65599 65600 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65601 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 65602 ${icecc_create_env_log_build} 2>&1 ) 65603 if test "$?" != "0"; then 65604 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65605 $as_echo "$as_me: icecc-create-env output:" >&6;} 65606 cat \ 65607 ${icecc_create_env_log_build} 65608 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65609 fi 65610 65611 elif test "x${BUILD_CC##*/}" = "xclang"; then 65612 65613 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65614 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 65615 if test "$?" != "0"; then 65616 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65617 $as_echo "$as_me: icecc-create-env output:" >&6;} 65618 cat ${icecc_create_env_log_build} 65619 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65620 fi 65621 65622 else 65623 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 65624 fi 65625 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 65626 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65627 if test ! -f ${ICECC_ENV_BUNDLE}; then 65628 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65629 fi 65630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 65631 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 65632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65633 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65634 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 65635 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 65636 else 65637 BUILD_ICECC="${ICECC}" 65638 fi 65639 65640 65641 fi 65642 65643 65644 # Can the C/C++ compiler use precompiled headers? 65645 65646 65647 ############################################################################### 65648 # 65649 # Can the C/C++ compiler use precompiled headers? 65650 # 65651 # Check whether --enable-precompiled-headers was given. 65652 if test "${enable_precompiled_headers+set}" = set; then : 65653 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 65654 else 65655 ENABLE_PRECOMPH=yes 65656 fi 65657 65658 65659 USE_PRECOMPILED_HEADER=1 65660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 65661 $as_echo_n "checking If precompiled header is enabled... " >&6; } 65662 if test "x$ENABLE_PRECOMPH" = xno; then 65663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65664 $as_echo "no, forced" >&6; } 65665 USE_PRECOMPILED_HEADER=0 65666 elif test "x$ICECC" != "x"; then 65667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 65668 $as_echo "no, does not work effectively with icecc" >&6; } 65669 USE_PRECOMPILED_HEADER=0 65670 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 65671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 65672 $as_echo "no, does not work with Solaris Studio" >&6; } 65673 USE_PRECOMPILED_HEADER=0 65674 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 65675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 65676 $as_echo "no, does not work with xlc" >&6; } 65677 USE_PRECOMPILED_HEADER=0 65678 else 65679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65680 $as_echo "yes" >&6; } 65681 fi 65682 65683 if test "x$ENABLE_PRECOMPH" = xyes; then 65684 # Check that the compiler actually supports precomp headers. 65685 if test "x$TOOLCHAIN_TYPE" = xgcc; then 65686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 65687 $as_echo_n "checking that precompiled headers work... " >&6; } 65688 echo "int alfa();" > conftest.h 65689 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 65690 if test ! -f conftest.hpp.gch; then 65691 USE_PRECOMPILED_HEADER=0 65692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65693 $as_echo "no" >&6; } 65694 else 65695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65696 $as_echo "yes" >&6; } 65697 fi 65698 $RM conftest.h conftest.hpp.gch 65699 fi 65700 fi 65701 65702 65703 65704 65705 # Setup use of ccache, if available 65706 65707 # Check whether --enable-ccache was given. 65708 if test "${enable_ccache+set}" = set; then : 65709 enableval=$enable_ccache; 65710 fi 65711 65712 65713 CCACHE= 65714 CCACHE_STATUS= 65715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 65716 $as_echo_n "checking is ccache enabled... " >&6; } 65717 if test "x$enable_ccache" = xyes; then 65718 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 65719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65720 $as_echo "yes" >&6; } 65721 OLD_PATH="$PATH" 65722 if test "x$TOOLCHAIN_PATH" != x; then 65723 PATH=$TOOLCHAIN_PATH:$PATH 65724 fi 65725 65726 65727 65728 # Publish this variable in the help. 65729 65730 65731 if [ -z "${CCACHE+x}" ]; then 65732 # The variable is not set by user, try to locate tool using the code snippet 65733 for ac_prog in ccache 65734 do 65735 # Extract the first word of "$ac_prog", so it can be a program name with args. 65736 set dummy $ac_prog; ac_word=$2 65737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65738 $as_echo_n "checking for $ac_word... " >&6; } 65739 if ${ac_cv_path_CCACHE+:} false; then : 65740 $as_echo_n "(cached) " >&6 65741 else 65742 case $CCACHE in 65743 [\\/]* | ?:[\\/]*) 65744 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65745 ;; 65746 *) 65747 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65748 for as_dir in $PATH 65749 do 65750 IFS=$as_save_IFS 65751 test -z "$as_dir" && as_dir=. 65752 for ac_exec_ext in '' $ac_executable_extensions; do 65753 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65754 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65755 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65756 break 2 65757 fi 65758 done 65759 done 65760 IFS=$as_save_IFS 65761 65762 ;; 65763 esac 65764 fi 65765 CCACHE=$ac_cv_path_CCACHE 65766 if test -n "$CCACHE"; then 65767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65768 $as_echo "$CCACHE" >&6; } 65769 else 65770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65771 $as_echo "no" >&6; } 65772 fi 65773 65774 65775 test -n "$CCACHE" && break 65776 done 65777 65778 else 65779 # The variable is set, but is it from the command line or the environment? 65780 65781 # Try to remove the string !CCACHE! from our list. 65782 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 65783 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65784 # If it failed, the variable was not from the command line. Ignore it, 65785 # but warn the user (except for BASH, which is always set by the calling BASH). 65786 if test "xCCACHE" != xBASH; then 65787 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 65788 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 65789 fi 65790 # Try to locate tool using the code snippet 65791 for ac_prog in ccache 65792 do 65793 # Extract the first word of "$ac_prog", so it can be a program name with args. 65794 set dummy $ac_prog; ac_word=$2 65795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65796 $as_echo_n "checking for $ac_word... " >&6; } 65797 if ${ac_cv_path_CCACHE+:} false; then : 65798 $as_echo_n "(cached) " >&6 65799 else 65800 case $CCACHE in 65801 [\\/]* | ?:[\\/]*) 65802 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65803 ;; 65804 *) 65805 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65806 for as_dir in $PATH 65807 do 65808 IFS=$as_save_IFS 65809 test -z "$as_dir" && as_dir=. 65810 for ac_exec_ext in '' $ac_executable_extensions; do 65811 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65812 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65813 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65814 break 2 65815 fi 65816 done 65817 done 65818 IFS=$as_save_IFS 65819 65820 ;; 65821 esac 65822 fi 65823 CCACHE=$ac_cv_path_CCACHE 65824 if test -n "$CCACHE"; then 65825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65826 $as_echo "$CCACHE" >&6; } 65827 else 65828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65829 $as_echo "no" >&6; } 65830 fi 65831 65832 65833 test -n "$CCACHE" && break 65834 done 65835 65836 else 65837 # If it succeeded, then it was overridden by the user. We will use it 65838 # for the tool. 65839 65840 # First remove it from the list of overridden variables, so we can test 65841 # for unknown variables in the end. 65842 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65843 65844 # Check if we try to supply an empty value 65845 if test "x$CCACHE" = x; then 65846 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 65847 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 65848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65849 $as_echo_n "checking for CCACHE... " >&6; } 65850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65851 $as_echo "disabled" >&6; } 65852 else 65853 # Check if the provided tool contains a complete path. 65854 tool_specified="$CCACHE" 65855 tool_basename="${tool_specified##*/}" 65856 if test "x$tool_basename" = "x$tool_specified"; then 65857 # A command without a complete path is provided, search $PATH. 65858 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 65859 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 65860 # Extract the first word of "$tool_basename", so it can be a program name with args. 65861 set dummy $tool_basename; ac_word=$2 65862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65863 $as_echo_n "checking for $ac_word... " >&6; } 65864 if ${ac_cv_path_CCACHE+:} false; then : 65865 $as_echo_n "(cached) " >&6 65866 else 65867 case $CCACHE in 65868 [\\/]* | ?:[\\/]*) 65869 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65870 ;; 65871 *) 65872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65873 for as_dir in $PATH 65874 do 65875 IFS=$as_save_IFS 65876 test -z "$as_dir" && as_dir=. 65877 for ac_exec_ext in '' $ac_executable_extensions; do 65878 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65879 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65880 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65881 break 2 65882 fi 65883 done 65884 done 65885 IFS=$as_save_IFS 65886 65887 ;; 65888 esac 65889 fi 65890 CCACHE=$ac_cv_path_CCACHE 65891 if test -n "$CCACHE"; then 65892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65893 $as_echo "$CCACHE" >&6; } 65894 else 65895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65896 $as_echo "no" >&6; } 65897 fi 65898 65899 65900 if test "x$CCACHE" = x; then 65901 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65902 fi 65903 else 65904 # Otherwise we believe it is a complete path. Use it as it is. 65905 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 65906 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 65907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65908 $as_echo_n "checking for CCACHE... " >&6; } 65909 if test ! -x "$tool_specified"; then 65910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65911 $as_echo "not found" >&6; } 65912 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 65913 fi 65914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65915 $as_echo "$tool_specified" >&6; } 65916 fi 65917 fi 65918 fi 65919 65920 fi 65921 65922 65923 65924 if test "x$CCACHE" = x; then 65925 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 65926 fi 65927 65928 65929 PATH="$OLD_PATH" 65930 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 65931 CCACHE_STATUS="Active ($CCACHE_VERSION)" 65932 else 65933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65934 $as_echo "no" >&6; } 65935 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 65936 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 65937 fi 65938 elif test "x$enable_ccache" = xno; then 65939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 65940 $as_echo "no, explicitly disabled" >&6; } 65941 CCACHE_STATUS="Disabled" 65942 elif test "x$enable_ccache" = x; then 65943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65944 $as_echo "no" >&6; } 65945 else 65946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 65947 $as_echo "unknown" >&6; } 65948 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 65949 fi 65950 65951 65952 65953 # Check whether --with-ccache-dir was given. 65954 if test "${with_ccache_dir+set}" = set; then : 65955 withval=$with_ccache_dir; 65956 fi 65957 65958 65959 if test "x$with_ccache_dir" != x; then 65960 # When using a non home ccache directory, assume the use is to share ccache files 65961 # with other users. Thus change the umask. 65962 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 65963 if test "x$CCACHE" = x; then 65964 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 65965 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 65966 fi 65967 fi 65968 65969 if test "x$CCACHE" != x; then 65970 65971 if test "x$CCACHE" != x; then 65972 if test "x$USE_PRECOMPILED_HEADER" = "x1"; then 65973 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 65974 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 65975 if test "x$HAS_BAD_CCACHE" != "x"; then 65976 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 65977 fi 65978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 65979 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 65980 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 65981 PUSHED_FLAGS="$CXXFLAGS" 65982 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 65983 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65984 /* end confdefs.h. */ 65985 65986 int 65987 main () 65988 { 65989 65990 ; 65991 return 0; 65992 } 65993 _ACEOF 65994 if ac_fn_cxx_try_compile "$LINENO"; then : 65995 CC_KNOWS_CCACHE_TRICK=yes 65996 else 65997 CC_KNOWS_CCACHE_TRICK=no 65998 fi 65999 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 66000 CXXFLAGS="$PUSHED_FLAGS" 66001 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 66002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66003 $as_echo "yes" >&6; } 66004 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 66005 66006 CCACHE_SLOPPINESS=pch_defines,time_macros 66007 else 66008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66009 $as_echo "no" >&6; } 66010 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 66011 fi 66012 fi 66013 66014 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 66015 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 66016 66017 if test "x$SET_CCACHE_DIR" != x; then 66018 mkdir -p $CCACHE_DIR > /dev/null 2>&1 66019 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 66020 fi 66021 fi 66022 66023 fi 66024 66025 66026 ############################################################################### 66027 # 66028 # And now the finish... 66029 # 66030 ############################################################################### 66031 66032 # Check for some common pitfalls 66033 66034 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66035 file_to_test="$SRC_ROOT/LICENSE" 66036 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 66037 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 66038 fi 66039 fi 66040 66041 66042 # Did user specify any unknown variables? 66043 66044 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 66045 # Replace the separating ! with spaces before presenting for end user. 66046 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 66047 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 66048 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 66049 fi 66050 66051 66052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 66053 $as_echo_n "checking if build directory is on local disk... " >&6; } 66054 66055 # df -l lists only local disks; if the given directory is not found then 66056 # a non-zero exit code is given 66057 if test "x$DF" = x; then 66058 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66059 # msys does not have df; use Windows "net use" instead. 66060 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 66061 if test "x$IS_NETWORK_DISK" = x; then 66062 OUTPUT_DIR_IS_LOCAL="yes" 66063 else 66064 OUTPUT_DIR_IS_LOCAL="no" 66065 fi 66066 else 66067 # No df here, say it's local 66068 OUTPUT_DIR_IS_LOCAL="yes" 66069 fi 66070 else 66071 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 66072 OUTPUT_DIR_IS_LOCAL="yes" 66073 else 66074 OUTPUT_DIR_IS_LOCAL="no" 66075 fi 66076 fi 66077 66078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 66079 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 66080 66081 66082 66083 # Check if the user has any old-style ALT_ variables set. 66084 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 66085 66086 # Before generating output files, test if they exist. If they do, this is a reconfigure. 66087 # Since we can't properly handle the dependencies for this, warn the user about the situation 66088 if test -e $OUTPUT_ROOT/spec.gmk; then 66089 IS_RECONFIGURE=yes 66090 else 66091 IS_RECONFIGURE=no 66092 fi 66093 66094 66095 # At the end, call the custom hook. (Dummy macro if no custom sources available) 66096 66097 66098 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 66099 66100 # Keep feature lists sorted and free of duplicates 66101 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 66102 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 66103 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 66104 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 66105 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 66106 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 66107 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 66108 66109 # Validate features 66110 for variant in $JVM_VARIANTS; do 66111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 66112 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 66113 features_var_name=JVM_FEATURES_$variant 66114 JVM_FEATURES_TO_TEST=${!features_var_name} 66115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 66116 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 66117 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 66118 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 66119 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 66120 if test "x$INVALID_FEATURES" != x; then 66121 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 66122 fi 66123 done 66124 66125 66126 # We're messing a bit with internal autoconf variables to put the config.status 66127 # in the output directory instead of the current directory. 66128 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 66129 66130 # Create the actual output files. Now the main work of configure is done. 66131 cat >confcache <<\_ACEOF 66132 # This file is a shell script that caches the results of configure 66133 # tests run on this system so they can be shared between configure 66134 # scripts and configure runs, see configure's option --config-cache. 66135 # It is not useful on other systems. If it contains results you don't 66136 # want to keep, you may remove or edit it. 66137 # 66138 # config.status only pays attention to the cache file if you give it 66139 # the --recheck option to rerun configure. 66140 # 66141 # `ac_cv_env_foo' variables (set or unset) will be overridden when 66142 # loading this file, other *unset* `ac_cv_foo' will be assigned the 66143 # following values. 66144 66145 _ACEOF 66146 66147 # The following way of writing the cache mishandles newlines in values, 66148 # but we know of no workaround that is simple, portable, and efficient. 66149 # So, we kill variables containing newlines. 66150 # Ultrix sh set writes to stderr and can't be redirected directly, 66151 # and sets the high bit in the cache file unless we assign to the vars. 66152 ( 66153 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 66154 eval ac_val=\$$ac_var 66155 case $ac_val in #( 66156 *${as_nl}*) 66157 case $ac_var in #( 66158 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 66159 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 66160 esac 66161 case $ac_var in #( 66162 _ | IFS | as_nl) ;; #( 66163 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 66164 *) { eval $ac_var=; unset $ac_var;} ;; 66165 esac ;; 66166 esac 66167 done 66168 66169 (set) 2>&1 | 66170 case $as_nl`(ac_space=' '; set) 2>&1` in #( 66171 *${as_nl}ac_space=\ *) 66172 # `set' does not quote correctly, so add quotes: double-quote 66173 # substitution turns \\\\ into \\, and sed turns \\ into \. 66174 sed -n \ 66175 "s/'/'\\\\''/g; 66176 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 66177 ;; #( 66178 *) 66179 # `set' quotes correctly as required by POSIX, so do not add quotes. 66180 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 66181 ;; 66182 esac | 66183 sort 66184 ) | 66185 sed ' 66186 /^ac_cv_env_/b end 66187 t clear 66188 :clear 66189 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 66190 t end 66191 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 66192 :end' >>confcache 66193 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 66194 if test -w "$cache_file"; then 66195 if test "x$cache_file" != "x/dev/null"; then 66196 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 66197 $as_echo "$as_me: updating cache $cache_file" >&6;} 66198 if test ! -f "$cache_file" || test -h "$cache_file"; then 66199 cat confcache >"$cache_file" 66200 else 66201 case $cache_file in #( 66202 */* | ?:*) 66203 mv -f confcache "$cache_file"$$ && 66204 mv -f "$cache_file"$$ "$cache_file" ;; #( 66205 *) 66206 mv -f confcache "$cache_file" ;; 66207 esac 66208 fi 66209 fi 66210 else 66211 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 66212 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 66213 fi 66214 fi 66215 rm -f confcache 66216 66217 test "x$prefix" = xNONE && prefix=$ac_default_prefix 66218 # Let make expand exec_prefix. 66219 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 66220 66221 # Transform confdefs.h into DEFS. 66222 # Protect against shell expansion while executing Makefile rules. 66223 # Protect against Makefile macro expansion. 66224 # 66225 # If the first sed substitution is executed (which looks for macros that 66226 # take arguments), then branch to the quote section. Otherwise, 66227 # look for a macro that doesn't take arguments. 66228 ac_script=' 66229 :mline 66230 /\\$/{ 66231 N 66232 s,\\\n,, 66233 b mline 66234 } 66235 t clear 66236 :clear 66237 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 66238 t quote 66239 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 66240 t quote 66241 b any 66242 :quote 66243 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 66244 s/\[/\\&/g 66245 s/\]/\\&/g 66246 s/\$/$$/g 66247 H 66248 :any 66249 ${ 66250 g 66251 s/^\n// 66252 s/\n/ /g 66253 p 66254 } 66255 ' 66256 DEFS=`sed -n "$ac_script" confdefs.h` 66257 66258 66259 ac_libobjs= 66260 ac_ltlibobjs= 66261 U= 66262 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 66263 # 1. Remove the extension, and $U if already installed. 66264 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 66265 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 66266 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 66267 # will be set to the directory where LIBOBJS objects are built. 66268 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 66269 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 66270 done 66271 LIBOBJS=$ac_libobjs 66272 66273 LTLIBOBJS=$ac_ltlibobjs 66274 66275 66276 66277 : "${CONFIG_STATUS=./config.status}" 66278 ac_write_fail=0 66279 ac_clean_files_save=$ac_clean_files 66280 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 66281 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 66282 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 66283 as_write_fail=0 66284 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 66285 #! $SHELL 66286 # Generated by $as_me. 66287 # Run this file to recreate the current configuration. 66288 # Compiler output produced by configure, useful for debugging 66289 # configure, is in config.log if it exists. 66290 66291 debug=false 66292 ac_cs_recheck=false 66293 ac_cs_silent=false 66294 66295 SHELL=\${CONFIG_SHELL-$SHELL} 66296 export SHELL 66297 _ASEOF 66298 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 66299 ## -------------------- ## 66300 ## M4sh Initialization. ## 66301 ## -------------------- ## 66302 66303 # Be more Bourne compatible 66304 DUALCASE=1; export DUALCASE # for MKS sh 66305 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 66306 emulate sh 66307 NULLCMD=: 66308 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 66309 # is contrary to our usage. Disable this feature. 66310 alias -g '${1+"$@"}'='"$@"' 66311 setopt NO_GLOB_SUBST 66312 else 66313 case `(set -o) 2>/dev/null` in #( 66314 *posix*) : 66315 set -o posix ;; #( 66316 *) : 66317 ;; 66318 esac 66319 fi 66320 66321 66322 as_nl=' 66323 ' 66324 export as_nl 66325 # Printing a long string crashes Solaris 7 /usr/bin/printf. 66326 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 66327 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 66328 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 66329 # Prefer a ksh shell builtin over an external printf program on Solaris, 66330 # but without wasting forks for bash or zsh. 66331 if test -z "$BASH_VERSION$ZSH_VERSION" \ 66332 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 66333 as_echo='print -r --' 66334 as_echo_n='print -rn --' 66335 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 66336 as_echo='printf %s\n' 66337 as_echo_n='printf %s' 66338 else 66339 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 66340 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 66341 as_echo_n='/usr/ucb/echo -n' 66342 else 66343 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 66344 as_echo_n_body='eval 66345 arg=$1; 66346 case $arg in #( 66347 *"$as_nl"*) 66348 expr "X$arg" : "X\\(.*\\)$as_nl"; 66349 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 66350 esac; 66351 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 66352 ' 66353 export as_echo_n_body 66354 as_echo_n='sh -c $as_echo_n_body as_echo' 66355 fi 66356 export as_echo_body 66357 as_echo='sh -c $as_echo_body as_echo' 66358 fi 66359 66360 # The user is always right. 66361 if test "${PATH_SEPARATOR+set}" != set; then 66362 PATH_SEPARATOR=: 66363 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 66364 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 66365 PATH_SEPARATOR=';' 66366 } 66367 fi 66368 66369 66370 # IFS 66371 # We need space, tab and new line, in precisely that order. Quoting is 66372 # there to prevent editors from complaining about space-tab. 66373 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 66374 # splitting by setting IFS to empty value.) 66375 IFS=" "" $as_nl" 66376 66377 # Find who we are. Look in the path if we contain no directory separator. 66378 as_myself= 66379 case $0 in #(( 66380 *[\\/]* ) as_myself=$0 ;; 66381 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66382 for as_dir in $PATH 66383 do 66384 IFS=$as_save_IFS 66385 test -z "$as_dir" && as_dir=. 66386 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 66387 done 66388 IFS=$as_save_IFS 66389 66390 ;; 66391 esac 66392 # We did not find ourselves, most probably we were run as `sh COMMAND' 66393 # in which case we are not to be found in the path. 66394 if test "x$as_myself" = x; then 66395 as_myself=$0 66396 fi 66397 if test ! -f "$as_myself"; then 66398 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 66399 exit 1 66400 fi 66401 66402 # Unset variables that we do not need and which cause bugs (e.g. in 66403 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 66404 # suppresses any "Segmentation fault" message there. '((' could 66405 # trigger a bug in pdksh 5.2.14. 66406 for as_var in BASH_ENV ENV MAIL MAILPATH 66407 do eval test x\${$as_var+set} = xset \ 66408 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 66409 done 66410 PS1='$ ' 66411 PS2='> ' 66412 PS4='+ ' 66413 66414 # NLS nuisances. 66415 LC_ALL=C 66416 export LC_ALL 66417 LANGUAGE=C 66418 export LANGUAGE 66419 66420 # CDPATH. 66421 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 66422 66423 66424 # as_fn_error STATUS ERROR [LINENO LOG_FD] 66425 # ---------------------------------------- 66426 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 66427 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 66428 # script with STATUS, using 1 if that was 0. 66429 as_fn_error () 66430 { 66431 as_status=$1; test $as_status -eq 0 && as_status=1 66432 if test "$4"; then 66433 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 66434 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 66435 fi 66436 $as_echo "$as_me: error: $2" >&2 66437 as_fn_exit $as_status 66438 } # as_fn_error 66439 66440 66441 # as_fn_set_status STATUS 66442 # ----------------------- 66443 # Set $? to STATUS, without forking. 66444 as_fn_set_status () 66445 { 66446 return $1 66447 } # as_fn_set_status 66448 66449 # as_fn_exit STATUS 66450 # ----------------- 66451 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 66452 as_fn_exit () 66453 { 66454 set +e 66455 as_fn_set_status $1 66456 exit $1 66457 } # as_fn_exit 66458 66459 # as_fn_unset VAR 66460 # --------------- 66461 # Portably unset VAR. 66462 as_fn_unset () 66463 { 66464 { eval $1=; unset $1;} 66465 } 66466 as_unset=as_fn_unset 66467 # as_fn_append VAR VALUE 66468 # ---------------------- 66469 # Append the text in VALUE to the end of the definition contained in VAR. Take 66470 # advantage of any shell optimizations that allow amortized linear growth over 66471 # repeated appends, instead of the typical quadratic growth present in naive 66472 # implementations. 66473 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 66474 eval 'as_fn_append () 66475 { 66476 eval $1+=\$2 66477 }' 66478 else 66479 as_fn_append () 66480 { 66481 eval $1=\$$1\$2 66482 } 66483 fi # as_fn_append 66484 66485 # as_fn_arith ARG... 66486 # ------------------ 66487 # Perform arithmetic evaluation on the ARGs, and store the result in the 66488 # global $as_val. Take advantage of shells that can avoid forks. The arguments 66489 # must be portable across $(()) and expr. 66490 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 66491 eval 'as_fn_arith () 66492 { 66493 as_val=$(( $* )) 66494 }' 66495 else 66496 as_fn_arith () 66497 { 66498 as_val=`expr "$@" || test $? -eq 1` 66499 } 66500 fi # as_fn_arith 66501 66502 66503 if expr a : '\(a\)' >/dev/null 2>&1 && 66504 test "X`expr 00001 : '.*\(...\)'`" = X001; then 66505 as_expr=expr 66506 else 66507 as_expr=false 66508 fi 66509 66510 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 66511 as_basename=basename 66512 else 66513 as_basename=false 66514 fi 66515 66516 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 66517 as_dirname=dirname 66518 else 66519 as_dirname=false 66520 fi 66521 66522 as_me=`$as_basename -- "$0" || 66523 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 66524 X"$0" : 'X\(//\)$' \| \ 66525 X"$0" : 'X\(/\)' \| . 2>/dev/null || 66526 $as_echo X/"$0" | 66527 sed '/^.*\/\([^/][^/]*\)\/*$/{ 66528 s//\1/ 66529 q 66530 } 66531 /^X\/\(\/\/\)$/{ 66532 s//\1/ 66533 q 66534 } 66535 /^X\/\(\/\).*/{ 66536 s//\1/ 66537 q 66538 } 66539 s/.*/./; q'` 66540 66541 # Avoid depending upon Character Ranges. 66542 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 66543 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 66544 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 66545 as_cr_digits='0123456789' 66546 as_cr_alnum=$as_cr_Letters$as_cr_digits 66547 66548 ECHO_C= ECHO_N= ECHO_T= 66549 case `echo -n x` in #((((( 66550 -n*) 66551 case `echo 'xy\c'` in 66552 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 66553 xy) ECHO_C='\c';; 66554 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 66555 ECHO_T=' ';; 66556 esac;; 66557 *) 66558 ECHO_N='-n';; 66559 esac 66560 66561 rm -f conf$$ conf$$.exe conf$$.file 66562 if test -d conf$$.dir; then 66563 rm -f conf$$.dir/conf$$.file 66564 else 66565 rm -f conf$$.dir 66566 mkdir conf$$.dir 2>/dev/null 66567 fi 66568 if (echo >conf$$.file) 2>/dev/null; then 66569 if ln -s conf$$.file conf$$ 2>/dev/null; then 66570 as_ln_s='ln -s' 66571 # ... but there are two gotchas: 66572 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 66573 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 66574 # In both cases, we have to default to `cp -pR'. 66575 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 66576 as_ln_s='cp -pR' 66577 elif ln conf$$.file conf$$ 2>/dev/null; then 66578 as_ln_s=ln 66579 else 66580 as_ln_s='cp -pR' 66581 fi 66582 else 66583 as_ln_s='cp -pR' 66584 fi 66585 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 66586 rmdir conf$$.dir 2>/dev/null 66587 66588 66589 # as_fn_mkdir_p 66590 # ------------- 66591 # Create "$as_dir" as a directory, including parents if necessary. 66592 as_fn_mkdir_p () 66593 { 66594 66595 case $as_dir in #( 66596 -*) as_dir=./$as_dir;; 66597 esac 66598 test -d "$as_dir" || eval $as_mkdir_p || { 66599 as_dirs= 66600 while :; do 66601 case $as_dir in #( 66602 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 66603 *) as_qdir=$as_dir;; 66604 esac 66605 as_dirs="'$as_qdir' $as_dirs" 66606 as_dir=`$as_dirname -- "$as_dir" || 66607 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 66608 X"$as_dir" : 'X\(//\)[^/]' \| \ 66609 X"$as_dir" : 'X\(//\)$' \| \ 66610 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 66611 $as_echo X"$as_dir" | 66612 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 66613 s//\1/ 66614 q 66615 } 66616 /^X\(\/\/\)[^/].*/{ 66617 s//\1/ 66618 q 66619 } 66620 /^X\(\/\/\)$/{ 66621 s//\1/ 66622 q 66623 } 66624 /^X\(\/\).*/{ 66625 s//\1/ 66626 q 66627 } 66628 s/.*/./; q'` 66629 test -d "$as_dir" && break 66630 done 66631 test -z "$as_dirs" || eval "mkdir $as_dirs" 66632 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 66633 66634 66635 } # as_fn_mkdir_p 66636 if mkdir -p . 2>/dev/null; then 66637 as_mkdir_p='mkdir -p "$as_dir"' 66638 else 66639 test -d ./-p && rmdir ./-p 66640 as_mkdir_p=false 66641 fi 66642 66643 66644 # as_fn_executable_p FILE 66645 # ----------------------- 66646 # Test if FILE is an executable regular file. 66647 as_fn_executable_p () 66648 { 66649 test -f "$1" && test -x "$1" 66650 } # as_fn_executable_p 66651 as_test_x='test -x' 66652 as_executable_p=as_fn_executable_p 66653 66654 # Sed expression to map a string onto a valid CPP name. 66655 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 66656 66657 # Sed expression to map a string onto a valid variable name. 66658 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 66659 66660 66661 exec 6>&1 66662 ## ----------------------------------- ## 66663 ## Main body of $CONFIG_STATUS script. ## 66664 ## ----------------------------------- ## 66665 _ASEOF 66666 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 66667 66668 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66669 # Save the log message, to keep $0 and so on meaningful, and to 66670 # report actual input values of CONFIG_FILES etc. instead of their 66671 # values after options handling. 66672 ac_log=" 66673 This file was extended by OpenJDK $as_me jdk9, which was 66674 generated by GNU Autoconf 2.69. Invocation command line was 66675 66676 CONFIG_FILES = $CONFIG_FILES 66677 CONFIG_HEADERS = $CONFIG_HEADERS 66678 CONFIG_LINKS = $CONFIG_LINKS 66679 CONFIG_COMMANDS = $CONFIG_COMMANDS 66680 $ $0 $@ 66681 66682 on `(hostname || uname -n) 2>/dev/null | sed 1q` 66683 " 66684 66685 _ACEOF 66686 66687 case $ac_config_files in *" 66688 "*) set x $ac_config_files; shift; ac_config_files=$*;; 66689 esac 66690 66691 66692 66693 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66694 # Files that config.status was made for. 66695 config_files="$ac_config_files" 66696 66697 _ACEOF 66698 66699 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66700 ac_cs_usage="\ 66701 \`$as_me' instantiates files and other configuration actions 66702 from templates according to the current configuration. Unless the files 66703 and actions are specified as TAGs, all are instantiated by default. 66704 66705 Usage: $0 [OPTION]... [TAG]... 66706 66707 -h, --help print this help, then exit 66708 -V, --version print version number and configuration settings, then exit 66709 --config print configuration, then exit 66710 -q, --quiet, --silent 66711 do not print progress messages 66712 -d, --debug don't remove temporary files 66713 --recheck update $as_me by reconfiguring in the same conditions 66714 --file=FILE[:TEMPLATE] 66715 instantiate the configuration file FILE 66716 66717 Configuration files: 66718 $config_files 66719 66720 Report bugs to <build-dev@openjdk.java.net>. 66721 OpenJDK home page: <http://openjdk.java.net>." 66722 66723 _ACEOF 66724 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66725 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 66726 ac_cs_version="\\ 66727 OpenJDK config.status jdk9 66728 configured by $0, generated by GNU Autoconf 2.69, 66729 with options \\"\$ac_cs_config\\" 66730 66731 Copyright (C) 2012 Free Software Foundation, Inc. 66732 This config.status script is free software; the Free Software Foundation 66733 gives unlimited permission to copy, distribute and modify it." 66734 66735 ac_pwd='$ac_pwd' 66736 srcdir='$srcdir' 66737 AWK='$AWK' 66738 test -n "\$AWK" || AWK=awk 66739 _ACEOF 66740 66741 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66742 # The default lists apply if the user does not specify any file. 66743 ac_need_defaults=: 66744 while test $# != 0 66745 do 66746 case $1 in 66747 --*=?*) 66748 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66749 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 66750 ac_shift=: 66751 ;; 66752 --*=) 66753 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66754 ac_optarg= 66755 ac_shift=: 66756 ;; 66757 *) 66758 ac_option=$1 66759 ac_optarg=$2 66760 ac_shift=shift 66761 ;; 66762 esac 66763 66764 case $ac_option in 66765 # Handling of the options. 66766 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 66767 ac_cs_recheck=: ;; 66768 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 66769 $as_echo "$ac_cs_version"; exit ;; 66770 --config | --confi | --conf | --con | --co | --c ) 66771 $as_echo "$ac_cs_config"; exit ;; 66772 --debug | --debu | --deb | --de | --d | -d ) 66773 debug=: ;; 66774 --file | --fil | --fi | --f ) 66775 $ac_shift 66776 case $ac_optarg in 66777 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 66778 '') as_fn_error $? "missing file argument" ;; 66779 esac 66780 as_fn_append CONFIG_FILES " '$ac_optarg'" 66781 ac_need_defaults=false;; 66782 --he | --h | --help | --hel | -h ) 66783 $as_echo "$ac_cs_usage"; exit ;; 66784 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 66785 | -silent | --silent | --silen | --sile | --sil | --si | --s) 66786 ac_cs_silent=: ;; 66787 66788 # This is an error. 66789 -*) as_fn_error $? "unrecognized option: \`$1' 66790 Try \`$0 --help' for more information." ;; 66791 66792 *) as_fn_append ac_config_targets " $1" 66793 ac_need_defaults=false ;; 66794 66795 esac 66796 shift 66797 done 66798 66799 ac_configure_extra_args= 66800 66801 if $ac_cs_silent; then 66802 exec 6>/dev/null 66803 ac_configure_extra_args="$ac_configure_extra_args --silent" 66804 fi 66805 66806 _ACEOF 66807 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66808 if \$ac_cs_recheck; then 66809 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 66810 shift 66811 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 66812 CONFIG_SHELL='$SHELL' 66813 export CONFIG_SHELL 66814 exec "\$@" 66815 fi 66816 66817 _ACEOF 66818 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66819 exec 5>>config.log 66820 { 66821 echo 66822 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 66823 ## Running $as_me. ## 66824 _ASBOX 66825 $as_echo "$ac_log" 66826 } >&5 66827 66828 _ACEOF 66829 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66830 _ACEOF 66831 66832 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66833 66834 # Handling of arguments. 66835 for ac_config_target in $ac_config_targets 66836 do 66837 case $ac_config_target in 66838 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 66839 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 66840 "$OUTPUT_ROOT/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 66841 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 66842 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 66843 66844 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 66845 esac 66846 done 66847 66848 66849 # If the user did not use the arguments to specify the items to instantiate, 66850 # then the envvar interface is used. Set only those that are not. 66851 # We use the long form for the default assignment because of an extremely 66852 # bizarre bug on SunOS 4.1.3. 66853 if $ac_need_defaults; then 66854 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 66855 fi 66856 66857 # Have a temporary directory for convenience. Make it in the build tree 66858 # simply because there is no reason against having it here, and in addition, 66859 # creating and moving files from /tmp can sometimes cause problems. 66860 # Hook for its removal unless debugging. 66861 # Note that there is a small window in which the directory will not be cleaned: 66862 # after its creation but before its name has been assigned to `$tmp'. 66863 $debug || 66864 { 66865 tmp= ac_tmp= 66866 trap 'exit_status=$? 66867 : "${ac_tmp:=$tmp}" 66868 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 66869 ' 0 66870 trap 'as_fn_exit 1' 1 2 13 15 66871 } 66872 # Create a (secure) tmp directory for tmp files. 66873 66874 { 66875 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 66876 test -d "$tmp" 66877 } || 66878 { 66879 tmp=./conf$$-$RANDOM 66880 (umask 077 && mkdir "$tmp") 66881 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 66882 ac_tmp=$tmp 66883 66884 # Set up the scripts for CONFIG_FILES section. 66885 # No need to generate them if there are no CONFIG_FILES. 66886 # This happens for instance with `./config.status config.h'. 66887 if test -n "$CONFIG_FILES"; then 66888 66889 66890 ac_cr=`echo X | tr X '\015'` 66891 # On cygwin, bash can eat \r inside `` if the user requested igncr. 66892 # But we know of no other shell where ac_cr would be empty at this 66893 # point, so we can use a bashism as a fallback. 66894 if test "x$ac_cr" = x; then 66895 eval ac_cr=\$\'\\r\' 66896 fi 66897 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 66898 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 66899 ac_cs_awk_cr='\\r' 66900 else 66901 ac_cs_awk_cr=$ac_cr 66902 fi 66903 66904 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 66905 _ACEOF 66906 66907 66908 { 66909 echo "cat >conf$$subs.awk <<_ACEOF" && 66910 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 66911 echo "_ACEOF" 66912 } >conf$$subs.sh || 66913 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66914 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 66915 ac_delim='%!_!# ' 66916 for ac_last_try in false false false false false :; do 66917 . ./conf$$subs.sh || 66918 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66919 66920 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 66921 if test $ac_delim_n = $ac_delim_num; then 66922 break 66923 elif $ac_last_try; then 66924 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66925 else 66926 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 66927 fi 66928 done 66929 rm -f conf$$subs.sh 66930 66931 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66932 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 66933 _ACEOF 66934 sed -n ' 66935 h 66936 s/^/S["/; s/!.*/"]=/ 66937 p 66938 g 66939 s/^[^!]*!// 66940 :repl 66941 t repl 66942 s/'"$ac_delim"'$// 66943 t delim 66944 :nl 66945 h 66946 s/\(.\{148\}\)..*/\1/ 66947 t more1 66948 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 66949 p 66950 n 66951 b repl 66952 :more1 66953 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66954 p 66955 g 66956 s/.\{148\}// 66957 t nl 66958 :delim 66959 h 66960 s/\(.\{148\}\)..*/\1/ 66961 t more2 66962 s/["\\]/\\&/g; s/^/"/; s/$/"/ 66963 p 66964 b 66965 :more2 66966 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66967 p 66968 g 66969 s/.\{148\}// 66970 t delim 66971 ' <conf$$subs.awk | sed ' 66972 /^[^""]/{ 66973 N 66974 s/\n// 66975 } 66976 ' >>$CONFIG_STATUS || ac_write_fail=1 66977 rm -f conf$$subs.awk 66978 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66979 _ACAWK 66980 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 66981 for (key in S) S_is_set[key] = 1 66982 FS = "" 66983 66984 } 66985 { 66986 line = $ 0 66987 nfields = split(line, field, "@") 66988 substed = 0 66989 len = length(field[1]) 66990 for (i = 2; i < nfields; i++) { 66991 key = field[i] 66992 keylen = length(key) 66993 if (S_is_set[key]) { 66994 value = S[key] 66995 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 66996 len += length(value) + length(field[++i]) 66997 substed = 1 66998 } else 66999 len += 1 + keylen 67000 } 67001 67002 print line 67003 } 67004 67005 _ACAWK 67006 _ACEOF 67007 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67008 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 67009 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 67010 else 67011 cat 67012 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 67013 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 67014 _ACEOF 67015 67016 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 67017 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 67018 # trailing colons and then remove the whole line if VPATH becomes empty 67019 # (actually we leave an empty line to preserve line numbers). 67020 if test "x$srcdir" = x.; then 67021 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 67022 h 67023 s/// 67024 s/^/:/ 67025 s/[ ]*$/:/ 67026 s/:\$(srcdir):/:/g 67027 s/:\${srcdir}:/:/g 67028 s/:@srcdir@:/:/g 67029 s/^:*// 67030 s/:*$// 67031 x 67032 s/\(=[ ]*\).*/\1/ 67033 G 67034 s/\n// 67035 s/^[^=]*=[ ]*$// 67036 }' 67037 fi 67038 67039 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67040 fi # test -n "$CONFIG_FILES" 67041 67042 67043 eval set X " :F $CONFIG_FILES " 67044 shift 67045 for ac_tag 67046 do 67047 case $ac_tag in 67048 :[FHLC]) ac_mode=$ac_tag; continue;; 67049 esac 67050 case $ac_mode$ac_tag in 67051 :[FHL]*:*);; 67052 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 67053 :[FH]-) ac_tag=-:-;; 67054 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 67055 esac 67056 ac_save_IFS=$IFS 67057 IFS=: 67058 set x $ac_tag 67059 IFS=$ac_save_IFS 67060 shift 67061 ac_file=$1 67062 shift 67063 67064 case $ac_mode in 67065 :L) ac_source=$1;; 67066 :[FH]) 67067 ac_file_inputs= 67068 for ac_f 67069 do 67070 case $ac_f in 67071 -) ac_f="$ac_tmp/stdin";; 67072 *) # Look for the file first in the build tree, then in the source tree 67073 # (if the path is not absolute). The absolute path cannot be DOS-style, 67074 # because $ac_f cannot contain `:'. 67075 test -f "$ac_f" || 67076 case $ac_f in 67077 [\\/$]*) false;; 67078 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 67079 esac || 67080 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 67081 esac 67082 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 67083 as_fn_append ac_file_inputs " '$ac_f'" 67084 done 67085 67086 # Let's still pretend it is `configure' which instantiates (i.e., don't 67087 # use $as_me), people would be surprised to read: 67088 # /* config.h. Generated by config.status. */ 67089 configure_input='Generated from '` 67090 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 67091 `' by configure.' 67092 if test x"$ac_file" != x-; then 67093 configure_input="$ac_file. $configure_input" 67094 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 67095 $as_echo "$as_me: creating $ac_file" >&6;} 67096 fi 67097 # Neutralize special characters interpreted by sed in replacement strings. 67098 case $configure_input in #( 67099 *\&* | *\|* | *\\* ) 67100 ac_sed_conf_input=`$as_echo "$configure_input" | 67101 sed 's/[\\\\&|]/\\\\&/g'`;; #( 67102 *) ac_sed_conf_input=$configure_input;; 67103 esac 67104 67105 case $ac_tag in 67106 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 67107 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 67108 esac 67109 ;; 67110 esac 67111 67112 ac_dir=`$as_dirname -- "$ac_file" || 67113 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 67114 X"$ac_file" : 'X\(//\)[^/]' \| \ 67115 X"$ac_file" : 'X\(//\)$' \| \ 67116 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 67117 $as_echo X"$ac_file" | 67118 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 67119 s//\1/ 67120 q 67121 } 67122 /^X\(\/\/\)[^/].*/{ 67123 s//\1/ 67124 q 67125 } 67126 /^X\(\/\/\)$/{ 67127 s//\1/ 67128 q 67129 } 67130 /^X\(\/\).*/{ 67131 s//\1/ 67132 q 67133 } 67134 s/.*/./; q'` 67135 as_dir="$ac_dir"; as_fn_mkdir_p 67136 ac_builddir=. 67137 67138 case "$ac_dir" in 67139 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 67140 *) 67141 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 67142 # A ".." for each directory in $ac_dir_suffix. 67143 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 67144 case $ac_top_builddir_sub in 67145 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 67146 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 67147 esac ;; 67148 esac 67149 ac_abs_top_builddir=$ac_pwd 67150 ac_abs_builddir=$ac_pwd$ac_dir_suffix 67151 # for backward compatibility: 67152 ac_top_builddir=$ac_top_build_prefix 67153 67154 case $srcdir in 67155 .) # We are building in place. 67156 ac_srcdir=. 67157 ac_top_srcdir=$ac_top_builddir_sub 67158 ac_abs_top_srcdir=$ac_pwd ;; 67159 [\\/]* | ?:[\\/]* ) # Absolute name. 67160 ac_srcdir=$srcdir$ac_dir_suffix; 67161 ac_top_srcdir=$srcdir 67162 ac_abs_top_srcdir=$srcdir ;; 67163 *) # Relative name. 67164 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 67165 ac_top_srcdir=$ac_top_build_prefix$srcdir 67166 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 67167 esac 67168 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 67169 67170 67171 case $ac_mode in 67172 :F) 67173 # 67174 # CONFIG_FILE 67175 # 67176 67177 _ACEOF 67178 67179 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67180 # If the template does not know about datarootdir, expand it. 67181 # FIXME: This hack should be removed a few years after 2.60. 67182 ac_datarootdir_hack=; ac_datarootdir_seen= 67183 ac_sed_dataroot=' 67184 /datarootdir/ { 67185 p 67186 q 67187 } 67188 /@datadir@/p 67189 /@docdir@/p 67190 /@infodir@/p 67191 /@localedir@/p 67192 /@mandir@/p' 67193 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 67194 *datarootdir*) ac_datarootdir_seen=yes;; 67195 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 67196 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 67197 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 67198 _ACEOF 67199 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67200 ac_datarootdir_hack=' 67201 s&@datadir@&$datadir&g 67202 s&@docdir@&$docdir&g 67203 s&@infodir@&$infodir&g 67204 s&@localedir@&$localedir&g 67205 s&@mandir@&$mandir&g 67206 s&\\\${datarootdir}&$datarootdir&g' ;; 67207 esac 67208 _ACEOF 67209 67210 # Neutralize VPATH when `$srcdir' = `.'. 67211 # Shell code in configure.ac might set extrasub. 67212 # FIXME: do we really want to maintain this feature? 67213 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67214 ac_sed_extra="$ac_vpsub 67215 $extrasub 67216 _ACEOF 67217 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67218 :t 67219 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 67220 s|@configure_input@|$ac_sed_conf_input|;t t 67221 s&@top_builddir@&$ac_top_builddir_sub&;t t 67222 s&@top_build_prefix@&$ac_top_build_prefix&;t t 67223 s&@srcdir@&$ac_srcdir&;t t 67224 s&@abs_srcdir@&$ac_abs_srcdir&;t t 67225 s&@top_srcdir@&$ac_top_srcdir&;t t 67226 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 67227 s&@builddir@&$ac_builddir&;t t 67228 s&@abs_builddir@&$ac_abs_builddir&;t t 67229 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 67230 $ac_datarootdir_hack 67231 " 67232 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 67233 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 67234 67235 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 67236 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 67237 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 67238 "$ac_tmp/out"`; test -z "$ac_out"; } && 67239 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 67240 which seems to be undefined. Please make sure it is defined" >&5 67241 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 67242 which seems to be undefined. Please make sure it is defined" >&2;} 67243 67244 rm -f "$ac_tmp/stdin" 67245 case $ac_file in 67246 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 67247 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 67248 esac \ 67249 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 67250 ;; 67251 67252 67253 67254 esac 67255 67256 done # for ac_tag 67257 67258 67259 as_fn_exit 0 67260 _ACEOF 67261 ac_clean_files=$ac_clean_files_save 67262 67263 test $ac_write_fail = 0 || 67264 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 67265 67266 67267 # configure is writing to config.log, and then calls config.status. 67268 # config.status does its own redirection, appending to config.log. 67269 # Unfortunately, on DOS this fails, as config.log is still kept open 67270 # by configure, so config.status won't be able to write to it; its 67271 # output is simply discarded. So we exec the FD to /dev/null, 67272 # effectively closing config.log, so it can be properly (re)opened and 67273 # appended to by config.status. When coming back to configure, we 67274 # need to make the FD available again. 67275 if test "$no_create" != yes; then 67276 ac_cs_success=: 67277 ac_config_status_args= 67278 test "$silent" = yes && 67279 ac_config_status_args="$ac_config_status_args --quiet" 67280 exec 5>/dev/null 67281 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 67282 exec 5>>config.log 67283 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 67284 # would make configure fail if this is the last instruction. 67285 $ac_cs_success || as_fn_exit 1 67286 fi 67287 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 67288 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 67289 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 67290 fi 67291 67292 67293 # After AC_OUTPUT, we need to do final work 67294 67295 67296 # Try to move config.log (generated by autoconf) to the configure-support directory. 67297 if test -e ./config.log; then 67298 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 67299 fi 67300 67301 # Rotate our log file (configure.log) 67302 if test -e "$OUTPUT_ROOT/configure.log.old"; then 67303 $RM -f "$OUTPUT_ROOT/configure.log.old" 67304 fi 67305 if test -e "$OUTPUT_ROOT/configure.log"; then 67306 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 67307 fi 67308 67309 # Move configure.log from current directory to the build output root 67310 if test -e ./configure.log; then 67311 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 67312 fi 67313 67314 # Make the compare script executable 67315 $CHMOD +x $OUTPUT_ROOT/compare.sh 67316 67317 67318 # Finally output some useful information to the user 67319 67320 # Finally output some useful information to the user 67321 67322 printf "\n" 67323 printf "====================================================\n" 67324 if test "x$no_create" != "xyes"; then 67325 if test "x$IS_RECONFIGURE" != "xyes"; then 67326 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 67327 else 67328 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 67329 fi 67330 else 67331 if test "x$IS_RECONFIGURE" != "xyes"; then 67332 printf "A configuration has been successfully checked but not created\n" 67333 else 67334 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 67335 fi 67336 fi 67337 if test "x$CONFIGURE_COMMAND_LINE" != x; then 67338 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 67339 else 67340 printf "using default settings.\n" 67341 fi 67342 67343 printf "\n" 67344 printf "Configuration summary:\n" 67345 printf "* Debug level: $DEBUG_LEVEL\n" 67346 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 67347 printf "* JDK variant: $JDK_VARIANT\n" 67348 printf "* JVM variants: $JVM_VARIANTS\n" 67349 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 67350 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 67351 67352 printf "\n" 67353 printf "Tools summary:\n" 67354 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 67355 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 67356 fi 67357 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 67358 if test "x$TOOLCHAIN_VERSION" != "x"; then 67359 print_version=" $TOOLCHAIN_VERSION" 67360 fi 67361 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 67362 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 67363 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 67364 67365 printf "\n" 67366 printf "Build performance summary:\n" 67367 printf "* Cores to use: $JOBS\n" 67368 printf "* Memory limit: $MEMORY_SIZE MB\n" 67369 if test "x$CCACHE_STATUS" != "x"; then 67370 printf "* ccache status: $CCACHE_STATUS\n" 67371 fi 67372 printf "\n" 67373 67374 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 67375 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 67376 printf "will result in longer build times.\n" 67377 printf "\n" 67378 fi 67379 67380 if test "x$FOUND_ALT_VARIABLES" != "x"; then 67381 printf "WARNING: You have old-style ALT_ environment variables set.\n" 67382 printf "These are not respected, and will be ignored. It is recommended\n" 67383 printf "that you clean your environment. The following variables are set:\n" 67384 printf "$FOUND_ALT_VARIABLES\n" 67385 printf "\n" 67386 fi 67387 67388 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 67389 printf "WARNING: Your build output directory is not on a local disk.\n" 67390 printf "This will severely degrade build performance!\n" 67391 printf "It is recommended that you create an output directory on a local disk,\n" 67392 printf "and run the configure script again from that directory.\n" 67393 printf "\n" 67394 fi 67395 67396 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 67397 printf "WARNING: The result of this configuration has overridden an older\n" 67398 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 67399 printf "proper build. Failure to do so might result in strange build problems.\n" 67400 printf "\n" 67401 fi 67402 67403 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 67404 printf "WARNING: The result of this configuration was not saved.\n" 67405 printf "You should run without '--no-create | -n' to create the configuration.\n" 67406 printf "\n" 67407 fi 67408 67409 67410 67411 # Locate config.log. 67412 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 67413 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 67414 elif test -e "./config.log"; then 67415 CONFIG_LOG_PATH="." 67416 fi 67417 67418 if test -e "$CONFIG_LOG_PATH/config.log"; then 67419 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 67420 if test $? -eq 0; then 67421 printf "The following warnings were produced. Repeated here for convenience:\n" 67422 # We must quote sed expression (using []) to stop m4 from eating the []. 67423 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 67424 printf "\n" 67425 fi 67426 fi 67427