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=1472718471 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 * ) 49863 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49864 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49865 ;; 49866 esac 49867 49868 49869 49870 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 # Execute function body 49922 49923 # Need to assign to a variable since m4 is blocked from modifying parts in []. 49924 REFERENCE_VERSION=6 49925 49926 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 49927 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 49928 fi 49929 49930 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 49931 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 49932 fi 49933 49934 # Version comparison method inspired by http://stackoverflow.com/a/24067243 49935 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 49936 49937 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 49938 : 49939 49940 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 49941 # runs afoul of the more aggressive versions of these optimisations. 49942 # Notably, value range propagation now assumes that the this pointer of C++ 49943 # member functions is non-null. 49944 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 49945 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 49946 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 49947 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 49948 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49949 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49950 49951 else 49952 : 49953 49954 fi 49955 49956 49957 49958 49959 49960 49961 49962 49963 49964 49965 49966 49967 49968 49969 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49970 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49971 49972 # Restrict the debug information created by Clang to avoid 49973 # too big object files and speed the build up a little bit 49974 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 49975 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 49976 if test "x$OPENJDK_TARGET_OS" = xlinux; then 49977 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49978 # Force compatibility with i586 on 32 bit intel platforms. 49979 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49980 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49981 fi 49982 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 49983 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49984 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49985 case $OPENJDK_TARGET_CPU_ARCH in 49986 ppc ) 49987 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49988 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49989 ;; 49990 * ) 49991 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49992 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49993 ;; 49994 esac 49995 fi 49996 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49997 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 49998 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 49999 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 50000 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 50001 fi 50002 50003 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50004 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50005 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50006 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50007 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50008 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50009 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50010 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 50011 -MD -Zc:wchar_t- -W3 -wd4800 \ 50012 -DWIN32_LEAN_AND_MEAN \ 50013 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50014 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50015 -DWIN32 -DIAL" 50016 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50017 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50018 else 50019 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50020 fi 50021 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50022 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50023 # studio. 50024 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50025 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50026 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50027 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50028 fi 50029 fi 50030 50031 ############################################################################### 50032 50033 # Adjust flags according to debug level. 50034 case $DEBUG_LEVEL in 50035 fastdebug | slowdebug ) 50036 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50037 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50038 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50039 ;; 50040 release ) 50041 ;; 50042 * ) 50043 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50044 ;; 50045 esac 50046 50047 # Set some common defines. These works for all compilers, but assume 50048 # -D is universally accepted. 50049 50050 # Setup endianness 50051 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50052 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50053 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50054 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50055 # Note: -Dmacro is the same as #define macro 1 50056 # -Dmacro= is the same as #define macro 50057 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50058 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50059 else 50060 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50061 fi 50062 else 50063 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50064 # are defined in the system? 50065 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50066 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50067 else 50068 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50069 fi 50070 fi 50071 50072 # Setup target OS define. Use OS target name but in upper case. 50073 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50074 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 50075 50076 # Setup target CPU 50077 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50078 $OPENJDK_TARGET_ADD_LP64 \ 50079 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 50080 50081 # Setup debug/release defines 50082 if test "x$DEBUG_LEVEL" = xrelease; then 50083 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 50084 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50085 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 50086 fi 50087 else 50088 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 50089 fi 50090 50091 # Set some additional per-OS defines. 50092 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50093 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 50094 JVM_CFLAGS="$JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50095 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50096 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50097 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 50098 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50099 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50100 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50101 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50102 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 50103 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50104 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50105 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50106 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50107 -fno-omit-frame-pointer" 50108 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50109 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 50110 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50111 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 50112 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50113 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50114 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50115 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50116 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50117 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50118 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 50119 fi 50120 50121 # Set some additional per-CPU defines. 50122 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 50123 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 50124 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50125 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 50126 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 50127 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50128 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50129 # fixes `relocation truncated to fit' error for gcc 4.1. 50130 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 50131 # Use ppc64 instructions, but schedule for power5 50132 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50133 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50134 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 50135 fi 50136 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 50137 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50138 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50139 # Little endian machine uses ELFv2 ABI. 50140 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 50141 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50142 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power7 -mtune=power8" 50143 fi 50144 fi 50145 50146 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50147 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50148 fi 50149 50150 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50151 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 50152 # Solaris does not have _LP64=1 in the old build. 50153 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50154 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 50155 fi 50156 fi 50157 50158 # Set JVM_CFLAGS warning handling 50159 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50160 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50161 -Wunused-value -Woverloaded-virtual" 50162 50163 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50164 50165 50166 50167 50168 50169 50170 50171 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 # Execute function body 50219 50220 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50221 REFERENCE_VERSION=4.8 50222 50223 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50224 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 50225 fi 50226 50227 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50228 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 50229 fi 50230 50231 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50232 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50233 50234 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50235 : 50236 50237 # These flags either do not work or give spurious warnings prior to gcc 4.8. 50238 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 50239 50240 50241 else 50242 : 50243 50244 fi 50245 50246 50247 50248 50249 50250 50251 50252 50253 50254 50255 50256 50257 50258 50259 fi 50260 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 50261 # Non-zero builds have stricter warnings 50262 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 50263 else 50264 if test "x$TOOLCHAIN_TYPE" = xclang; then 50265 # Some versions of llvm do not like -Wundef 50266 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 50267 fi 50268 fi 50269 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50270 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 50271 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 50272 fi 50273 50274 # Additional macosx handling 50275 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50276 # Setting these parameters makes it an error to link to macosx APIs that are 50277 # newer than the given OS version and makes the linked binaries compatible 50278 # even if built on a newer version of the OS. 50279 # The expected format is X.Y.Z 50280 MACOSX_VERSION_MIN=10.7.0 50281 50282 50283 # The macro takes the version with no dots, ex: 1070 50284 # Let the flags variables get resolved in make for easier override on make 50285 # command line. 50286 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50287 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50288 fi 50289 50290 # Setup some hard coded includes 50291 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50292 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 50293 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 50294 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 50295 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 50296 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 50297 50298 # The shared libraries are compiled using the picflag. 50299 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50300 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 50301 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50302 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 50303 50304 # Executable flags 50305 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 50306 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 50307 50308 50309 50310 50311 50312 50313 # Setup LDFLAGS et al. 50314 # 50315 50316 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50317 LDFLAGS_MICROSOFT="-nologo -opt:ref" 50318 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 50319 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 50320 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50321 LDFLAGS_SAFESH="-safeseh" 50322 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 50323 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 50324 # NOTE: Old build added -machine. Probably not needed. 50325 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 50326 else 50327 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 50328 fi 50329 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50330 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 50331 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50332 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 50333 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50334 fi 50335 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50336 # If this is a --hash-style=gnu system, use --hash-style=both, why? 50337 # We have previously set HAS_GNU_HASH if this is the case 50338 if test -n "$HAS_GNU_HASH"; then 50339 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 50340 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 50341 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 50342 fi 50343 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50344 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50345 fi 50346 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50347 # And since we now know that the linker is gnu, then add -z defs, to forbid 50348 # undefined symbols in object files. 50349 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 50350 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 50351 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 50352 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 50353 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 50354 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50355 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 50356 fi 50357 case $DEBUG_LEVEL in 50358 release ) 50359 # tell linker to optimize libraries. 50360 # Should this be supplied to the OSS linker as well? 50361 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 50362 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 50363 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 50364 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50365 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50366 fi 50367 ;; 50368 slowdebug ) 50369 # Hotspot always let the linker optimize 50370 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50371 if test "x$HAS_LINKER_NOW" = "xtrue"; then 50372 # do relocations at load 50373 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 50374 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 50375 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 50376 fi 50377 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50378 # mark relocations read only 50379 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50380 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50381 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50382 fi 50383 ;; 50384 fastdebug ) 50385 # Hotspot always let the linker optimize 50386 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50387 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50388 # mark relocations read only 50389 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50390 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50391 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50392 fi 50393 ;; 50394 * ) 50395 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50396 ;; 50397 esac 50398 fi 50399 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50400 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 50401 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 50402 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 50403 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 50404 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 50405 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50406 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 50407 fi 50408 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50409 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 50410 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 50411 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 50412 fi 50413 50414 # Customize LDFLAGS for executables 50415 50416 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 50417 50418 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50419 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 50420 LDFLAGS_STACK_SIZE=1048576 50421 else 50422 LDFLAGS_STACK_SIZE=327680 50423 fi 50424 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 50425 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50426 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 50427 fi 50428 50429 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 50430 50431 # Customize LDFLAGS for libs 50432 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 50433 50434 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 50435 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50436 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50437 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 50438 JDKLIB_LIBS="" 50439 else 50440 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50441 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)" 50442 50443 if test "xTARGET" = "xTARGET"; then 50444 # On some platforms (mac) the linker warns about non existing -L dirs. 50445 # Add server first if available. Linking aginst client does not always produce the same results. 50446 # Only add client/minimal dir if client/minimal is being built. 50447 # Default to server for other variants. 50448 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 50449 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50450 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 50451 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/client" 50452 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 50453 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/minimal" 50454 else 50455 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50456 fi 50457 elif test "xTARGET" = "xBUILD"; then 50458 # When building a buildjdk, it's always only the server variant 50459 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50460 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50461 fi 50462 50463 JDKLIB_LIBS="-ljava -ljvm" 50464 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50465 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 50466 fi 50467 50468 fi 50469 50470 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 50471 50472 # Set JVM_LIBS (per os) 50473 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50474 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 50475 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50476 # FIXME: This hard-coded path is not really proper. 50477 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50478 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 50479 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50480 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 50481 fi 50482 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 50483 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 50484 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50485 JVM_LIBS="$JVM_LIBS -lm" 50486 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50487 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 50488 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50489 JVM_LIBS="$JVM_LIBS -lm" 50490 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50491 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 50492 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 50493 wsock32.lib winmm.lib version.lib psapi.lib" 50494 fi 50495 50496 # Set JVM_ASFLAGS 50497 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50498 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50499 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 50500 fi 50501 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50502 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 50503 fi 50504 50505 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 50506 50507 50508 50509 50510 50511 50512 50513 50514 50515 50516 50517 50518 50519 50520 50521 # Special extras... 50522 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50523 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 50524 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50525 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50526 fi 50527 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50528 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50529 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50530 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50531 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50532 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50533 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 50534 50535 50536 50537 50538 50539 50540 50541 50542 50543 50544 50545 50546 50547 50548 50549 50550 50551 50552 50553 50554 50555 50556 50557 50558 50559 50560 50561 50562 50563 50564 50565 50566 50567 50568 50569 50570 50571 50572 50573 50574 50575 50576 # Execute function body 50577 50578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 50579 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 50580 supports=yes 50581 50582 saved_cxxflags="$CXXFLAGS" 50583 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 50584 ac_ext=cpp 50585 ac_cpp='$CXXCPP $CPPFLAGS' 50586 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50587 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50588 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50589 50590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50591 /* end confdefs.h. */ 50592 int i; 50593 _ACEOF 50594 if ac_fn_cxx_try_compile "$LINENO"; then : 50595 50596 else 50597 supports=no 50598 fi 50599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50600 ac_ext=cpp 50601 ac_cpp='$CXXCPP $CPPFLAGS' 50602 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50603 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50604 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50605 50606 CXXFLAGS="$saved_cxxflags" 50607 50608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50609 $as_echo "$supports" >&6; } 50610 if test "x$supports" = "xyes" ; then 50611 : 50612 50613 else 50614 : 50615 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 50616 fi 50617 50618 50619 50620 50621 50622 50623 50624 50625 50626 50627 50628 50629 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50630 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50631 50632 fi 50633 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50634 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50635 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50636 fi 50637 50638 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50639 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50640 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50641 fi 50642 50643 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 50644 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 50645 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 50646 50647 ############################################################################### 50648 # 50649 # Now setup the CFLAGS and LDFLAGS for the JDK build. 50650 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 50651 # 50652 50653 # Setup compiler/platform specific flags into 50654 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 50655 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 50656 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 50657 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50658 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50659 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 50660 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 50661 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50662 # Force compatibility with i586 on 32 bit intel platforms. 50663 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50664 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50665 fi 50666 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50667 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50668 case $OPENJDK_BUILD_CPU_ARCH in 50669 arm ) 50670 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50671 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50672 ;; 50673 ppc ) 50674 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50675 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50676 ;; 50677 * ) 50678 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50679 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50680 ;; 50681 esac 50682 50683 50684 50685 50686 50687 50688 50689 50690 50691 50692 50693 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 # Execute function body 50737 50738 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50739 REFERENCE_VERSION=6 50740 50741 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50742 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 50743 fi 50744 50745 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50746 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 50747 fi 50748 50749 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50750 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50751 50752 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50753 : 50754 50755 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 50756 # runs afoul of the more aggressive versions of these optimisations. 50757 # Notably, value range propagation now assumes that the this pointer of C++ 50758 # member functions is non-null. 50759 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 50760 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 50761 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 50762 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 50763 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50764 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50765 50766 else 50767 : 50768 50769 fi 50770 50771 50772 50773 50774 50775 50776 50777 50778 50779 50780 50781 50782 50783 50784 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50785 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50786 50787 # Restrict the debug information created by Clang to avoid 50788 # too big object files and speed the build up a little bit 50789 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 50790 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 50791 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50792 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50793 # Force compatibility with i586 on 32 bit intel platforms. 50794 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50795 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50796 fi 50797 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 50798 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50799 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50800 case $OPENJDK_BUILD_CPU_ARCH in 50801 ppc ) 50802 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50803 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50804 ;; 50805 * ) 50806 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50807 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50808 ;; 50809 esac 50810 fi 50811 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50812 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 50813 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 50814 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 50815 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 50816 fi 50817 50818 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50819 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50820 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50821 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50822 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50823 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50824 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50825 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50826 -MD -Zc:wchar_t- -W3 -wd4800 \ 50827 -DWIN32_LEAN_AND_MEAN \ 50828 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50829 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50830 -DWIN32 -DIAL" 50831 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 50832 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50833 else 50834 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50835 fi 50836 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50837 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50838 # studio. 50839 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50840 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50841 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50842 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50843 fi 50844 fi 50845 50846 ############################################################################### 50847 50848 # Adjust flags according to debug level. 50849 case $DEBUG_LEVEL in 50850 fastdebug | slowdebug ) 50851 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50852 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50853 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50854 ;; 50855 release ) 50856 ;; 50857 * ) 50858 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50859 ;; 50860 esac 50861 50862 # Set some common defines. These works for all compilers, but assume 50863 # -D is universally accepted. 50864 50865 # Setup endianness 50866 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50867 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50868 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50869 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50870 # Note: -Dmacro is the same as #define macro 1 50871 # -Dmacro= is the same as #define macro 50872 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50873 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50874 else 50875 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50876 fi 50877 else 50878 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50879 # are defined in the system? 50880 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50881 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50882 else 50883 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50884 fi 50885 fi 50886 50887 # Setup target OS define. Use OS target name but in upper case. 50888 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50889 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 50890 50891 # Setup target CPU 50892 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50893 $OPENJDK_BUILD_ADD_LP64 \ 50894 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 50895 50896 # Setup debug/release defines 50897 if test "x$DEBUG_LEVEL" = xrelease; then 50898 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 50899 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50900 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 50901 fi 50902 else 50903 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 50904 fi 50905 50906 # Set some additional per-OS defines. 50907 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50908 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 50909 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50910 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50911 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 50912 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 50913 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50914 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50915 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 50916 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50917 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 50918 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50919 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50920 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50921 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50922 -fno-omit-frame-pointer" 50923 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50924 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 50925 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50926 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 50927 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50928 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50929 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 50930 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50931 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 50932 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50933 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 50934 fi 50935 50936 # Set some additional per-CPU defines. 50937 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 50938 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 50939 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 50940 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 50941 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 50942 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50943 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50944 # fixes `relocation truncated to fit' error for gcc 4.1. 50945 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 50946 # Use ppc64 instructions, but schedule for power5 50947 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50948 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50949 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 50950 fi 50951 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 50952 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50953 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50954 # Little endian machine uses ELFv2 ABI. 50955 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 50956 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50957 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power7 -mtune=power8" 50958 fi 50959 fi 50960 50961 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50962 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50963 fi 50964 50965 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 50966 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 50967 # Solaris does not have _LP64=1 in the old build. 50968 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50969 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 50970 fi 50971 fi 50972 50973 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 50974 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50975 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50976 -Wunused-value -Woverloaded-virtual" 50977 50978 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50979 50980 50981 50982 50983 50984 50985 50986 50987 50988 50989 50990 50991 50992 50993 50994 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 # Execute function body 51034 51035 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51036 REFERENCE_VERSION=4.8 51037 51038 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 51039 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 51040 fi 51041 51042 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51043 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51044 fi 51045 51046 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51047 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 51048 51049 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51050 : 51051 51052 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51053 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51054 51055 51056 else 51057 : 51058 51059 fi 51060 51061 51062 51063 51064 51065 51066 51067 51068 51069 51070 51071 51072 51073 51074 fi 51075 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51076 # Non-zero builds have stricter warnings 51077 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51078 else 51079 if test "x$TOOLCHAIN_TYPE" = xclang; then 51080 # Some versions of llvm do not like -Wundef 51081 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 51082 fi 51083 fi 51084 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51085 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51086 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51087 fi 51088 51089 # Additional macosx handling 51090 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51091 # Setting these parameters makes it an error to link to macosx APIs that are 51092 # newer than the given OS version and makes the linked binaries compatible 51093 # even if built on a newer version of the OS. 51094 # The expected format is X.Y.Z 51095 MACOSX_VERSION_MIN=10.7.0 51096 51097 51098 # The macro takes the version with no dots, ex: 1070 51099 # Let the flags variables get resolved in make for easier override on make 51100 # command line. 51101 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)" 51102 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51103 fi 51104 51105 # Setup some hard coded includes 51106 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51107 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 51108 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 51109 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 51110 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 51111 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 51112 51113 # The shared libraries are compiled using the picflag. 51114 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51115 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 51116 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51117 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 51118 51119 # Executable flags 51120 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 51121 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 51122 51123 51124 51125 51126 51127 51128 # Setup LDFLAGS et al. 51129 # 51130 51131 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51132 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51133 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51134 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51135 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 51136 LDFLAGS_SAFESH="-safeseh" 51137 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 51138 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 51139 # NOTE: Old build added -machine. Probably not needed. 51140 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 51141 else 51142 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 51143 fi 51144 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51145 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51146 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51147 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51148 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51149 fi 51150 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51151 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51152 # We have previously set HAS_GNU_HASH if this is the case 51153 if test -n "$HAS_GNU_HASH"; then 51154 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51155 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51156 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51157 fi 51158 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51159 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51160 fi 51161 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51162 # And since we now know that the linker is gnu, then add -z defs, to forbid 51163 # undefined symbols in object files. 51164 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51165 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51166 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51167 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51168 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51169 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51170 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 51171 fi 51172 case $DEBUG_LEVEL in 51173 release ) 51174 # tell linker to optimize libraries. 51175 # Should this be supplied to the OSS linker as well? 51176 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51177 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51178 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51179 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51180 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51181 fi 51182 ;; 51183 slowdebug ) 51184 # Hotspot always let the linker optimize 51185 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51186 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51187 # do relocations at load 51188 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 51189 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 51190 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 51191 fi 51192 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51193 # mark relocations read only 51194 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51195 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51196 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51197 fi 51198 ;; 51199 fastdebug ) 51200 # Hotspot always let the linker optimize 51201 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51202 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51203 # mark relocations read only 51204 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51205 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51206 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51207 fi 51208 ;; 51209 * ) 51210 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51211 ;; 51212 esac 51213 fi 51214 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51215 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 51216 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 51217 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 51218 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 51219 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 51220 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51221 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 51222 fi 51223 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51224 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 51225 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 51226 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 51227 fi 51228 51229 # Customize LDFLAGS for executables 51230 51231 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 51232 51233 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51234 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 51235 LDFLAGS_STACK_SIZE=1048576 51236 else 51237 LDFLAGS_STACK_SIZE=327680 51238 fi 51239 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 51240 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 51241 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 51242 fi 51243 51244 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51245 51246 # Customize LDFLAGS for libs 51247 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 51248 51249 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 51250 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51251 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51252 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 51253 OPENJDK_BUILD_JDKLIB_LIBS="" 51254 else 51255 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51256 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)" 51257 51258 if test "xBUILD" = "xTARGET"; then 51259 # On some platforms (mac) the linker warns about non existing -L dirs. 51260 # Add server first if available. Linking aginst client does not always produce the same results. 51261 # Only add client/minimal dir if client/minimal is being built. 51262 # Default to server for other variants. 51263 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 51264 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51265 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 51266 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/client" 51267 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 51268 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/minimal" 51269 else 51270 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51271 fi 51272 elif test "xBUILD" = "xBUILD"; then 51273 # When building a buildjdk, it's always only the server variant 51274 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51275 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51276 fi 51277 51278 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 51279 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51280 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 51281 fi 51282 51283 fi 51284 51285 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 51286 51287 # Set OPENJDK_BUILD_JVM_LIBS (per os) 51288 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51289 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 51290 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 51291 # FIXME: This hard-coded path is not really proper. 51292 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 51293 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 51294 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 51295 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 51296 fi 51297 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 51298 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 51299 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51300 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51301 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51302 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 51303 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 51304 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51305 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 51306 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51307 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51308 wsock32.lib winmm.lib version.lib psapi.lib" 51309 fi 51310 51311 # Set OPENJDK_BUILD_JVM_ASFLAGS 51312 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51313 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51314 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 51315 fi 51316 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51317 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51318 fi 51319 51320 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51321 51322 51323 51324 51325 51326 51327 51328 51329 51330 51331 51332 51333 51334 51335 51336 # Tests are only ever compiled for TARGET 51337 # Flags for compiling test libraries 51338 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51339 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51340 51341 # Flags for compiling test executables 51342 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 51343 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 51344 51345 51346 51347 51348 51349 51350 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 51351 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 51352 51353 51354 51355 51356 51357 51358 # Some Zero and Shark settings. 51359 # ZERO_ARCHFLAG tells the compiler which mode to build for 51360 case "${OPENJDK_TARGET_CPU}" in 51361 s390) 51362 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31" 51363 ;; 51364 *) 51365 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51366 esac 51367 51368 51369 51370 51371 51372 51373 51374 51375 51376 51377 51378 51379 51380 51381 51382 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 # Execute function body 51410 51411 51412 51413 51414 51415 51416 51417 51418 51419 51420 51421 51422 51423 51424 51425 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 # Execute function body 51459 51460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$ZERO_ARCHFLAG\"" >&5 51461 $as_echo_n "checking if the C compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51462 supports=yes 51463 51464 saved_cflags="$CFLAGS" 51465 CFLAGS="$CFLAGS $ZERO_ARCHFLAG" 51466 ac_ext=c 51467 ac_cpp='$CPP $CPPFLAGS' 51468 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51469 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51470 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51471 51472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51473 /* end confdefs.h. */ 51474 int i; 51475 _ACEOF 51476 if ac_fn_c_try_compile "$LINENO"; then : 51477 51478 else 51479 supports=no 51480 fi 51481 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51482 ac_ext=cpp 51483 ac_cpp='$CXXCPP $CPPFLAGS' 51484 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51485 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51486 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51487 51488 CFLAGS="$saved_cflags" 51489 51490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51491 $as_echo "$supports" >&6; } 51492 if test "x$supports" = "xyes" ; then 51493 : 51494 C_COMP_SUPPORTS="yes" 51495 else 51496 : 51497 C_COMP_SUPPORTS="no" 51498 fi 51499 51500 51501 51502 51503 51504 51505 51506 51507 51508 51509 51510 51511 51512 51513 51514 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 # Execute function body 51559 51560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"" >&5 51561 $as_echo_n "checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51562 supports=yes 51563 51564 saved_cxxflags="$CXXFLAGS" 51565 CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG" 51566 ac_ext=cpp 51567 ac_cpp='$CXXCPP $CPPFLAGS' 51568 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51569 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51570 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51571 51572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51573 /* end confdefs.h. */ 51574 int i; 51575 _ACEOF 51576 if ac_fn_cxx_try_compile "$LINENO"; then : 51577 51578 else 51579 supports=no 51580 fi 51581 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 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 CXXFLAGS="$saved_cxxflags" 51589 51590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51591 $as_echo "$supports" >&6; } 51592 if test "x$supports" = "xyes" ; then 51593 : 51594 CXX_COMP_SUPPORTS="yes" 51595 else 51596 : 51597 CXX_COMP_SUPPORTS="no" 51598 fi 51599 51600 51601 51602 51603 51604 51605 51606 51607 51608 51609 51610 51611 51612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$ZERO_ARCHFLAG\"" >&5 51613 $as_echo_n "checking if both compilers support \"$ZERO_ARCHFLAG\"... " >&6; } 51614 supports=no 51615 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51616 51617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51618 $as_echo "$supports" >&6; } 51619 if test "x$supports" = "xyes" ; then 51620 : 51621 51622 else 51623 : 51624 ZERO_ARCHFLAG="" 51625 fi 51626 51627 51628 51629 51630 51631 51632 51633 51634 # Check that the compiler supports -mX (or -qX on AIX) flags 51635 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 51636 51637 51638 51639 51640 51641 51642 51643 51644 51645 51646 51647 51648 51649 51650 51651 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 # Execute function body 51684 51685 51686 51687 51688 51689 51690 51691 51692 51693 51694 51695 51696 51697 51698 51699 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 # Execute function body 51733 51734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51735 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51736 supports=yes 51737 51738 saved_cflags="$CFLAGS" 51739 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51740 ac_ext=c 51741 ac_cpp='$CPP $CPPFLAGS' 51742 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51743 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51744 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51745 51746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51747 /* end confdefs.h. */ 51748 int i; 51749 _ACEOF 51750 if ac_fn_c_try_compile "$LINENO"; then : 51751 51752 else 51753 supports=no 51754 fi 51755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51756 ac_ext=cpp 51757 ac_cpp='$CXXCPP $CPPFLAGS' 51758 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51759 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51760 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51761 51762 CFLAGS="$saved_cflags" 51763 51764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51765 $as_echo "$supports" >&6; } 51766 if test "x$supports" = "xyes" ; then 51767 : 51768 C_COMP_SUPPORTS="yes" 51769 else 51770 : 51771 C_COMP_SUPPORTS="no" 51772 fi 51773 51774 51775 51776 51777 51778 51779 51780 51781 51782 51783 51784 51785 51786 51787 51788 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 51808 51809 51810 51811 51812 51813 51814 51815 51816 51817 51818 51819 51820 51821 51822 51823 51824 51825 51826 51827 51828 51829 51830 51831 51832 # Execute function body 51833 51834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51835 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51836 supports=yes 51837 51838 saved_cxxflags="$CXXFLAGS" 51839 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51840 ac_ext=cpp 51841 ac_cpp='$CXXCPP $CPPFLAGS' 51842 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51843 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51844 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51845 51846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51847 /* end confdefs.h. */ 51848 int i; 51849 _ACEOF 51850 if ac_fn_cxx_try_compile "$LINENO"; then : 51851 51852 else 51853 supports=no 51854 fi 51855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 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 CXXFLAGS="$saved_cxxflags" 51863 51864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51865 $as_echo "$supports" >&6; } 51866 if test "x$supports" = "xyes" ; then 51867 : 51868 CXX_COMP_SUPPORTS="yes" 51869 else 51870 : 51871 CXX_COMP_SUPPORTS="no" 51872 fi 51873 51874 51875 51876 51877 51878 51879 51880 51881 51882 51883 51884 51885 51886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51887 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51888 supports=no 51889 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51890 51891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51892 $as_echo "$supports" >&6; } 51893 if test "x$supports" = "xyes" ; then 51894 : 51895 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 51896 else 51897 : 51898 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 51899 fi 51900 51901 51902 51903 51904 51905 51906 51907 51908 # Check whether --enable-warnings-as-errors was given. 51909 if test "${enable_warnings_as_errors+set}" = set; then : 51910 enableval=$enable_warnings_as_errors; 51911 fi 51912 51913 51914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 51915 $as_echo_n "checking if native warnings are errors... " >&6; } 51916 if test "x$enable_warnings_as_errors" = "xyes"; then 51917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitely set)" >&5 51918 $as_echo "yes (explicitely set)" >&6; } 51919 WARNINGS_AS_ERRORS=true 51920 elif test "x$enable_warnings_as_errors" = "xno"; then 51921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 51922 $as_echo "no" >&6; } 51923 WARNINGS_AS_ERRORS=false 51924 elif test "x$enable_warnings_as_errors" = "x"; then 51925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 51926 $as_echo "yes (default)" >&6; } 51927 WARNINGS_AS_ERRORS=true 51928 else 51929 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 51930 fi 51931 51932 if test "x$WARNINGS_AS_ERRORS" = "xfalse"; then 51933 # Set legacy hotspot variable 51934 HOTSPOT_SET_WARNINGS_AS_ERRORS="WARNINGS_ARE_ERRORS=" 51935 else 51936 HOTSPOT_SET_WARNINGS_AS_ERRORS="" 51937 fi 51938 51939 51940 51941 51942 case "${TOOLCHAIN_TYPE}" in 51943 microsoft) 51944 DISABLE_WARNING_PREFIX="-wd" 51945 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 51946 ;; 51947 solstudio) 51948 DISABLE_WARNING_PREFIX="-erroff=" 51949 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 51950 ;; 51951 gcc) 51952 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 51953 51954 51955 51956 51957 51958 51959 51960 51961 51962 51963 51964 51965 51966 51967 51968 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 # Execute function body 52001 52002 52003 52004 52005 52006 52007 52008 52009 52010 52011 52012 52013 52014 52015 52016 52017 52018 52019 52020 52021 52022 52023 52024 52025 52026 52027 52028 52029 52030 52031 52032 52033 52034 52035 52036 52037 52038 52039 52040 52041 52042 52043 52044 52045 52046 52047 52048 52049 # Execute function body 52050 52051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52052 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52053 supports=yes 52054 52055 saved_cflags="$CFLAGS" 52056 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52057 ac_ext=c 52058 ac_cpp='$CPP $CPPFLAGS' 52059 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52060 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52061 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52062 52063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52064 /* end confdefs.h. */ 52065 int i; 52066 _ACEOF 52067 if ac_fn_c_try_compile "$LINENO"; then : 52068 52069 else 52070 supports=no 52071 fi 52072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52073 ac_ext=cpp 52074 ac_cpp='$CXXCPP $CPPFLAGS' 52075 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52076 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52077 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52078 52079 CFLAGS="$saved_cflags" 52080 52081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52082 $as_echo "$supports" >&6; } 52083 if test "x$supports" = "xyes" ; then 52084 : 52085 C_COMP_SUPPORTS="yes" 52086 else 52087 : 52088 C_COMP_SUPPORTS="no" 52089 fi 52090 52091 52092 52093 52094 52095 52096 52097 52098 52099 52100 52101 52102 52103 52104 52105 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 # Execute function body 52150 52151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52152 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52153 supports=yes 52154 52155 saved_cxxflags="$CXXFLAGS" 52156 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52157 ac_ext=cpp 52158 ac_cpp='$CXXCPP $CPPFLAGS' 52159 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52160 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52161 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52162 52163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52164 /* end confdefs.h. */ 52165 int i; 52166 _ACEOF 52167 if ac_fn_cxx_try_compile "$LINENO"; then : 52168 52169 else 52170 supports=no 52171 fi 52172 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 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 CXXFLAGS="$saved_cxxflags" 52180 52181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52182 $as_echo "$supports" >&6; } 52183 if test "x$supports" = "xyes" ; then 52184 : 52185 CXX_COMP_SUPPORTS="yes" 52186 else 52187 : 52188 CXX_COMP_SUPPORTS="no" 52189 fi 52190 52191 52192 52193 52194 52195 52196 52197 52198 52199 52200 52201 52202 52203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52204 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52205 supports=no 52206 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52207 52208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52209 $as_echo "$supports" >&6; } 52210 if test "x$supports" = "xyes" ; then 52211 : 52212 GCC_CAN_DISABLE_WARNINGS=true 52213 else 52214 : 52215 GCC_CAN_DISABLE_WARNINGS=false 52216 52217 fi 52218 52219 52220 52221 52222 52223 52224 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52225 DISABLE_WARNING_PREFIX="-Wno-" 52226 else 52227 DISABLE_WARNING_PREFIX= 52228 fi 52229 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52230 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 52231 # CFLAGS since any target specific flags will likely not work with the 52232 # build compiler 52233 CC_OLD="$CC" 52234 CXX_OLD="$CXX" 52235 CC="$BUILD_CC" 52236 CXX="$BUILD_CXX" 52237 CFLAGS_OLD="$CFLAGS" 52238 CFLAGS="" 52239 52240 52241 52242 52243 52244 52245 52246 52247 52248 52249 52250 52251 52252 52253 52254 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 # Execute function body 52287 52288 52289 52290 52291 52292 52293 52294 52295 52296 52297 52298 52299 52300 52301 52302 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 # Execute function body 52336 52337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52338 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52339 supports=yes 52340 52341 saved_cflags="$CFLAGS" 52342 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52343 ac_ext=c 52344 ac_cpp='$CPP $CPPFLAGS' 52345 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52346 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52347 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52348 52349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52350 /* end confdefs.h. */ 52351 int i; 52352 _ACEOF 52353 if ac_fn_c_try_compile "$LINENO"; then : 52354 52355 else 52356 supports=no 52357 fi 52358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52359 ac_ext=cpp 52360 ac_cpp='$CXXCPP $CPPFLAGS' 52361 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52362 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52363 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52364 52365 CFLAGS="$saved_cflags" 52366 52367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52368 $as_echo "$supports" >&6; } 52369 if test "x$supports" = "xyes" ; then 52370 : 52371 C_COMP_SUPPORTS="yes" 52372 else 52373 : 52374 C_COMP_SUPPORTS="no" 52375 fi 52376 52377 52378 52379 52380 52381 52382 52383 52384 52385 52386 52387 52388 52389 52390 52391 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 # Execute function body 52436 52437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52438 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52439 supports=yes 52440 52441 saved_cxxflags="$CXXFLAGS" 52442 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52443 ac_ext=cpp 52444 ac_cpp='$CXXCPP $CPPFLAGS' 52445 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52446 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52447 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52448 52449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52450 /* end confdefs.h. */ 52451 int i; 52452 _ACEOF 52453 if ac_fn_cxx_try_compile "$LINENO"; then : 52454 52455 else 52456 supports=no 52457 fi 52458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 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 CXXFLAGS="$saved_cxxflags" 52466 52467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52468 $as_echo "$supports" >&6; } 52469 if test "x$supports" = "xyes" ; then 52470 : 52471 CXX_COMP_SUPPORTS="yes" 52472 else 52473 : 52474 CXX_COMP_SUPPORTS="no" 52475 fi 52476 52477 52478 52479 52480 52481 52482 52483 52484 52485 52486 52487 52488 52489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52490 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52491 supports=no 52492 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52493 52494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52495 $as_echo "$supports" >&6; } 52496 if test "x$supports" = "xyes" ; then 52497 : 52498 BUILD_CC_CAN_DISABLE_WARNINGS=true 52499 else 52500 : 52501 BUILD_CC_CAN_DISABLE_WARNINGS=false 52502 52503 fi 52504 52505 52506 52507 52508 52509 52510 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52511 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 52512 else 52513 BUILD_CC_DISABLE_WARNING_PREFIX= 52514 fi 52515 CC="$CC_OLD" 52516 CXX="$CXX_OLD" 52517 CFLAGS="$CFLAGS_OLD" 52518 ;; 52519 clang) 52520 DISABLE_WARNING_PREFIX="-Wno-" 52521 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52522 ;; 52523 xlc) 52524 DISABLE_WARNING_PREFIX="-qsuppress=" 52525 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 52526 ;; 52527 esac 52528 52529 52530 52531 52532 52533 # Setup debug symbols (need objcopy from the toolchain for that) 52534 52535 # 52536 # NATIVE_DEBUG_SYMBOLS 52537 # This must be done after the toolchain is setup, since we're looking at objcopy. 52538 # 52539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 52540 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 52541 52542 # Check whether --with-native-debug-symbols was given. 52543 if test "${with_native_debug_symbols+set}" = set; then : 52544 withval=$with_native_debug_symbols; 52545 if test "x$OPENJDK_TARGET_OS" = xaix; then 52546 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 52547 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 52548 fi 52549 fi 52550 52551 else 52552 52553 if test "x$OPENJDK_TARGET_OS" = xaix; then 52554 # AIX doesn't support 'zipped' so use 'internal' as default 52555 with_native_debug_symbols="internal" 52556 else 52557 if test "x$STATIC_BUILD" = xtrue; then 52558 with_native_debug_symbols="none" 52559 else 52560 with_native_debug_symbols="zipped" 52561 fi 52562 fi 52563 52564 fi 52565 52566 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 52567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 52568 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 52569 52570 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 52571 52572 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52573 if test "x$OBJCOPY" = x; then 52574 # enabling of enable-debug-symbols and can't find objcopy 52575 # this is an error 52576 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52577 fi 52578 fi 52579 52580 COMPILE_WITH_DEBUG_SYMBOLS=true 52581 COPY_DEBUG_SYMBOLS=true 52582 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 52583 52584 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52585 DEBUG_BINARIES=false 52586 STRIP_POLICY=min_strip 52587 52588 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 52589 COMPILE_WITH_DEBUG_SYMBOLS=false 52590 COPY_DEBUG_SYMBOLS=false 52591 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52592 52593 DEBUG_BINARIES=false 52594 STRIP_POLICY=no_strip 52595 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 52596 COMPILE_WITH_DEBUG_SYMBOLS=true 52597 COPY_DEBUG_SYMBOLS=false 52598 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52599 52600 # Hotspot legacy support, will turn on -g when COPY_DEBUG_SYMBOLS=false 52601 DEBUG_BINARIES=true 52602 STRIP_POLICY=no_strip 52603 STRIP="" 52604 52605 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 52606 52607 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52608 if test "x$OBJCOPY" = x; then 52609 # enabling of enable-debug-symbols and can't find objcopy 52610 # this is an error 52611 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52612 fi 52613 fi 52614 52615 COMPILE_WITH_DEBUG_SYMBOLS=true 52616 COPY_DEBUG_SYMBOLS=true 52617 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52618 52619 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52620 DEBUG_BINARIES=false 52621 STRIP_POLICY=min_strip 52622 else 52623 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 52624 fi 52625 52626 # --enable-debug-symbols is deprecated. 52627 # Please use --with-native-debug-symbols=[internal,external,zipped] . 52628 52629 # Check whether --enable-debug-symbols was given. 52630 if test "${enable_debug_symbols+set}" = set; then : 52631 enableval=$enable_debug_symbols; 52632 fi 52633 52634 if test "x$enable_debug_symbols" != x; then 52635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 52636 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 52637 52638 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 52639 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 52640 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 52641 fi 52642 52643 fi 52644 52645 52646 # --enable-zip-debug-info is deprecated. 52647 # Please use --with-native-debug-symbols=zipped . 52648 52649 # Check whether --enable-zip-debug-info was given. 52650 if test "${enable_zip_debug_info+set}" = set; then : 52651 enableval=$enable_zip_debug_info; 52652 fi 52653 52654 if test "x$enable_zip_debug_info" != x; then 52655 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 52656 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 52657 52658 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 52659 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 52660 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 52661 fi 52662 52663 fi 52664 52665 52666 52667 52668 52669 52670 # Legacy values 52671 52672 52673 52674 52675 # Check whether --enable-native-coverage was given. 52676 if test "${enable_native_coverage+set}" = set; then : 52677 enableval=$enable_native_coverage; 52678 fi 52679 52680 GCOV_ENABLED="false" 52681 if test "x$enable_native_coverage" = "xyes"; then 52682 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 52683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52684 $as_echo_n "checking if native coverage is enabled... " >&6; } 52685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52686 $as_echo "yes" >&6; } 52687 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 52688 GCOV_LDFLAGS="-fprofile-arcs" 52689 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS" 52690 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS" 52691 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS" 52692 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 52693 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 52694 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 52695 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 52696 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 52697 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 52698 GCOV_ENABLED="true" 52699 else 52700 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 52701 fi 52702 elif test "x$enable_native_coverage" = "xno"; then 52703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52704 $as_echo_n "checking if native coverage is enabled... " >&6; } 52705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52706 $as_echo "no" >&6; } 52707 elif test "x$enable_native_coverage" != "x"; then 52708 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 52709 fi 52710 52711 52712 52713 52714 # Need toolchain to setup dtrace 52715 52716 # Test for dtrace dependencies 52717 # Check whether --enable-dtrace was given. 52718 if test "${enable_dtrace+set}" = set; then : 52719 enableval=$enable_dtrace; 52720 fi 52721 52722 52723 DTRACE_DEP_MISSING=false 52724 52725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 52726 $as_echo_n "checking for dtrace tool... " >&6; } 52727 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 52728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 52729 $as_echo "$DTRACE" >&6; } 52730 else 52731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 52732 $as_echo "not found, cannot build dtrace" >&6; } 52733 DTRACE_DEP_MISSING=true 52734 fi 52735 52736 for ac_header in sys/sdt.h 52737 do : 52738 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 52739 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 52740 cat >>confdefs.h <<_ACEOF 52741 #define HAVE_SYS_SDT_H 1 52742 _ACEOF 52743 DTRACE_HEADERS_OK=yes 52744 else 52745 DTRACE_HEADERS_OK=no 52746 fi 52747 52748 done 52749 52750 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 52751 DTRACE_DEP_MISSING=true 52752 fi 52753 52754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 52755 $as_echo_n "checking if dtrace should be built... " >&6; } 52756 if test "x$enable_dtrace" = "xyes"; then 52757 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52759 $as_echo "no, missing dependencies" >&6; } 52760 52761 # Print a helpful message on how to acquire the necessary build dependency. 52762 # dtrace is the help tag: freetype, cups, alsa etc 52763 MISSING_DEPENDENCY=dtrace 52764 52765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52766 cygwin_help $MISSING_DEPENDENCY 52767 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52768 msys_help $MISSING_DEPENDENCY 52769 else 52770 PKGHANDLER_COMMAND= 52771 52772 case $PKGHANDLER in 52773 apt-get) 52774 apt_help $MISSING_DEPENDENCY ;; 52775 yum) 52776 yum_help $MISSING_DEPENDENCY ;; 52777 port) 52778 port_help $MISSING_DEPENDENCY ;; 52779 pkgutil) 52780 pkgutil_help $MISSING_DEPENDENCY ;; 52781 pkgadd) 52782 pkgadd_help $MISSING_DEPENDENCY ;; 52783 esac 52784 52785 if test "x$PKGHANDLER_COMMAND" != x; then 52786 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 52787 fi 52788 fi 52789 52790 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 52791 else 52792 INCLUDE_DTRACE=true 52793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52794 $as_echo "yes, forced" >&6; } 52795 fi 52796 elif test "x$enable_dtrace" = "xno"; then 52797 INCLUDE_DTRACE=false 52798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52799 $as_echo "no, forced" >&6; } 52800 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 52801 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52802 INCLUDE_DTRACE=false 52803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52804 $as_echo "no, missing dependencies" >&6; } 52805 else 52806 INCLUDE_DTRACE=true 52807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 52808 $as_echo "yes, dependencies present" >&6; } 52809 fi 52810 else 52811 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 52812 fi 52813 52814 52815 52816 # The user can in some cases supply additional jvm features. For the custom 52817 # variant, this defines the entire variant. 52818 52819 # Check whether --with-jvm-features was given. 52820 if test "${with_jvm_features+set}" = set; then : 52821 withval=$with_jvm_features; 52822 fi 52823 52824 if test "x$with_jvm_features" != x; then 52825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 52826 $as_echo_n "checking additional JVM features... " >&6; } 52827 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 52828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 52829 $as_echo "$JVM_FEATURES" >&6; } 52830 fi 52831 52832 # Verify that dependencies are met for explicitly set features. 52833 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 52834 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 52835 fi 52836 52837 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 52838 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 52839 fi 52840 52841 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 52842 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 52843 fi 52844 52845 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52846 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 52847 fi 52848 52849 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52850 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 52851 fi 52852 52853 # Turn on additional features based on other parts of configure 52854 if test "x$INCLUDE_DTRACE" = "xtrue"; then 52855 JVM_FEATURES="$JVM_FEATURES dtrace" 52856 else 52857 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 52858 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 52859 fi 52860 fi 52861 52862 if test "x$STATIC_BUILD" = "xtrue"; then 52863 JVM_FEATURES="$JVM_FEATURES static-build" 52864 else 52865 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 52866 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 52867 fi 52868 fi 52869 52870 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52871 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 52872 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 52873 fi 52874 fi 52875 52876 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52877 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 52878 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 52879 fi 52880 fi 52881 52882 # Only enable jvmci on x86_64, sparcv9 and aarch64. 52883 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 52884 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 52885 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 52886 JVM_FEATURES_jvmci="jvmci" 52887 else 52888 JVM_FEATURES_jvmci="" 52889 fi 52890 52891 # All variants but minimal (and custom) get these features 52892 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti fprof vm-structs jni-check services management all-gcs nmt cds" 52893 52894 # Enable features depending on variant. 52895 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52896 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52897 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 52898 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES" 52899 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 52900 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 52901 JVM_FEATURES_custom="$JVM_FEATURES" 52902 52903 52904 52905 52906 52907 52908 52909 52910 52911 # Used for verification of Makefiles by check-jvm-feature 52912 52913 52914 # We don't support --with-jvm-interpreter anymore, use zero instead. 52915 52916 52917 # Check whether --with-jvm-interpreter was given. 52918 if test "${with_jvm_interpreter+set}" = set; then : 52919 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 52920 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 52921 fi 52922 52923 52924 52925 52926 # Check whether --enable-hotspot-gtest was given. 52927 if test "${enable_hotspot_gtest+set}" = set; then : 52928 enableval=$enable_hotspot_gtest; 52929 fi 52930 52931 52932 if test -e "$HOTSPOT_TOPDIR/test/native"; then 52933 GTEST_DIR_EXISTS="true" 52934 else 52935 GTEST_DIR_EXISTS="false" 52936 fi 52937 52938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 52939 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 52940 if test "x$enable_hotspot_gtest" = "xyes"; then 52941 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 52942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52943 $as_echo "yes, forced" >&6; } 52944 BUILD_GTEST="true" 52945 else 52946 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 52947 fi 52948 elif test "x$enable_hotspot_gtest" = "xno"; then 52949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52950 $as_echo "no, forced" >&6; } 52951 BUILD_GTEST="false" 52952 elif test "x$enable_hotspot_gtest" = "x"; then 52953 if test "x$GTEST_DIR_EXISTS" = "xtrue" && test "x$OPENJDK_TARGET_OS" != "xaix"; then 52954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52955 $as_echo "yes" >&6; } 52956 BUILD_GTEST="true" 52957 else 52958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52959 $as_echo "no" >&6; } 52960 BUILD_GTEST="false" 52961 fi 52962 else 52963 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 52964 fi 52965 52966 52967 52968 52969 ############################################################################### 52970 # 52971 # Check dependencies for external and internal libraries. 52972 # 52973 ############################################################################### 52974 52975 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 52976 52977 # When using cygwin or msys, we need a wrapper binary that renames 52978 # /cygdrive/c/ arguments into c:/ arguments and peeks into 52979 # @files and rewrites these too! This wrapper binary is 52980 # called fixpath. 52981 FIXPATH= 52982 if test "x$OPENJDK_BUILD_OS" = xwindows; then 52983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 52984 $as_echo_n "checking if fixpath can be created... " >&6; } 52985 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 52986 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 52987 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 52988 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 52989 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 52990 FIXPATH="$FIXPATH_BIN -c" 52991 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 52992 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 52993 # @ was chosen as separator to minimize risk of other tools messing around with it 52994 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 52995 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 52996 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 52997 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 52998 fi 52999 FIXPATH_SRC_W="$FIXPATH_SRC" 53000 FIXPATH_BIN_W="$FIXPATH_BIN" 53001 53002 unix_path="$FIXPATH_SRC_W" 53003 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53004 windows_path=`$CYGPATH -m "$unix_path"` 53005 FIXPATH_SRC_W="$windows_path" 53006 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53007 windows_path=`cmd //c echo $unix_path` 53008 FIXPATH_SRC_W="$windows_path" 53009 fi 53010 53011 53012 unix_path="$FIXPATH_BIN_W" 53013 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53014 windows_path=`$CYGPATH -m "$unix_path"` 53015 FIXPATH_BIN_W="$windows_path" 53016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53017 windows_path=`cmd //c echo $unix_path` 53018 FIXPATH_BIN_W="$windows_path" 53019 fi 53020 53021 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 53022 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 53023 cd $FIXPATH_DIR 53024 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 53025 cd $CURDIR 53026 53027 if test ! -x $FIXPATH_BIN; then 53028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53029 $as_echo "no" >&6; } 53030 cat $FIXPATH_DIR/fixpath1.log 53031 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 53032 fi 53033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53034 $as_echo "yes" >&6; } 53035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 53036 $as_echo_n "checking if fixpath.exe works... " >&6; } 53037 cd $FIXPATH_DIR 53038 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 53039 > $FIXPATH_DIR/fixpath2.log 2>&1 53040 cd $CURDIR 53041 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 53042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53043 $as_echo "no" >&6; } 53044 cat $FIXPATH_DIR/fixpath2.log 53045 as_fn_error $? "fixpath did not work!" "$LINENO" 5 53046 fi 53047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53048 $as_echo "yes" >&6; } 53049 53050 FIXPATH_DETACH_FLAG="--detach" 53051 fi 53052 53053 53054 53055 53056 53057 53058 # Check if X11 is needed 53059 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 53060 # No X11 support on windows or macosx 53061 NEEDS_LIB_X11=false 53062 else 53063 if test "x$SUPPORT_HEADFUL" = xno; then 53064 # No X11 support if building headless-only 53065 NEEDS_LIB_X11=false 53066 else 53067 # All other instances need X11 53068 NEEDS_LIB_X11=true 53069 fi 53070 fi 53071 53072 # Check if cups is needed 53073 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53074 # Windows have a separate print system 53075 NEEDS_LIB_CUPS=false 53076 else 53077 NEEDS_LIB_CUPS=true 53078 fi 53079 53080 # A custom hook may have set this already 53081 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 53082 NEEDS_LIB_FREETYPE=true 53083 fi 53084 53085 # Check if alsa is needed 53086 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53087 NEEDS_LIB_ALSA=true 53088 else 53089 NEEDS_LIB_ALSA=false 53090 fi 53091 53092 # Check if ffi is needed 53093 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53094 NEEDS_LIB_FFI=true 53095 else 53096 NEEDS_LIB_FFI=false 53097 fi 53098 53099 53100 # statically link libstdc++ before C++ ABI is stablized on Linux unless 53101 # dynamic build is configured on command line. 53102 53103 # Check whether --with-stdc++lib was given. 53104 if test "${with_stdc__lib+set}" = set; then : 53105 withval=$with_stdc__lib; 53106 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 53107 && test "x$with_stdc__lib" != xdefault; then 53108 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 53109 fi 53110 53111 else 53112 with_stdc__lib=default 53113 53114 fi 53115 53116 53117 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53118 # Test if -lstdc++ works. 53119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5 53120 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; } 53121 ac_ext=cpp 53122 ac_cpp='$CXXCPP $CPPFLAGS' 53123 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53124 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53125 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53126 53127 OLD_CXXFLAGS="$CXXFLAGS" 53128 CXXFLAGS="$CXXFLAGS -lstdc++" 53129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53130 /* end confdefs.h. */ 53131 53132 int 53133 main () 53134 { 53135 return 0; 53136 ; 53137 return 0; 53138 } 53139 _ACEOF 53140 if ac_fn_cxx_try_link "$LINENO"; then : 53141 has_dynamic_libstdcxx=yes 53142 else 53143 has_dynamic_libstdcxx=no 53144 fi 53145 rm -f core conftest.err conftest.$ac_objext \ 53146 conftest$ac_exeext conftest.$ac_ext 53147 CXXFLAGS="$OLD_CXXFLAGS" 53148 ac_ext=cpp 53149 ac_cpp='$CXXCPP $CPPFLAGS' 53150 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53151 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53152 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53153 53154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5 53155 $as_echo "$has_dynamic_libstdcxx" >&6; } 53156 53157 # Test if stdc++ can be linked statically. 53158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 53159 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 53160 STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic" 53161 ac_ext=cpp 53162 ac_cpp='$CXXCPP $CPPFLAGS' 53163 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53164 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53165 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53166 53167 OLD_LIBS="$LIBS" 53168 OLD_CXX="$CXX" 53169 LIBS="$STATIC_STDCXX_FLAGS" 53170 CXX="$CC" 53171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53172 /* end confdefs.h. */ 53173 53174 int 53175 main () 53176 { 53177 return 0; 53178 ; 53179 return 0; 53180 } 53181 _ACEOF 53182 if ac_fn_cxx_try_link "$LINENO"; then : 53183 has_static_libstdcxx=yes 53184 else 53185 has_static_libstdcxx=no 53186 fi 53187 rm -f core conftest.err conftest.$ac_objext \ 53188 conftest$ac_exeext conftest.$ac_ext 53189 LIBS="$OLD_LIBS" 53190 CXX="$OLD_CXX" 53191 ac_ext=cpp 53192 ac_cpp='$CXXCPP $CPPFLAGS' 53193 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53194 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53195 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53196 53197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 53198 $as_echo "$has_static_libstdcxx" >&6; } 53199 53200 if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then 53201 as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5 53202 fi 53203 53204 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 53205 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 53206 fi 53207 53208 if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then 53209 as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5 53210 fi 53211 53212 # If dynamic was requested, it's available since it would fail above otherwise. 53213 # If dynamic wasn't requested, go with static unless it isn't available. 53214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 53215 $as_echo_n "checking how to link with libstdc++... " >&6; } 53216 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53217 LIBCXX="$LIBCXX -lstdc++" 53218 # To help comparisons with old build, put stdc++ first in JVM_LIBS 53219 JVM_LIBS="-lstdc++ $JVM_LIBS" 53220 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53221 # just use the same setting as for the TARGET toolchain. 53222 OPENJDK_BUILD_JVM_LIBS="-lstdc++ $OPENJDK_BUILD_JVM_LIBS" 53223 LDCXX="$CXX" 53224 STATIC_CXX_SETTING="STATIC_CXX=false" 53225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 53226 $as_echo "dynamic" >&6; } 53227 else 53228 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 53229 JVM_LDFLAGS="$JVM_LDFLAGS -static-libgcc" 53230 # To help comparisons with old build, put stdc++ first in JVM_LIBS 53231 JVM_LIBS="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic $JVM_LIBS" 53232 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53233 # just use the same setting as for the TARGET toolchain. 53234 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -static-libgcc" 53235 OPENJDK_BUILD_JVM_LIBS="-Wl,-Bstatic -lstdc++ -Wl,-Bdynamic $OPENJDK_BUILD_JVM_LIBS" 53236 LDCXX="$CC" 53237 STATIC_CXX_SETTING="STATIC_CXX=true" 53238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 53239 $as_echo "static" >&6; } 53240 fi 53241 fi 53242 53243 53244 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 53245 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 53246 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 53247 fi 53248 53249 # TODO better (platform agnostic) test 53250 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then 53251 LIBCXX="-lstdc++" 53252 fi 53253 53254 53255 # Setup Windows runtime dlls 53256 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 53257 53258 53259 # Check whether --with-msvcr-dll was given. 53260 if test "${with_msvcr_dll+set}" = set; then : 53261 withval=$with_msvcr_dll; 53262 fi 53263 53264 53265 if test "x$with_msvcr_dll" != x; then 53266 # If given explicitely by user, do not probe. If not present, fail directly. 53267 53268 DLL_NAME="$MSVCR_NAME" 53269 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 53270 METHOD="--with-msvcr-dll" 53271 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53272 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53273 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53274 53275 # Need to check if the found msvcr is correct architecture 53276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53277 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53278 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53279 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53280 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53281 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53282 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53283 CORRECT_MSVCR_ARCH="PE32 executable" 53284 else 53285 CORRECT_MSVCR_ARCH="PE32+ executable" 53286 fi 53287 else 53288 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53289 CORRECT_MSVCR_ARCH=386 53290 else 53291 CORRECT_MSVCR_ARCH=x86-64 53292 fi 53293 fi 53294 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53296 $as_echo "ok" >&6; } 53297 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53298 53299 # Only process if variable expands to non-empty 53300 53301 if test "x$MSVC_DLL" != x; then 53302 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53303 53304 # Input might be given as Windows format, start by converting to 53305 # unix format. 53306 path="$MSVC_DLL" 53307 new_path=`$CYGPATH -u "$path"` 53308 53309 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53310 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53311 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53312 # "foo.exe" is OK but "foo" is an error. 53313 # 53314 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53315 # It is also a way to make sure we got the proper file name for the real test later on. 53316 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53317 if test "x$test_shortpath" = x; then 53318 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53319 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53320 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53321 fi 53322 53323 # Call helper function which possibly converts this using DOS-style short mode. 53324 # If so, the updated path is stored in $new_path. 53325 53326 input_path="$new_path" 53327 # Check if we need to convert this using DOS-style short mode. If the path 53328 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53329 # take no chances and rewrite it. 53330 # Note: m4 eats our [], so we need to use [ and ] instead. 53331 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53332 if test "x$has_forbidden_chars" != x; then 53333 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53334 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53335 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53336 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53337 # Going to short mode and back again did indeed matter. Since short mode is 53338 # case insensitive, let's make it lowercase to improve readability. 53339 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53340 # Now convert it back to Unix-style (cygpath) 53341 input_path=`$CYGPATH -u "$shortmode_path"` 53342 new_path="$input_path" 53343 fi 53344 fi 53345 53346 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53347 if test "x$test_cygdrive_prefix" = x; then 53348 # As a simple fix, exclude /usr/bin since it's not a real path. 53349 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53350 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53351 # a path prefixed by /cygdrive for fixpath to work. 53352 new_path="$CYGWIN_ROOT_PATH$input_path" 53353 fi 53354 fi 53355 53356 53357 if test "x$path" != "x$new_path"; then 53358 MSVC_DLL="$new_path" 53359 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53360 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53361 fi 53362 53363 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53364 53365 path="$MSVC_DLL" 53366 has_colon=`$ECHO $path | $GREP ^.:` 53367 new_path="$path" 53368 if test "x$has_colon" = x; then 53369 # Not in mixed or Windows style, start by that. 53370 new_path=`cmd //c echo $path` 53371 fi 53372 53373 53374 input_path="$new_path" 53375 # Check if we need to convert this using DOS-style short mode. If the path 53376 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53377 # take no chances and rewrite it. 53378 # Note: m4 eats our [], so we need to use [ and ] instead. 53379 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53380 if test "x$has_forbidden_chars" != x; then 53381 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53382 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53383 fi 53384 53385 53386 windows_path="$new_path" 53387 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53388 unix_path=`$CYGPATH -u "$windows_path"` 53389 new_path="$unix_path" 53390 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53391 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53392 new_path="$unix_path" 53393 fi 53394 53395 if test "x$path" != "x$new_path"; then 53396 MSVC_DLL="$new_path" 53397 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53398 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53399 fi 53400 53401 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53402 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53403 53404 else 53405 # We're on a unix platform. Hooray! :) 53406 path="$MSVC_DLL" 53407 has_space=`$ECHO "$path" | $GREP " "` 53408 if test "x$has_space" != x; then 53409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53410 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53411 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53412 fi 53413 53414 # Use eval to expand a potential ~ 53415 eval path="$path" 53416 if test ! -f "$path" && test ! -d "$path"; then 53417 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53418 fi 53419 53420 if test -d "$path"; then 53421 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53422 else 53423 dir="`$DIRNAME "$path"`" 53424 base="`$BASENAME "$path"`" 53425 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53426 fi 53427 fi 53428 fi 53429 53430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53431 $as_echo_n "checking for $DLL_NAME... " >&6; } 53432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53433 $as_echo "$MSVC_DLL" >&6; } 53434 else 53435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53436 $as_echo "incorrect, ignoring" >&6; } 53437 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53438 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53439 fi 53440 fi 53441 53442 if test "x$MSVC_DLL" = x; then 53443 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 53444 fi 53445 MSVCR_DLL="$MSVC_DLL" 53446 elif test "x$DEVKIT_MSVCR_DLL" != x; then 53447 53448 DLL_NAME="$MSVCR_NAME" 53449 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 53450 METHOD="devkit" 53451 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53452 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53453 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53454 53455 # Need to check if the found msvcr is correct architecture 53456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53457 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53458 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53459 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53460 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53461 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53462 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53463 CORRECT_MSVCR_ARCH="PE32 executable" 53464 else 53465 CORRECT_MSVCR_ARCH="PE32+ executable" 53466 fi 53467 else 53468 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53469 CORRECT_MSVCR_ARCH=386 53470 else 53471 CORRECT_MSVCR_ARCH=x86-64 53472 fi 53473 fi 53474 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53476 $as_echo "ok" >&6; } 53477 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53478 53479 # Only process if variable expands to non-empty 53480 53481 if test "x$MSVC_DLL" != x; then 53482 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53483 53484 # Input might be given as Windows format, start by converting to 53485 # unix format. 53486 path="$MSVC_DLL" 53487 new_path=`$CYGPATH -u "$path"` 53488 53489 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53490 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53491 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53492 # "foo.exe" is OK but "foo" is an error. 53493 # 53494 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53495 # It is also a way to make sure we got the proper file name for the real test later on. 53496 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53497 if test "x$test_shortpath" = x; then 53498 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53499 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53500 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53501 fi 53502 53503 # Call helper function which possibly converts this using DOS-style short mode. 53504 # If so, the updated path is stored in $new_path. 53505 53506 input_path="$new_path" 53507 # Check if we need to convert this using DOS-style short mode. If the path 53508 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53509 # take no chances and rewrite it. 53510 # Note: m4 eats our [], so we need to use [ and ] instead. 53511 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53512 if test "x$has_forbidden_chars" != x; then 53513 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53514 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53515 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53516 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53517 # Going to short mode and back again did indeed matter. Since short mode is 53518 # case insensitive, let's make it lowercase to improve readability. 53519 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53520 # Now convert it back to Unix-style (cygpath) 53521 input_path=`$CYGPATH -u "$shortmode_path"` 53522 new_path="$input_path" 53523 fi 53524 fi 53525 53526 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53527 if test "x$test_cygdrive_prefix" = x; then 53528 # As a simple fix, exclude /usr/bin since it's not a real path. 53529 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53530 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53531 # a path prefixed by /cygdrive for fixpath to work. 53532 new_path="$CYGWIN_ROOT_PATH$input_path" 53533 fi 53534 fi 53535 53536 53537 if test "x$path" != "x$new_path"; then 53538 MSVC_DLL="$new_path" 53539 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53540 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53541 fi 53542 53543 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53544 53545 path="$MSVC_DLL" 53546 has_colon=`$ECHO $path | $GREP ^.:` 53547 new_path="$path" 53548 if test "x$has_colon" = x; then 53549 # Not in mixed or Windows style, start by that. 53550 new_path=`cmd //c echo $path` 53551 fi 53552 53553 53554 input_path="$new_path" 53555 # Check if we need to convert this using DOS-style short mode. If the path 53556 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53557 # take no chances and rewrite it. 53558 # Note: m4 eats our [], so we need to use [ and ] instead. 53559 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53560 if test "x$has_forbidden_chars" != x; then 53561 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53562 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53563 fi 53564 53565 53566 windows_path="$new_path" 53567 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53568 unix_path=`$CYGPATH -u "$windows_path"` 53569 new_path="$unix_path" 53570 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53571 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53572 new_path="$unix_path" 53573 fi 53574 53575 if test "x$path" != "x$new_path"; then 53576 MSVC_DLL="$new_path" 53577 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53578 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53579 fi 53580 53581 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53582 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53583 53584 else 53585 # We're on a unix platform. Hooray! :) 53586 path="$MSVC_DLL" 53587 has_space=`$ECHO "$path" | $GREP " "` 53588 if test "x$has_space" != x; then 53589 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53590 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53591 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53592 fi 53593 53594 # Use eval to expand a potential ~ 53595 eval path="$path" 53596 if test ! -f "$path" && test ! -d "$path"; then 53597 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53598 fi 53599 53600 if test -d "$path"; then 53601 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53602 else 53603 dir="`$DIRNAME "$path"`" 53604 base="`$BASENAME "$path"`" 53605 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53606 fi 53607 fi 53608 fi 53609 53610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53611 $as_echo_n "checking for $DLL_NAME... " >&6; } 53612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53613 $as_echo "$MSVC_DLL" >&6; } 53614 else 53615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53616 $as_echo "incorrect, ignoring" >&6; } 53617 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53618 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53619 fi 53620 fi 53621 53622 if test "x$MSVC_DLL" = x; then 53623 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 53624 fi 53625 MSVCR_DLL="$MSVC_DLL" 53626 else 53627 53628 DLL_NAME="${MSVCR_NAME}" 53629 MSVC_DLL= 53630 53631 if test "x$MSVC_DLL" = x; then 53632 # Probe: Using well-known location from Visual Studio 10.0 53633 if test "x$VCINSTALLDIR" != x; then 53634 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 53635 53636 windows_path="$CYGWIN_VC_INSTALL_DIR" 53637 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53638 unix_path=`$CYGPATH -u "$windows_path"` 53639 CYGWIN_VC_INSTALL_DIR="$unix_path" 53640 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53641 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53642 CYGWIN_VC_INSTALL_DIR="$unix_path" 53643 fi 53644 53645 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 53646 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53647 else 53648 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53649 fi 53650 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 53651 53652 DLL_NAME="$DLL_NAME" 53653 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53654 METHOD="well-known location in VCINSTALLDIR" 53655 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53656 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53657 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53658 53659 # Need to check if the found msvcr is correct architecture 53660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53661 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53662 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53663 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53664 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53665 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53666 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53667 CORRECT_MSVCR_ARCH="PE32 executable" 53668 else 53669 CORRECT_MSVCR_ARCH="PE32+ executable" 53670 fi 53671 else 53672 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53673 CORRECT_MSVCR_ARCH=386 53674 else 53675 CORRECT_MSVCR_ARCH=x86-64 53676 fi 53677 fi 53678 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53680 $as_echo "ok" >&6; } 53681 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53682 53683 # Only process if variable expands to non-empty 53684 53685 if test "x$MSVC_DLL" != x; then 53686 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53687 53688 # Input might be given as Windows format, start by converting to 53689 # unix format. 53690 path="$MSVC_DLL" 53691 new_path=`$CYGPATH -u "$path"` 53692 53693 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53694 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53695 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53696 # "foo.exe" is OK but "foo" is an error. 53697 # 53698 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53699 # It is also a way to make sure we got the proper file name for the real test later on. 53700 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53701 if test "x$test_shortpath" = x; then 53702 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53703 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53704 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53705 fi 53706 53707 # Call helper function which possibly converts this using DOS-style short mode. 53708 # If so, the updated path is stored in $new_path. 53709 53710 input_path="$new_path" 53711 # Check if we need to convert this using DOS-style short mode. If the path 53712 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53713 # take no chances and rewrite it. 53714 # Note: m4 eats our [], so we need to use [ and ] instead. 53715 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53716 if test "x$has_forbidden_chars" != x; then 53717 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53718 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53719 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53720 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53721 # Going to short mode and back again did indeed matter. Since short mode is 53722 # case insensitive, let's make it lowercase to improve readability. 53723 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53724 # Now convert it back to Unix-style (cygpath) 53725 input_path=`$CYGPATH -u "$shortmode_path"` 53726 new_path="$input_path" 53727 fi 53728 fi 53729 53730 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53731 if test "x$test_cygdrive_prefix" = x; then 53732 # As a simple fix, exclude /usr/bin since it's not a real path. 53733 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53734 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53735 # a path prefixed by /cygdrive for fixpath to work. 53736 new_path="$CYGWIN_ROOT_PATH$input_path" 53737 fi 53738 fi 53739 53740 53741 if test "x$path" != "x$new_path"; then 53742 MSVC_DLL="$new_path" 53743 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53744 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53745 fi 53746 53747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53748 53749 path="$MSVC_DLL" 53750 has_colon=`$ECHO $path | $GREP ^.:` 53751 new_path="$path" 53752 if test "x$has_colon" = x; then 53753 # Not in mixed or Windows style, start by that. 53754 new_path=`cmd //c echo $path` 53755 fi 53756 53757 53758 input_path="$new_path" 53759 # Check if we need to convert this using DOS-style short mode. If the path 53760 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53761 # take no chances and rewrite it. 53762 # Note: m4 eats our [], so we need to use [ and ] instead. 53763 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53764 if test "x$has_forbidden_chars" != x; then 53765 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53766 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53767 fi 53768 53769 53770 windows_path="$new_path" 53771 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53772 unix_path=`$CYGPATH -u "$windows_path"` 53773 new_path="$unix_path" 53774 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53775 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53776 new_path="$unix_path" 53777 fi 53778 53779 if test "x$path" != "x$new_path"; then 53780 MSVC_DLL="$new_path" 53781 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53782 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53783 fi 53784 53785 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53786 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53787 53788 else 53789 # We're on a unix platform. Hooray! :) 53790 path="$MSVC_DLL" 53791 has_space=`$ECHO "$path" | $GREP " "` 53792 if test "x$has_space" != x; then 53793 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53794 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53795 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53796 fi 53797 53798 # Use eval to expand a potential ~ 53799 eval path="$path" 53800 if test ! -f "$path" && test ! -d "$path"; then 53801 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53802 fi 53803 53804 if test -d "$path"; then 53805 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53806 else 53807 dir="`$DIRNAME "$path"`" 53808 base="`$BASENAME "$path"`" 53809 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53810 fi 53811 fi 53812 fi 53813 53814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53815 $as_echo_n "checking for $DLL_NAME... " >&6; } 53816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53817 $as_echo "$MSVC_DLL" >&6; } 53818 else 53819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53820 $as_echo "incorrect, ignoring" >&6; } 53821 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53822 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53823 fi 53824 fi 53825 53826 fi 53827 fi 53828 53829 if test "x$MSVC_DLL" = x; then 53830 # Probe: Check in the Boot JDK directory. 53831 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 53832 53833 DLL_NAME="$DLL_NAME" 53834 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53835 METHOD="well-known location in Boot JDK" 53836 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53837 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53838 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53839 53840 # Need to check if the found msvcr is correct architecture 53841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53842 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53843 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53844 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53845 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53846 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53847 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53848 CORRECT_MSVCR_ARCH="PE32 executable" 53849 else 53850 CORRECT_MSVCR_ARCH="PE32+ executable" 53851 fi 53852 else 53853 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53854 CORRECT_MSVCR_ARCH=386 53855 else 53856 CORRECT_MSVCR_ARCH=x86-64 53857 fi 53858 fi 53859 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53861 $as_echo "ok" >&6; } 53862 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53863 53864 # Only process if variable expands to non-empty 53865 53866 if test "x$MSVC_DLL" != x; then 53867 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53868 53869 # Input might be given as Windows format, start by converting to 53870 # unix format. 53871 path="$MSVC_DLL" 53872 new_path=`$CYGPATH -u "$path"` 53873 53874 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53875 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53876 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53877 # "foo.exe" is OK but "foo" is an error. 53878 # 53879 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53880 # It is also a way to make sure we got the proper file name for the real test later on. 53881 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53882 if test "x$test_shortpath" = x; then 53883 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53884 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53885 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53886 fi 53887 53888 # Call helper function which possibly converts this using DOS-style short mode. 53889 # If so, the updated path is stored in $new_path. 53890 53891 input_path="$new_path" 53892 # Check if we need to convert this using DOS-style short mode. If the path 53893 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53894 # take no chances and rewrite it. 53895 # Note: m4 eats our [], so we need to use [ and ] instead. 53896 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53897 if test "x$has_forbidden_chars" != x; then 53898 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53899 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53900 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53901 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53902 # Going to short mode and back again did indeed matter. Since short mode is 53903 # case insensitive, let's make it lowercase to improve readability. 53904 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53905 # Now convert it back to Unix-style (cygpath) 53906 input_path=`$CYGPATH -u "$shortmode_path"` 53907 new_path="$input_path" 53908 fi 53909 fi 53910 53911 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53912 if test "x$test_cygdrive_prefix" = x; then 53913 # As a simple fix, exclude /usr/bin since it's not a real path. 53914 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53915 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53916 # a path prefixed by /cygdrive for fixpath to work. 53917 new_path="$CYGWIN_ROOT_PATH$input_path" 53918 fi 53919 fi 53920 53921 53922 if test "x$path" != "x$new_path"; then 53923 MSVC_DLL="$new_path" 53924 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53925 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53926 fi 53927 53928 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53929 53930 path="$MSVC_DLL" 53931 has_colon=`$ECHO $path | $GREP ^.:` 53932 new_path="$path" 53933 if test "x$has_colon" = x; then 53934 # Not in mixed or Windows style, start by that. 53935 new_path=`cmd //c echo $path` 53936 fi 53937 53938 53939 input_path="$new_path" 53940 # Check if we need to convert this using DOS-style short mode. If the path 53941 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53942 # take no chances and rewrite it. 53943 # Note: m4 eats our [], so we need to use [ and ] instead. 53944 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53945 if test "x$has_forbidden_chars" != x; then 53946 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53947 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53948 fi 53949 53950 53951 windows_path="$new_path" 53952 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53953 unix_path=`$CYGPATH -u "$windows_path"` 53954 new_path="$unix_path" 53955 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53956 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53957 new_path="$unix_path" 53958 fi 53959 53960 if test "x$path" != "x$new_path"; then 53961 MSVC_DLL="$new_path" 53962 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53963 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53964 fi 53965 53966 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53967 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53968 53969 else 53970 # We're on a unix platform. Hooray! :) 53971 path="$MSVC_DLL" 53972 has_space=`$ECHO "$path" | $GREP " "` 53973 if test "x$has_space" != x; then 53974 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53975 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53976 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53977 fi 53978 53979 # Use eval to expand a potential ~ 53980 eval path="$path" 53981 if test ! -f "$path" && test ! -d "$path"; then 53982 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53983 fi 53984 53985 if test -d "$path"; then 53986 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53987 else 53988 dir="`$DIRNAME "$path"`" 53989 base="`$BASENAME "$path"`" 53990 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53991 fi 53992 fi 53993 fi 53994 53995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53996 $as_echo_n "checking for $DLL_NAME... " >&6; } 53997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53998 $as_echo "$MSVC_DLL" >&6; } 53999 else 54000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54001 $as_echo "incorrect, ignoring" >&6; } 54002 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54003 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54004 fi 54005 fi 54006 54007 fi 54008 54009 if test "x$MSVC_DLL" = x; then 54010 # Probe: Look in the Windows system32 directory 54011 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 54012 54013 windows_path="$CYGWIN_SYSTEMROOT" 54014 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54015 unix_path=`$CYGPATH -u "$windows_path"` 54016 CYGWIN_SYSTEMROOT="$unix_path" 54017 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54018 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54019 CYGWIN_SYSTEMROOT="$unix_path" 54020 fi 54021 54022 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 54023 54024 DLL_NAME="$DLL_NAME" 54025 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54026 METHOD="well-known location in SYSTEMROOT" 54027 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54028 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54029 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54030 54031 # Need to check if the found msvcr is correct architecture 54032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54033 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54034 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54036 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54037 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54038 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54039 CORRECT_MSVCR_ARCH="PE32 executable" 54040 else 54041 CORRECT_MSVCR_ARCH="PE32+ executable" 54042 fi 54043 else 54044 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54045 CORRECT_MSVCR_ARCH=386 54046 else 54047 CORRECT_MSVCR_ARCH=x86-64 54048 fi 54049 fi 54050 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54052 $as_echo "ok" >&6; } 54053 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54054 54055 # Only process if variable expands to non-empty 54056 54057 if test "x$MSVC_DLL" != x; then 54058 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54059 54060 # Input might be given as Windows format, start by converting to 54061 # unix format. 54062 path="$MSVC_DLL" 54063 new_path=`$CYGPATH -u "$path"` 54064 54065 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54066 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54067 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54068 # "foo.exe" is OK but "foo" is an error. 54069 # 54070 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54071 # It is also a way to make sure we got the proper file name for the real test later on. 54072 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54073 if test "x$test_shortpath" = x; then 54074 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54075 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54076 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54077 fi 54078 54079 # Call helper function which possibly converts this using DOS-style short mode. 54080 # If so, the updated path is stored in $new_path. 54081 54082 input_path="$new_path" 54083 # Check if we need to convert this using DOS-style short mode. If the path 54084 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54085 # take no chances and rewrite it. 54086 # Note: m4 eats our [], so we need to use [ and ] instead. 54087 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54088 if test "x$has_forbidden_chars" != x; then 54089 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54090 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54091 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54092 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54093 # Going to short mode and back again did indeed matter. Since short mode is 54094 # case insensitive, let's make it lowercase to improve readability. 54095 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54096 # Now convert it back to Unix-style (cygpath) 54097 input_path=`$CYGPATH -u "$shortmode_path"` 54098 new_path="$input_path" 54099 fi 54100 fi 54101 54102 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54103 if test "x$test_cygdrive_prefix" = x; then 54104 # As a simple fix, exclude /usr/bin since it's not a real path. 54105 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54106 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54107 # a path prefixed by /cygdrive for fixpath to work. 54108 new_path="$CYGWIN_ROOT_PATH$input_path" 54109 fi 54110 fi 54111 54112 54113 if test "x$path" != "x$new_path"; then 54114 MSVC_DLL="$new_path" 54115 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54116 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54117 fi 54118 54119 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54120 54121 path="$MSVC_DLL" 54122 has_colon=`$ECHO $path | $GREP ^.:` 54123 new_path="$path" 54124 if test "x$has_colon" = x; then 54125 # Not in mixed or Windows style, start by that. 54126 new_path=`cmd //c echo $path` 54127 fi 54128 54129 54130 input_path="$new_path" 54131 # Check if we need to convert this using DOS-style short mode. If the path 54132 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54133 # take no chances and rewrite it. 54134 # Note: m4 eats our [], so we need to use [ and ] instead. 54135 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54136 if test "x$has_forbidden_chars" != x; then 54137 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54138 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54139 fi 54140 54141 54142 windows_path="$new_path" 54143 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54144 unix_path=`$CYGPATH -u "$windows_path"` 54145 new_path="$unix_path" 54146 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54147 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54148 new_path="$unix_path" 54149 fi 54150 54151 if test "x$path" != "x$new_path"; then 54152 MSVC_DLL="$new_path" 54153 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54154 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54155 fi 54156 54157 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54158 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54159 54160 else 54161 # We're on a unix platform. Hooray! :) 54162 path="$MSVC_DLL" 54163 has_space=`$ECHO "$path" | $GREP " "` 54164 if test "x$has_space" != x; then 54165 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54166 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54167 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54168 fi 54169 54170 # Use eval to expand a potential ~ 54171 eval path="$path" 54172 if test ! -f "$path" && test ! -d "$path"; then 54173 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54174 fi 54175 54176 if test -d "$path"; then 54177 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54178 else 54179 dir="`$DIRNAME "$path"`" 54180 base="`$BASENAME "$path"`" 54181 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54182 fi 54183 fi 54184 fi 54185 54186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54187 $as_echo_n "checking for $DLL_NAME... " >&6; } 54188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54189 $as_echo "$MSVC_DLL" >&6; } 54190 else 54191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54192 $as_echo "incorrect, ignoring" >&6; } 54193 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54194 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54195 fi 54196 fi 54197 54198 fi 54199 54200 if test "x$MSVC_DLL" = x; then 54201 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 54202 if test "x$VS100COMNTOOLS" != x; then 54203 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 54204 54205 windows_path="$CYGWIN_VS_TOOLS_DIR" 54206 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54207 unix_path=`$CYGPATH -u "$windows_path"` 54208 CYGWIN_VS_TOOLS_DIR="$unix_path" 54209 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54210 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54211 CYGWIN_VS_TOOLS_DIR="$unix_path" 54212 fi 54213 54214 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54215 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54216 | $GREP -i /x64/ | $HEAD --lines 1` 54217 else 54218 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54219 | $GREP -i /x86/ | $HEAD --lines 1` 54220 fi 54221 54222 DLL_NAME="$DLL_NAME" 54223 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54224 METHOD="search of VS100COMNTOOLS" 54225 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54226 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54227 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54228 54229 # Need to check if the found msvcr is correct architecture 54230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54231 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54232 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54234 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54235 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54236 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54237 CORRECT_MSVCR_ARCH="PE32 executable" 54238 else 54239 CORRECT_MSVCR_ARCH="PE32+ executable" 54240 fi 54241 else 54242 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54243 CORRECT_MSVCR_ARCH=386 54244 else 54245 CORRECT_MSVCR_ARCH=x86-64 54246 fi 54247 fi 54248 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54250 $as_echo "ok" >&6; } 54251 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54252 54253 # Only process if variable expands to non-empty 54254 54255 if test "x$MSVC_DLL" != x; then 54256 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54257 54258 # Input might be given as Windows format, start by converting to 54259 # unix format. 54260 path="$MSVC_DLL" 54261 new_path=`$CYGPATH -u "$path"` 54262 54263 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54264 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54265 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54266 # "foo.exe" is OK but "foo" is an error. 54267 # 54268 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54269 # It is also a way to make sure we got the proper file name for the real test later on. 54270 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54271 if test "x$test_shortpath" = x; then 54272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54273 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54274 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54275 fi 54276 54277 # Call helper function which possibly converts this using DOS-style short mode. 54278 # If so, the updated path is stored in $new_path. 54279 54280 input_path="$new_path" 54281 # Check if we need to convert this using DOS-style short mode. If the path 54282 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54283 # take no chances and rewrite it. 54284 # Note: m4 eats our [], so we need to use [ and ] instead. 54285 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54286 if test "x$has_forbidden_chars" != x; then 54287 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54288 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54289 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54290 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54291 # Going to short mode and back again did indeed matter. Since short mode is 54292 # case insensitive, let's make it lowercase to improve readability. 54293 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54294 # Now convert it back to Unix-style (cygpath) 54295 input_path=`$CYGPATH -u "$shortmode_path"` 54296 new_path="$input_path" 54297 fi 54298 fi 54299 54300 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54301 if test "x$test_cygdrive_prefix" = x; then 54302 # As a simple fix, exclude /usr/bin since it's not a real path. 54303 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54304 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54305 # a path prefixed by /cygdrive for fixpath to work. 54306 new_path="$CYGWIN_ROOT_PATH$input_path" 54307 fi 54308 fi 54309 54310 54311 if test "x$path" != "x$new_path"; then 54312 MSVC_DLL="$new_path" 54313 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54314 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54315 fi 54316 54317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54318 54319 path="$MSVC_DLL" 54320 has_colon=`$ECHO $path | $GREP ^.:` 54321 new_path="$path" 54322 if test "x$has_colon" = x; then 54323 # Not in mixed or Windows style, start by that. 54324 new_path=`cmd //c echo $path` 54325 fi 54326 54327 54328 input_path="$new_path" 54329 # Check if we need to convert this using DOS-style short mode. If the path 54330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54331 # take no chances and rewrite it. 54332 # Note: m4 eats our [], so we need to use [ and ] instead. 54333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54334 if test "x$has_forbidden_chars" != x; then 54335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54336 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54337 fi 54338 54339 54340 windows_path="$new_path" 54341 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54342 unix_path=`$CYGPATH -u "$windows_path"` 54343 new_path="$unix_path" 54344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54345 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54346 new_path="$unix_path" 54347 fi 54348 54349 if test "x$path" != "x$new_path"; then 54350 MSVC_DLL="$new_path" 54351 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54352 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54353 fi 54354 54355 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54356 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54357 54358 else 54359 # We're on a unix platform. Hooray! :) 54360 path="$MSVC_DLL" 54361 has_space=`$ECHO "$path" | $GREP " "` 54362 if test "x$has_space" != x; then 54363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54364 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54365 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54366 fi 54367 54368 # Use eval to expand a potential ~ 54369 eval path="$path" 54370 if test ! -f "$path" && test ! -d "$path"; then 54371 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54372 fi 54373 54374 if test -d "$path"; then 54375 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54376 else 54377 dir="`$DIRNAME "$path"`" 54378 base="`$BASENAME "$path"`" 54379 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54380 fi 54381 fi 54382 fi 54383 54384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54385 $as_echo_n "checking for $DLL_NAME... " >&6; } 54386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54387 $as_echo "$MSVC_DLL" >&6; } 54388 else 54389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54390 $as_echo "incorrect, ignoring" >&6; } 54391 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54392 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54393 fi 54394 fi 54395 54396 fi 54397 fi 54398 54399 if test "x$MSVC_DLL" = x; then 54400 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 54401 # (This was the original behaviour; kept since it might turn something up) 54402 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 54403 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54404 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54405 | $GREP x64 | $HEAD --lines 1` 54406 else 54407 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54408 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 54409 if test "x$POSSIBLE_MSVC_DLL" = x; then 54410 # We're grasping at straws now... 54411 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54412 | $HEAD --lines 1` 54413 fi 54414 fi 54415 54416 54417 DLL_NAME="$DLL_NAME" 54418 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54419 METHOD="search of VCINSTALLDIR" 54420 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54421 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54422 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54423 54424 # Need to check if the found msvcr is correct architecture 54425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54426 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54427 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54428 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54429 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54430 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54431 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54432 CORRECT_MSVCR_ARCH="PE32 executable" 54433 else 54434 CORRECT_MSVCR_ARCH="PE32+ executable" 54435 fi 54436 else 54437 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54438 CORRECT_MSVCR_ARCH=386 54439 else 54440 CORRECT_MSVCR_ARCH=x86-64 54441 fi 54442 fi 54443 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54445 $as_echo "ok" >&6; } 54446 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54447 54448 # Only process if variable expands to non-empty 54449 54450 if test "x$MSVC_DLL" != x; then 54451 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54452 54453 # Input might be given as Windows format, start by converting to 54454 # unix format. 54455 path="$MSVC_DLL" 54456 new_path=`$CYGPATH -u "$path"` 54457 54458 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54459 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54460 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54461 # "foo.exe" is OK but "foo" is an error. 54462 # 54463 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54464 # It is also a way to make sure we got the proper file name for the real test later on. 54465 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54466 if test "x$test_shortpath" = x; then 54467 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54468 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54469 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54470 fi 54471 54472 # Call helper function which possibly converts this using DOS-style short mode. 54473 # If so, the updated path is stored in $new_path. 54474 54475 input_path="$new_path" 54476 # Check if we need to convert this using DOS-style short mode. If the path 54477 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54478 # take no chances and rewrite it. 54479 # Note: m4 eats our [], so we need to use [ and ] instead. 54480 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54481 if test "x$has_forbidden_chars" != x; then 54482 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54483 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54484 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54485 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54486 # Going to short mode and back again did indeed matter. Since short mode is 54487 # case insensitive, let's make it lowercase to improve readability. 54488 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54489 # Now convert it back to Unix-style (cygpath) 54490 input_path=`$CYGPATH -u "$shortmode_path"` 54491 new_path="$input_path" 54492 fi 54493 fi 54494 54495 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54496 if test "x$test_cygdrive_prefix" = x; then 54497 # As a simple fix, exclude /usr/bin since it's not a real path. 54498 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54499 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54500 # a path prefixed by /cygdrive for fixpath to work. 54501 new_path="$CYGWIN_ROOT_PATH$input_path" 54502 fi 54503 fi 54504 54505 54506 if test "x$path" != "x$new_path"; then 54507 MSVC_DLL="$new_path" 54508 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54509 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54510 fi 54511 54512 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54513 54514 path="$MSVC_DLL" 54515 has_colon=`$ECHO $path | $GREP ^.:` 54516 new_path="$path" 54517 if test "x$has_colon" = x; then 54518 # Not in mixed or Windows style, start by that. 54519 new_path=`cmd //c echo $path` 54520 fi 54521 54522 54523 input_path="$new_path" 54524 # Check if we need to convert this using DOS-style short mode. If the path 54525 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54526 # take no chances and rewrite it. 54527 # Note: m4 eats our [], so we need to use [ and ] instead. 54528 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54529 if test "x$has_forbidden_chars" != x; then 54530 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54531 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54532 fi 54533 54534 54535 windows_path="$new_path" 54536 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54537 unix_path=`$CYGPATH -u "$windows_path"` 54538 new_path="$unix_path" 54539 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54540 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54541 new_path="$unix_path" 54542 fi 54543 54544 if test "x$path" != "x$new_path"; then 54545 MSVC_DLL="$new_path" 54546 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54547 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54548 fi 54549 54550 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54551 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54552 54553 else 54554 # We're on a unix platform. Hooray! :) 54555 path="$MSVC_DLL" 54556 has_space=`$ECHO "$path" | $GREP " "` 54557 if test "x$has_space" != x; then 54558 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54559 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54560 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54561 fi 54562 54563 # Use eval to expand a potential ~ 54564 eval path="$path" 54565 if test ! -f "$path" && test ! -d "$path"; then 54566 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54567 fi 54568 54569 if test -d "$path"; then 54570 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54571 else 54572 dir="`$DIRNAME "$path"`" 54573 base="`$BASENAME "$path"`" 54574 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54575 fi 54576 fi 54577 fi 54578 54579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54580 $as_echo_n "checking for $DLL_NAME... " >&6; } 54581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54582 $as_echo "$MSVC_DLL" >&6; } 54583 else 54584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54585 $as_echo "incorrect, ignoring" >&6; } 54586 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54587 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54588 fi 54589 fi 54590 54591 fi 54592 fi 54593 54594 if test "x$MSVC_DLL" = x; then 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: no" >&5 54598 $as_echo "no" >&6; } 54599 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 54600 fi 54601 54602 MSVCR_DLL="$MSVC_DLL" 54603 fi 54604 54605 54606 54607 # Check whether --with-msvcp-dll was given. 54608 if test "${with_msvcp_dll+set}" = set; then : 54609 withval=$with_msvcp_dll; 54610 fi 54611 54612 54613 if test "x$MSVCP_NAME" != "x"; then 54614 if test "x$with_msvcp_dll" != x; then 54615 # If given explicitely by user, do not probe. If not present, fail directly. 54616 54617 DLL_NAME="$MSVCP_NAME" 54618 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 54619 METHOD="--with-msvcp-dll" 54620 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54621 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54622 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54623 54624 # Need to check if the found msvcr is correct architecture 54625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54626 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54627 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54628 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54629 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54630 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54631 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54632 CORRECT_MSVCR_ARCH="PE32 executable" 54633 else 54634 CORRECT_MSVCR_ARCH="PE32+ executable" 54635 fi 54636 else 54637 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54638 CORRECT_MSVCR_ARCH=386 54639 else 54640 CORRECT_MSVCR_ARCH=x86-64 54641 fi 54642 fi 54643 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54645 $as_echo "ok" >&6; } 54646 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54647 54648 # Only process if variable expands to non-empty 54649 54650 if test "x$MSVC_DLL" != x; then 54651 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54652 54653 # Input might be given as Windows format, start by converting to 54654 # unix format. 54655 path="$MSVC_DLL" 54656 new_path=`$CYGPATH -u "$path"` 54657 54658 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54659 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54660 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54661 # "foo.exe" is OK but "foo" is an error. 54662 # 54663 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54664 # It is also a way to make sure we got the proper file name for the real test later on. 54665 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54666 if test "x$test_shortpath" = x; then 54667 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54668 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54669 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54670 fi 54671 54672 # Call helper function which possibly converts this using DOS-style short mode. 54673 # If so, the updated path is stored in $new_path. 54674 54675 input_path="$new_path" 54676 # Check if we need to convert this using DOS-style short mode. If the path 54677 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54678 # take no chances and rewrite it. 54679 # Note: m4 eats our [], so we need to use [ and ] instead. 54680 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54681 if test "x$has_forbidden_chars" != x; then 54682 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54683 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54684 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54685 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54686 # Going to short mode and back again did indeed matter. Since short mode is 54687 # case insensitive, let's make it lowercase to improve readability. 54688 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54689 # Now convert it back to Unix-style (cygpath) 54690 input_path=`$CYGPATH -u "$shortmode_path"` 54691 new_path="$input_path" 54692 fi 54693 fi 54694 54695 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54696 if test "x$test_cygdrive_prefix" = x; then 54697 # As a simple fix, exclude /usr/bin since it's not a real path. 54698 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54699 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54700 # a path prefixed by /cygdrive for fixpath to work. 54701 new_path="$CYGWIN_ROOT_PATH$input_path" 54702 fi 54703 fi 54704 54705 54706 if test "x$path" != "x$new_path"; then 54707 MSVC_DLL="$new_path" 54708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54709 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54710 fi 54711 54712 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54713 54714 path="$MSVC_DLL" 54715 has_colon=`$ECHO $path | $GREP ^.:` 54716 new_path="$path" 54717 if test "x$has_colon" = x; then 54718 # Not in mixed or Windows style, start by that. 54719 new_path=`cmd //c echo $path` 54720 fi 54721 54722 54723 input_path="$new_path" 54724 # Check if we need to convert this using DOS-style short mode. If the path 54725 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54726 # take no chances and rewrite it. 54727 # Note: m4 eats our [], so we need to use [ and ] instead. 54728 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54729 if test "x$has_forbidden_chars" != x; then 54730 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54731 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54732 fi 54733 54734 54735 windows_path="$new_path" 54736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54737 unix_path=`$CYGPATH -u "$windows_path"` 54738 new_path="$unix_path" 54739 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54740 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54741 new_path="$unix_path" 54742 fi 54743 54744 if test "x$path" != "x$new_path"; then 54745 MSVC_DLL="$new_path" 54746 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54747 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54748 fi 54749 54750 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54751 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54752 54753 else 54754 # We're on a unix platform. Hooray! :) 54755 path="$MSVC_DLL" 54756 has_space=`$ECHO "$path" | $GREP " "` 54757 if test "x$has_space" != x; then 54758 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54759 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54760 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54761 fi 54762 54763 # Use eval to expand a potential ~ 54764 eval path="$path" 54765 if test ! -f "$path" && test ! -d "$path"; then 54766 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54767 fi 54768 54769 if test -d "$path"; then 54770 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54771 else 54772 dir="`$DIRNAME "$path"`" 54773 base="`$BASENAME "$path"`" 54774 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54775 fi 54776 fi 54777 fi 54778 54779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54780 $as_echo_n "checking for $DLL_NAME... " >&6; } 54781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54782 $as_echo "$MSVC_DLL" >&6; } 54783 else 54784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54785 $as_echo "incorrect, ignoring" >&6; } 54786 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54787 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54788 fi 54789 fi 54790 54791 if test "x$MSVC_DLL" = x; then 54792 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 54793 fi 54794 MSVCP_DLL="$MSVC_DLL" 54795 elif test "x$DEVKIT_MSVCP_DLL" != x; then 54796 54797 DLL_NAME="$MSVCP_NAME" 54798 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 54799 METHOD="devkit" 54800 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54801 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54802 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54803 54804 # Need to check if the found msvcr is correct architecture 54805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54806 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54807 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54808 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54809 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54810 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54811 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54812 CORRECT_MSVCR_ARCH="PE32 executable" 54813 else 54814 CORRECT_MSVCR_ARCH="PE32+ executable" 54815 fi 54816 else 54817 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54818 CORRECT_MSVCR_ARCH=386 54819 else 54820 CORRECT_MSVCR_ARCH=x86-64 54821 fi 54822 fi 54823 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54825 $as_echo "ok" >&6; } 54826 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54827 54828 # Only process if variable expands to non-empty 54829 54830 if test "x$MSVC_DLL" != x; then 54831 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54832 54833 # Input might be given as Windows format, start by converting to 54834 # unix format. 54835 path="$MSVC_DLL" 54836 new_path=`$CYGPATH -u "$path"` 54837 54838 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54839 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54840 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54841 # "foo.exe" is OK but "foo" is an error. 54842 # 54843 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54844 # It is also a way to make sure we got the proper file name for the real test later on. 54845 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54846 if test "x$test_shortpath" = x; then 54847 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54848 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54849 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54850 fi 54851 54852 # Call helper function which possibly converts this using DOS-style short mode. 54853 # If so, the updated path is stored in $new_path. 54854 54855 input_path="$new_path" 54856 # Check if we need to convert this using DOS-style short mode. If the path 54857 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54858 # take no chances and rewrite it. 54859 # Note: m4 eats our [], so we need to use [ and ] instead. 54860 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54861 if test "x$has_forbidden_chars" != x; then 54862 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54863 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54864 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54865 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54866 # Going to short mode and back again did indeed matter. Since short mode is 54867 # case insensitive, let's make it lowercase to improve readability. 54868 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54869 # Now convert it back to Unix-style (cygpath) 54870 input_path=`$CYGPATH -u "$shortmode_path"` 54871 new_path="$input_path" 54872 fi 54873 fi 54874 54875 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54876 if test "x$test_cygdrive_prefix" = x; then 54877 # As a simple fix, exclude /usr/bin since it's not a real path. 54878 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54879 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54880 # a path prefixed by /cygdrive for fixpath to work. 54881 new_path="$CYGWIN_ROOT_PATH$input_path" 54882 fi 54883 fi 54884 54885 54886 if test "x$path" != "x$new_path"; then 54887 MSVC_DLL="$new_path" 54888 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54889 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54890 fi 54891 54892 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54893 54894 path="$MSVC_DLL" 54895 has_colon=`$ECHO $path | $GREP ^.:` 54896 new_path="$path" 54897 if test "x$has_colon" = x; then 54898 # Not in mixed or Windows style, start by that. 54899 new_path=`cmd //c echo $path` 54900 fi 54901 54902 54903 input_path="$new_path" 54904 # Check if we need to convert this using DOS-style short mode. If the path 54905 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54906 # take no chances and rewrite it. 54907 # Note: m4 eats our [], so we need to use [ and ] instead. 54908 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54909 if test "x$has_forbidden_chars" != x; then 54910 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54911 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54912 fi 54913 54914 54915 windows_path="$new_path" 54916 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54917 unix_path=`$CYGPATH -u "$windows_path"` 54918 new_path="$unix_path" 54919 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54920 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54921 new_path="$unix_path" 54922 fi 54923 54924 if test "x$path" != "x$new_path"; then 54925 MSVC_DLL="$new_path" 54926 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54927 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54928 fi 54929 54930 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54931 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54932 54933 else 54934 # We're on a unix platform. Hooray! :) 54935 path="$MSVC_DLL" 54936 has_space=`$ECHO "$path" | $GREP " "` 54937 if test "x$has_space" != x; then 54938 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54939 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54940 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54941 fi 54942 54943 # Use eval to expand a potential ~ 54944 eval path="$path" 54945 if test ! -f "$path" && test ! -d "$path"; then 54946 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54947 fi 54948 54949 if test -d "$path"; then 54950 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54951 else 54952 dir="`$DIRNAME "$path"`" 54953 base="`$BASENAME "$path"`" 54954 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54955 fi 54956 fi 54957 fi 54958 54959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54960 $as_echo_n "checking for $DLL_NAME... " >&6; } 54961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54962 $as_echo "$MSVC_DLL" >&6; } 54963 else 54964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54965 $as_echo "incorrect, ignoring" >&6; } 54966 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54967 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54968 fi 54969 fi 54970 54971 if test "x$MSVC_DLL" = x; then 54972 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 54973 fi 54974 MSVCP_DLL="$MSVC_DLL" 54975 else 54976 54977 DLL_NAME="${MSVCP_NAME}" 54978 MSVC_DLL= 54979 54980 if test "x$MSVC_DLL" = x; then 54981 # Probe: Using well-known location from Visual Studio 10.0 54982 if test "x$VCINSTALLDIR" != x; then 54983 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 54984 54985 windows_path="$CYGWIN_VC_INSTALL_DIR" 54986 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54987 unix_path=`$CYGPATH -u "$windows_path"` 54988 CYGWIN_VC_INSTALL_DIR="$unix_path" 54989 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54990 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54991 CYGWIN_VC_INSTALL_DIR="$unix_path" 54992 fi 54993 54994 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54995 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54996 else 54997 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54998 fi 54999 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 55000 55001 DLL_NAME="$DLL_NAME" 55002 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55003 METHOD="well-known location in VCINSTALLDIR" 55004 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55005 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55006 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55007 55008 # Need to check if the found msvcr is correct architecture 55009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55010 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55011 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55012 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55013 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55014 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55015 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55016 CORRECT_MSVCR_ARCH="PE32 executable" 55017 else 55018 CORRECT_MSVCR_ARCH="PE32+ executable" 55019 fi 55020 else 55021 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55022 CORRECT_MSVCR_ARCH=386 55023 else 55024 CORRECT_MSVCR_ARCH=x86-64 55025 fi 55026 fi 55027 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55029 $as_echo "ok" >&6; } 55030 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55031 55032 # Only process if variable expands to non-empty 55033 55034 if test "x$MSVC_DLL" != x; then 55035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55036 55037 # Input might be given as Windows format, start by converting to 55038 # unix format. 55039 path="$MSVC_DLL" 55040 new_path=`$CYGPATH -u "$path"` 55041 55042 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55043 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55044 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55045 # "foo.exe" is OK but "foo" is an error. 55046 # 55047 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55048 # It is also a way to make sure we got the proper file name for the real test later on. 55049 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55050 if test "x$test_shortpath" = x; then 55051 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55052 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55053 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55054 fi 55055 55056 # Call helper function which possibly converts this using DOS-style short mode. 55057 # If so, the updated path is stored in $new_path. 55058 55059 input_path="$new_path" 55060 # Check if we need to convert this using DOS-style short mode. If the path 55061 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55062 # take no chances and rewrite it. 55063 # Note: m4 eats our [], so we need to use [ and ] instead. 55064 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55065 if test "x$has_forbidden_chars" != x; then 55066 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55067 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55068 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55069 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55070 # Going to short mode and back again did indeed matter. Since short mode is 55071 # case insensitive, let's make it lowercase to improve readability. 55072 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55073 # Now convert it back to Unix-style (cygpath) 55074 input_path=`$CYGPATH -u "$shortmode_path"` 55075 new_path="$input_path" 55076 fi 55077 fi 55078 55079 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55080 if test "x$test_cygdrive_prefix" = x; then 55081 # As a simple fix, exclude /usr/bin since it's not a real path. 55082 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55083 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55084 # a path prefixed by /cygdrive for fixpath to work. 55085 new_path="$CYGWIN_ROOT_PATH$input_path" 55086 fi 55087 fi 55088 55089 55090 if test "x$path" != "x$new_path"; then 55091 MSVC_DLL="$new_path" 55092 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55093 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55094 fi 55095 55096 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55097 55098 path="$MSVC_DLL" 55099 has_colon=`$ECHO $path | $GREP ^.:` 55100 new_path="$path" 55101 if test "x$has_colon" = x; then 55102 # Not in mixed or Windows style, start by that. 55103 new_path=`cmd //c echo $path` 55104 fi 55105 55106 55107 input_path="$new_path" 55108 # Check if we need to convert this using DOS-style short mode. If the path 55109 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55110 # take no chances and rewrite it. 55111 # Note: m4 eats our [], so we need to use [ and ] instead. 55112 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55113 if test "x$has_forbidden_chars" != x; then 55114 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55115 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55116 fi 55117 55118 55119 windows_path="$new_path" 55120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55121 unix_path=`$CYGPATH -u "$windows_path"` 55122 new_path="$unix_path" 55123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55124 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55125 new_path="$unix_path" 55126 fi 55127 55128 if test "x$path" != "x$new_path"; then 55129 MSVC_DLL="$new_path" 55130 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55131 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55132 fi 55133 55134 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55135 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55136 55137 else 55138 # We're on a unix platform. Hooray! :) 55139 path="$MSVC_DLL" 55140 has_space=`$ECHO "$path" | $GREP " "` 55141 if test "x$has_space" != x; then 55142 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55143 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55144 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55145 fi 55146 55147 # Use eval to expand a potential ~ 55148 eval path="$path" 55149 if test ! -f "$path" && test ! -d "$path"; then 55150 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55151 fi 55152 55153 if test -d "$path"; then 55154 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55155 else 55156 dir="`$DIRNAME "$path"`" 55157 base="`$BASENAME "$path"`" 55158 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55159 fi 55160 fi 55161 fi 55162 55163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55164 $as_echo_n "checking for $DLL_NAME... " >&6; } 55165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55166 $as_echo "$MSVC_DLL" >&6; } 55167 else 55168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55169 $as_echo "incorrect, ignoring" >&6; } 55170 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55171 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55172 fi 55173 fi 55174 55175 fi 55176 fi 55177 55178 if test "x$MSVC_DLL" = x; then 55179 # Probe: Check in the Boot JDK directory. 55180 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 55181 55182 DLL_NAME="$DLL_NAME" 55183 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55184 METHOD="well-known location in Boot JDK" 55185 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55186 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55187 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55188 55189 # Need to check if the found msvcr is correct architecture 55190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55191 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55192 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55193 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55194 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55195 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55196 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55197 CORRECT_MSVCR_ARCH="PE32 executable" 55198 else 55199 CORRECT_MSVCR_ARCH="PE32+ executable" 55200 fi 55201 else 55202 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55203 CORRECT_MSVCR_ARCH=386 55204 else 55205 CORRECT_MSVCR_ARCH=x86-64 55206 fi 55207 fi 55208 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55210 $as_echo "ok" >&6; } 55211 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55212 55213 # Only process if variable expands to non-empty 55214 55215 if test "x$MSVC_DLL" != x; then 55216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55217 55218 # Input might be given as Windows format, start by converting to 55219 # unix format. 55220 path="$MSVC_DLL" 55221 new_path=`$CYGPATH -u "$path"` 55222 55223 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55224 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55225 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55226 # "foo.exe" is OK but "foo" is an error. 55227 # 55228 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55229 # It is also a way to make sure we got the proper file name for the real test later on. 55230 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55231 if test "x$test_shortpath" = x; then 55232 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55233 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55234 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55235 fi 55236 55237 # Call helper function which possibly converts this using DOS-style short mode. 55238 # If so, the updated path is stored in $new_path. 55239 55240 input_path="$new_path" 55241 # Check if we need to convert this using DOS-style short mode. If the path 55242 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55243 # take no chances and rewrite it. 55244 # Note: m4 eats our [], so we need to use [ and ] instead. 55245 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55246 if test "x$has_forbidden_chars" != x; then 55247 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55248 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55249 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55250 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55251 # Going to short mode and back again did indeed matter. Since short mode is 55252 # case insensitive, let's make it lowercase to improve readability. 55253 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55254 # Now convert it back to Unix-style (cygpath) 55255 input_path=`$CYGPATH -u "$shortmode_path"` 55256 new_path="$input_path" 55257 fi 55258 fi 55259 55260 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55261 if test "x$test_cygdrive_prefix" = x; then 55262 # As a simple fix, exclude /usr/bin since it's not a real path. 55263 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55264 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55265 # a path prefixed by /cygdrive for fixpath to work. 55266 new_path="$CYGWIN_ROOT_PATH$input_path" 55267 fi 55268 fi 55269 55270 55271 if test "x$path" != "x$new_path"; then 55272 MSVC_DLL="$new_path" 55273 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55274 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55275 fi 55276 55277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55278 55279 path="$MSVC_DLL" 55280 has_colon=`$ECHO $path | $GREP ^.:` 55281 new_path="$path" 55282 if test "x$has_colon" = x; then 55283 # Not in mixed or Windows style, start by that. 55284 new_path=`cmd //c echo $path` 55285 fi 55286 55287 55288 input_path="$new_path" 55289 # Check if we need to convert this using DOS-style short mode. If the path 55290 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55291 # take no chances and rewrite it. 55292 # Note: m4 eats our [], so we need to use [ and ] instead. 55293 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55294 if test "x$has_forbidden_chars" != x; then 55295 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55296 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55297 fi 55298 55299 55300 windows_path="$new_path" 55301 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55302 unix_path=`$CYGPATH -u "$windows_path"` 55303 new_path="$unix_path" 55304 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55305 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55306 new_path="$unix_path" 55307 fi 55308 55309 if test "x$path" != "x$new_path"; then 55310 MSVC_DLL="$new_path" 55311 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55312 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55313 fi 55314 55315 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55316 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55317 55318 else 55319 # We're on a unix platform. Hooray! :) 55320 path="$MSVC_DLL" 55321 has_space=`$ECHO "$path" | $GREP " "` 55322 if test "x$has_space" != x; then 55323 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55324 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55325 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55326 fi 55327 55328 # Use eval to expand a potential ~ 55329 eval path="$path" 55330 if test ! -f "$path" && test ! -d "$path"; then 55331 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55332 fi 55333 55334 if test -d "$path"; then 55335 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55336 else 55337 dir="`$DIRNAME "$path"`" 55338 base="`$BASENAME "$path"`" 55339 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55340 fi 55341 fi 55342 fi 55343 55344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55345 $as_echo_n "checking for $DLL_NAME... " >&6; } 55346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55347 $as_echo "$MSVC_DLL" >&6; } 55348 else 55349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55350 $as_echo "incorrect, ignoring" >&6; } 55351 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55352 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55353 fi 55354 fi 55355 55356 fi 55357 55358 if test "x$MSVC_DLL" = x; then 55359 # Probe: Look in the Windows system32 directory 55360 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55361 55362 windows_path="$CYGWIN_SYSTEMROOT" 55363 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55364 unix_path=`$CYGPATH -u "$windows_path"` 55365 CYGWIN_SYSTEMROOT="$unix_path" 55366 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55367 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55368 CYGWIN_SYSTEMROOT="$unix_path" 55369 fi 55370 55371 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55372 55373 DLL_NAME="$DLL_NAME" 55374 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55375 METHOD="well-known location in SYSTEMROOT" 55376 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55377 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55378 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55379 55380 # Need to check if the found msvcr is correct architecture 55381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55382 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55383 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55385 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55386 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55387 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55388 CORRECT_MSVCR_ARCH="PE32 executable" 55389 else 55390 CORRECT_MSVCR_ARCH="PE32+ executable" 55391 fi 55392 else 55393 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55394 CORRECT_MSVCR_ARCH=386 55395 else 55396 CORRECT_MSVCR_ARCH=x86-64 55397 fi 55398 fi 55399 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55401 $as_echo "ok" >&6; } 55402 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55403 55404 # Only process if variable expands to non-empty 55405 55406 if test "x$MSVC_DLL" != x; then 55407 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55408 55409 # Input might be given as Windows format, start by converting to 55410 # unix format. 55411 path="$MSVC_DLL" 55412 new_path=`$CYGPATH -u "$path"` 55413 55414 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55415 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55416 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55417 # "foo.exe" is OK but "foo" is an error. 55418 # 55419 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55420 # It is also a way to make sure we got the proper file name for the real test later on. 55421 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55422 if test "x$test_shortpath" = x; then 55423 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55424 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55425 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55426 fi 55427 55428 # Call helper function which possibly converts this using DOS-style short mode. 55429 # If so, the updated path is stored in $new_path. 55430 55431 input_path="$new_path" 55432 # Check if we need to convert this using DOS-style short mode. If the path 55433 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55434 # take no chances and rewrite it. 55435 # Note: m4 eats our [], so we need to use [ and ] instead. 55436 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55437 if test "x$has_forbidden_chars" != x; then 55438 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55439 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55440 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55441 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55442 # Going to short mode and back again did indeed matter. Since short mode is 55443 # case insensitive, let's make it lowercase to improve readability. 55444 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55445 # Now convert it back to Unix-style (cygpath) 55446 input_path=`$CYGPATH -u "$shortmode_path"` 55447 new_path="$input_path" 55448 fi 55449 fi 55450 55451 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55452 if test "x$test_cygdrive_prefix" = x; then 55453 # As a simple fix, exclude /usr/bin since it's not a real path. 55454 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55455 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55456 # a path prefixed by /cygdrive for fixpath to work. 55457 new_path="$CYGWIN_ROOT_PATH$input_path" 55458 fi 55459 fi 55460 55461 55462 if test "x$path" != "x$new_path"; then 55463 MSVC_DLL="$new_path" 55464 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55465 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55466 fi 55467 55468 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55469 55470 path="$MSVC_DLL" 55471 has_colon=`$ECHO $path | $GREP ^.:` 55472 new_path="$path" 55473 if test "x$has_colon" = x; then 55474 # Not in mixed or Windows style, start by that. 55475 new_path=`cmd //c echo $path` 55476 fi 55477 55478 55479 input_path="$new_path" 55480 # Check if we need to convert this using DOS-style short mode. If the path 55481 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55482 # take no chances and rewrite it. 55483 # Note: m4 eats our [], so we need to use [ and ] instead. 55484 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55485 if test "x$has_forbidden_chars" != x; then 55486 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55487 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55488 fi 55489 55490 55491 windows_path="$new_path" 55492 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55493 unix_path=`$CYGPATH -u "$windows_path"` 55494 new_path="$unix_path" 55495 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55496 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55497 new_path="$unix_path" 55498 fi 55499 55500 if test "x$path" != "x$new_path"; then 55501 MSVC_DLL="$new_path" 55502 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55503 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55504 fi 55505 55506 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55507 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55508 55509 else 55510 # We're on a unix platform. Hooray! :) 55511 path="$MSVC_DLL" 55512 has_space=`$ECHO "$path" | $GREP " "` 55513 if test "x$has_space" != x; then 55514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55515 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55516 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55517 fi 55518 55519 # Use eval to expand a potential ~ 55520 eval path="$path" 55521 if test ! -f "$path" && test ! -d "$path"; then 55522 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55523 fi 55524 55525 if test -d "$path"; then 55526 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55527 else 55528 dir="`$DIRNAME "$path"`" 55529 base="`$BASENAME "$path"`" 55530 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55531 fi 55532 fi 55533 fi 55534 55535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55536 $as_echo_n "checking for $DLL_NAME... " >&6; } 55537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55538 $as_echo "$MSVC_DLL" >&6; } 55539 else 55540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55541 $as_echo "incorrect, ignoring" >&6; } 55542 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55543 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55544 fi 55545 fi 55546 55547 fi 55548 55549 if test "x$MSVC_DLL" = x; then 55550 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55551 if test "x$VS100COMNTOOLS" != x; then 55552 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55553 55554 windows_path="$CYGWIN_VS_TOOLS_DIR" 55555 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55556 unix_path=`$CYGPATH -u "$windows_path"` 55557 CYGWIN_VS_TOOLS_DIR="$unix_path" 55558 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55559 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55560 CYGWIN_VS_TOOLS_DIR="$unix_path" 55561 fi 55562 55563 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55564 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55565 | $GREP -i /x64/ | $HEAD --lines 1` 55566 else 55567 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55568 | $GREP -i /x86/ | $HEAD --lines 1` 55569 fi 55570 55571 DLL_NAME="$DLL_NAME" 55572 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55573 METHOD="search of VS100COMNTOOLS" 55574 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55575 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55576 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55577 55578 # Need to check if the found msvcr is correct architecture 55579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55580 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55581 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55582 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55583 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55584 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55585 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55586 CORRECT_MSVCR_ARCH="PE32 executable" 55587 else 55588 CORRECT_MSVCR_ARCH="PE32+ executable" 55589 fi 55590 else 55591 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55592 CORRECT_MSVCR_ARCH=386 55593 else 55594 CORRECT_MSVCR_ARCH=x86-64 55595 fi 55596 fi 55597 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55599 $as_echo "ok" >&6; } 55600 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55601 55602 # Only process if variable expands to non-empty 55603 55604 if test "x$MSVC_DLL" != x; then 55605 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55606 55607 # Input might be given as Windows format, start by converting to 55608 # unix format. 55609 path="$MSVC_DLL" 55610 new_path=`$CYGPATH -u "$path"` 55611 55612 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55613 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55614 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55615 # "foo.exe" is OK but "foo" is an error. 55616 # 55617 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55618 # It is also a way to make sure we got the proper file name for the real test later on. 55619 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55620 if test "x$test_shortpath" = x; then 55621 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55622 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55623 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55624 fi 55625 55626 # Call helper function which possibly converts this using DOS-style short mode. 55627 # If so, the updated path is stored in $new_path. 55628 55629 input_path="$new_path" 55630 # Check if we need to convert this using DOS-style short mode. If the path 55631 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55632 # take no chances and rewrite it. 55633 # Note: m4 eats our [], so we need to use [ and ] instead. 55634 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55635 if test "x$has_forbidden_chars" != x; then 55636 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55637 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55638 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55639 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55640 # Going to short mode and back again did indeed matter. Since short mode is 55641 # case insensitive, let's make it lowercase to improve readability. 55642 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55643 # Now convert it back to Unix-style (cygpath) 55644 input_path=`$CYGPATH -u "$shortmode_path"` 55645 new_path="$input_path" 55646 fi 55647 fi 55648 55649 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55650 if test "x$test_cygdrive_prefix" = x; then 55651 # As a simple fix, exclude /usr/bin since it's not a real path. 55652 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55653 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55654 # a path prefixed by /cygdrive for fixpath to work. 55655 new_path="$CYGWIN_ROOT_PATH$input_path" 55656 fi 55657 fi 55658 55659 55660 if test "x$path" != "x$new_path"; then 55661 MSVC_DLL="$new_path" 55662 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55663 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55664 fi 55665 55666 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55667 55668 path="$MSVC_DLL" 55669 has_colon=`$ECHO $path | $GREP ^.:` 55670 new_path="$path" 55671 if test "x$has_colon" = x; then 55672 # Not in mixed or Windows style, start by that. 55673 new_path=`cmd //c echo $path` 55674 fi 55675 55676 55677 input_path="$new_path" 55678 # Check if we need to convert this using DOS-style short mode. If the path 55679 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55680 # take no chances and rewrite it. 55681 # Note: m4 eats our [], so we need to use [ and ] instead. 55682 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55683 if test "x$has_forbidden_chars" != x; then 55684 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55685 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55686 fi 55687 55688 55689 windows_path="$new_path" 55690 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55691 unix_path=`$CYGPATH -u "$windows_path"` 55692 new_path="$unix_path" 55693 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55694 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55695 new_path="$unix_path" 55696 fi 55697 55698 if test "x$path" != "x$new_path"; then 55699 MSVC_DLL="$new_path" 55700 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55701 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55702 fi 55703 55704 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55705 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55706 55707 else 55708 # We're on a unix platform. Hooray! :) 55709 path="$MSVC_DLL" 55710 has_space=`$ECHO "$path" | $GREP " "` 55711 if test "x$has_space" != x; then 55712 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55713 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55714 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55715 fi 55716 55717 # Use eval to expand a potential ~ 55718 eval path="$path" 55719 if test ! -f "$path" && test ! -d "$path"; then 55720 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55721 fi 55722 55723 if test -d "$path"; then 55724 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55725 else 55726 dir="`$DIRNAME "$path"`" 55727 base="`$BASENAME "$path"`" 55728 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55729 fi 55730 fi 55731 fi 55732 55733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55734 $as_echo_n "checking for $DLL_NAME... " >&6; } 55735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55736 $as_echo "$MSVC_DLL" >&6; } 55737 else 55738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55739 $as_echo "incorrect, ignoring" >&6; } 55740 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55741 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55742 fi 55743 fi 55744 55745 fi 55746 fi 55747 55748 if test "x$MSVC_DLL" = x; then 55749 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55750 # (This was the original behaviour; kept since it might turn something up) 55751 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55752 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55753 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55754 | $GREP x64 | $HEAD --lines 1` 55755 else 55756 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55757 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55758 if test "x$POSSIBLE_MSVC_DLL" = x; then 55759 # We're grasping at straws now... 55760 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55761 | $HEAD --lines 1` 55762 fi 55763 fi 55764 55765 55766 DLL_NAME="$DLL_NAME" 55767 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55768 METHOD="search of VCINSTALLDIR" 55769 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55770 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55771 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55772 55773 # Need to check if the found msvcr is correct architecture 55774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55775 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55776 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55777 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55778 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55779 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55780 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55781 CORRECT_MSVCR_ARCH="PE32 executable" 55782 else 55783 CORRECT_MSVCR_ARCH="PE32+ executable" 55784 fi 55785 else 55786 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55787 CORRECT_MSVCR_ARCH=386 55788 else 55789 CORRECT_MSVCR_ARCH=x86-64 55790 fi 55791 fi 55792 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55794 $as_echo "ok" >&6; } 55795 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55796 55797 # Only process if variable expands to non-empty 55798 55799 if test "x$MSVC_DLL" != x; then 55800 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55801 55802 # Input might be given as Windows format, start by converting to 55803 # unix format. 55804 path="$MSVC_DLL" 55805 new_path=`$CYGPATH -u "$path"` 55806 55807 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55808 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55809 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55810 # "foo.exe" is OK but "foo" is an error. 55811 # 55812 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55813 # It is also a way to make sure we got the proper file name for the real test later on. 55814 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55815 if test "x$test_shortpath" = x; then 55816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55817 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55818 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55819 fi 55820 55821 # Call helper function which possibly converts this using DOS-style short mode. 55822 # If so, the updated path is stored in $new_path. 55823 55824 input_path="$new_path" 55825 # Check if we need to convert this using DOS-style short mode. If the path 55826 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55827 # take no chances and rewrite it. 55828 # Note: m4 eats our [], so we need to use [ and ] instead. 55829 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55830 if test "x$has_forbidden_chars" != x; then 55831 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55832 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55833 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55834 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55835 # Going to short mode and back again did indeed matter. Since short mode is 55836 # case insensitive, let's make it lowercase to improve readability. 55837 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55838 # Now convert it back to Unix-style (cygpath) 55839 input_path=`$CYGPATH -u "$shortmode_path"` 55840 new_path="$input_path" 55841 fi 55842 fi 55843 55844 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55845 if test "x$test_cygdrive_prefix" = x; then 55846 # As a simple fix, exclude /usr/bin since it's not a real path. 55847 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55848 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55849 # a path prefixed by /cygdrive for fixpath to work. 55850 new_path="$CYGWIN_ROOT_PATH$input_path" 55851 fi 55852 fi 55853 55854 55855 if test "x$path" != "x$new_path"; then 55856 MSVC_DLL="$new_path" 55857 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55858 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55859 fi 55860 55861 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55862 55863 path="$MSVC_DLL" 55864 has_colon=`$ECHO $path | $GREP ^.:` 55865 new_path="$path" 55866 if test "x$has_colon" = x; then 55867 # Not in mixed or Windows style, start by that. 55868 new_path=`cmd //c echo $path` 55869 fi 55870 55871 55872 input_path="$new_path" 55873 # Check if we need to convert this using DOS-style short mode. If the path 55874 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55875 # take no chances and rewrite it. 55876 # Note: m4 eats our [], so we need to use [ and ] instead. 55877 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55878 if test "x$has_forbidden_chars" != x; then 55879 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55880 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55881 fi 55882 55883 55884 windows_path="$new_path" 55885 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55886 unix_path=`$CYGPATH -u "$windows_path"` 55887 new_path="$unix_path" 55888 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55889 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55890 new_path="$unix_path" 55891 fi 55892 55893 if test "x$path" != "x$new_path"; then 55894 MSVC_DLL="$new_path" 55895 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55896 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55897 fi 55898 55899 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55900 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55901 55902 else 55903 # We're on a unix platform. Hooray! :) 55904 path="$MSVC_DLL" 55905 has_space=`$ECHO "$path" | $GREP " "` 55906 if test "x$has_space" != x; then 55907 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55908 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55909 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55910 fi 55911 55912 # Use eval to expand a potential ~ 55913 eval path="$path" 55914 if test ! -f "$path" && test ! -d "$path"; then 55915 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55916 fi 55917 55918 if test -d "$path"; then 55919 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55920 else 55921 dir="`$DIRNAME "$path"`" 55922 base="`$BASENAME "$path"`" 55923 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55924 fi 55925 fi 55926 fi 55927 55928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55929 $as_echo_n "checking for $DLL_NAME... " >&6; } 55930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55931 $as_echo "$MSVC_DLL" >&6; } 55932 else 55933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55934 $as_echo "incorrect, ignoring" >&6; } 55935 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55936 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55937 fi 55938 fi 55939 55940 fi 55941 fi 55942 55943 if test "x$MSVC_DLL" = x; then 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: no" >&5 55947 $as_echo "no" >&6; } 55948 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 55949 fi 55950 55951 MSVCP_DLL="$MSVC_DLL" 55952 fi 55953 55954 fi 55955 55956 fi 55957 55958 55959 if test "x$NEEDS_LIB_X11" = xfalse; then 55960 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 55961 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 55962 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 55963 fi 55964 X_CFLAGS= 55965 X_LIBS= 55966 else 55967 55968 if test "x${with_x}" = xno; then 55969 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 55970 fi 55971 55972 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 55973 # The user has specified a X11 base directory. Use it for includes and 55974 # libraries, unless explicitely overridden. 55975 if test "x$x_includes" = xNONE; then 55976 x_includes="${with_x}/include" 55977 fi 55978 if test "x$x_libraries" = xNONE; then 55979 x_libraries="${with_x}/lib" 55980 fi 55981 else 55982 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 55983 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 55984 # --x-libraries for the sysroot, if that seems to be correct. 55985 if test "x$SYSROOT" != "x"; then 55986 if test "x$x_includes" = xNONE; then 55987 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 55988 x_includes="$SYSROOT/usr/X11R6/include" 55989 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 55990 x_includes="$SYSROOT/usr/include" 55991 fi 55992 fi 55993 if test "x$x_libraries" = xNONE; then 55994 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 55995 x_libraries="$SYSROOT/usr/X11R6/lib" 55996 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55997 x_libraries="$SYSROOT/usr/lib64" 55998 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 55999 x_libraries="$SYSROOT/usr/lib" 56000 fi 56001 fi 56002 fi 56003 fi 56004 56005 # Now let autoconf do it's magic 56006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 56007 $as_echo_n "checking for X... " >&6; } 56008 56009 56010 # Check whether --with-x was given. 56011 if test "${with_x+set}" = set; then : 56012 withval=$with_x; 56013 fi 56014 56015 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 56016 if test "x$with_x" = xno; then 56017 # The user explicitly disabled X. 56018 have_x=disabled 56019 else 56020 case $x_includes,$x_libraries in #( 56021 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 56022 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 56023 $as_echo_n "(cached) " >&6 56024 else 56025 # One or both of the vars are not set, and there is no cached value. 56026 ac_x_includes=no ac_x_libraries=no 56027 rm -f -r conftest.dir 56028 if mkdir conftest.dir; then 56029 cd conftest.dir 56030 cat >Imakefile <<'_ACEOF' 56031 incroot: 56032 @echo incroot='${INCROOT}' 56033 usrlibdir: 56034 @echo usrlibdir='${USRLIBDIR}' 56035 libdir: 56036 @echo libdir='${LIBDIR}' 56037 _ACEOF 56038 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 56039 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 56040 for ac_var in incroot usrlibdir libdir; do 56041 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 56042 done 56043 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 56044 for ac_extension in a so sl dylib la dll; do 56045 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 56046 test -f "$ac_im_libdir/libX11.$ac_extension"; then 56047 ac_im_usrlibdir=$ac_im_libdir; break 56048 fi 56049 done 56050 # Screen out bogus values from the imake configuration. They are 56051 # bogus both because they are the default anyway, and because 56052 # using them would break gcc on systems where it needs fixed includes. 56053 case $ac_im_incroot in 56054 /usr/include) ac_x_includes= ;; 56055 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 56056 esac 56057 case $ac_im_usrlibdir in 56058 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 56059 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 56060 esac 56061 fi 56062 cd .. 56063 rm -f -r conftest.dir 56064 fi 56065 56066 # Standard set of common directories for X headers. 56067 # Check X11 before X11Rn because it is often a symlink to the current release. 56068 ac_x_header_dirs=' 56069 /usr/X11/include 56070 /usr/X11R7/include 56071 /usr/X11R6/include 56072 /usr/X11R5/include 56073 /usr/X11R4/include 56074 56075 /usr/include/X11 56076 /usr/include/X11R7 56077 /usr/include/X11R6 56078 /usr/include/X11R5 56079 /usr/include/X11R4 56080 56081 /usr/local/X11/include 56082 /usr/local/X11R7/include 56083 /usr/local/X11R6/include 56084 /usr/local/X11R5/include 56085 /usr/local/X11R4/include 56086 56087 /usr/local/include/X11 56088 /usr/local/include/X11R7 56089 /usr/local/include/X11R6 56090 /usr/local/include/X11R5 56091 /usr/local/include/X11R4 56092 56093 /usr/X386/include 56094 /usr/x386/include 56095 /usr/XFree86/include/X11 56096 56097 /usr/include 56098 /usr/local/include 56099 /usr/unsupported/include 56100 /usr/athena/include 56101 /usr/local/x11r5/include 56102 /usr/lpp/Xamples/include 56103 56104 /usr/openwin/include 56105 /usr/openwin/share/include' 56106 56107 if test "$ac_x_includes" = no; then 56108 # Guess where to find include files, by looking for Xlib.h. 56109 # First, try using that file with no special directory specified. 56110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56111 /* end confdefs.h. */ 56112 #include <X11/Xlib.h> 56113 _ACEOF 56114 if ac_fn_cxx_try_cpp "$LINENO"; then : 56115 # We can compile using X headers with no special include directory. 56116 ac_x_includes= 56117 else 56118 for ac_dir in $ac_x_header_dirs; do 56119 if test -r "$ac_dir/X11/Xlib.h"; then 56120 ac_x_includes=$ac_dir 56121 break 56122 fi 56123 done 56124 fi 56125 rm -f conftest.err conftest.i conftest.$ac_ext 56126 fi # $ac_x_includes = no 56127 56128 if test "$ac_x_libraries" = no; then 56129 # Check for the libraries. 56130 # See if we find them without any special options. 56131 # Don't add to $LIBS permanently. 56132 ac_save_LIBS=$LIBS 56133 LIBS="-lX11 $LIBS" 56134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56135 /* end confdefs.h. */ 56136 #include <X11/Xlib.h> 56137 int 56138 main () 56139 { 56140 XrmInitialize () 56141 ; 56142 return 0; 56143 } 56144 _ACEOF 56145 if ac_fn_cxx_try_link "$LINENO"; then : 56146 LIBS=$ac_save_LIBS 56147 # We can link X programs with no special library path. 56148 ac_x_libraries= 56149 else 56150 LIBS=$ac_save_LIBS 56151 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 56152 do 56153 # Don't even attempt the hair of trying to link an X program! 56154 for ac_extension in a so sl dylib la dll; do 56155 if test -r "$ac_dir/libX11.$ac_extension"; then 56156 ac_x_libraries=$ac_dir 56157 break 2 56158 fi 56159 done 56160 done 56161 fi 56162 rm -f core conftest.err conftest.$ac_objext \ 56163 conftest$ac_exeext conftest.$ac_ext 56164 fi # $ac_x_libraries = no 56165 56166 case $ac_x_includes,$ac_x_libraries in #( 56167 no,* | *,no | *\'*) 56168 # Didn't find X, or a directory has "'" in its name. 56169 ac_cv_have_x="have_x=no";; #( 56170 *) 56171 # Record where we found X for the cache. 56172 ac_cv_have_x="have_x=yes\ 56173 ac_x_includes='$ac_x_includes'\ 56174 ac_x_libraries='$ac_x_libraries'" 56175 esac 56176 fi 56177 ;; #( 56178 *) have_x=yes;; 56179 esac 56180 eval "$ac_cv_have_x" 56181 fi # $with_x != no 56182 56183 if test "$have_x" != yes; then 56184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 56185 $as_echo "$have_x" >&6; } 56186 no_x=yes 56187 else 56188 # If each of the values was on the command line, it overrides each guess. 56189 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 56190 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 56191 # Update the cache value to reflect the command line values. 56192 ac_cv_have_x="have_x=yes\ 56193 ac_x_includes='$x_includes'\ 56194 ac_x_libraries='$x_libraries'" 56195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 56196 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 56197 fi 56198 56199 if test "$no_x" = yes; then 56200 # Not all programs may use this symbol, but it does not hurt to define it. 56201 56202 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 56203 56204 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 56205 else 56206 if test -n "$x_includes"; then 56207 X_CFLAGS="$X_CFLAGS -I$x_includes" 56208 fi 56209 56210 # It would also be nice to do this for all -L options, not just this one. 56211 if test -n "$x_libraries"; then 56212 X_LIBS="$X_LIBS -L$x_libraries" 56213 # For Solaris; some versions of Sun CC require a space after -R and 56214 # others require no space. Words are not sufficient . . . . 56215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 56216 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 56217 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 56218 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 56219 ac_cxx_werror_flag=yes 56220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56221 /* end confdefs.h. */ 56222 56223 int 56224 main () 56225 { 56226 56227 ; 56228 return 0; 56229 } 56230 _ACEOF 56231 if ac_fn_cxx_try_link "$LINENO"; then : 56232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56233 $as_echo "no" >&6; } 56234 X_LIBS="$X_LIBS -R$x_libraries" 56235 else 56236 LIBS="$ac_xsave_LIBS -R $x_libraries" 56237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56238 /* end confdefs.h. */ 56239 56240 int 56241 main () 56242 { 56243 56244 ; 56245 return 0; 56246 } 56247 _ACEOF 56248 if ac_fn_cxx_try_link "$LINENO"; then : 56249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56250 $as_echo "yes" >&6; } 56251 X_LIBS="$X_LIBS -R $x_libraries" 56252 else 56253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 56254 $as_echo "neither works" >&6; } 56255 fi 56256 rm -f core conftest.err conftest.$ac_objext \ 56257 conftest$ac_exeext conftest.$ac_ext 56258 fi 56259 rm -f core conftest.err conftest.$ac_objext \ 56260 conftest$ac_exeext conftest.$ac_ext 56261 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 56262 LIBS=$ac_xsave_LIBS 56263 fi 56264 56265 # Check for system-dependent libraries X programs must link with. 56266 # Do this before checking for the system-independent R6 libraries 56267 # (-lICE), since we may need -lsocket or whatever for X linking. 56268 56269 if test "$ISC" = yes; then 56270 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 56271 else 56272 # Martyn Johnson says this is needed for Ultrix, if the X 56273 # libraries were built with DECnet support. And Karl Berry says 56274 # the Alpha needs dnet_stub (dnet does not exist). 56275 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 56276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56277 /* end confdefs.h. */ 56278 56279 /* Override any GCC internal prototype to avoid an error. 56280 Use char because int might match the return type of a GCC 56281 builtin and then its argument prototype would still apply. */ 56282 #ifdef __cplusplus 56283 extern "C" 56284 #endif 56285 char XOpenDisplay (); 56286 int 56287 main () 56288 { 56289 return XOpenDisplay (); 56290 ; 56291 return 0; 56292 } 56293 _ACEOF 56294 if ac_fn_cxx_try_link "$LINENO"; then : 56295 56296 else 56297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 56298 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 56299 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 56300 $as_echo_n "(cached) " >&6 56301 else 56302 ac_check_lib_save_LIBS=$LIBS 56303 LIBS="-ldnet $LIBS" 56304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56305 /* end confdefs.h. */ 56306 56307 /* Override any GCC internal prototype to avoid an error. 56308 Use char because int might match the return type of a GCC 56309 builtin and then its argument prototype would still apply. */ 56310 #ifdef __cplusplus 56311 extern "C" 56312 #endif 56313 char dnet_ntoa (); 56314 int 56315 main () 56316 { 56317 return dnet_ntoa (); 56318 ; 56319 return 0; 56320 } 56321 _ACEOF 56322 if ac_fn_cxx_try_link "$LINENO"; then : 56323 ac_cv_lib_dnet_dnet_ntoa=yes 56324 else 56325 ac_cv_lib_dnet_dnet_ntoa=no 56326 fi 56327 rm -f core conftest.err conftest.$ac_objext \ 56328 conftest$ac_exeext conftest.$ac_ext 56329 LIBS=$ac_check_lib_save_LIBS 56330 fi 56331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 56332 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 56333 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 56334 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 56335 fi 56336 56337 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 56338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 56339 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 56340 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 56341 $as_echo_n "(cached) " >&6 56342 else 56343 ac_check_lib_save_LIBS=$LIBS 56344 LIBS="-ldnet_stub $LIBS" 56345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56346 /* end confdefs.h. */ 56347 56348 /* Override any GCC internal prototype to avoid an error. 56349 Use char because int might match the return type of a GCC 56350 builtin and then its argument prototype would still apply. */ 56351 #ifdef __cplusplus 56352 extern "C" 56353 #endif 56354 char dnet_ntoa (); 56355 int 56356 main () 56357 { 56358 return dnet_ntoa (); 56359 ; 56360 return 0; 56361 } 56362 _ACEOF 56363 if ac_fn_cxx_try_link "$LINENO"; then : 56364 ac_cv_lib_dnet_stub_dnet_ntoa=yes 56365 else 56366 ac_cv_lib_dnet_stub_dnet_ntoa=no 56367 fi 56368 rm -f core conftest.err conftest.$ac_objext \ 56369 conftest$ac_exeext conftest.$ac_ext 56370 LIBS=$ac_check_lib_save_LIBS 56371 fi 56372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 56373 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 56374 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 56375 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 56376 fi 56377 56378 fi 56379 fi 56380 rm -f core conftest.err conftest.$ac_objext \ 56381 conftest$ac_exeext conftest.$ac_ext 56382 LIBS="$ac_xsave_LIBS" 56383 56384 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 56385 # to get the SysV transport functions. 56386 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 56387 # needs -lnsl. 56388 # The nsl library prevents programs from opening the X display 56389 # on Irix 5.2, according to T.E. Dickey. 56390 # The functions gethostbyname, getservbyname, and inet_addr are 56391 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 56392 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 56393 if test "x$ac_cv_func_gethostbyname" = xyes; then : 56394 56395 fi 56396 56397 if test $ac_cv_func_gethostbyname = no; then 56398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 56399 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 56400 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 56401 $as_echo_n "(cached) " >&6 56402 else 56403 ac_check_lib_save_LIBS=$LIBS 56404 LIBS="-lnsl $LIBS" 56405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56406 /* end confdefs.h. */ 56407 56408 /* Override any GCC internal prototype to avoid an error. 56409 Use char because int might match the return type of a GCC 56410 builtin and then its argument prototype would still apply. */ 56411 #ifdef __cplusplus 56412 extern "C" 56413 #endif 56414 char gethostbyname (); 56415 int 56416 main () 56417 { 56418 return gethostbyname (); 56419 ; 56420 return 0; 56421 } 56422 _ACEOF 56423 if ac_fn_cxx_try_link "$LINENO"; then : 56424 ac_cv_lib_nsl_gethostbyname=yes 56425 else 56426 ac_cv_lib_nsl_gethostbyname=no 56427 fi 56428 rm -f core conftest.err conftest.$ac_objext \ 56429 conftest$ac_exeext conftest.$ac_ext 56430 LIBS=$ac_check_lib_save_LIBS 56431 fi 56432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 56433 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 56434 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 56435 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 56436 fi 56437 56438 if test $ac_cv_lib_nsl_gethostbyname = no; then 56439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 56440 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 56441 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 56442 $as_echo_n "(cached) " >&6 56443 else 56444 ac_check_lib_save_LIBS=$LIBS 56445 LIBS="-lbsd $LIBS" 56446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56447 /* end confdefs.h. */ 56448 56449 /* Override any GCC internal prototype to avoid an error. 56450 Use char because int might match the return type of a GCC 56451 builtin and then its argument prototype would still apply. */ 56452 #ifdef __cplusplus 56453 extern "C" 56454 #endif 56455 char gethostbyname (); 56456 int 56457 main () 56458 { 56459 return gethostbyname (); 56460 ; 56461 return 0; 56462 } 56463 _ACEOF 56464 if ac_fn_cxx_try_link "$LINENO"; then : 56465 ac_cv_lib_bsd_gethostbyname=yes 56466 else 56467 ac_cv_lib_bsd_gethostbyname=no 56468 fi 56469 rm -f core conftest.err conftest.$ac_objext \ 56470 conftest$ac_exeext conftest.$ac_ext 56471 LIBS=$ac_check_lib_save_LIBS 56472 fi 56473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 56474 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 56475 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 56476 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 56477 fi 56478 56479 fi 56480 fi 56481 56482 # lieder@skyler.mavd.honeywell.com says without -lsocket, 56483 # socket/setsockopt and other routines are undefined under SCO ODT 56484 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 56485 # on later versions), says Simon Leinen: it contains gethostby* 56486 # variants that don't use the name server (or something). -lsocket 56487 # must be given before -lnsl if both are needed. We assume that 56488 # if connect needs -lnsl, so does gethostbyname. 56489 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 56490 if test "x$ac_cv_func_connect" = xyes; then : 56491 56492 fi 56493 56494 if test $ac_cv_func_connect = no; then 56495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 56496 $as_echo_n "checking for connect in -lsocket... " >&6; } 56497 if ${ac_cv_lib_socket_connect+:} false; then : 56498 $as_echo_n "(cached) " >&6 56499 else 56500 ac_check_lib_save_LIBS=$LIBS 56501 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 56502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56503 /* end confdefs.h. */ 56504 56505 /* Override any GCC internal prototype to avoid an error. 56506 Use char because int might match the return type of a GCC 56507 builtin and then its argument prototype would still apply. */ 56508 #ifdef __cplusplus 56509 extern "C" 56510 #endif 56511 char connect (); 56512 int 56513 main () 56514 { 56515 return connect (); 56516 ; 56517 return 0; 56518 } 56519 _ACEOF 56520 if ac_fn_cxx_try_link "$LINENO"; then : 56521 ac_cv_lib_socket_connect=yes 56522 else 56523 ac_cv_lib_socket_connect=no 56524 fi 56525 rm -f core conftest.err conftest.$ac_objext \ 56526 conftest$ac_exeext conftest.$ac_ext 56527 LIBS=$ac_check_lib_save_LIBS 56528 fi 56529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 56530 $as_echo "$ac_cv_lib_socket_connect" >&6; } 56531 if test "x$ac_cv_lib_socket_connect" = xyes; then : 56532 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 56533 fi 56534 56535 fi 56536 56537 # Guillermo Gomez says -lposix is necessary on A/UX. 56538 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 56539 if test "x$ac_cv_func_remove" = xyes; then : 56540 56541 fi 56542 56543 if test $ac_cv_func_remove = no; then 56544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 56545 $as_echo_n "checking for remove in -lposix... " >&6; } 56546 if ${ac_cv_lib_posix_remove+:} false; then : 56547 $as_echo_n "(cached) " >&6 56548 else 56549 ac_check_lib_save_LIBS=$LIBS 56550 LIBS="-lposix $LIBS" 56551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56552 /* end confdefs.h. */ 56553 56554 /* Override any GCC internal prototype to avoid an error. 56555 Use char because int might match the return type of a GCC 56556 builtin and then its argument prototype would still apply. */ 56557 #ifdef __cplusplus 56558 extern "C" 56559 #endif 56560 char remove (); 56561 int 56562 main () 56563 { 56564 return remove (); 56565 ; 56566 return 0; 56567 } 56568 _ACEOF 56569 if ac_fn_cxx_try_link "$LINENO"; then : 56570 ac_cv_lib_posix_remove=yes 56571 else 56572 ac_cv_lib_posix_remove=no 56573 fi 56574 rm -f core conftest.err conftest.$ac_objext \ 56575 conftest$ac_exeext conftest.$ac_ext 56576 LIBS=$ac_check_lib_save_LIBS 56577 fi 56578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 56579 $as_echo "$ac_cv_lib_posix_remove" >&6; } 56580 if test "x$ac_cv_lib_posix_remove" = xyes; then : 56581 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 56582 fi 56583 56584 fi 56585 56586 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 56587 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 56588 if test "x$ac_cv_func_shmat" = xyes; then : 56589 56590 fi 56591 56592 if test $ac_cv_func_shmat = no; then 56593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 56594 $as_echo_n "checking for shmat in -lipc... " >&6; } 56595 if ${ac_cv_lib_ipc_shmat+:} false; then : 56596 $as_echo_n "(cached) " >&6 56597 else 56598 ac_check_lib_save_LIBS=$LIBS 56599 LIBS="-lipc $LIBS" 56600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56601 /* end confdefs.h. */ 56602 56603 /* Override any GCC internal prototype to avoid an error. 56604 Use char because int might match the return type of a GCC 56605 builtin and then its argument prototype would still apply. */ 56606 #ifdef __cplusplus 56607 extern "C" 56608 #endif 56609 char shmat (); 56610 int 56611 main () 56612 { 56613 return shmat (); 56614 ; 56615 return 0; 56616 } 56617 _ACEOF 56618 if ac_fn_cxx_try_link "$LINENO"; then : 56619 ac_cv_lib_ipc_shmat=yes 56620 else 56621 ac_cv_lib_ipc_shmat=no 56622 fi 56623 rm -f core conftest.err conftest.$ac_objext \ 56624 conftest$ac_exeext conftest.$ac_ext 56625 LIBS=$ac_check_lib_save_LIBS 56626 fi 56627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 56628 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 56629 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 56630 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 56631 fi 56632 56633 fi 56634 fi 56635 56636 # Check for libraries that X11R6 Xt/Xaw programs need. 56637 ac_save_LDFLAGS=$LDFLAGS 56638 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 56639 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 56640 # check for ICE first), but we must link in the order -lSM -lICE or 56641 # we get undefined symbols. So assume we have SM if we have ICE. 56642 # These have to be linked with before -lX11, unlike the other 56643 # libraries we check for below, so use a different variable. 56644 # John Interrante, Karl Berry 56645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 56646 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 56647 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 56648 $as_echo_n "(cached) " >&6 56649 else 56650 ac_check_lib_save_LIBS=$LIBS 56651 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 56652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56653 /* end confdefs.h. */ 56654 56655 /* Override any GCC internal prototype to avoid an error. 56656 Use char because int might match the return type of a GCC 56657 builtin and then its argument prototype would still apply. */ 56658 #ifdef __cplusplus 56659 extern "C" 56660 #endif 56661 char IceConnectionNumber (); 56662 int 56663 main () 56664 { 56665 return IceConnectionNumber (); 56666 ; 56667 return 0; 56668 } 56669 _ACEOF 56670 if ac_fn_cxx_try_link "$LINENO"; then : 56671 ac_cv_lib_ICE_IceConnectionNumber=yes 56672 else 56673 ac_cv_lib_ICE_IceConnectionNumber=no 56674 fi 56675 rm -f core conftest.err conftest.$ac_objext \ 56676 conftest$ac_exeext conftest.$ac_ext 56677 LIBS=$ac_check_lib_save_LIBS 56678 fi 56679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 56680 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 56681 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 56682 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 56683 fi 56684 56685 LDFLAGS=$ac_save_LDFLAGS 56686 56687 fi 56688 56689 56690 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 56691 # this doesn't make sense so we remove it. 56692 if test "x$COMPILE_TYPE" = xcross; then 56693 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 56694 fi 56695 56696 if test "x$no_x" = xyes; then 56697 56698 # Print a helpful message on how to acquire the necessary build dependency. 56699 # x11 is the help tag: freetype, cups, alsa etc 56700 MISSING_DEPENDENCY=x11 56701 56702 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56703 cygwin_help $MISSING_DEPENDENCY 56704 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56705 msys_help $MISSING_DEPENDENCY 56706 else 56707 PKGHANDLER_COMMAND= 56708 56709 case $PKGHANDLER in 56710 apt-get) 56711 apt_help $MISSING_DEPENDENCY ;; 56712 yum) 56713 yum_help $MISSING_DEPENDENCY ;; 56714 port) 56715 port_help $MISSING_DEPENDENCY ;; 56716 pkgutil) 56717 pkgutil_help $MISSING_DEPENDENCY ;; 56718 pkgadd) 56719 pkgadd_help $MISSING_DEPENDENCY ;; 56720 esac 56721 56722 if test "x$PKGHANDLER_COMMAND" != x; then 56723 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56724 fi 56725 fi 56726 56727 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 56728 fi 56729 56730 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 56731 OPENWIN_HOME="/usr/openwin" 56732 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 56733 X_LIBS="-L$SYSROOT$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \ 56734 -L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 56735 -R$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \ 56736 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 56737 fi 56738 56739 ac_ext=c 56740 ac_cpp='$CPP $CPPFLAGS' 56741 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56742 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56743 ac_compiler_gnu=$ac_cv_c_compiler_gnu 56744 56745 OLD_CFLAGS="$CFLAGS" 56746 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 56747 56748 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 56749 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 56750 do : 56751 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56752 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 56753 # include <X11/Xlib.h> 56754 # include <X11/Xutil.h> 56755 56756 56757 " 56758 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56759 cat >>confdefs.h <<_ACEOF 56760 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56761 _ACEOF 56762 X11_HEADERS_OK=yes 56763 else 56764 X11_HEADERS_OK=no; break 56765 fi 56766 56767 done 56768 56769 56770 if test "x$X11_HEADERS_OK" = xno; then 56771 56772 # Print a helpful message on how to acquire the necessary build dependency. 56773 # x11 is the help tag: freetype, cups, alsa etc 56774 MISSING_DEPENDENCY=x11 56775 56776 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56777 cygwin_help $MISSING_DEPENDENCY 56778 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56779 msys_help $MISSING_DEPENDENCY 56780 else 56781 PKGHANDLER_COMMAND= 56782 56783 case $PKGHANDLER in 56784 apt-get) 56785 apt_help $MISSING_DEPENDENCY ;; 56786 yum) 56787 yum_help $MISSING_DEPENDENCY ;; 56788 port) 56789 port_help $MISSING_DEPENDENCY ;; 56790 pkgutil) 56791 pkgutil_help $MISSING_DEPENDENCY ;; 56792 pkgadd) 56793 pkgadd_help $MISSING_DEPENDENCY ;; 56794 esac 56795 56796 if test "x$PKGHANDLER_COMMAND" != x; then 56797 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56798 fi 56799 fi 56800 56801 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 56802 fi 56803 56804 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 56805 # defined in libawt_xawt. 56806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 56807 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 56808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56809 /* end confdefs.h. */ 56810 #include <X11/extensions/Xrender.h> 56811 int 56812 main () 56813 { 56814 XLinearGradient x; 56815 ; 56816 return 0; 56817 } 56818 _ACEOF 56819 if ac_fn_c_try_compile "$LINENO"; then : 56820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56821 $as_echo "yes" >&6; } 56822 else 56823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56824 $as_echo "no" >&6; } 56825 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 56826 fi 56827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 56828 56829 CFLAGS="$OLD_CFLAGS" 56830 ac_ext=cpp 56831 ac_cpp='$CXXCPP $CPPFLAGS' 56832 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56833 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56834 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 56835 56836 fi # NEEDS_LIB_X11 56837 56838 56839 56840 56841 56842 56843 # Check whether --with-cups was given. 56844 if test "${with_cups+set}" = set; then : 56845 withval=$with_cups; 56846 fi 56847 56848 56849 # Check whether --with-cups-include was given. 56850 if test "${with_cups_include+set}" = set; then : 56851 withval=$with_cups_include; 56852 fi 56853 56854 56855 if test "x$NEEDS_LIB_CUPS" = xfalse; then 56856 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 56857 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 56858 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 56859 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 56860 fi 56861 CUPS_CFLAGS= 56862 else 56863 CUPS_FOUND=no 56864 56865 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 56866 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 56867 fi 56868 56869 if test "x${with_cups}" != x; then 56870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56871 $as_echo_n "checking for cups headers... " >&6; } 56872 if test -s "${with_cups}/include/cups/cups.h"; then 56873 CUPS_CFLAGS="-I${with_cups}/include" 56874 CUPS_FOUND=yes 56875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56876 $as_echo "$CUPS_FOUND" >&6; } 56877 else 56878 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 56879 fi 56880 fi 56881 if test "x${with_cups_include}" != x; then 56882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56883 $as_echo_n "checking for cups headers... " >&6; } 56884 if test -s "${with_cups_include}/cups/cups.h"; then 56885 CUPS_CFLAGS="-I${with_cups_include}" 56886 CUPS_FOUND=yes 56887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56888 $as_echo "$CUPS_FOUND" >&6; } 56889 else 56890 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 56891 fi 56892 fi 56893 if test "x$CUPS_FOUND" = xno; then 56894 # Are the cups headers installed in the default /usr/include location? 56895 for ac_header in cups/cups.h cups/ppd.h 56896 do : 56897 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56898 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 56899 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56900 cat >>confdefs.h <<_ACEOF 56901 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56902 _ACEOF 56903 56904 CUPS_FOUND=yes 56905 CUPS_CFLAGS= 56906 DEFAULT_CUPS=yes 56907 56908 fi 56909 56910 done 56911 56912 fi 56913 if test "x$CUPS_FOUND" = xno; then 56914 # Getting nervous now? Lets poke around for standard Solaris third-party 56915 # package installation locations. 56916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56917 $as_echo_n "checking for cups headers... " >&6; } 56918 if test -s $SYSROOT/opt/sfw/cups/include/cups/cups.h; then 56919 # An SFW package seems to be installed! 56920 CUPS_FOUND=yes 56921 CUPS_CFLAGS="-I$SYSROOT/opt/sfw/cups/include" 56922 elif test -s $SYSROOT/opt/csw/include/cups/cups.h; then 56923 # A CSW package seems to be installed! 56924 CUPS_FOUND=yes 56925 CUPS_CFLAGS="-I$SYSROOT/opt/csw/include" 56926 fi 56927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56928 $as_echo "$CUPS_FOUND" >&6; } 56929 fi 56930 if test "x$CUPS_FOUND" = xno; then 56931 56932 # Print a helpful message on how to acquire the necessary build dependency. 56933 # cups is the help tag: freetype, cups, alsa etc 56934 MISSING_DEPENDENCY=cups 56935 56936 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56937 cygwin_help $MISSING_DEPENDENCY 56938 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56939 msys_help $MISSING_DEPENDENCY 56940 else 56941 PKGHANDLER_COMMAND= 56942 56943 case $PKGHANDLER in 56944 apt-get) 56945 apt_help $MISSING_DEPENDENCY ;; 56946 yum) 56947 yum_help $MISSING_DEPENDENCY ;; 56948 port) 56949 port_help $MISSING_DEPENDENCY ;; 56950 pkgutil) 56951 pkgutil_help $MISSING_DEPENDENCY ;; 56952 pkgadd) 56953 pkgadd_help $MISSING_DEPENDENCY ;; 56954 esac 56955 56956 if test "x$PKGHANDLER_COMMAND" != x; then 56957 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56958 fi 56959 fi 56960 56961 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 56962 fi 56963 fi 56964 56965 56966 56967 56968 56969 # Check whether --with-freetype was given. 56970 if test "${with_freetype+set}" = set; then : 56971 withval=$with_freetype; 56972 fi 56973 56974 56975 # Check whether --with-freetype-include was given. 56976 if test "${with_freetype_include+set}" = set; then : 56977 withval=$with_freetype_include; 56978 fi 56979 56980 56981 # Check whether --with-freetype-lib was given. 56982 if test "${with_freetype_lib+set}" = set; then : 56983 withval=$with_freetype_lib; 56984 fi 56985 56986 56987 # Check whether --with-freetype-src was given. 56988 if test "${with_freetype_src+set}" = set; then : 56989 withval=$with_freetype_src; 56990 fi 56991 56992 # Check whether --enable-freetype-bundling was given. 56993 if test "${enable_freetype_bundling+set}" = set; then : 56994 enableval=$enable_freetype_bundling; 56995 fi 56996 56997 56998 # Need to specify explicitly since it needs to be overridden on some versions of macosx 56999 FREETYPE_BASE_NAME=freetype 57000 FREETYPE_CFLAGS= 57001 FREETYPE_LIBS= 57002 FREETYPE_BUNDLE_LIB_PATH= 57003 57004 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 57005 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 57006 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 57007 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 57008 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 57009 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 57010 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 57011 fi 57012 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 57013 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 57014 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 57015 fi 57016 else 57017 # freetype is needed to build; go get it! 57018 57019 BUNDLE_FREETYPE="$enable_freetype_bundling" 57020 57021 if test "x$with_freetype_src" != x; then 57022 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57023 # Try to build freetype if --with-freetype-src was given on Windows 57024 57025 FREETYPE_SRC_PATH="$with_freetype_src" 57026 BUILD_FREETYPE=yes 57027 57028 # Check if the freetype sources are acessible.. 57029 if ! test -d $FREETYPE_SRC_PATH; then 57030 { $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 57031 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 57032 BUILD_FREETYPE=no 57033 fi 57034 # ..and contain a vc2010 project file 57035 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 57036 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 57037 { $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 57038 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 57039 BUILD_FREETYPE=no 57040 fi 57041 # Now check if configure found a version of 'msbuild.exe' 57042 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 57043 { $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 57044 $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;} 57045 BUILD_FREETYPE=no 57046 fi 57047 57048 # Ready to go.. 57049 if test "x$BUILD_FREETYPE" = xyes; then 57050 # msbuild requires trailing slashes for output directories 57051 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 57052 freetype_lib_path_unix="$freetype_lib_path" 57053 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 57054 57055 unix_path="$vcxproj_path" 57056 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57057 windows_path=`$CYGPATH -m "$unix_path"` 57058 vcxproj_path="$windows_path" 57059 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57060 windows_path=`cmd //c echo $unix_path` 57061 vcxproj_path="$windows_path" 57062 fi 57063 57064 57065 unix_path="$freetype_lib_path" 57066 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57067 windows_path=`$CYGPATH -m "$unix_path"` 57068 freetype_lib_path="$windows_path" 57069 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57070 windows_path=`cmd //c echo $unix_path` 57071 freetype_lib_path="$windows_path" 57072 fi 57073 57074 57075 unix_path="$freetype_obj_path" 57076 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57077 windows_path=`$CYGPATH -m "$unix_path"` 57078 freetype_obj_path="$windows_path" 57079 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57080 windows_path=`cmd //c echo $unix_path` 57081 freetype_obj_path="$windows_path" 57082 fi 57083 57084 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57085 freetype_platform=x64 57086 else 57087 freetype_platform=win32 57088 fi 57089 57090 # The original freetype project file is for VS 2010 (i.e. 'v100'), 57091 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 57092 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 57093 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 57094 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 57095 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 57096 57097 # First we try to build the freetype.dll 57098 $ECHO -e "@echo off\n"\ 57099 "$MSBUILD $vcxproj_path "\ 57100 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57101 "/p:Configuration=\"Release Multithreaded\" "\ 57102 "/p:Platform=$freetype_platform "\ 57103 "/p:ConfigurationType=DynamicLibrary "\ 57104 "/p:TargetName=freetype "\ 57105 "/p:OutDir=\"$freetype_lib_path\" "\ 57106 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 57107 cmd /c freetype.bat 57108 57109 if test -s "$freetype_lib_path_unix/freetype.dll"; then 57110 # If that succeeds we also build freetype.lib 57111 $ECHO -e "@echo off\n"\ 57112 "$MSBUILD $vcxproj_path "\ 57113 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57114 "/p:Configuration=\"Release Multithreaded\" "\ 57115 "/p:Platform=$freetype_platform "\ 57116 "/p:ConfigurationType=StaticLibrary "\ 57117 "/p:TargetName=freetype "\ 57118 "/p:OutDir=\"$freetype_lib_path\" "\ 57119 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 57120 cmd /c freetype.bat 57121 57122 if test -s "$freetype_lib_path_unix/freetype.lib"; then 57123 # Once we build both, lib and dll, set freetype lib and include path appropriately 57124 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 57125 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 57126 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 57127 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 57128 else 57129 BUILD_FREETYPE=no 57130 fi 57131 else 57132 BUILD_FREETYPE=no 57133 fi 57134 fi 57135 57136 if test "x$BUILD_FREETYPE" = xyes; then 57137 # Okay, we built it. Check that it works. 57138 57139 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57140 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57141 METHOD="--with-freetype-src" 57142 57143 # Let's start with an optimistic view of the world :-) 57144 FOUND_FREETYPE=yes 57145 57146 # First look for the canonical freetype main include file ft2build.h. 57147 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57148 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57149 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57150 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57151 # Fail. 57152 FOUND_FREETYPE=no 57153 fi 57154 fi 57155 57156 if test "x$FOUND_FREETYPE" = xyes; then 57157 # Include file found, let's continue the sanity check. 57158 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57159 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57160 57161 # Reset to default value 57162 FREETYPE_BASE_NAME=freetype 57163 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57164 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57165 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57166 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57167 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57168 # for the .6 version explicitly. 57169 FREETYPE_BASE_NAME=freetype.6 57170 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57171 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57172 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57173 else 57174 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57175 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57176 FOUND_FREETYPE=no 57177 fi 57178 else 57179 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57180 # On Windows, we will need both .lib and .dll file. 57181 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57182 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57183 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57184 FOUND_FREETYPE=no 57185 fi 57186 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57187 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57188 # Found lib in isa dir, use that instead. 57189 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57190 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57191 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57192 fi 57193 fi 57194 fi 57195 57196 if test "x$FOUND_FREETYPE" = xyes; then 57197 57198 # Only process if variable expands to non-empty 57199 57200 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57201 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57202 57203 # Input might be given as Windows format, start by converting to 57204 # unix format. 57205 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57206 new_path=`$CYGPATH -u "$path"` 57207 57208 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57209 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57210 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57211 # "foo.exe" is OK but "foo" is an error. 57212 # 57213 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57214 # It is also a way to make sure we got the proper file name for the real test later on. 57215 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57216 if test "x$test_shortpath" = x; then 57217 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57218 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57219 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57220 fi 57221 57222 # Call helper function which possibly converts this using DOS-style short mode. 57223 # If so, the updated path is stored in $new_path. 57224 57225 input_path="$new_path" 57226 # Check if we need to convert this using DOS-style short mode. If the path 57227 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57228 # take no chances and rewrite it. 57229 # Note: m4 eats our [], so we need to use [ and ] instead. 57230 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57231 if test "x$has_forbidden_chars" != x; then 57232 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57233 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57234 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57235 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57236 # Going to short mode and back again did indeed matter. Since short mode is 57237 # case insensitive, let's make it lowercase to improve readability. 57238 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57239 # Now convert it back to Unix-style (cygpath) 57240 input_path=`$CYGPATH -u "$shortmode_path"` 57241 new_path="$input_path" 57242 fi 57243 fi 57244 57245 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57246 if test "x$test_cygdrive_prefix" = x; then 57247 # As a simple fix, exclude /usr/bin since it's not a real path. 57248 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57249 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57250 # a path prefixed by /cygdrive for fixpath to work. 57251 new_path="$CYGWIN_ROOT_PATH$input_path" 57252 fi 57253 fi 57254 57255 57256 if test "x$path" != "x$new_path"; then 57257 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57258 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57259 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57260 fi 57261 57262 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57263 57264 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57265 has_colon=`$ECHO $path | $GREP ^.:` 57266 new_path="$path" 57267 if test "x$has_colon" = x; then 57268 # Not in mixed or Windows style, start by that. 57269 new_path=`cmd //c echo $path` 57270 fi 57271 57272 57273 input_path="$new_path" 57274 # Check if we need to convert this using DOS-style short mode. If the path 57275 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57276 # take no chances and rewrite it. 57277 # Note: m4 eats our [], so we need to use [ and ] instead. 57278 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57279 if test "x$has_forbidden_chars" != x; then 57280 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57281 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57282 fi 57283 57284 57285 windows_path="$new_path" 57286 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57287 unix_path=`$CYGPATH -u "$windows_path"` 57288 new_path="$unix_path" 57289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57290 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57291 new_path="$unix_path" 57292 fi 57293 57294 if test "x$path" != "x$new_path"; then 57295 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57296 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57297 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57298 fi 57299 57300 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57301 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57302 57303 else 57304 # We're on a unix platform. Hooray! :) 57305 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57306 has_space=`$ECHO "$path" | $GREP " "` 57307 if test "x$has_space" != x; then 57308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57309 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57310 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57311 fi 57312 57313 # Use eval to expand a potential ~ 57314 eval path="$path" 57315 if test ! -f "$path" && test ! -d "$path"; then 57316 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57317 fi 57318 57319 if test -d "$path"; then 57320 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57321 else 57322 dir="`$DIRNAME "$path"`" 57323 base="`$BASENAME "$path"`" 57324 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57325 fi 57326 fi 57327 fi 57328 57329 57330 # Only process if variable expands to non-empty 57331 57332 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57334 57335 # Input might be given as Windows format, start by converting to 57336 # unix format. 57337 path="$POTENTIAL_FREETYPE_LIB_PATH" 57338 new_path=`$CYGPATH -u "$path"` 57339 57340 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57341 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57342 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57343 # "foo.exe" is OK but "foo" is an error. 57344 # 57345 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57346 # It is also a way to make sure we got the proper file name for the real test later on. 57347 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57348 if test "x$test_shortpath" = x; then 57349 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57350 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57351 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57352 fi 57353 57354 # Call helper function which possibly converts this using DOS-style short mode. 57355 # If so, the updated path is stored in $new_path. 57356 57357 input_path="$new_path" 57358 # Check if we need to convert this using DOS-style short mode. If the path 57359 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57360 # take no chances and rewrite it. 57361 # Note: m4 eats our [], so we need to use [ and ] instead. 57362 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57363 if test "x$has_forbidden_chars" != x; then 57364 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57365 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57366 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57367 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57368 # Going to short mode and back again did indeed matter. Since short mode is 57369 # case insensitive, let's make it lowercase to improve readability. 57370 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57371 # Now convert it back to Unix-style (cygpath) 57372 input_path=`$CYGPATH -u "$shortmode_path"` 57373 new_path="$input_path" 57374 fi 57375 fi 57376 57377 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57378 if test "x$test_cygdrive_prefix" = x; then 57379 # As a simple fix, exclude /usr/bin since it's not a real path. 57380 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57381 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57382 # a path prefixed by /cygdrive for fixpath to work. 57383 new_path="$CYGWIN_ROOT_PATH$input_path" 57384 fi 57385 fi 57386 57387 57388 if test "x$path" != "x$new_path"; then 57389 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57390 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57391 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57392 fi 57393 57394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57395 57396 path="$POTENTIAL_FREETYPE_LIB_PATH" 57397 has_colon=`$ECHO $path | $GREP ^.:` 57398 new_path="$path" 57399 if test "x$has_colon" = x; then 57400 # Not in mixed or Windows style, start by that. 57401 new_path=`cmd //c echo $path` 57402 fi 57403 57404 57405 input_path="$new_path" 57406 # Check if we need to convert this using DOS-style short mode. If the path 57407 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57408 # take no chances and rewrite it. 57409 # Note: m4 eats our [], so we need to use [ and ] instead. 57410 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57411 if test "x$has_forbidden_chars" != x; then 57412 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57413 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57414 fi 57415 57416 57417 windows_path="$new_path" 57418 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57419 unix_path=`$CYGPATH -u "$windows_path"` 57420 new_path="$unix_path" 57421 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57422 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57423 new_path="$unix_path" 57424 fi 57425 57426 if test "x$path" != "x$new_path"; then 57427 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57428 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57429 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57430 fi 57431 57432 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57433 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57434 57435 else 57436 # We're on a unix platform. Hooray! :) 57437 path="$POTENTIAL_FREETYPE_LIB_PATH" 57438 has_space=`$ECHO "$path" | $GREP " "` 57439 if test "x$has_space" != x; then 57440 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57441 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57442 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57443 fi 57444 57445 # Use eval to expand a potential ~ 57446 eval path="$path" 57447 if test ! -f "$path" && test ! -d "$path"; then 57448 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57449 fi 57450 57451 if test -d "$path"; then 57452 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57453 else 57454 dir="`$DIRNAME "$path"`" 57455 base="`$BASENAME "$path"`" 57456 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57457 fi 57458 fi 57459 fi 57460 57461 57462 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57464 $as_echo_n "checking for freetype includes... " >&6; } 57465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57466 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57467 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57469 $as_echo_n "checking for freetype libraries... " >&6; } 57470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57471 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57472 fi 57473 57474 if test "x$FOUND_FREETYPE" != xyes; then 57475 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 57476 fi 57477 else 57478 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 57479 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 57480 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 57481 fi 57482 else 57483 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 57484 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 57485 fi 57486 fi 57487 57488 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 57489 # User has specified settings 57490 57491 if test "x$BUNDLE_FREETYPE" = x; then 57492 # If not specified, default is to bundle freetype 57493 BUNDLE_FREETYPE=yes 57494 fi 57495 57496 if test "x$with_freetype" != x; then 57497 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 57498 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 57499 fi 57500 57501 # Allow --with-freetype-lib and --with-freetype-include to override 57502 if test "x$with_freetype_include" != x; then 57503 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 57504 fi 57505 if test "x$with_freetype_lib" != x; then 57506 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 57507 fi 57508 57509 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57510 # Okay, we got it. Check that it works. 57511 57512 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57513 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57514 METHOD="--with-freetype" 57515 57516 # Let's start with an optimistic view of the world :-) 57517 FOUND_FREETYPE=yes 57518 57519 # First look for the canonical freetype main include file ft2build.h. 57520 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57521 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57522 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57523 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57524 # Fail. 57525 FOUND_FREETYPE=no 57526 fi 57527 fi 57528 57529 if test "x$FOUND_FREETYPE" = xyes; then 57530 # Include file found, let's continue the sanity check. 57531 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57532 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57533 57534 # Reset to default value 57535 FREETYPE_BASE_NAME=freetype 57536 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57537 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57538 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57539 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57540 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57541 # for the .6 version explicitly. 57542 FREETYPE_BASE_NAME=freetype.6 57543 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57544 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57545 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57546 else 57547 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57548 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57549 FOUND_FREETYPE=no 57550 fi 57551 else 57552 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57553 # On Windows, we will need both .lib and .dll file. 57554 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57555 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57556 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57557 FOUND_FREETYPE=no 57558 fi 57559 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57560 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57561 # Found lib in isa dir, use that instead. 57562 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57563 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57564 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57565 fi 57566 fi 57567 fi 57568 57569 if test "x$FOUND_FREETYPE" = xyes; then 57570 57571 # Only process if variable expands to non-empty 57572 57573 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57574 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57575 57576 # Input might be given as Windows format, start by converting to 57577 # unix format. 57578 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57579 new_path=`$CYGPATH -u "$path"` 57580 57581 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57582 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57583 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57584 # "foo.exe" is OK but "foo" is an error. 57585 # 57586 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57587 # It is also a way to make sure we got the proper file name for the real test later on. 57588 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57589 if test "x$test_shortpath" = x; then 57590 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57591 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57592 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57593 fi 57594 57595 # Call helper function which possibly converts this using DOS-style short mode. 57596 # If so, the updated path is stored in $new_path. 57597 57598 input_path="$new_path" 57599 # Check if we need to convert this using DOS-style short mode. If the path 57600 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57601 # take no chances and rewrite it. 57602 # Note: m4 eats our [], so we need to use [ and ] instead. 57603 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57604 if test "x$has_forbidden_chars" != x; then 57605 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57606 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57607 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57608 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57609 # Going to short mode and back again did indeed matter. Since short mode is 57610 # case insensitive, let's make it lowercase to improve readability. 57611 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57612 # Now convert it back to Unix-style (cygpath) 57613 input_path=`$CYGPATH -u "$shortmode_path"` 57614 new_path="$input_path" 57615 fi 57616 fi 57617 57618 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57619 if test "x$test_cygdrive_prefix" = x; then 57620 # As a simple fix, exclude /usr/bin since it's not a real path. 57621 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57622 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57623 # a path prefixed by /cygdrive for fixpath to work. 57624 new_path="$CYGWIN_ROOT_PATH$input_path" 57625 fi 57626 fi 57627 57628 57629 if test "x$path" != "x$new_path"; then 57630 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57631 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57632 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57633 fi 57634 57635 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57636 57637 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57638 has_colon=`$ECHO $path | $GREP ^.:` 57639 new_path="$path" 57640 if test "x$has_colon" = x; then 57641 # Not in mixed or Windows style, start by that. 57642 new_path=`cmd //c echo $path` 57643 fi 57644 57645 57646 input_path="$new_path" 57647 # Check if we need to convert this using DOS-style short mode. If the path 57648 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57649 # take no chances and rewrite it. 57650 # Note: m4 eats our [], so we need to use [ and ] instead. 57651 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57652 if test "x$has_forbidden_chars" != x; then 57653 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57654 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57655 fi 57656 57657 57658 windows_path="$new_path" 57659 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57660 unix_path=`$CYGPATH -u "$windows_path"` 57661 new_path="$unix_path" 57662 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57663 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57664 new_path="$unix_path" 57665 fi 57666 57667 if test "x$path" != "x$new_path"; then 57668 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57669 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57670 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57671 fi 57672 57673 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57674 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57675 57676 else 57677 # We're on a unix platform. Hooray! :) 57678 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57679 has_space=`$ECHO "$path" | $GREP " "` 57680 if test "x$has_space" != x; then 57681 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57682 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57683 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57684 fi 57685 57686 # Use eval to expand a potential ~ 57687 eval path="$path" 57688 if test ! -f "$path" && test ! -d "$path"; then 57689 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57690 fi 57691 57692 if test -d "$path"; then 57693 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57694 else 57695 dir="`$DIRNAME "$path"`" 57696 base="`$BASENAME "$path"`" 57697 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57698 fi 57699 fi 57700 fi 57701 57702 57703 # Only process if variable expands to non-empty 57704 57705 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57707 57708 # Input might be given as Windows format, start by converting to 57709 # unix format. 57710 path="$POTENTIAL_FREETYPE_LIB_PATH" 57711 new_path=`$CYGPATH -u "$path"` 57712 57713 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57714 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57715 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57716 # "foo.exe" is OK but "foo" is an error. 57717 # 57718 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57719 # It is also a way to make sure we got the proper file name for the real test later on. 57720 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57721 if test "x$test_shortpath" = x; then 57722 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57723 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57724 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57725 fi 57726 57727 # Call helper function which possibly converts this using DOS-style short mode. 57728 # If so, the updated path is stored in $new_path. 57729 57730 input_path="$new_path" 57731 # Check if we need to convert this using DOS-style short mode. If the path 57732 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57733 # take no chances and rewrite it. 57734 # Note: m4 eats our [], so we need to use [ and ] instead. 57735 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57736 if test "x$has_forbidden_chars" != x; then 57737 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57738 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57739 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57740 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57741 # Going to short mode and back again did indeed matter. Since short mode is 57742 # case insensitive, let's make it lowercase to improve readability. 57743 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57744 # Now convert it back to Unix-style (cygpath) 57745 input_path=`$CYGPATH -u "$shortmode_path"` 57746 new_path="$input_path" 57747 fi 57748 fi 57749 57750 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57751 if test "x$test_cygdrive_prefix" = x; then 57752 # As a simple fix, exclude /usr/bin since it's not a real path. 57753 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57754 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57755 # a path prefixed by /cygdrive for fixpath to work. 57756 new_path="$CYGWIN_ROOT_PATH$input_path" 57757 fi 57758 fi 57759 57760 57761 if test "x$path" != "x$new_path"; then 57762 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57763 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57764 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57765 fi 57766 57767 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57768 57769 path="$POTENTIAL_FREETYPE_LIB_PATH" 57770 has_colon=`$ECHO $path | $GREP ^.:` 57771 new_path="$path" 57772 if test "x$has_colon" = x; then 57773 # Not in mixed or Windows style, start by that. 57774 new_path=`cmd //c echo $path` 57775 fi 57776 57777 57778 input_path="$new_path" 57779 # Check if we need to convert this using DOS-style short mode. If the path 57780 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57781 # take no chances and rewrite it. 57782 # Note: m4 eats our [], so we need to use [ and ] instead. 57783 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57784 if test "x$has_forbidden_chars" != x; then 57785 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57786 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57787 fi 57788 57789 57790 windows_path="$new_path" 57791 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57792 unix_path=`$CYGPATH -u "$windows_path"` 57793 new_path="$unix_path" 57794 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57795 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57796 new_path="$unix_path" 57797 fi 57798 57799 if test "x$path" != "x$new_path"; then 57800 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57801 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57802 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57803 fi 57804 57805 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57806 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57807 57808 else 57809 # We're on a unix platform. Hooray! :) 57810 path="$POTENTIAL_FREETYPE_LIB_PATH" 57811 has_space=`$ECHO "$path" | $GREP " "` 57812 if test "x$has_space" != x; then 57813 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57814 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57815 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57816 fi 57817 57818 # Use eval to expand a potential ~ 57819 eval path="$path" 57820 if test ! -f "$path" && test ! -d "$path"; then 57821 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57822 fi 57823 57824 if test -d "$path"; then 57825 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57826 else 57827 dir="`$DIRNAME "$path"`" 57828 base="`$BASENAME "$path"`" 57829 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57830 fi 57831 fi 57832 fi 57833 57834 57835 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57837 $as_echo_n "checking for freetype includes... " >&6; } 57838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57839 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57840 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57842 $as_echo_n "checking for freetype libraries... " >&6; } 57843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57844 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57845 fi 57846 57847 if test "x$FOUND_FREETYPE" != xyes; then 57848 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 57849 fi 57850 else 57851 # User specified only one of lib or include. This is an error. 57852 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 57853 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 57854 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 57855 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57856 else 57857 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 57858 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 57859 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57860 fi 57861 fi 57862 else 57863 # User did not specify settings, but we need freetype. Try to locate it. 57864 57865 if test "x$BUNDLE_FREETYPE" = x; then 57866 # If not specified, default is to bundle freetype only on windows 57867 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57868 BUNDLE_FREETYPE=yes 57869 else 57870 BUNDLE_FREETYPE=no 57871 fi 57872 fi 57873 57874 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 57875 if test "x$SYSROOT" = x; then 57876 if test "x$FOUND_FREETYPE" != xyes; then 57877 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 57878 if test "x$PKG_CONFIG" != x; then 57879 57880 pkg_failed=no 57881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 57882 $as_echo_n "checking for FREETYPE... " >&6; } 57883 57884 if test -n "$FREETYPE_CFLAGS"; then 57885 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 57886 elif test -n "$PKG_CONFIG"; then 57887 if test -n "$PKG_CONFIG" && \ 57888 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57889 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57890 ac_status=$? 57891 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57892 test $ac_status = 0; }; then 57893 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 57894 else 57895 pkg_failed=yes 57896 fi 57897 else 57898 pkg_failed=untried 57899 fi 57900 if test -n "$FREETYPE_LIBS"; then 57901 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 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_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 57910 else 57911 pkg_failed=yes 57912 fi 57913 else 57914 pkg_failed=untried 57915 fi 57916 57917 57918 57919 if test $pkg_failed = yes; then 57920 57921 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57922 _pkg_short_errors_supported=yes 57923 else 57924 _pkg_short_errors_supported=no 57925 fi 57926 if test $_pkg_short_errors_supported = yes; then 57927 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 57928 else 57929 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 57930 fi 57931 # Put the nasty error message in config.log where it belongs 57932 echo "$FREETYPE_PKG_ERRORS" >&5 57933 57934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57935 $as_echo "no" >&6; } 57936 FOUND_FREETYPE=no 57937 elif test $pkg_failed = untried; then 57938 FOUND_FREETYPE=no 57939 else 57940 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 57941 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 57942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57943 $as_echo "yes" >&6; } 57944 FOUND_FREETYPE=yes 57945 fi 57946 if test "x$FOUND_FREETYPE" = xyes; then 57947 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 57948 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 57949 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 57950 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 57951 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 57952 fi 57953 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 57954 if test "x$BUNDLE_FREETYPE" = xyes; then 57955 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 57956 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 57957 FOUND_FREETYPE=no 57958 else 57959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 57960 $as_echo_n "checking for freetype... " >&6; } 57961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 57962 $as_echo "yes (using pkg-config)" >&6; } 57963 fi 57964 fi 57965 fi 57966 fi 57967 fi 57968 57969 if test "x$FOUND_FREETYPE" != xyes; then 57970 # Check in well-known locations 57971 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57972 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 57973 57974 windows_path="$FREETYPE_BASE_DIR" 57975 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57976 unix_path=`$CYGPATH -u "$windows_path"` 57977 FREETYPE_BASE_DIR="$unix_path" 57978 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57979 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57980 FREETYPE_BASE_DIR="$unix_path" 57981 fi 57982 57983 57984 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 57985 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 57986 METHOD="well-known location" 57987 57988 # Let's start with an optimistic view of the world :-) 57989 FOUND_FREETYPE=yes 57990 57991 # First look for the canonical freetype main include file ft2build.h. 57992 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57993 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57994 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57995 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57996 # Fail. 57997 FOUND_FREETYPE=no 57998 fi 57999 fi 58000 58001 if test "x$FOUND_FREETYPE" = xyes; then 58002 # Include file found, let's continue the sanity check. 58003 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58004 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58005 58006 # Reset to default value 58007 FREETYPE_BASE_NAME=freetype 58008 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58009 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58010 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58011 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58012 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58013 # for the .6 version explicitly. 58014 FREETYPE_BASE_NAME=freetype.6 58015 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58016 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58017 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58018 else 58019 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58020 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58021 FOUND_FREETYPE=no 58022 fi 58023 else 58024 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58025 # On Windows, we will need both .lib and .dll file. 58026 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58027 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58028 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58029 FOUND_FREETYPE=no 58030 fi 58031 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58032 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58033 # Found lib in isa dir, use that instead. 58034 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58035 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58036 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58037 fi 58038 fi 58039 fi 58040 58041 if test "x$FOUND_FREETYPE" = xyes; then 58042 58043 # Only process if variable expands to non-empty 58044 58045 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58046 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58047 58048 # Input might be given as Windows format, start by converting to 58049 # unix format. 58050 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58051 new_path=`$CYGPATH -u "$path"` 58052 58053 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58054 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58055 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58056 # "foo.exe" is OK but "foo" is an error. 58057 # 58058 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58059 # It is also a way to make sure we got the proper file name for the real test later on. 58060 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58061 if test "x$test_shortpath" = x; then 58062 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58063 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58064 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58065 fi 58066 58067 # Call helper function which possibly converts this using DOS-style short mode. 58068 # If so, the updated path is stored in $new_path. 58069 58070 input_path="$new_path" 58071 # Check if we need to convert this using DOS-style short mode. If the path 58072 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58073 # take no chances and rewrite it. 58074 # Note: m4 eats our [], so we need to use [ and ] instead. 58075 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58076 if test "x$has_forbidden_chars" != x; then 58077 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58078 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58079 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58080 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58081 # Going to short mode and back again did indeed matter. Since short mode is 58082 # case insensitive, let's make it lowercase to improve readability. 58083 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58084 # Now convert it back to Unix-style (cygpath) 58085 input_path=`$CYGPATH -u "$shortmode_path"` 58086 new_path="$input_path" 58087 fi 58088 fi 58089 58090 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58091 if test "x$test_cygdrive_prefix" = x; then 58092 # As a simple fix, exclude /usr/bin since it's not a real path. 58093 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58094 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58095 # a path prefixed by /cygdrive for fixpath to work. 58096 new_path="$CYGWIN_ROOT_PATH$input_path" 58097 fi 58098 fi 58099 58100 58101 if test "x$path" != "x$new_path"; then 58102 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58103 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58104 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58105 fi 58106 58107 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58108 58109 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58110 has_colon=`$ECHO $path | $GREP ^.:` 58111 new_path="$path" 58112 if test "x$has_colon" = x; then 58113 # Not in mixed or Windows style, start by that. 58114 new_path=`cmd //c echo $path` 58115 fi 58116 58117 58118 input_path="$new_path" 58119 # Check if we need to convert this using DOS-style short mode. If the path 58120 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58121 # take no chances and rewrite it. 58122 # Note: m4 eats our [], so we need to use [ and ] instead. 58123 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58124 if test "x$has_forbidden_chars" != x; then 58125 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58126 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58127 fi 58128 58129 58130 windows_path="$new_path" 58131 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58132 unix_path=`$CYGPATH -u "$windows_path"` 58133 new_path="$unix_path" 58134 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58135 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58136 new_path="$unix_path" 58137 fi 58138 58139 if test "x$path" != "x$new_path"; then 58140 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58141 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58142 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58143 fi 58144 58145 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58146 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58147 58148 else 58149 # We're on a unix platform. Hooray! :) 58150 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58151 has_space=`$ECHO "$path" | $GREP " "` 58152 if test "x$has_space" != x; then 58153 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58154 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58155 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58156 fi 58157 58158 # Use eval to expand a potential ~ 58159 eval path="$path" 58160 if test ! -f "$path" && test ! -d "$path"; then 58161 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58162 fi 58163 58164 if test -d "$path"; then 58165 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58166 else 58167 dir="`$DIRNAME "$path"`" 58168 base="`$BASENAME "$path"`" 58169 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58170 fi 58171 fi 58172 fi 58173 58174 58175 # Only process if variable expands to non-empty 58176 58177 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58178 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58179 58180 # Input might be given as Windows format, start by converting to 58181 # unix format. 58182 path="$POTENTIAL_FREETYPE_LIB_PATH" 58183 new_path=`$CYGPATH -u "$path"` 58184 58185 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58186 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58187 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58188 # "foo.exe" is OK but "foo" is an error. 58189 # 58190 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58191 # It is also a way to make sure we got the proper file name for the real test later on. 58192 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58193 if test "x$test_shortpath" = x; then 58194 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58195 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58196 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58197 fi 58198 58199 # Call helper function which possibly converts this using DOS-style short mode. 58200 # If so, the updated path is stored in $new_path. 58201 58202 input_path="$new_path" 58203 # Check if we need to convert this using DOS-style short mode. If the path 58204 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58205 # take no chances and rewrite it. 58206 # Note: m4 eats our [], so we need to use [ and ] instead. 58207 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58208 if test "x$has_forbidden_chars" != x; then 58209 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58210 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58211 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58212 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58213 # Going to short mode and back again did indeed matter. Since short mode is 58214 # case insensitive, let's make it lowercase to improve readability. 58215 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58216 # Now convert it back to Unix-style (cygpath) 58217 input_path=`$CYGPATH -u "$shortmode_path"` 58218 new_path="$input_path" 58219 fi 58220 fi 58221 58222 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58223 if test "x$test_cygdrive_prefix" = x; then 58224 # As a simple fix, exclude /usr/bin since it's not a real path. 58225 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58226 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58227 # a path prefixed by /cygdrive for fixpath to work. 58228 new_path="$CYGWIN_ROOT_PATH$input_path" 58229 fi 58230 fi 58231 58232 58233 if test "x$path" != "x$new_path"; then 58234 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58235 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58236 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58237 fi 58238 58239 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58240 58241 path="$POTENTIAL_FREETYPE_LIB_PATH" 58242 has_colon=`$ECHO $path | $GREP ^.:` 58243 new_path="$path" 58244 if test "x$has_colon" = x; then 58245 # Not in mixed or Windows style, start by that. 58246 new_path=`cmd //c echo $path` 58247 fi 58248 58249 58250 input_path="$new_path" 58251 # Check if we need to convert this using DOS-style short mode. If the path 58252 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58253 # take no chances and rewrite it. 58254 # Note: m4 eats our [], so we need to use [ and ] instead. 58255 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58256 if test "x$has_forbidden_chars" != x; then 58257 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58258 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58259 fi 58260 58261 58262 windows_path="$new_path" 58263 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58264 unix_path=`$CYGPATH -u "$windows_path"` 58265 new_path="$unix_path" 58266 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58267 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58268 new_path="$unix_path" 58269 fi 58270 58271 if test "x$path" != "x$new_path"; then 58272 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58273 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58274 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58275 fi 58276 58277 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58278 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58279 58280 else 58281 # We're on a unix platform. Hooray! :) 58282 path="$POTENTIAL_FREETYPE_LIB_PATH" 58283 has_space=`$ECHO "$path" | $GREP " "` 58284 if test "x$has_space" != x; then 58285 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58286 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58287 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58288 fi 58289 58290 # Use eval to expand a potential ~ 58291 eval path="$path" 58292 if test ! -f "$path" && test ! -d "$path"; then 58293 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58294 fi 58295 58296 if test -d "$path"; then 58297 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58298 else 58299 dir="`$DIRNAME "$path"`" 58300 base="`$BASENAME "$path"`" 58301 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58302 fi 58303 fi 58304 fi 58305 58306 58307 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58309 $as_echo_n "checking for freetype includes... " >&6; } 58310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58311 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58312 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58314 $as_echo_n "checking for freetype libraries... " >&6; } 58315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58316 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58317 fi 58318 58319 if test "x$FOUND_FREETYPE" != xyes; then 58320 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 58321 58322 windows_path="$FREETYPE_BASE_DIR" 58323 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58324 unix_path=`$CYGPATH -u "$windows_path"` 58325 FREETYPE_BASE_DIR="$unix_path" 58326 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58327 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58328 FREETYPE_BASE_DIR="$unix_path" 58329 fi 58330 58331 58332 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58333 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58334 METHOD="well-known location" 58335 58336 # Let's start with an optimistic view of the world :-) 58337 FOUND_FREETYPE=yes 58338 58339 # First look for the canonical freetype main include file ft2build.h. 58340 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58341 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58342 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58343 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58344 # Fail. 58345 FOUND_FREETYPE=no 58346 fi 58347 fi 58348 58349 if test "x$FOUND_FREETYPE" = xyes; then 58350 # Include file found, let's continue the sanity check. 58351 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58352 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58353 58354 # Reset to default value 58355 FREETYPE_BASE_NAME=freetype 58356 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58357 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58358 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58359 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58360 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58361 # for the .6 version explicitly. 58362 FREETYPE_BASE_NAME=freetype.6 58363 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58364 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58365 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58366 else 58367 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58368 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58369 FOUND_FREETYPE=no 58370 fi 58371 else 58372 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58373 # On Windows, we will need both .lib and .dll file. 58374 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58375 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58376 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58377 FOUND_FREETYPE=no 58378 fi 58379 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58380 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58381 # Found lib in isa dir, use that instead. 58382 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58383 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58384 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58385 fi 58386 fi 58387 fi 58388 58389 if test "x$FOUND_FREETYPE" = xyes; then 58390 58391 # Only process if variable expands to non-empty 58392 58393 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58394 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58395 58396 # Input might be given as Windows format, start by converting to 58397 # unix format. 58398 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58399 new_path=`$CYGPATH -u "$path"` 58400 58401 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58402 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58403 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58404 # "foo.exe" is OK but "foo" is an error. 58405 # 58406 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58407 # It is also a way to make sure we got the proper file name for the real test later on. 58408 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58409 if test "x$test_shortpath" = x; then 58410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58411 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58412 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58413 fi 58414 58415 # Call helper function which possibly converts this using DOS-style short mode. 58416 # If so, the updated path is stored in $new_path. 58417 58418 input_path="$new_path" 58419 # Check if we need to convert this using DOS-style short mode. If the path 58420 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58421 # take no chances and rewrite it. 58422 # Note: m4 eats our [], so we need to use [ and ] instead. 58423 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58424 if test "x$has_forbidden_chars" != x; then 58425 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58426 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58427 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58428 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58429 # Going to short mode and back again did indeed matter. Since short mode is 58430 # case insensitive, let's make it lowercase to improve readability. 58431 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58432 # Now convert it back to Unix-style (cygpath) 58433 input_path=`$CYGPATH -u "$shortmode_path"` 58434 new_path="$input_path" 58435 fi 58436 fi 58437 58438 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58439 if test "x$test_cygdrive_prefix" = x; then 58440 # As a simple fix, exclude /usr/bin since it's not a real path. 58441 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58442 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58443 # a path prefixed by /cygdrive for fixpath to work. 58444 new_path="$CYGWIN_ROOT_PATH$input_path" 58445 fi 58446 fi 58447 58448 58449 if test "x$path" != "x$new_path"; then 58450 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58451 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58452 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58453 fi 58454 58455 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58456 58457 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58458 has_colon=`$ECHO $path | $GREP ^.:` 58459 new_path="$path" 58460 if test "x$has_colon" = x; then 58461 # Not in mixed or Windows style, start by that. 58462 new_path=`cmd //c echo $path` 58463 fi 58464 58465 58466 input_path="$new_path" 58467 # Check if we need to convert this using DOS-style short mode. If the path 58468 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58469 # take no chances and rewrite it. 58470 # Note: m4 eats our [], so we need to use [ and ] instead. 58471 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58472 if test "x$has_forbidden_chars" != x; then 58473 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58474 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58475 fi 58476 58477 58478 windows_path="$new_path" 58479 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58480 unix_path=`$CYGPATH -u "$windows_path"` 58481 new_path="$unix_path" 58482 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58483 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58484 new_path="$unix_path" 58485 fi 58486 58487 if test "x$path" != "x$new_path"; then 58488 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58489 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58490 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58491 fi 58492 58493 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58494 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58495 58496 else 58497 # We're on a unix platform. Hooray! :) 58498 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58499 has_space=`$ECHO "$path" | $GREP " "` 58500 if test "x$has_space" != x; then 58501 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58502 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58503 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58504 fi 58505 58506 # Use eval to expand a potential ~ 58507 eval path="$path" 58508 if test ! -f "$path" && test ! -d "$path"; then 58509 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58510 fi 58511 58512 if test -d "$path"; then 58513 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58514 else 58515 dir="`$DIRNAME "$path"`" 58516 base="`$BASENAME "$path"`" 58517 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58518 fi 58519 fi 58520 fi 58521 58522 58523 # Only process if variable expands to non-empty 58524 58525 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58527 58528 # Input might be given as Windows format, start by converting to 58529 # unix format. 58530 path="$POTENTIAL_FREETYPE_LIB_PATH" 58531 new_path=`$CYGPATH -u "$path"` 58532 58533 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58534 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58535 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58536 # "foo.exe" is OK but "foo" is an error. 58537 # 58538 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58539 # It is also a way to make sure we got the proper file name for the real test later on. 58540 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58541 if test "x$test_shortpath" = x; then 58542 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58543 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58544 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58545 fi 58546 58547 # Call helper function which possibly converts this using DOS-style short mode. 58548 # If so, the updated path is stored in $new_path. 58549 58550 input_path="$new_path" 58551 # Check if we need to convert this using DOS-style short mode. If the path 58552 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58553 # take no chances and rewrite it. 58554 # Note: m4 eats our [], so we need to use [ and ] instead. 58555 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58556 if test "x$has_forbidden_chars" != x; then 58557 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58558 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58559 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58560 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58561 # Going to short mode and back again did indeed matter. Since short mode is 58562 # case insensitive, let's make it lowercase to improve readability. 58563 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58564 # Now convert it back to Unix-style (cygpath) 58565 input_path=`$CYGPATH -u "$shortmode_path"` 58566 new_path="$input_path" 58567 fi 58568 fi 58569 58570 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58571 if test "x$test_cygdrive_prefix" = x; then 58572 # As a simple fix, exclude /usr/bin since it's not a real path. 58573 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58574 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58575 # a path prefixed by /cygdrive for fixpath to work. 58576 new_path="$CYGWIN_ROOT_PATH$input_path" 58577 fi 58578 fi 58579 58580 58581 if test "x$path" != "x$new_path"; then 58582 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58583 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58584 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58585 fi 58586 58587 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58588 58589 path="$POTENTIAL_FREETYPE_LIB_PATH" 58590 has_colon=`$ECHO $path | $GREP ^.:` 58591 new_path="$path" 58592 if test "x$has_colon" = x; then 58593 # Not in mixed or Windows style, start by that. 58594 new_path=`cmd //c echo $path` 58595 fi 58596 58597 58598 input_path="$new_path" 58599 # Check if we need to convert this using DOS-style short mode. If the path 58600 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58601 # take no chances and rewrite it. 58602 # Note: m4 eats our [], so we need to use [ and ] instead. 58603 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58604 if test "x$has_forbidden_chars" != x; then 58605 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58606 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58607 fi 58608 58609 58610 windows_path="$new_path" 58611 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58612 unix_path=`$CYGPATH -u "$windows_path"` 58613 new_path="$unix_path" 58614 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58615 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58616 new_path="$unix_path" 58617 fi 58618 58619 if test "x$path" != "x$new_path"; then 58620 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58621 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58622 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58623 fi 58624 58625 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58626 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58627 58628 else 58629 # We're on a unix platform. Hooray! :) 58630 path="$POTENTIAL_FREETYPE_LIB_PATH" 58631 has_space=`$ECHO "$path" | $GREP " "` 58632 if test "x$has_space" != x; then 58633 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58634 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58635 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58636 fi 58637 58638 # Use eval to expand a potential ~ 58639 eval path="$path" 58640 if test ! -f "$path" && test ! -d "$path"; then 58641 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58642 fi 58643 58644 if test -d "$path"; then 58645 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58646 else 58647 dir="`$DIRNAME "$path"`" 58648 base="`$BASENAME "$path"`" 58649 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58650 fi 58651 fi 58652 fi 58653 58654 58655 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58657 $as_echo_n "checking for freetype includes... " >&6; } 58658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58659 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58660 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58662 $as_echo_n "checking for freetype libraries... " >&6; } 58663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58664 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58665 fi 58666 58667 fi 58668 if test "x$FOUND_FREETYPE" != xyes; then 58669 FREETYPE_BASE_DIR="$HOME/freetype" 58670 58671 windows_path="$FREETYPE_BASE_DIR" 58672 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58673 unix_path=`$CYGPATH -u "$windows_path"` 58674 FREETYPE_BASE_DIR="$unix_path" 58675 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58676 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58677 FREETYPE_BASE_DIR="$unix_path" 58678 fi 58679 58680 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58681 58682 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58683 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 58684 METHOD="well-known location" 58685 58686 # Let's start with an optimistic view of the world :-) 58687 FOUND_FREETYPE=yes 58688 58689 # First look for the canonical freetype main include file ft2build.h. 58690 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58691 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58692 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58693 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58694 # Fail. 58695 FOUND_FREETYPE=no 58696 fi 58697 fi 58698 58699 if test "x$FOUND_FREETYPE" = xyes; then 58700 # Include file found, let's continue the sanity check. 58701 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58702 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58703 58704 # Reset to default value 58705 FREETYPE_BASE_NAME=freetype 58706 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58707 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58708 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58709 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58710 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58711 # for the .6 version explicitly. 58712 FREETYPE_BASE_NAME=freetype.6 58713 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58714 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58715 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58716 else 58717 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58718 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58719 FOUND_FREETYPE=no 58720 fi 58721 else 58722 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58723 # On Windows, we will need both .lib and .dll file. 58724 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58725 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58726 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58727 FOUND_FREETYPE=no 58728 fi 58729 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58730 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58731 # Found lib in isa dir, use that instead. 58732 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58733 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58734 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58735 fi 58736 fi 58737 fi 58738 58739 if test "x$FOUND_FREETYPE" = xyes; then 58740 58741 # Only process if variable expands to non-empty 58742 58743 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58745 58746 # Input might be given as Windows format, start by converting to 58747 # unix format. 58748 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58749 new_path=`$CYGPATH -u "$path"` 58750 58751 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58752 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58753 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58754 # "foo.exe" is OK but "foo" is an error. 58755 # 58756 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58757 # It is also a way to make sure we got the proper file name for the real test later on. 58758 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58759 if test "x$test_shortpath" = x; then 58760 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58761 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58762 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58763 fi 58764 58765 # Call helper function which possibly converts this using DOS-style short mode. 58766 # If so, the updated path is stored in $new_path. 58767 58768 input_path="$new_path" 58769 # Check if we need to convert this using DOS-style short mode. If the path 58770 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58771 # take no chances and rewrite it. 58772 # Note: m4 eats our [], so we need to use [ and ] instead. 58773 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58774 if test "x$has_forbidden_chars" != x; then 58775 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58776 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58777 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58778 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58779 # Going to short mode and back again did indeed matter. Since short mode is 58780 # case insensitive, let's make it lowercase to improve readability. 58781 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58782 # Now convert it back to Unix-style (cygpath) 58783 input_path=`$CYGPATH -u "$shortmode_path"` 58784 new_path="$input_path" 58785 fi 58786 fi 58787 58788 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58789 if test "x$test_cygdrive_prefix" = x; then 58790 # As a simple fix, exclude /usr/bin since it's not a real path. 58791 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58792 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58793 # a path prefixed by /cygdrive for fixpath to work. 58794 new_path="$CYGWIN_ROOT_PATH$input_path" 58795 fi 58796 fi 58797 58798 58799 if test "x$path" != "x$new_path"; then 58800 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58801 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58802 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58803 fi 58804 58805 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58806 58807 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58808 has_colon=`$ECHO $path | $GREP ^.:` 58809 new_path="$path" 58810 if test "x$has_colon" = x; then 58811 # Not in mixed or Windows style, start by that. 58812 new_path=`cmd //c echo $path` 58813 fi 58814 58815 58816 input_path="$new_path" 58817 # Check if we need to convert this using DOS-style short mode. If the path 58818 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58819 # take no chances and rewrite it. 58820 # Note: m4 eats our [], so we need to use [ and ] instead. 58821 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58822 if test "x$has_forbidden_chars" != x; then 58823 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58824 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58825 fi 58826 58827 58828 windows_path="$new_path" 58829 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58830 unix_path=`$CYGPATH -u "$windows_path"` 58831 new_path="$unix_path" 58832 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58833 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58834 new_path="$unix_path" 58835 fi 58836 58837 if test "x$path" != "x$new_path"; then 58838 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58839 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58840 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58841 fi 58842 58843 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58844 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58845 58846 else 58847 # We're on a unix platform. Hooray! :) 58848 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58849 has_space=`$ECHO "$path" | $GREP " "` 58850 if test "x$has_space" != x; then 58851 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58852 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58853 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58854 fi 58855 58856 # Use eval to expand a potential ~ 58857 eval path="$path" 58858 if test ! -f "$path" && test ! -d "$path"; then 58859 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58860 fi 58861 58862 if test -d "$path"; then 58863 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58864 else 58865 dir="`$DIRNAME "$path"`" 58866 base="`$BASENAME "$path"`" 58867 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58868 fi 58869 fi 58870 fi 58871 58872 58873 # Only process if variable expands to non-empty 58874 58875 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58876 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58877 58878 # Input might be given as Windows format, start by converting to 58879 # unix format. 58880 path="$POTENTIAL_FREETYPE_LIB_PATH" 58881 new_path=`$CYGPATH -u "$path"` 58882 58883 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58884 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58885 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58886 # "foo.exe" is OK but "foo" is an error. 58887 # 58888 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58889 # It is also a way to make sure we got the proper file name for the real test later on. 58890 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58891 if test "x$test_shortpath" = x; then 58892 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58893 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58894 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58895 fi 58896 58897 # Call helper function which possibly converts this using DOS-style short mode. 58898 # If so, the updated path is stored in $new_path. 58899 58900 input_path="$new_path" 58901 # Check if we need to convert this using DOS-style short mode. If the path 58902 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58903 # take no chances and rewrite it. 58904 # Note: m4 eats our [], so we need to use [ and ] instead. 58905 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58906 if test "x$has_forbidden_chars" != x; then 58907 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58908 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58909 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58910 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58911 # Going to short mode and back again did indeed matter. Since short mode is 58912 # case insensitive, let's make it lowercase to improve readability. 58913 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58914 # Now convert it back to Unix-style (cygpath) 58915 input_path=`$CYGPATH -u "$shortmode_path"` 58916 new_path="$input_path" 58917 fi 58918 fi 58919 58920 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58921 if test "x$test_cygdrive_prefix" = x; then 58922 # As a simple fix, exclude /usr/bin since it's not a real path. 58923 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58924 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58925 # a path prefixed by /cygdrive for fixpath to work. 58926 new_path="$CYGWIN_ROOT_PATH$input_path" 58927 fi 58928 fi 58929 58930 58931 if test "x$path" != "x$new_path"; then 58932 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58933 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58934 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58935 fi 58936 58937 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58938 58939 path="$POTENTIAL_FREETYPE_LIB_PATH" 58940 has_colon=`$ECHO $path | $GREP ^.:` 58941 new_path="$path" 58942 if test "x$has_colon" = x; then 58943 # Not in mixed or Windows style, start by that. 58944 new_path=`cmd //c echo $path` 58945 fi 58946 58947 58948 input_path="$new_path" 58949 # Check if we need to convert this using DOS-style short mode. If the path 58950 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58951 # take no chances and rewrite it. 58952 # Note: m4 eats our [], so we need to use [ and ] instead. 58953 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58954 if test "x$has_forbidden_chars" != x; then 58955 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58956 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58957 fi 58958 58959 58960 windows_path="$new_path" 58961 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58962 unix_path=`$CYGPATH -u "$windows_path"` 58963 new_path="$unix_path" 58964 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58965 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58966 new_path="$unix_path" 58967 fi 58968 58969 if test "x$path" != "x$new_path"; then 58970 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58971 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58972 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58973 fi 58974 58975 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58976 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58977 58978 else 58979 # We're on a unix platform. Hooray! :) 58980 path="$POTENTIAL_FREETYPE_LIB_PATH" 58981 has_space=`$ECHO "$path" | $GREP " "` 58982 if test "x$has_space" != x; then 58983 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58984 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58985 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58986 fi 58987 58988 # Use eval to expand a potential ~ 58989 eval path="$path" 58990 if test ! -f "$path" && test ! -d "$path"; then 58991 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58992 fi 58993 58994 if test -d "$path"; then 58995 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58996 else 58997 dir="`$DIRNAME "$path"`" 58998 base="`$BASENAME "$path"`" 58999 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59000 fi 59001 fi 59002 fi 59003 59004 59005 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59007 $as_echo_n "checking for freetype includes... " >&6; } 59008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59009 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59010 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59012 $as_echo_n "checking for freetype libraries... " >&6; } 59013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59014 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59015 fi 59016 59017 else 59018 59019 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59020 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59021 METHOD="well-known location" 59022 59023 # Let's start with an optimistic view of the world :-) 59024 FOUND_FREETYPE=yes 59025 59026 # First look for the canonical freetype main include file ft2build.h. 59027 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59028 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59029 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59030 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59031 # Fail. 59032 FOUND_FREETYPE=no 59033 fi 59034 fi 59035 59036 if test "x$FOUND_FREETYPE" = xyes; then 59037 # Include file found, let's continue the sanity check. 59038 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59039 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59040 59041 # Reset to default value 59042 FREETYPE_BASE_NAME=freetype 59043 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59044 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59045 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59046 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59047 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59048 # for the .6 version explicitly. 59049 FREETYPE_BASE_NAME=freetype.6 59050 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59051 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59052 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59053 else 59054 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59055 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59056 FOUND_FREETYPE=no 59057 fi 59058 else 59059 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59060 # On Windows, we will need both .lib and .dll file. 59061 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59062 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59063 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59064 FOUND_FREETYPE=no 59065 fi 59066 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59067 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59068 # Found lib in isa dir, use that instead. 59069 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59070 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59071 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59072 fi 59073 fi 59074 fi 59075 59076 if test "x$FOUND_FREETYPE" = xyes; then 59077 59078 # Only process if variable expands to non-empty 59079 59080 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59081 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59082 59083 # Input might be given as Windows format, start by converting to 59084 # unix format. 59085 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59086 new_path=`$CYGPATH -u "$path"` 59087 59088 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59089 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59090 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59091 # "foo.exe" is OK but "foo" is an error. 59092 # 59093 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59094 # It is also a way to make sure we got the proper file name for the real test later on. 59095 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59096 if test "x$test_shortpath" = x; then 59097 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59098 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59099 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59100 fi 59101 59102 # Call helper function which possibly converts this using DOS-style short mode. 59103 # If so, the updated path is stored in $new_path. 59104 59105 input_path="$new_path" 59106 # Check if we need to convert this using DOS-style short mode. If the path 59107 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59108 # take no chances and rewrite it. 59109 # Note: m4 eats our [], so we need to use [ and ] instead. 59110 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59111 if test "x$has_forbidden_chars" != x; then 59112 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59113 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59114 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59115 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59116 # Going to short mode and back again did indeed matter. Since short mode is 59117 # case insensitive, let's make it lowercase to improve readability. 59118 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59119 # Now convert it back to Unix-style (cygpath) 59120 input_path=`$CYGPATH -u "$shortmode_path"` 59121 new_path="$input_path" 59122 fi 59123 fi 59124 59125 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59126 if test "x$test_cygdrive_prefix" = x; then 59127 # As a simple fix, exclude /usr/bin since it's not a real path. 59128 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59129 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59130 # a path prefixed by /cygdrive for fixpath to work. 59131 new_path="$CYGWIN_ROOT_PATH$input_path" 59132 fi 59133 fi 59134 59135 59136 if test "x$path" != "x$new_path"; then 59137 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59138 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59139 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59140 fi 59141 59142 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59143 59144 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59145 has_colon=`$ECHO $path | $GREP ^.:` 59146 new_path="$path" 59147 if test "x$has_colon" = x; then 59148 # Not in mixed or Windows style, start by that. 59149 new_path=`cmd //c echo $path` 59150 fi 59151 59152 59153 input_path="$new_path" 59154 # Check if we need to convert this using DOS-style short mode. If the path 59155 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59156 # take no chances and rewrite it. 59157 # Note: m4 eats our [], so we need to use [ and ] instead. 59158 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59159 if test "x$has_forbidden_chars" != x; then 59160 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59161 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59162 fi 59163 59164 59165 windows_path="$new_path" 59166 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59167 unix_path=`$CYGPATH -u "$windows_path"` 59168 new_path="$unix_path" 59169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59170 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59171 new_path="$unix_path" 59172 fi 59173 59174 if test "x$path" != "x$new_path"; then 59175 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59176 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59177 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59178 fi 59179 59180 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59181 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59182 59183 else 59184 # We're on a unix platform. Hooray! :) 59185 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59186 has_space=`$ECHO "$path" | $GREP " "` 59187 if test "x$has_space" != x; then 59188 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59189 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59190 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59191 fi 59192 59193 # Use eval to expand a potential ~ 59194 eval path="$path" 59195 if test ! -f "$path" && test ! -d "$path"; then 59196 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59197 fi 59198 59199 if test -d "$path"; then 59200 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59201 else 59202 dir="`$DIRNAME "$path"`" 59203 base="`$BASENAME "$path"`" 59204 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59205 fi 59206 fi 59207 fi 59208 59209 59210 # Only process if variable expands to non-empty 59211 59212 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59213 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59214 59215 # Input might be given as Windows format, start by converting to 59216 # unix format. 59217 path="$POTENTIAL_FREETYPE_LIB_PATH" 59218 new_path=`$CYGPATH -u "$path"` 59219 59220 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59221 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59222 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59223 # "foo.exe" is OK but "foo" is an error. 59224 # 59225 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59226 # It is also a way to make sure we got the proper file name for the real test later on. 59227 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59228 if test "x$test_shortpath" = x; then 59229 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59230 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59231 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59232 fi 59233 59234 # Call helper function which possibly converts this using DOS-style short mode. 59235 # If so, the updated path is stored in $new_path. 59236 59237 input_path="$new_path" 59238 # Check if we need to convert this using DOS-style short mode. If the path 59239 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59240 # take no chances and rewrite it. 59241 # Note: m4 eats our [], so we need to use [ and ] instead. 59242 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59243 if test "x$has_forbidden_chars" != x; then 59244 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59245 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59246 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59247 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59248 # Going to short mode and back again did indeed matter. Since short mode is 59249 # case insensitive, let's make it lowercase to improve readability. 59250 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59251 # Now convert it back to Unix-style (cygpath) 59252 input_path=`$CYGPATH -u "$shortmode_path"` 59253 new_path="$input_path" 59254 fi 59255 fi 59256 59257 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59258 if test "x$test_cygdrive_prefix" = x; then 59259 # As a simple fix, exclude /usr/bin since it's not a real path. 59260 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59261 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59262 # a path prefixed by /cygdrive for fixpath to work. 59263 new_path="$CYGWIN_ROOT_PATH$input_path" 59264 fi 59265 fi 59266 59267 59268 if test "x$path" != "x$new_path"; then 59269 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59270 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59271 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59272 fi 59273 59274 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59275 59276 path="$POTENTIAL_FREETYPE_LIB_PATH" 59277 has_colon=`$ECHO $path | $GREP ^.:` 59278 new_path="$path" 59279 if test "x$has_colon" = x; then 59280 # Not in mixed or Windows style, start by that. 59281 new_path=`cmd //c echo $path` 59282 fi 59283 59284 59285 input_path="$new_path" 59286 # Check if we need to convert this using DOS-style short mode. If the path 59287 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59288 # take no chances and rewrite it. 59289 # Note: m4 eats our [], so we need to use [ and ] instead. 59290 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59291 if test "x$has_forbidden_chars" != x; then 59292 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59293 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59294 fi 59295 59296 59297 windows_path="$new_path" 59298 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59299 unix_path=`$CYGPATH -u "$windows_path"` 59300 new_path="$unix_path" 59301 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59302 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59303 new_path="$unix_path" 59304 fi 59305 59306 if test "x$path" != "x$new_path"; then 59307 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59308 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59309 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59310 fi 59311 59312 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59313 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59314 59315 else 59316 # We're on a unix platform. Hooray! :) 59317 path="$POTENTIAL_FREETYPE_LIB_PATH" 59318 has_space=`$ECHO "$path" | $GREP " "` 59319 if test "x$has_space" != x; then 59320 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59321 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59322 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59323 fi 59324 59325 # Use eval to expand a potential ~ 59326 eval path="$path" 59327 if test ! -f "$path" && test ! -d "$path"; then 59328 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59329 fi 59330 59331 if test -d "$path"; then 59332 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59333 else 59334 dir="`$DIRNAME "$path"`" 59335 base="`$BASENAME "$path"`" 59336 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59337 fi 59338 fi 59339 fi 59340 59341 59342 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59344 $as_echo_n "checking for freetype includes... " >&6; } 59345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59346 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59347 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59349 $as_echo_n "checking for freetype libraries... " >&6; } 59350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59351 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59352 fi 59353 59354 fi 59355 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 59356 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 59357 # Source is available, as a last resort try to build freetype in default location 59358 59359 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 59360 BUILD_FREETYPE=yes 59361 59362 # Check if the freetype sources are acessible.. 59363 if ! test -d $FREETYPE_SRC_PATH; then 59364 { $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 59365 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 59366 BUILD_FREETYPE=no 59367 fi 59368 # ..and contain a vc2010 project file 59369 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 59370 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 59371 { $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 59372 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 59373 BUILD_FREETYPE=no 59374 fi 59375 # Now check if configure found a version of 'msbuild.exe' 59376 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 59377 { $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 59378 $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;} 59379 BUILD_FREETYPE=no 59380 fi 59381 59382 # Ready to go.. 59383 if test "x$BUILD_FREETYPE" = xyes; then 59384 # msbuild requires trailing slashes for output directories 59385 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 59386 freetype_lib_path_unix="$freetype_lib_path" 59387 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 59388 59389 unix_path="$vcxproj_path" 59390 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59391 windows_path=`$CYGPATH -m "$unix_path"` 59392 vcxproj_path="$windows_path" 59393 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59394 windows_path=`cmd //c echo $unix_path` 59395 vcxproj_path="$windows_path" 59396 fi 59397 59398 59399 unix_path="$freetype_lib_path" 59400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59401 windows_path=`$CYGPATH -m "$unix_path"` 59402 freetype_lib_path="$windows_path" 59403 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59404 windows_path=`cmd //c echo $unix_path` 59405 freetype_lib_path="$windows_path" 59406 fi 59407 59408 59409 unix_path="$freetype_obj_path" 59410 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59411 windows_path=`$CYGPATH -m "$unix_path"` 59412 freetype_obj_path="$windows_path" 59413 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59414 windows_path=`cmd //c echo $unix_path` 59415 freetype_obj_path="$windows_path" 59416 fi 59417 59418 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59419 freetype_platform=x64 59420 else 59421 freetype_platform=win32 59422 fi 59423 59424 # The original freetype project file is for VS 2010 (i.e. 'v100'), 59425 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 59426 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 59427 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 59428 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 59429 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 59430 59431 # First we try to build the freetype.dll 59432 $ECHO -e "@echo off\n"\ 59433 "$MSBUILD $vcxproj_path "\ 59434 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59435 "/p:Configuration=\"Release Multithreaded\" "\ 59436 "/p:Platform=$freetype_platform "\ 59437 "/p:ConfigurationType=DynamicLibrary "\ 59438 "/p:TargetName=freetype "\ 59439 "/p:OutDir=\"$freetype_lib_path\" "\ 59440 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 59441 cmd /c freetype.bat 59442 59443 if test -s "$freetype_lib_path_unix/freetype.dll"; then 59444 # If that succeeds we also build freetype.lib 59445 $ECHO -e "@echo off\n"\ 59446 "$MSBUILD $vcxproj_path "\ 59447 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59448 "/p:Configuration=\"Release Multithreaded\" "\ 59449 "/p:Platform=$freetype_platform "\ 59450 "/p:ConfigurationType=StaticLibrary "\ 59451 "/p:TargetName=freetype "\ 59452 "/p:OutDir=\"$freetype_lib_path\" "\ 59453 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 59454 cmd /c freetype.bat 59455 59456 if test -s "$freetype_lib_path_unix/freetype.lib"; then 59457 # Once we build both, lib and dll, set freetype lib and include path appropriately 59458 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 59459 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 59460 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 59461 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 59462 else 59463 BUILD_FREETYPE=no 59464 fi 59465 else 59466 BUILD_FREETYPE=no 59467 fi 59468 fi 59469 59470 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59471 59472 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59473 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59474 METHOD="well-known location" 59475 59476 # Let's start with an optimistic view of the world :-) 59477 FOUND_FREETYPE=yes 59478 59479 # First look for the canonical freetype main include file ft2build.h. 59480 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59481 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59482 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59483 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59484 # Fail. 59485 FOUND_FREETYPE=no 59486 fi 59487 fi 59488 59489 if test "x$FOUND_FREETYPE" = xyes; then 59490 # Include file found, let's continue the sanity check. 59491 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59492 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59493 59494 # Reset to default value 59495 FREETYPE_BASE_NAME=freetype 59496 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59497 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59498 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59499 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59500 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59501 # for the .6 version explicitly. 59502 FREETYPE_BASE_NAME=freetype.6 59503 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59504 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59505 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59506 else 59507 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59508 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59509 FOUND_FREETYPE=no 59510 fi 59511 else 59512 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59513 # On Windows, we will need both .lib and .dll file. 59514 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59515 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59516 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59517 FOUND_FREETYPE=no 59518 fi 59519 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59520 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59521 # Found lib in isa dir, use that instead. 59522 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59523 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59524 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59525 fi 59526 fi 59527 fi 59528 59529 if test "x$FOUND_FREETYPE" = xyes; then 59530 59531 # Only process if variable expands to non-empty 59532 59533 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59535 59536 # Input might be given as Windows format, start by converting to 59537 # unix format. 59538 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59539 new_path=`$CYGPATH -u "$path"` 59540 59541 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59542 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59543 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59544 # "foo.exe" is OK but "foo" is an error. 59545 # 59546 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59547 # It is also a way to make sure we got the proper file name for the real test later on. 59548 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59549 if test "x$test_shortpath" = x; then 59550 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59551 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59552 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59553 fi 59554 59555 # Call helper function which possibly converts this using DOS-style short mode. 59556 # If so, the updated path is stored in $new_path. 59557 59558 input_path="$new_path" 59559 # Check if we need to convert this using DOS-style short mode. If the path 59560 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59561 # take no chances and rewrite it. 59562 # Note: m4 eats our [], so we need to use [ and ] instead. 59563 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59564 if test "x$has_forbidden_chars" != x; then 59565 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59566 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59567 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59568 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59569 # Going to short mode and back again did indeed matter. Since short mode is 59570 # case insensitive, let's make it lowercase to improve readability. 59571 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59572 # Now convert it back to Unix-style (cygpath) 59573 input_path=`$CYGPATH -u "$shortmode_path"` 59574 new_path="$input_path" 59575 fi 59576 fi 59577 59578 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59579 if test "x$test_cygdrive_prefix" = x; then 59580 # As a simple fix, exclude /usr/bin since it's not a real path. 59581 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59582 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59583 # a path prefixed by /cygdrive for fixpath to work. 59584 new_path="$CYGWIN_ROOT_PATH$input_path" 59585 fi 59586 fi 59587 59588 59589 if test "x$path" != "x$new_path"; then 59590 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59591 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59592 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59593 fi 59594 59595 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59596 59597 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59598 has_colon=`$ECHO $path | $GREP ^.:` 59599 new_path="$path" 59600 if test "x$has_colon" = x; then 59601 # Not in mixed or Windows style, start by that. 59602 new_path=`cmd //c echo $path` 59603 fi 59604 59605 59606 input_path="$new_path" 59607 # Check if we need to convert this using DOS-style short mode. If the path 59608 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59609 # take no chances and rewrite it. 59610 # Note: m4 eats our [], so we need to use [ and ] instead. 59611 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59612 if test "x$has_forbidden_chars" != x; then 59613 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59614 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59615 fi 59616 59617 59618 windows_path="$new_path" 59619 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59620 unix_path=`$CYGPATH -u "$windows_path"` 59621 new_path="$unix_path" 59622 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59623 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59624 new_path="$unix_path" 59625 fi 59626 59627 if test "x$path" != "x$new_path"; then 59628 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59629 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59630 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59631 fi 59632 59633 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59634 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59635 59636 else 59637 # We're on a unix platform. Hooray! :) 59638 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59639 has_space=`$ECHO "$path" | $GREP " "` 59640 if test "x$has_space" != x; then 59641 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59642 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59643 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59644 fi 59645 59646 # Use eval to expand a potential ~ 59647 eval path="$path" 59648 if test ! -f "$path" && test ! -d "$path"; then 59649 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59650 fi 59651 59652 if test -d "$path"; then 59653 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59654 else 59655 dir="`$DIRNAME "$path"`" 59656 base="`$BASENAME "$path"`" 59657 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59658 fi 59659 fi 59660 fi 59661 59662 59663 # Only process if variable expands to non-empty 59664 59665 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59667 59668 # Input might be given as Windows format, start by converting to 59669 # unix format. 59670 path="$POTENTIAL_FREETYPE_LIB_PATH" 59671 new_path=`$CYGPATH -u "$path"` 59672 59673 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59674 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59675 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59676 # "foo.exe" is OK but "foo" is an error. 59677 # 59678 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59679 # It is also a way to make sure we got the proper file name for the real test later on. 59680 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59681 if test "x$test_shortpath" = x; then 59682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59683 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59684 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59685 fi 59686 59687 # Call helper function which possibly converts this using DOS-style short mode. 59688 # If so, the updated path is stored in $new_path. 59689 59690 input_path="$new_path" 59691 # Check if we need to convert this using DOS-style short mode. If the path 59692 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59693 # take no chances and rewrite it. 59694 # Note: m4 eats our [], so we need to use [ and ] instead. 59695 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59696 if test "x$has_forbidden_chars" != x; then 59697 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59698 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59699 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59700 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59701 # Going to short mode and back again did indeed matter. Since short mode is 59702 # case insensitive, let's make it lowercase to improve readability. 59703 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59704 # Now convert it back to Unix-style (cygpath) 59705 input_path=`$CYGPATH -u "$shortmode_path"` 59706 new_path="$input_path" 59707 fi 59708 fi 59709 59710 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59711 if test "x$test_cygdrive_prefix" = x; then 59712 # As a simple fix, exclude /usr/bin since it's not a real path. 59713 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59714 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59715 # a path prefixed by /cygdrive for fixpath to work. 59716 new_path="$CYGWIN_ROOT_PATH$input_path" 59717 fi 59718 fi 59719 59720 59721 if test "x$path" != "x$new_path"; then 59722 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59723 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59724 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59725 fi 59726 59727 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59728 59729 path="$POTENTIAL_FREETYPE_LIB_PATH" 59730 has_colon=`$ECHO $path | $GREP ^.:` 59731 new_path="$path" 59732 if test "x$has_colon" = x; then 59733 # Not in mixed or Windows style, start by that. 59734 new_path=`cmd //c echo $path` 59735 fi 59736 59737 59738 input_path="$new_path" 59739 # Check if we need to convert this using DOS-style short mode. If the path 59740 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59741 # take no chances and rewrite it. 59742 # Note: m4 eats our [], so we need to use [ and ] instead. 59743 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59744 if test "x$has_forbidden_chars" != x; then 59745 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59746 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59747 fi 59748 59749 59750 windows_path="$new_path" 59751 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59752 unix_path=`$CYGPATH -u "$windows_path"` 59753 new_path="$unix_path" 59754 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59755 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59756 new_path="$unix_path" 59757 fi 59758 59759 if test "x$path" != "x$new_path"; then 59760 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59761 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59762 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59763 fi 59764 59765 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59766 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59767 59768 else 59769 # We're on a unix platform. Hooray! :) 59770 path="$POTENTIAL_FREETYPE_LIB_PATH" 59771 has_space=`$ECHO "$path" | $GREP " "` 59772 if test "x$has_space" != x; then 59773 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59774 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59775 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59776 fi 59777 59778 # Use eval to expand a potential ~ 59779 eval path="$path" 59780 if test ! -f "$path" && test ! -d "$path"; then 59781 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59782 fi 59783 59784 if test -d "$path"; then 59785 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59786 else 59787 dir="`$DIRNAME "$path"`" 59788 base="`$BASENAME "$path"`" 59789 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59790 fi 59791 fi 59792 fi 59793 59794 59795 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59797 $as_echo_n "checking for freetype includes... " >&6; } 59798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59799 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59800 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59802 $as_echo_n "checking for freetype libraries... " >&6; } 59803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59804 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59805 fi 59806 59807 else 59808 59809 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59810 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59811 METHOD="well-known location" 59812 59813 # Let's start with an optimistic view of the world :-) 59814 FOUND_FREETYPE=yes 59815 59816 # First look for the canonical freetype main include file ft2build.h. 59817 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59818 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59819 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59820 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59821 # Fail. 59822 FOUND_FREETYPE=no 59823 fi 59824 fi 59825 59826 if test "x$FOUND_FREETYPE" = xyes; then 59827 # Include file found, let's continue the sanity check. 59828 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59829 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59830 59831 # Reset to default value 59832 FREETYPE_BASE_NAME=freetype 59833 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59834 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59835 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59836 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59837 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59838 # for the .6 version explicitly. 59839 FREETYPE_BASE_NAME=freetype.6 59840 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59841 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59842 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59843 else 59844 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59845 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59846 FOUND_FREETYPE=no 59847 fi 59848 else 59849 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59850 # On Windows, we will need both .lib and .dll file. 59851 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59852 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59853 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59854 FOUND_FREETYPE=no 59855 fi 59856 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59857 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59858 # Found lib in isa dir, use that instead. 59859 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59860 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59861 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59862 fi 59863 fi 59864 fi 59865 59866 if test "x$FOUND_FREETYPE" = xyes; then 59867 59868 # Only process if variable expands to non-empty 59869 59870 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59871 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59872 59873 # Input might be given as Windows format, start by converting to 59874 # unix format. 59875 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59876 new_path=`$CYGPATH -u "$path"` 59877 59878 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59879 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59880 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59881 # "foo.exe" is OK but "foo" is an error. 59882 # 59883 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59884 # It is also a way to make sure we got the proper file name for the real test later on. 59885 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59886 if test "x$test_shortpath" = x; then 59887 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59888 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59889 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59890 fi 59891 59892 # Call helper function which possibly converts this using DOS-style short mode. 59893 # If so, the updated path is stored in $new_path. 59894 59895 input_path="$new_path" 59896 # Check if we need to convert this using DOS-style short mode. If the path 59897 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59898 # take no chances and rewrite it. 59899 # Note: m4 eats our [], so we need to use [ and ] instead. 59900 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59901 if test "x$has_forbidden_chars" != x; then 59902 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59903 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59904 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59905 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59906 # Going to short mode and back again did indeed matter. Since short mode is 59907 # case insensitive, let's make it lowercase to improve readability. 59908 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59909 # Now convert it back to Unix-style (cygpath) 59910 input_path=`$CYGPATH -u "$shortmode_path"` 59911 new_path="$input_path" 59912 fi 59913 fi 59914 59915 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59916 if test "x$test_cygdrive_prefix" = x; then 59917 # As a simple fix, exclude /usr/bin since it's not a real path. 59918 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59919 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59920 # a path prefixed by /cygdrive for fixpath to work. 59921 new_path="$CYGWIN_ROOT_PATH$input_path" 59922 fi 59923 fi 59924 59925 59926 if test "x$path" != "x$new_path"; then 59927 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59928 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59929 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59930 fi 59931 59932 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59933 59934 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59935 has_colon=`$ECHO $path | $GREP ^.:` 59936 new_path="$path" 59937 if test "x$has_colon" = x; then 59938 # Not in mixed or Windows style, start by that. 59939 new_path=`cmd //c echo $path` 59940 fi 59941 59942 59943 input_path="$new_path" 59944 # Check if we need to convert this using DOS-style short mode. If the path 59945 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59946 # take no chances and rewrite it. 59947 # Note: m4 eats our [], so we need to use [ and ] instead. 59948 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59949 if test "x$has_forbidden_chars" != x; then 59950 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59951 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59952 fi 59953 59954 59955 windows_path="$new_path" 59956 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59957 unix_path=`$CYGPATH -u "$windows_path"` 59958 new_path="$unix_path" 59959 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59960 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59961 new_path="$unix_path" 59962 fi 59963 59964 if test "x$path" != "x$new_path"; then 59965 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59966 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59967 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59968 fi 59969 59970 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59971 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59972 59973 else 59974 # We're on a unix platform. Hooray! :) 59975 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59976 has_space=`$ECHO "$path" | $GREP " "` 59977 if test "x$has_space" != x; then 59978 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59979 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59980 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59981 fi 59982 59983 # Use eval to expand a potential ~ 59984 eval path="$path" 59985 if test ! -f "$path" && test ! -d "$path"; then 59986 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59987 fi 59988 59989 if test -d "$path"; then 59990 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59991 else 59992 dir="`$DIRNAME "$path"`" 59993 base="`$BASENAME "$path"`" 59994 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59995 fi 59996 fi 59997 fi 59998 59999 60000 # Only process if variable expands to non-empty 60001 60002 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60003 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60004 60005 # Input might be given as Windows format, start by converting to 60006 # unix format. 60007 path="$POTENTIAL_FREETYPE_LIB_PATH" 60008 new_path=`$CYGPATH -u "$path"` 60009 60010 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60011 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60012 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60013 # "foo.exe" is OK but "foo" is an error. 60014 # 60015 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60016 # It is also a way to make sure we got the proper file name for the real test later on. 60017 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60018 if test "x$test_shortpath" = x; then 60019 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60020 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60021 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60022 fi 60023 60024 # Call helper function which possibly converts this using DOS-style short mode. 60025 # If so, the updated path is stored in $new_path. 60026 60027 input_path="$new_path" 60028 # Check if we need to convert this using DOS-style short mode. If the path 60029 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60030 # take no chances and rewrite it. 60031 # Note: m4 eats our [], so we need to use [ and ] instead. 60032 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60033 if test "x$has_forbidden_chars" != x; then 60034 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60035 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60036 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60037 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60038 # Going to short mode and back again did indeed matter. Since short mode is 60039 # case insensitive, let's make it lowercase to improve readability. 60040 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60041 # Now convert it back to Unix-style (cygpath) 60042 input_path=`$CYGPATH -u "$shortmode_path"` 60043 new_path="$input_path" 60044 fi 60045 fi 60046 60047 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60048 if test "x$test_cygdrive_prefix" = x; then 60049 # As a simple fix, exclude /usr/bin since it's not a real path. 60050 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60051 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60052 # a path prefixed by /cygdrive for fixpath to work. 60053 new_path="$CYGWIN_ROOT_PATH$input_path" 60054 fi 60055 fi 60056 60057 60058 if test "x$path" != "x$new_path"; then 60059 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60061 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60062 fi 60063 60064 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60065 60066 path="$POTENTIAL_FREETYPE_LIB_PATH" 60067 has_colon=`$ECHO $path | $GREP ^.:` 60068 new_path="$path" 60069 if test "x$has_colon" = x; then 60070 # Not in mixed or Windows style, start by that. 60071 new_path=`cmd //c echo $path` 60072 fi 60073 60074 60075 input_path="$new_path" 60076 # Check if we need to convert this using DOS-style short mode. If the path 60077 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60078 # take no chances and rewrite it. 60079 # Note: m4 eats our [], so we need to use [ and ] instead. 60080 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60081 if test "x$has_forbidden_chars" != x; then 60082 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60083 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60084 fi 60085 60086 60087 windows_path="$new_path" 60088 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60089 unix_path=`$CYGPATH -u "$windows_path"` 60090 new_path="$unix_path" 60091 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60092 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60093 new_path="$unix_path" 60094 fi 60095 60096 if test "x$path" != "x$new_path"; then 60097 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60098 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60099 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60100 fi 60101 60102 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60103 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60104 60105 else 60106 # We're on a unix platform. Hooray! :) 60107 path="$POTENTIAL_FREETYPE_LIB_PATH" 60108 has_space=`$ECHO "$path" | $GREP " "` 60109 if test "x$has_space" != x; then 60110 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60111 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60112 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60113 fi 60114 60115 # Use eval to expand a potential ~ 60116 eval path="$path" 60117 if test ! -f "$path" && test ! -d "$path"; then 60118 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60119 fi 60120 60121 if test -d "$path"; then 60122 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60123 else 60124 dir="`$DIRNAME "$path"`" 60125 base="`$BASENAME "$path"`" 60126 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60127 fi 60128 fi 60129 fi 60130 60131 60132 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60134 $as_echo_n "checking for freetype includes... " >&6; } 60135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60136 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60137 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60139 $as_echo_n "checking for freetype libraries... " >&6; } 60140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60141 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60142 fi 60143 60144 fi 60145 fi 60146 fi 60147 else 60148 FREETYPE_BASE_DIR="$SYSROOT/usr" 60149 60150 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60151 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60152 METHOD="well-known location" 60153 60154 # Let's start with an optimistic view of the world :-) 60155 FOUND_FREETYPE=yes 60156 60157 # First look for the canonical freetype main include file ft2build.h. 60158 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60159 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60160 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60161 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60162 # Fail. 60163 FOUND_FREETYPE=no 60164 fi 60165 fi 60166 60167 if test "x$FOUND_FREETYPE" = xyes; then 60168 # Include file found, let's continue the sanity check. 60169 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60170 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60171 60172 # Reset to default value 60173 FREETYPE_BASE_NAME=freetype 60174 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60175 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60176 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60177 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60178 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60179 # for the .6 version explicitly. 60180 FREETYPE_BASE_NAME=freetype.6 60181 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60182 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60183 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60184 else 60185 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60186 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60187 FOUND_FREETYPE=no 60188 fi 60189 else 60190 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60191 # On Windows, we will need both .lib and .dll file. 60192 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60193 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60194 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60195 FOUND_FREETYPE=no 60196 fi 60197 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60198 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60199 # Found lib in isa dir, use that instead. 60200 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60201 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60202 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60203 fi 60204 fi 60205 fi 60206 60207 if test "x$FOUND_FREETYPE" = xyes; then 60208 60209 # Only process if variable expands to non-empty 60210 60211 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60212 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60213 60214 # Input might be given as Windows format, start by converting to 60215 # unix format. 60216 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60217 new_path=`$CYGPATH -u "$path"` 60218 60219 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60220 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60221 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60222 # "foo.exe" is OK but "foo" is an error. 60223 # 60224 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60225 # It is also a way to make sure we got the proper file name for the real test later on. 60226 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60227 if test "x$test_shortpath" = x; then 60228 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60229 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60230 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60231 fi 60232 60233 # Call helper function which possibly converts this using DOS-style short mode. 60234 # If so, the updated path is stored in $new_path. 60235 60236 input_path="$new_path" 60237 # Check if we need to convert this using DOS-style short mode. If the path 60238 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60239 # take no chances and rewrite it. 60240 # Note: m4 eats our [], so we need to use [ and ] instead. 60241 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60242 if test "x$has_forbidden_chars" != x; then 60243 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60244 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60245 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60246 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60247 # Going to short mode and back again did indeed matter. Since short mode is 60248 # case insensitive, let's make it lowercase to improve readability. 60249 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60250 # Now convert it back to Unix-style (cygpath) 60251 input_path=`$CYGPATH -u "$shortmode_path"` 60252 new_path="$input_path" 60253 fi 60254 fi 60255 60256 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60257 if test "x$test_cygdrive_prefix" = x; then 60258 # As a simple fix, exclude /usr/bin since it's not a real path. 60259 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60260 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60261 # a path prefixed by /cygdrive for fixpath to work. 60262 new_path="$CYGWIN_ROOT_PATH$input_path" 60263 fi 60264 fi 60265 60266 60267 if test "x$path" != "x$new_path"; then 60268 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60269 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60270 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60271 fi 60272 60273 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60274 60275 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60276 has_colon=`$ECHO $path | $GREP ^.:` 60277 new_path="$path" 60278 if test "x$has_colon" = x; then 60279 # Not in mixed or Windows style, start by that. 60280 new_path=`cmd //c echo $path` 60281 fi 60282 60283 60284 input_path="$new_path" 60285 # Check if we need to convert this using DOS-style short mode. If the path 60286 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60287 # take no chances and rewrite it. 60288 # Note: m4 eats our [], so we need to use [ and ] instead. 60289 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60290 if test "x$has_forbidden_chars" != x; then 60291 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60292 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60293 fi 60294 60295 60296 windows_path="$new_path" 60297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60298 unix_path=`$CYGPATH -u "$windows_path"` 60299 new_path="$unix_path" 60300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60301 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60302 new_path="$unix_path" 60303 fi 60304 60305 if test "x$path" != "x$new_path"; then 60306 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60307 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60308 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60309 fi 60310 60311 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60312 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60313 60314 else 60315 # We're on a unix platform. Hooray! :) 60316 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60317 has_space=`$ECHO "$path" | $GREP " "` 60318 if test "x$has_space" != x; then 60319 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60320 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60321 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60322 fi 60323 60324 # Use eval to expand a potential ~ 60325 eval path="$path" 60326 if test ! -f "$path" && test ! -d "$path"; then 60327 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60328 fi 60329 60330 if test -d "$path"; then 60331 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60332 else 60333 dir="`$DIRNAME "$path"`" 60334 base="`$BASENAME "$path"`" 60335 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60336 fi 60337 fi 60338 fi 60339 60340 60341 # Only process if variable expands to non-empty 60342 60343 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60345 60346 # Input might be given as Windows format, start by converting to 60347 # unix format. 60348 path="$POTENTIAL_FREETYPE_LIB_PATH" 60349 new_path=`$CYGPATH -u "$path"` 60350 60351 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60352 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60353 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60354 # "foo.exe" is OK but "foo" is an error. 60355 # 60356 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60357 # It is also a way to make sure we got the proper file name for the real test later on. 60358 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60359 if test "x$test_shortpath" = x; then 60360 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60361 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60362 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60363 fi 60364 60365 # Call helper function which possibly converts this using DOS-style short mode. 60366 # If so, the updated path is stored in $new_path. 60367 60368 input_path="$new_path" 60369 # Check if we need to convert this using DOS-style short mode. If the path 60370 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60371 # take no chances and rewrite it. 60372 # Note: m4 eats our [], so we need to use [ and ] instead. 60373 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60374 if test "x$has_forbidden_chars" != x; then 60375 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60376 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60377 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60378 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60379 # Going to short mode and back again did indeed matter. Since short mode is 60380 # case insensitive, let's make it lowercase to improve readability. 60381 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60382 # Now convert it back to Unix-style (cygpath) 60383 input_path=`$CYGPATH -u "$shortmode_path"` 60384 new_path="$input_path" 60385 fi 60386 fi 60387 60388 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60389 if test "x$test_cygdrive_prefix" = x; then 60390 # As a simple fix, exclude /usr/bin since it's not a real path. 60391 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60392 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60393 # a path prefixed by /cygdrive for fixpath to work. 60394 new_path="$CYGWIN_ROOT_PATH$input_path" 60395 fi 60396 fi 60397 60398 60399 if test "x$path" != "x$new_path"; then 60400 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60401 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60402 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60403 fi 60404 60405 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60406 60407 path="$POTENTIAL_FREETYPE_LIB_PATH" 60408 has_colon=`$ECHO $path | $GREP ^.:` 60409 new_path="$path" 60410 if test "x$has_colon" = x; then 60411 # Not in mixed or Windows style, start by that. 60412 new_path=`cmd //c echo $path` 60413 fi 60414 60415 60416 input_path="$new_path" 60417 # Check if we need to convert this using DOS-style short mode. If the path 60418 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60419 # take no chances and rewrite it. 60420 # Note: m4 eats our [], so we need to use [ and ] instead. 60421 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60422 if test "x$has_forbidden_chars" != x; then 60423 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60424 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60425 fi 60426 60427 60428 windows_path="$new_path" 60429 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60430 unix_path=`$CYGPATH -u "$windows_path"` 60431 new_path="$unix_path" 60432 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60433 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60434 new_path="$unix_path" 60435 fi 60436 60437 if test "x$path" != "x$new_path"; then 60438 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60439 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60440 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60441 fi 60442 60443 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60444 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60445 60446 else 60447 # We're on a unix platform. Hooray! :) 60448 path="$POTENTIAL_FREETYPE_LIB_PATH" 60449 has_space=`$ECHO "$path" | $GREP " "` 60450 if test "x$has_space" != x; then 60451 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60452 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60453 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60454 fi 60455 60456 # Use eval to expand a potential ~ 60457 eval path="$path" 60458 if test ! -f "$path" && test ! -d "$path"; then 60459 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60460 fi 60461 60462 if test -d "$path"; then 60463 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60464 else 60465 dir="`$DIRNAME "$path"`" 60466 base="`$BASENAME "$path"`" 60467 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60468 fi 60469 fi 60470 fi 60471 60472 60473 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60475 $as_echo_n "checking for freetype includes... " >&6; } 60476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60477 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60478 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60480 $as_echo_n "checking for freetype libraries... " >&6; } 60481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60482 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60483 fi 60484 60485 60486 if test "x$FOUND_FREETYPE" != xyes; then 60487 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 60488 60489 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60490 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60491 METHOD="well-known location" 60492 60493 # Let's start with an optimistic view of the world :-) 60494 FOUND_FREETYPE=yes 60495 60496 # First look for the canonical freetype main include file ft2build.h. 60497 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60498 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60499 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60500 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60501 # Fail. 60502 FOUND_FREETYPE=no 60503 fi 60504 fi 60505 60506 if test "x$FOUND_FREETYPE" = xyes; then 60507 # Include file found, let's continue the sanity check. 60508 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60509 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60510 60511 # Reset to default value 60512 FREETYPE_BASE_NAME=freetype 60513 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60514 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60515 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60516 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60517 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60518 # for the .6 version explicitly. 60519 FREETYPE_BASE_NAME=freetype.6 60520 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60521 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60522 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60523 else 60524 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60525 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60526 FOUND_FREETYPE=no 60527 fi 60528 else 60529 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60530 # On Windows, we will need both .lib and .dll file. 60531 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60532 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60533 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60534 FOUND_FREETYPE=no 60535 fi 60536 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60537 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60538 # Found lib in isa dir, use that instead. 60539 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60540 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60541 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60542 fi 60543 fi 60544 fi 60545 60546 if test "x$FOUND_FREETYPE" = xyes; then 60547 60548 # Only process if variable expands to non-empty 60549 60550 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60551 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60552 60553 # Input might be given as Windows format, start by converting to 60554 # unix format. 60555 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60556 new_path=`$CYGPATH -u "$path"` 60557 60558 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60559 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60560 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60561 # "foo.exe" is OK but "foo" is an error. 60562 # 60563 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60564 # It is also a way to make sure we got the proper file name for the real test later on. 60565 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60566 if test "x$test_shortpath" = x; then 60567 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60568 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60569 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60570 fi 60571 60572 # Call helper function which possibly converts this using DOS-style short mode. 60573 # If so, the updated path is stored in $new_path. 60574 60575 input_path="$new_path" 60576 # Check if we need to convert this using DOS-style short mode. If the path 60577 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60578 # take no chances and rewrite it. 60579 # Note: m4 eats our [], so we need to use [ and ] instead. 60580 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60581 if test "x$has_forbidden_chars" != x; then 60582 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60583 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60584 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60585 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60586 # Going to short mode and back again did indeed matter. Since short mode is 60587 # case insensitive, let's make it lowercase to improve readability. 60588 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60589 # Now convert it back to Unix-style (cygpath) 60590 input_path=`$CYGPATH -u "$shortmode_path"` 60591 new_path="$input_path" 60592 fi 60593 fi 60594 60595 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60596 if test "x$test_cygdrive_prefix" = x; then 60597 # As a simple fix, exclude /usr/bin since it's not a real path. 60598 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60599 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60600 # a path prefixed by /cygdrive for fixpath to work. 60601 new_path="$CYGWIN_ROOT_PATH$input_path" 60602 fi 60603 fi 60604 60605 60606 if test "x$path" != "x$new_path"; then 60607 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60608 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60609 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60610 fi 60611 60612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60613 60614 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60615 has_colon=`$ECHO $path | $GREP ^.:` 60616 new_path="$path" 60617 if test "x$has_colon" = x; then 60618 # Not in mixed or Windows style, start by that. 60619 new_path=`cmd //c echo $path` 60620 fi 60621 60622 60623 input_path="$new_path" 60624 # Check if we need to convert this using DOS-style short mode. If the path 60625 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60626 # take no chances and rewrite it. 60627 # Note: m4 eats our [], so we need to use [ and ] instead. 60628 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60629 if test "x$has_forbidden_chars" != x; then 60630 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60631 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60632 fi 60633 60634 60635 windows_path="$new_path" 60636 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60637 unix_path=`$CYGPATH -u "$windows_path"` 60638 new_path="$unix_path" 60639 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60640 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60641 new_path="$unix_path" 60642 fi 60643 60644 if test "x$path" != "x$new_path"; then 60645 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60646 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60647 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60648 fi 60649 60650 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60651 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60652 60653 else 60654 # We're on a unix platform. Hooray! :) 60655 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60656 has_space=`$ECHO "$path" | $GREP " "` 60657 if test "x$has_space" != x; then 60658 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60659 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60660 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60661 fi 60662 60663 # Use eval to expand a potential ~ 60664 eval path="$path" 60665 if test ! -f "$path" && test ! -d "$path"; then 60666 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60667 fi 60668 60669 if test -d "$path"; then 60670 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60671 else 60672 dir="`$DIRNAME "$path"`" 60673 base="`$BASENAME "$path"`" 60674 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60675 fi 60676 fi 60677 fi 60678 60679 60680 # Only process if variable expands to non-empty 60681 60682 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60683 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60684 60685 # Input might be given as Windows format, start by converting to 60686 # unix format. 60687 path="$POTENTIAL_FREETYPE_LIB_PATH" 60688 new_path=`$CYGPATH -u "$path"` 60689 60690 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60691 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60692 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60693 # "foo.exe" is OK but "foo" is an error. 60694 # 60695 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60696 # It is also a way to make sure we got the proper file name for the real test later on. 60697 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60698 if test "x$test_shortpath" = x; then 60699 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60700 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60701 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60702 fi 60703 60704 # Call helper function which possibly converts this using DOS-style short mode. 60705 # If so, the updated path is stored in $new_path. 60706 60707 input_path="$new_path" 60708 # Check if we need to convert this using DOS-style short mode. If the path 60709 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60710 # take no chances and rewrite it. 60711 # Note: m4 eats our [], so we need to use [ and ] instead. 60712 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60713 if test "x$has_forbidden_chars" != x; then 60714 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60715 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60716 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60717 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60718 # Going to short mode and back again did indeed matter. Since short mode is 60719 # case insensitive, let's make it lowercase to improve readability. 60720 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60721 # Now convert it back to Unix-style (cygpath) 60722 input_path=`$CYGPATH -u "$shortmode_path"` 60723 new_path="$input_path" 60724 fi 60725 fi 60726 60727 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60728 if test "x$test_cygdrive_prefix" = x; then 60729 # As a simple fix, exclude /usr/bin since it's not a real path. 60730 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60731 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60732 # a path prefixed by /cygdrive for fixpath to work. 60733 new_path="$CYGWIN_ROOT_PATH$input_path" 60734 fi 60735 fi 60736 60737 60738 if test "x$path" != "x$new_path"; then 60739 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60740 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60741 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60742 fi 60743 60744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60745 60746 path="$POTENTIAL_FREETYPE_LIB_PATH" 60747 has_colon=`$ECHO $path | $GREP ^.:` 60748 new_path="$path" 60749 if test "x$has_colon" = x; then 60750 # Not in mixed or Windows style, start by that. 60751 new_path=`cmd //c echo $path` 60752 fi 60753 60754 60755 input_path="$new_path" 60756 # Check if we need to convert this using DOS-style short mode. If the path 60757 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60758 # take no chances and rewrite it. 60759 # Note: m4 eats our [], so we need to use [ and ] instead. 60760 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60761 if test "x$has_forbidden_chars" != x; then 60762 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60763 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60764 fi 60765 60766 60767 windows_path="$new_path" 60768 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60769 unix_path=`$CYGPATH -u "$windows_path"` 60770 new_path="$unix_path" 60771 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60772 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60773 new_path="$unix_path" 60774 fi 60775 60776 if test "x$path" != "x$new_path"; then 60777 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60778 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60779 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60780 fi 60781 60782 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60783 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60784 60785 else 60786 # We're on a unix platform. Hooray! :) 60787 path="$POTENTIAL_FREETYPE_LIB_PATH" 60788 has_space=`$ECHO "$path" | $GREP " "` 60789 if test "x$has_space" != x; then 60790 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60791 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60792 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60793 fi 60794 60795 # Use eval to expand a potential ~ 60796 eval path="$path" 60797 if test ! -f "$path" && test ! -d "$path"; then 60798 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60799 fi 60800 60801 if test -d "$path"; then 60802 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60803 else 60804 dir="`$DIRNAME "$path"`" 60805 base="`$BASENAME "$path"`" 60806 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60807 fi 60808 fi 60809 fi 60810 60811 60812 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60814 $as_echo_n "checking for freetype includes... " >&6; } 60815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60816 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60817 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60819 $as_echo_n "checking for freetype libraries... " >&6; } 60820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60821 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60822 fi 60823 60824 fi 60825 60826 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 60827 if test "x$FOUND_FREETYPE" != xyes; then 60828 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 60829 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 60830 60831 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60832 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60833 METHOD="well-known location" 60834 60835 # Let's start with an optimistic view of the world :-) 60836 FOUND_FREETYPE=yes 60837 60838 # First look for the canonical freetype main include file ft2build.h. 60839 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60840 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60841 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60842 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60843 # Fail. 60844 FOUND_FREETYPE=no 60845 fi 60846 fi 60847 60848 if test "x$FOUND_FREETYPE" = xyes; then 60849 # Include file found, let's continue the sanity check. 60850 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60851 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60852 60853 # Reset to default value 60854 FREETYPE_BASE_NAME=freetype 60855 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60856 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60857 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60858 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60859 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60860 # for the .6 version explicitly. 60861 FREETYPE_BASE_NAME=freetype.6 60862 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60863 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60864 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60865 else 60866 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60867 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60868 FOUND_FREETYPE=no 60869 fi 60870 else 60871 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60872 # On Windows, we will need both .lib and .dll file. 60873 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60874 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60875 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60876 FOUND_FREETYPE=no 60877 fi 60878 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60879 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60880 # Found lib in isa dir, use that instead. 60881 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60882 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60883 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60884 fi 60885 fi 60886 fi 60887 60888 if test "x$FOUND_FREETYPE" = xyes; then 60889 60890 # Only process if variable expands to non-empty 60891 60892 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60894 60895 # Input might be given as Windows format, start by converting to 60896 # unix format. 60897 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60898 new_path=`$CYGPATH -u "$path"` 60899 60900 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60901 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60902 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60903 # "foo.exe" is OK but "foo" is an error. 60904 # 60905 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60906 # It is also a way to make sure we got the proper file name for the real test later on. 60907 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60908 if test "x$test_shortpath" = x; then 60909 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60910 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60911 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60912 fi 60913 60914 # Call helper function which possibly converts this using DOS-style short mode. 60915 # If so, the updated path is stored in $new_path. 60916 60917 input_path="$new_path" 60918 # Check if we need to convert this using DOS-style short mode. If the path 60919 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60920 # take no chances and rewrite it. 60921 # Note: m4 eats our [], so we need to use [ and ] instead. 60922 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60923 if test "x$has_forbidden_chars" != x; then 60924 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60925 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60926 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60927 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60928 # Going to short mode and back again did indeed matter. Since short mode is 60929 # case insensitive, let's make it lowercase to improve readability. 60930 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60931 # Now convert it back to Unix-style (cygpath) 60932 input_path=`$CYGPATH -u "$shortmode_path"` 60933 new_path="$input_path" 60934 fi 60935 fi 60936 60937 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60938 if test "x$test_cygdrive_prefix" = x; then 60939 # As a simple fix, exclude /usr/bin since it's not a real path. 60940 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60941 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60942 # a path prefixed by /cygdrive for fixpath to work. 60943 new_path="$CYGWIN_ROOT_PATH$input_path" 60944 fi 60945 fi 60946 60947 60948 if test "x$path" != "x$new_path"; then 60949 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60950 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60951 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60952 fi 60953 60954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60955 60956 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60957 has_colon=`$ECHO $path | $GREP ^.:` 60958 new_path="$path" 60959 if test "x$has_colon" = x; then 60960 # Not in mixed or Windows style, start by that. 60961 new_path=`cmd //c echo $path` 60962 fi 60963 60964 60965 input_path="$new_path" 60966 # Check if we need to convert this using DOS-style short mode. If the path 60967 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60968 # take no chances and rewrite it. 60969 # Note: m4 eats our [], so we need to use [ and ] instead. 60970 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60971 if test "x$has_forbidden_chars" != x; then 60972 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60973 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60974 fi 60975 60976 60977 windows_path="$new_path" 60978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60979 unix_path=`$CYGPATH -u "$windows_path"` 60980 new_path="$unix_path" 60981 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60982 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60983 new_path="$unix_path" 60984 fi 60985 60986 if test "x$path" != "x$new_path"; then 60987 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60988 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60989 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60990 fi 60991 60992 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60993 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60994 60995 else 60996 # We're on a unix platform. Hooray! :) 60997 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60998 has_space=`$ECHO "$path" | $GREP " "` 60999 if test "x$has_space" != x; then 61000 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61001 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61002 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61003 fi 61004 61005 # Use eval to expand a potential ~ 61006 eval path="$path" 61007 if test ! -f "$path" && test ! -d "$path"; then 61008 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61009 fi 61010 61011 if test -d "$path"; then 61012 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61013 else 61014 dir="`$DIRNAME "$path"`" 61015 base="`$BASENAME "$path"`" 61016 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61017 fi 61018 fi 61019 fi 61020 61021 61022 # Only process if variable expands to non-empty 61023 61024 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61025 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61026 61027 # Input might be given as Windows format, start by converting to 61028 # unix format. 61029 path="$POTENTIAL_FREETYPE_LIB_PATH" 61030 new_path=`$CYGPATH -u "$path"` 61031 61032 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61033 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61034 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61035 # "foo.exe" is OK but "foo" is an error. 61036 # 61037 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61038 # It is also a way to make sure we got the proper file name for the real test later on. 61039 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61040 if test "x$test_shortpath" = x; then 61041 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61042 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61043 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61044 fi 61045 61046 # Call helper function which possibly converts this using DOS-style short mode. 61047 # If so, the updated path is stored in $new_path. 61048 61049 input_path="$new_path" 61050 # Check if we need to convert this using DOS-style short mode. If the path 61051 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61052 # take no chances and rewrite it. 61053 # Note: m4 eats our [], so we need to use [ and ] instead. 61054 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61055 if test "x$has_forbidden_chars" != x; then 61056 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61057 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61058 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61059 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61060 # Going to short mode and back again did indeed matter. Since short mode is 61061 # case insensitive, let's make it lowercase to improve readability. 61062 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61063 # Now convert it back to Unix-style (cygpath) 61064 input_path=`$CYGPATH -u "$shortmode_path"` 61065 new_path="$input_path" 61066 fi 61067 fi 61068 61069 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61070 if test "x$test_cygdrive_prefix" = x; then 61071 # As a simple fix, exclude /usr/bin since it's not a real path. 61072 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61073 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61074 # a path prefixed by /cygdrive for fixpath to work. 61075 new_path="$CYGWIN_ROOT_PATH$input_path" 61076 fi 61077 fi 61078 61079 61080 if test "x$path" != "x$new_path"; then 61081 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61082 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61083 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61084 fi 61085 61086 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61087 61088 path="$POTENTIAL_FREETYPE_LIB_PATH" 61089 has_colon=`$ECHO $path | $GREP ^.:` 61090 new_path="$path" 61091 if test "x$has_colon" = x; then 61092 # Not in mixed or Windows style, start by that. 61093 new_path=`cmd //c echo $path` 61094 fi 61095 61096 61097 input_path="$new_path" 61098 # Check if we need to convert this using DOS-style short mode. If the path 61099 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61100 # take no chances and rewrite it. 61101 # Note: m4 eats our [], so we need to use [ and ] instead. 61102 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61103 if test "x$has_forbidden_chars" != x; then 61104 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61105 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61106 fi 61107 61108 61109 windows_path="$new_path" 61110 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61111 unix_path=`$CYGPATH -u "$windows_path"` 61112 new_path="$unix_path" 61113 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61114 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61115 new_path="$unix_path" 61116 fi 61117 61118 if test "x$path" != "x$new_path"; then 61119 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61120 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61121 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61122 fi 61123 61124 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61125 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61126 61127 else 61128 # We're on a unix platform. Hooray! :) 61129 path="$POTENTIAL_FREETYPE_LIB_PATH" 61130 has_space=`$ECHO "$path" | $GREP " "` 61131 if test "x$has_space" != x; then 61132 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61133 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61134 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61135 fi 61136 61137 # Use eval to expand a potential ~ 61138 eval path="$path" 61139 if test ! -f "$path" && test ! -d "$path"; then 61140 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61141 fi 61142 61143 if test -d "$path"; then 61144 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61145 else 61146 dir="`$DIRNAME "$path"`" 61147 base="`$BASENAME "$path"`" 61148 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61149 fi 61150 fi 61151 fi 61152 61153 61154 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61156 $as_echo_n "checking for freetype includes... " >&6; } 61157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61158 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61159 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61161 $as_echo_n "checking for freetype libraries... " >&6; } 61162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61163 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61164 fi 61165 61166 fi 61167 fi 61168 61169 if test "x$FOUND_FREETYPE" != xyes; then 61170 FREETYPE_BASE_DIR="$SYSROOT/usr/sfw" 61171 61172 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61173 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61174 METHOD="well-known location" 61175 61176 # Let's start with an optimistic view of the world :-) 61177 FOUND_FREETYPE=yes 61178 61179 # First look for the canonical freetype main include file ft2build.h. 61180 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61181 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61182 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61183 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61184 # Fail. 61185 FOUND_FREETYPE=no 61186 fi 61187 fi 61188 61189 if test "x$FOUND_FREETYPE" = xyes; then 61190 # Include file found, let's continue the sanity check. 61191 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61192 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61193 61194 # Reset to default value 61195 FREETYPE_BASE_NAME=freetype 61196 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61197 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61198 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61199 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61200 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61201 # for the .6 version explicitly. 61202 FREETYPE_BASE_NAME=freetype.6 61203 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61204 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61205 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61206 else 61207 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61208 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61209 FOUND_FREETYPE=no 61210 fi 61211 else 61212 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61213 # On Windows, we will need both .lib and .dll file. 61214 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61215 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61216 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61217 FOUND_FREETYPE=no 61218 fi 61219 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61220 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61221 # Found lib in isa dir, use that instead. 61222 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61223 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61224 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61225 fi 61226 fi 61227 fi 61228 61229 if test "x$FOUND_FREETYPE" = xyes; then 61230 61231 # Only process if variable expands to non-empty 61232 61233 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61234 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61235 61236 # Input might be given as Windows format, start by converting to 61237 # unix format. 61238 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61239 new_path=`$CYGPATH -u "$path"` 61240 61241 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61242 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61243 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61244 # "foo.exe" is OK but "foo" is an error. 61245 # 61246 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61247 # It is also a way to make sure we got the proper file name for the real test later on. 61248 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61249 if test "x$test_shortpath" = x; then 61250 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61251 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61252 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61253 fi 61254 61255 # Call helper function which possibly converts this using DOS-style short mode. 61256 # If so, the updated path is stored in $new_path. 61257 61258 input_path="$new_path" 61259 # Check if we need to convert this using DOS-style short mode. If the path 61260 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61261 # take no chances and rewrite it. 61262 # Note: m4 eats our [], so we need to use [ and ] instead. 61263 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61264 if test "x$has_forbidden_chars" != x; then 61265 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61266 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61267 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61268 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61269 # Going to short mode and back again did indeed matter. Since short mode is 61270 # case insensitive, let's make it lowercase to improve readability. 61271 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61272 # Now convert it back to Unix-style (cygpath) 61273 input_path=`$CYGPATH -u "$shortmode_path"` 61274 new_path="$input_path" 61275 fi 61276 fi 61277 61278 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61279 if test "x$test_cygdrive_prefix" = x; then 61280 # As a simple fix, exclude /usr/bin since it's not a real path. 61281 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61282 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61283 # a path prefixed by /cygdrive for fixpath to work. 61284 new_path="$CYGWIN_ROOT_PATH$input_path" 61285 fi 61286 fi 61287 61288 61289 if test "x$path" != "x$new_path"; then 61290 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61291 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61292 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61293 fi 61294 61295 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61296 61297 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61298 has_colon=`$ECHO $path | $GREP ^.:` 61299 new_path="$path" 61300 if test "x$has_colon" = x; then 61301 # Not in mixed or Windows style, start by that. 61302 new_path=`cmd //c echo $path` 61303 fi 61304 61305 61306 input_path="$new_path" 61307 # Check if we need to convert this using DOS-style short mode. If the path 61308 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61309 # take no chances and rewrite it. 61310 # Note: m4 eats our [], so we need to use [ and ] instead. 61311 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61312 if test "x$has_forbidden_chars" != x; then 61313 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61314 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61315 fi 61316 61317 61318 windows_path="$new_path" 61319 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61320 unix_path=`$CYGPATH -u "$windows_path"` 61321 new_path="$unix_path" 61322 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61323 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61324 new_path="$unix_path" 61325 fi 61326 61327 if test "x$path" != "x$new_path"; then 61328 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61329 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61330 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61331 fi 61332 61333 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61334 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61335 61336 else 61337 # We're on a unix platform. Hooray! :) 61338 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61339 has_space=`$ECHO "$path" | $GREP " "` 61340 if test "x$has_space" != x; then 61341 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61342 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61343 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61344 fi 61345 61346 # Use eval to expand a potential ~ 61347 eval path="$path" 61348 if test ! -f "$path" && test ! -d "$path"; then 61349 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61350 fi 61351 61352 if test -d "$path"; then 61353 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61354 else 61355 dir="`$DIRNAME "$path"`" 61356 base="`$BASENAME "$path"`" 61357 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61358 fi 61359 fi 61360 fi 61361 61362 61363 # Only process if variable expands to non-empty 61364 61365 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61367 61368 # Input might be given as Windows format, start by converting to 61369 # unix format. 61370 path="$POTENTIAL_FREETYPE_LIB_PATH" 61371 new_path=`$CYGPATH -u "$path"` 61372 61373 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61374 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61375 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61376 # "foo.exe" is OK but "foo" is an error. 61377 # 61378 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61379 # It is also a way to make sure we got the proper file name for the real test later on. 61380 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61381 if test "x$test_shortpath" = x; then 61382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61383 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61384 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61385 fi 61386 61387 # Call helper function which possibly converts this using DOS-style short mode. 61388 # If so, the updated path is stored in $new_path. 61389 61390 input_path="$new_path" 61391 # Check if we need to convert this using DOS-style short mode. If the path 61392 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61393 # take no chances and rewrite it. 61394 # Note: m4 eats our [], so we need to use [ and ] instead. 61395 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61396 if test "x$has_forbidden_chars" != x; then 61397 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61398 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61399 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61400 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61401 # Going to short mode and back again did indeed matter. Since short mode is 61402 # case insensitive, let's make it lowercase to improve readability. 61403 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61404 # Now convert it back to Unix-style (cygpath) 61405 input_path=`$CYGPATH -u "$shortmode_path"` 61406 new_path="$input_path" 61407 fi 61408 fi 61409 61410 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61411 if test "x$test_cygdrive_prefix" = x; then 61412 # As a simple fix, exclude /usr/bin since it's not a real path. 61413 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61414 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61415 # a path prefixed by /cygdrive for fixpath to work. 61416 new_path="$CYGWIN_ROOT_PATH$input_path" 61417 fi 61418 fi 61419 61420 61421 if test "x$path" != "x$new_path"; then 61422 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61423 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61424 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61425 fi 61426 61427 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61428 61429 path="$POTENTIAL_FREETYPE_LIB_PATH" 61430 has_colon=`$ECHO $path | $GREP ^.:` 61431 new_path="$path" 61432 if test "x$has_colon" = x; then 61433 # Not in mixed or Windows style, start by that. 61434 new_path=`cmd //c echo $path` 61435 fi 61436 61437 61438 input_path="$new_path" 61439 # Check if we need to convert this using DOS-style short mode. If the path 61440 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61441 # take no chances and rewrite it. 61442 # Note: m4 eats our [], so we need to use [ and ] instead. 61443 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61444 if test "x$has_forbidden_chars" != x; then 61445 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61446 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61447 fi 61448 61449 61450 windows_path="$new_path" 61451 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61452 unix_path=`$CYGPATH -u "$windows_path"` 61453 new_path="$unix_path" 61454 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61455 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61456 new_path="$unix_path" 61457 fi 61458 61459 if test "x$path" != "x$new_path"; then 61460 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61461 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61462 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61463 fi 61464 61465 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61466 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61467 61468 else 61469 # We're on a unix platform. Hooray! :) 61470 path="$POTENTIAL_FREETYPE_LIB_PATH" 61471 has_space=`$ECHO "$path" | $GREP " "` 61472 if test "x$has_space" != x; then 61473 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61474 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61475 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61476 fi 61477 61478 # Use eval to expand a potential ~ 61479 eval path="$path" 61480 if test ! -f "$path" && test ! -d "$path"; then 61481 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61482 fi 61483 61484 if test -d "$path"; then 61485 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61486 else 61487 dir="`$DIRNAME "$path"`" 61488 base="`$BASENAME "$path"`" 61489 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61490 fi 61491 fi 61492 fi 61493 61494 61495 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61497 $as_echo_n "checking for freetype includes... " >&6; } 61498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61499 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61500 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61502 $as_echo_n "checking for freetype libraries... " >&6; } 61503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61504 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61505 fi 61506 61507 fi 61508 61509 if test "x$FOUND_FREETYPE" != xyes; then 61510 FREETYPE_BASE_DIR="$SYSROOT/usr" 61511 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61512 61513 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61514 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu" 61515 METHOD="well-known location" 61516 61517 # Let's start with an optimistic view of the world :-) 61518 FOUND_FREETYPE=yes 61519 61520 # First look for the canonical freetype main include file ft2build.h. 61521 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61522 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61523 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61524 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61525 # Fail. 61526 FOUND_FREETYPE=no 61527 fi 61528 fi 61529 61530 if test "x$FOUND_FREETYPE" = xyes; then 61531 # Include file found, let's continue the sanity check. 61532 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61533 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61534 61535 # Reset to default value 61536 FREETYPE_BASE_NAME=freetype 61537 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61538 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61539 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61540 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61541 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61542 # for the .6 version explicitly. 61543 FREETYPE_BASE_NAME=freetype.6 61544 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61545 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61546 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61547 else 61548 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61549 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61550 FOUND_FREETYPE=no 61551 fi 61552 else 61553 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61554 # On Windows, we will need both .lib and .dll file. 61555 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61556 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61557 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61558 FOUND_FREETYPE=no 61559 fi 61560 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61561 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61562 # Found lib in isa dir, use that instead. 61563 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61564 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61565 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61566 fi 61567 fi 61568 fi 61569 61570 if test "x$FOUND_FREETYPE" = xyes; then 61571 61572 # Only process if variable expands to non-empty 61573 61574 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61575 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61576 61577 # Input might be given as Windows format, start by converting to 61578 # unix format. 61579 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61580 new_path=`$CYGPATH -u "$path"` 61581 61582 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61583 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61584 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61585 # "foo.exe" is OK but "foo" is an error. 61586 # 61587 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61588 # It is also a way to make sure we got the proper file name for the real test later on. 61589 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61590 if test "x$test_shortpath" = x; then 61591 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61592 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61593 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61594 fi 61595 61596 # Call helper function which possibly converts this using DOS-style short mode. 61597 # If so, the updated path is stored in $new_path. 61598 61599 input_path="$new_path" 61600 # Check if we need to convert this using DOS-style short mode. If the path 61601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61602 # take no chances and rewrite it. 61603 # Note: m4 eats our [], so we need to use [ and ] instead. 61604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61605 if test "x$has_forbidden_chars" != x; then 61606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61607 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61608 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61609 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61610 # Going to short mode and back again did indeed matter. Since short mode is 61611 # case insensitive, let's make it lowercase to improve readability. 61612 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61613 # Now convert it back to Unix-style (cygpath) 61614 input_path=`$CYGPATH -u "$shortmode_path"` 61615 new_path="$input_path" 61616 fi 61617 fi 61618 61619 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61620 if test "x$test_cygdrive_prefix" = x; then 61621 # As a simple fix, exclude /usr/bin since it's not a real path. 61622 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61623 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61624 # a path prefixed by /cygdrive for fixpath to work. 61625 new_path="$CYGWIN_ROOT_PATH$input_path" 61626 fi 61627 fi 61628 61629 61630 if test "x$path" != "x$new_path"; then 61631 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61632 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61633 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61634 fi 61635 61636 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61637 61638 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61639 has_colon=`$ECHO $path | $GREP ^.:` 61640 new_path="$path" 61641 if test "x$has_colon" = x; then 61642 # Not in mixed or Windows style, start by that. 61643 new_path=`cmd //c echo $path` 61644 fi 61645 61646 61647 input_path="$new_path" 61648 # Check if we need to convert this using DOS-style short mode. If the path 61649 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61650 # take no chances and rewrite it. 61651 # Note: m4 eats our [], so we need to use [ and ] instead. 61652 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61653 if test "x$has_forbidden_chars" != x; then 61654 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61655 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61656 fi 61657 61658 61659 windows_path="$new_path" 61660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61661 unix_path=`$CYGPATH -u "$windows_path"` 61662 new_path="$unix_path" 61663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61665 new_path="$unix_path" 61666 fi 61667 61668 if test "x$path" != "x$new_path"; then 61669 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61671 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61672 fi 61673 61674 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61675 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61676 61677 else 61678 # We're on a unix platform. Hooray! :) 61679 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61680 has_space=`$ECHO "$path" | $GREP " "` 61681 if test "x$has_space" != x; then 61682 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61683 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61684 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61685 fi 61686 61687 # Use eval to expand a potential ~ 61688 eval path="$path" 61689 if test ! -f "$path" && test ! -d "$path"; then 61690 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61691 fi 61692 61693 if test -d "$path"; then 61694 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61695 else 61696 dir="`$DIRNAME "$path"`" 61697 base="`$BASENAME "$path"`" 61698 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61699 fi 61700 fi 61701 fi 61702 61703 61704 # Only process if variable expands to non-empty 61705 61706 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61708 61709 # Input might be given as Windows format, start by converting to 61710 # unix format. 61711 path="$POTENTIAL_FREETYPE_LIB_PATH" 61712 new_path=`$CYGPATH -u "$path"` 61713 61714 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61715 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61716 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61717 # "foo.exe" is OK but "foo" is an error. 61718 # 61719 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61720 # It is also a way to make sure we got the proper file name for the real test later on. 61721 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61722 if test "x$test_shortpath" = x; then 61723 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61724 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61725 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61726 fi 61727 61728 # Call helper function which possibly converts this using DOS-style short mode. 61729 # If so, the updated path is stored in $new_path. 61730 61731 input_path="$new_path" 61732 # Check if we need to convert this using DOS-style short mode. If the path 61733 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61734 # take no chances and rewrite it. 61735 # Note: m4 eats our [], so we need to use [ and ] instead. 61736 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61737 if test "x$has_forbidden_chars" != x; then 61738 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61739 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61740 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61741 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61742 # Going to short mode and back again did indeed matter. Since short mode is 61743 # case insensitive, let's make it lowercase to improve readability. 61744 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61745 # Now convert it back to Unix-style (cygpath) 61746 input_path=`$CYGPATH -u "$shortmode_path"` 61747 new_path="$input_path" 61748 fi 61749 fi 61750 61751 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61752 if test "x$test_cygdrive_prefix" = x; then 61753 # As a simple fix, exclude /usr/bin since it's not a real path. 61754 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61755 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61756 # a path prefixed by /cygdrive for fixpath to work. 61757 new_path="$CYGWIN_ROOT_PATH$input_path" 61758 fi 61759 fi 61760 61761 61762 if test "x$path" != "x$new_path"; then 61763 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61764 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61765 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61766 fi 61767 61768 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61769 61770 path="$POTENTIAL_FREETYPE_LIB_PATH" 61771 has_colon=`$ECHO $path | $GREP ^.:` 61772 new_path="$path" 61773 if test "x$has_colon" = x; then 61774 # Not in mixed or Windows style, start by that. 61775 new_path=`cmd //c echo $path` 61776 fi 61777 61778 61779 input_path="$new_path" 61780 # Check if we need to convert this using DOS-style short mode. If the path 61781 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61782 # take no chances and rewrite it. 61783 # Note: m4 eats our [], so we need to use [ and ] instead. 61784 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61785 if test "x$has_forbidden_chars" != x; then 61786 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61787 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61788 fi 61789 61790 61791 windows_path="$new_path" 61792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61793 unix_path=`$CYGPATH -u "$windows_path"` 61794 new_path="$unix_path" 61795 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61796 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61797 new_path="$unix_path" 61798 fi 61799 61800 if test "x$path" != "x$new_path"; then 61801 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61802 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61803 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61804 fi 61805 61806 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61807 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61808 61809 else 61810 # We're on a unix platform. Hooray! :) 61811 path="$POTENTIAL_FREETYPE_LIB_PATH" 61812 has_space=`$ECHO "$path" | $GREP " "` 61813 if test "x$has_space" != x; then 61814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61815 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61816 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61817 fi 61818 61819 # Use eval to expand a potential ~ 61820 eval path="$path" 61821 if test ! -f "$path" && test ! -d "$path"; then 61822 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61823 fi 61824 61825 if test -d "$path"; then 61826 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61827 else 61828 dir="`$DIRNAME "$path"`" 61829 base="`$BASENAME "$path"`" 61830 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61831 fi 61832 fi 61833 fi 61834 61835 61836 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61838 $as_echo_n "checking for freetype includes... " >&6; } 61839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61840 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61841 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61843 $as_echo_n "checking for freetype libraries... " >&6; } 61844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61845 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61846 fi 61847 61848 else 61849 61850 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61851 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 61852 METHOD="well-known location" 61853 61854 # Let's start with an optimistic view of the world :-) 61855 FOUND_FREETYPE=yes 61856 61857 # First look for the canonical freetype main include file ft2build.h. 61858 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61859 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61860 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61861 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61862 # Fail. 61863 FOUND_FREETYPE=no 61864 fi 61865 fi 61866 61867 if test "x$FOUND_FREETYPE" = xyes; then 61868 # Include file found, let's continue the sanity check. 61869 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61870 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61871 61872 # Reset to default value 61873 FREETYPE_BASE_NAME=freetype 61874 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61875 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61876 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61877 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61878 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61879 # for the .6 version explicitly. 61880 FREETYPE_BASE_NAME=freetype.6 61881 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61882 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61883 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61884 else 61885 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61886 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61887 FOUND_FREETYPE=no 61888 fi 61889 else 61890 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61891 # On Windows, we will need both .lib and .dll file. 61892 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61893 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61894 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61895 FOUND_FREETYPE=no 61896 fi 61897 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61898 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61899 # Found lib in isa dir, use that instead. 61900 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61902 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61903 fi 61904 fi 61905 fi 61906 61907 if test "x$FOUND_FREETYPE" = xyes; then 61908 61909 # Only process if variable expands to non-empty 61910 61911 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61912 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61913 61914 # Input might be given as Windows format, start by converting to 61915 # unix format. 61916 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61917 new_path=`$CYGPATH -u "$path"` 61918 61919 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61920 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61921 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61922 # "foo.exe" is OK but "foo" is an error. 61923 # 61924 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61925 # It is also a way to make sure we got the proper file name for the real test later on. 61926 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61927 if test "x$test_shortpath" = x; then 61928 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61929 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61930 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61931 fi 61932 61933 # Call helper function which possibly converts this using DOS-style short mode. 61934 # If so, the updated path is stored in $new_path. 61935 61936 input_path="$new_path" 61937 # Check if we need to convert this using DOS-style short mode. If the path 61938 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61939 # take no chances and rewrite it. 61940 # Note: m4 eats our [], so we need to use [ and ] instead. 61941 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61942 if test "x$has_forbidden_chars" != x; then 61943 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61944 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61945 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61946 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61947 # Going to short mode and back again did indeed matter. Since short mode is 61948 # case insensitive, let's make it lowercase to improve readability. 61949 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61950 # Now convert it back to Unix-style (cygpath) 61951 input_path=`$CYGPATH -u "$shortmode_path"` 61952 new_path="$input_path" 61953 fi 61954 fi 61955 61956 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61957 if test "x$test_cygdrive_prefix" = x; then 61958 # As a simple fix, exclude /usr/bin since it's not a real path. 61959 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61960 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61961 # a path prefixed by /cygdrive for fixpath to work. 61962 new_path="$CYGWIN_ROOT_PATH$input_path" 61963 fi 61964 fi 61965 61966 61967 if test "x$path" != "x$new_path"; then 61968 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61969 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61970 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61971 fi 61972 61973 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61974 61975 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61976 has_colon=`$ECHO $path | $GREP ^.:` 61977 new_path="$path" 61978 if test "x$has_colon" = x; then 61979 # Not in mixed or Windows style, start by that. 61980 new_path=`cmd //c echo $path` 61981 fi 61982 61983 61984 input_path="$new_path" 61985 # Check if we need to convert this using DOS-style short mode. If the path 61986 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61987 # take no chances and rewrite it. 61988 # Note: m4 eats our [], so we need to use [ and ] instead. 61989 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61990 if test "x$has_forbidden_chars" != x; then 61991 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61992 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61993 fi 61994 61995 61996 windows_path="$new_path" 61997 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61998 unix_path=`$CYGPATH -u "$windows_path"` 61999 new_path="$unix_path" 62000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62001 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62002 new_path="$unix_path" 62003 fi 62004 62005 if test "x$path" != "x$new_path"; then 62006 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62007 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62008 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62009 fi 62010 62011 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62012 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62013 62014 else 62015 # We're on a unix platform. Hooray! :) 62016 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62017 has_space=`$ECHO "$path" | $GREP " "` 62018 if test "x$has_space" != x; then 62019 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62020 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62021 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62022 fi 62023 62024 # Use eval to expand a potential ~ 62025 eval path="$path" 62026 if test ! -f "$path" && test ! -d "$path"; then 62027 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62028 fi 62029 62030 if test -d "$path"; then 62031 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62032 else 62033 dir="`$DIRNAME "$path"`" 62034 base="`$BASENAME "$path"`" 62035 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62036 fi 62037 fi 62038 fi 62039 62040 62041 # Only process if variable expands to non-empty 62042 62043 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62044 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62045 62046 # Input might be given as Windows format, start by converting to 62047 # unix format. 62048 path="$POTENTIAL_FREETYPE_LIB_PATH" 62049 new_path=`$CYGPATH -u "$path"` 62050 62051 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62052 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62053 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62054 # "foo.exe" is OK but "foo" is an error. 62055 # 62056 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62057 # It is also a way to make sure we got the proper file name for the real test later on. 62058 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62059 if test "x$test_shortpath" = x; then 62060 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62061 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62062 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62063 fi 62064 62065 # Call helper function which possibly converts this using DOS-style short mode. 62066 # If so, the updated path is stored in $new_path. 62067 62068 input_path="$new_path" 62069 # Check if we need to convert this using DOS-style short mode. If the path 62070 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62071 # take no chances and rewrite it. 62072 # Note: m4 eats our [], so we need to use [ and ] instead. 62073 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62074 if test "x$has_forbidden_chars" != x; then 62075 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62076 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62077 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62078 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62079 # Going to short mode and back again did indeed matter. Since short mode is 62080 # case insensitive, let's make it lowercase to improve readability. 62081 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62082 # Now convert it back to Unix-style (cygpath) 62083 input_path=`$CYGPATH -u "$shortmode_path"` 62084 new_path="$input_path" 62085 fi 62086 fi 62087 62088 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62089 if test "x$test_cygdrive_prefix" = x; then 62090 # As a simple fix, exclude /usr/bin since it's not a real path. 62091 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62092 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62093 # a path prefixed by /cygdrive for fixpath to work. 62094 new_path="$CYGWIN_ROOT_PATH$input_path" 62095 fi 62096 fi 62097 62098 62099 if test "x$path" != "x$new_path"; then 62100 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62101 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62102 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62103 fi 62104 62105 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62106 62107 path="$POTENTIAL_FREETYPE_LIB_PATH" 62108 has_colon=`$ECHO $path | $GREP ^.:` 62109 new_path="$path" 62110 if test "x$has_colon" = x; then 62111 # Not in mixed or Windows style, start by that. 62112 new_path=`cmd //c echo $path` 62113 fi 62114 62115 62116 input_path="$new_path" 62117 # Check if we need to convert this using DOS-style short mode. If the path 62118 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62119 # take no chances and rewrite it. 62120 # Note: m4 eats our [], so we need to use [ and ] instead. 62121 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62122 if test "x$has_forbidden_chars" != x; then 62123 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62124 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62125 fi 62126 62127 62128 windows_path="$new_path" 62129 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62130 unix_path=`$CYGPATH -u "$windows_path"` 62131 new_path="$unix_path" 62132 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62133 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62134 new_path="$unix_path" 62135 fi 62136 62137 if test "x$path" != "x$new_path"; then 62138 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62139 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62140 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62141 fi 62142 62143 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62144 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62145 62146 else 62147 # We're on a unix platform. Hooray! :) 62148 path="$POTENTIAL_FREETYPE_LIB_PATH" 62149 has_space=`$ECHO "$path" | $GREP " "` 62150 if test "x$has_space" != x; then 62151 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62152 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62153 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62154 fi 62155 62156 # Use eval to expand a potential ~ 62157 eval path="$path" 62158 if test ! -f "$path" && test ! -d "$path"; then 62159 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62160 fi 62161 62162 if test -d "$path"; then 62163 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62164 else 62165 dir="`$DIRNAME "$path"`" 62166 base="`$BASENAME "$path"`" 62167 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62168 fi 62169 fi 62170 fi 62171 62172 62173 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62175 $as_echo_n "checking for freetype includes... " >&6; } 62176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62177 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62178 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62180 $as_echo_n "checking for freetype libraries... " >&6; } 62181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62182 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62183 fi 62184 62185 if test "x$FOUND_FREETYPE" != xyes; then 62186 62187 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62188 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 62189 METHOD="well-known location" 62190 62191 # Let's start with an optimistic view of the world :-) 62192 FOUND_FREETYPE=yes 62193 62194 # First look for the canonical freetype main include file ft2build.h. 62195 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62196 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62197 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62198 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62199 # Fail. 62200 FOUND_FREETYPE=no 62201 fi 62202 fi 62203 62204 if test "x$FOUND_FREETYPE" = xyes; then 62205 # Include file found, let's continue the sanity check. 62206 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62207 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62208 62209 # Reset to default value 62210 FREETYPE_BASE_NAME=freetype 62211 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62212 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62213 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62214 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62215 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62216 # for the .6 version explicitly. 62217 FREETYPE_BASE_NAME=freetype.6 62218 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62219 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62220 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62221 else 62222 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62223 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62224 FOUND_FREETYPE=no 62225 fi 62226 else 62227 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62228 # On Windows, we will need both .lib and .dll file. 62229 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62230 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62231 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62232 FOUND_FREETYPE=no 62233 fi 62234 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62235 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62236 # Found lib in isa dir, use that instead. 62237 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62238 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62239 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62240 fi 62241 fi 62242 fi 62243 62244 if test "x$FOUND_FREETYPE" = xyes; then 62245 62246 # Only process if variable expands to non-empty 62247 62248 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62249 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62250 62251 # Input might be given as Windows format, start by converting to 62252 # unix format. 62253 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62254 new_path=`$CYGPATH -u "$path"` 62255 62256 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62257 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62258 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62259 # "foo.exe" is OK but "foo" is an error. 62260 # 62261 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62262 # It is also a way to make sure we got the proper file name for the real test later on. 62263 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62264 if test "x$test_shortpath" = x; then 62265 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62266 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62267 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62268 fi 62269 62270 # Call helper function which possibly converts this using DOS-style short mode. 62271 # If so, the updated path is stored in $new_path. 62272 62273 input_path="$new_path" 62274 # Check if we need to convert this using DOS-style short mode. If the path 62275 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62276 # take no chances and rewrite it. 62277 # Note: m4 eats our [], so we need to use [ and ] instead. 62278 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62279 if test "x$has_forbidden_chars" != x; then 62280 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62281 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62282 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62283 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62284 # Going to short mode and back again did indeed matter. Since short mode is 62285 # case insensitive, let's make it lowercase to improve readability. 62286 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62287 # Now convert it back to Unix-style (cygpath) 62288 input_path=`$CYGPATH -u "$shortmode_path"` 62289 new_path="$input_path" 62290 fi 62291 fi 62292 62293 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62294 if test "x$test_cygdrive_prefix" = x; then 62295 # As a simple fix, exclude /usr/bin since it's not a real path. 62296 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62297 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62298 # a path prefixed by /cygdrive for fixpath to work. 62299 new_path="$CYGWIN_ROOT_PATH$input_path" 62300 fi 62301 fi 62302 62303 62304 if test "x$path" != "x$new_path"; then 62305 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62306 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62307 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62308 fi 62309 62310 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62311 62312 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62313 has_colon=`$ECHO $path | $GREP ^.:` 62314 new_path="$path" 62315 if test "x$has_colon" = x; then 62316 # Not in mixed or Windows style, start by that. 62317 new_path=`cmd //c echo $path` 62318 fi 62319 62320 62321 input_path="$new_path" 62322 # Check if we need to convert this using DOS-style short mode. If the path 62323 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62324 # take no chances and rewrite it. 62325 # Note: m4 eats our [], so we need to use [ and ] instead. 62326 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62327 if test "x$has_forbidden_chars" != x; then 62328 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62329 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62330 fi 62331 62332 62333 windows_path="$new_path" 62334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62335 unix_path=`$CYGPATH -u "$windows_path"` 62336 new_path="$unix_path" 62337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62338 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62339 new_path="$unix_path" 62340 fi 62341 62342 if test "x$path" != "x$new_path"; then 62343 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62344 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62345 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62346 fi 62347 62348 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62349 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62350 62351 else 62352 # We're on a unix platform. Hooray! :) 62353 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62354 has_space=`$ECHO "$path" | $GREP " "` 62355 if test "x$has_space" != x; then 62356 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62357 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62358 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62359 fi 62360 62361 # Use eval to expand a potential ~ 62362 eval path="$path" 62363 if test ! -f "$path" && test ! -d "$path"; then 62364 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62365 fi 62366 62367 if test -d "$path"; then 62368 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62369 else 62370 dir="`$DIRNAME "$path"`" 62371 base="`$BASENAME "$path"`" 62372 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62373 fi 62374 fi 62375 fi 62376 62377 62378 # Only process if variable expands to non-empty 62379 62380 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62381 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62382 62383 # Input might be given as Windows format, start by converting to 62384 # unix format. 62385 path="$POTENTIAL_FREETYPE_LIB_PATH" 62386 new_path=`$CYGPATH -u "$path"` 62387 62388 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62389 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62390 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62391 # "foo.exe" is OK but "foo" is an error. 62392 # 62393 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62394 # It is also a way to make sure we got the proper file name for the real test later on. 62395 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62396 if test "x$test_shortpath" = x; then 62397 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62398 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62399 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62400 fi 62401 62402 # Call helper function which possibly converts this using DOS-style short mode. 62403 # If so, the updated path is stored in $new_path. 62404 62405 input_path="$new_path" 62406 # Check if we need to convert this using DOS-style short mode. If the path 62407 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62408 # take no chances and rewrite it. 62409 # Note: m4 eats our [], so we need to use [ and ] instead. 62410 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62411 if test "x$has_forbidden_chars" != x; then 62412 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62413 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62414 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62415 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62416 # Going to short mode and back again did indeed matter. Since short mode is 62417 # case insensitive, let's make it lowercase to improve readability. 62418 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62419 # Now convert it back to Unix-style (cygpath) 62420 input_path=`$CYGPATH -u "$shortmode_path"` 62421 new_path="$input_path" 62422 fi 62423 fi 62424 62425 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62426 if test "x$test_cygdrive_prefix" = x; then 62427 # As a simple fix, exclude /usr/bin since it's not a real path. 62428 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62429 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62430 # a path prefixed by /cygdrive for fixpath to work. 62431 new_path="$CYGWIN_ROOT_PATH$input_path" 62432 fi 62433 fi 62434 62435 62436 if test "x$path" != "x$new_path"; then 62437 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62438 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62439 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62440 fi 62441 62442 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62443 62444 path="$POTENTIAL_FREETYPE_LIB_PATH" 62445 has_colon=`$ECHO $path | $GREP ^.:` 62446 new_path="$path" 62447 if test "x$has_colon" = x; then 62448 # Not in mixed or Windows style, start by that. 62449 new_path=`cmd //c echo $path` 62450 fi 62451 62452 62453 input_path="$new_path" 62454 # Check if we need to convert this using DOS-style short mode. If the path 62455 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62456 # take no chances and rewrite it. 62457 # Note: m4 eats our [], so we need to use [ and ] instead. 62458 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62459 if test "x$has_forbidden_chars" != x; then 62460 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62461 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62462 fi 62463 62464 62465 windows_path="$new_path" 62466 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62467 unix_path=`$CYGPATH -u "$windows_path"` 62468 new_path="$unix_path" 62469 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62470 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62471 new_path="$unix_path" 62472 fi 62473 62474 if test "x$path" != "x$new_path"; then 62475 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62476 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62477 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62478 fi 62479 62480 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62481 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62482 62483 else 62484 # We're on a unix platform. Hooray! :) 62485 path="$POTENTIAL_FREETYPE_LIB_PATH" 62486 has_space=`$ECHO "$path" | $GREP " "` 62487 if test "x$has_space" != x; then 62488 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62489 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62490 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62491 fi 62492 62493 # Use eval to expand a potential ~ 62494 eval path="$path" 62495 if test ! -f "$path" && test ! -d "$path"; then 62496 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62497 fi 62498 62499 if test -d "$path"; then 62500 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62501 else 62502 dir="`$DIRNAME "$path"`" 62503 base="`$BASENAME "$path"`" 62504 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62505 fi 62506 fi 62507 fi 62508 62509 62510 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62512 $as_echo_n "checking for freetype includes... " >&6; } 62513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62514 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62515 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62517 $as_echo_n "checking for freetype libraries... " >&6; } 62518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62519 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62520 fi 62521 62522 fi 62523 fi 62524 fi 62525 fi 62526 fi # end check in well-known locations 62527 62528 if test "x$FOUND_FREETYPE" != xyes; then 62529 62530 # Print a helpful message on how to acquire the necessary build dependency. 62531 # freetype is the help tag: freetype, cups, alsa etc 62532 MISSING_DEPENDENCY=freetype 62533 62534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62535 cygwin_help $MISSING_DEPENDENCY 62536 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62537 msys_help $MISSING_DEPENDENCY 62538 else 62539 PKGHANDLER_COMMAND= 62540 62541 case $PKGHANDLER in 62542 apt-get) 62543 apt_help $MISSING_DEPENDENCY ;; 62544 yum) 62545 yum_help $MISSING_DEPENDENCY ;; 62546 port) 62547 port_help $MISSING_DEPENDENCY ;; 62548 pkgutil) 62549 pkgutil_help $MISSING_DEPENDENCY ;; 62550 pkgadd) 62551 pkgadd_help $MISSING_DEPENDENCY ;; 62552 esac 62553 62554 if test "x$PKGHANDLER_COMMAND" != x; then 62555 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62556 fi 62557 fi 62558 62559 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 62560 fi 62561 fi # end user specified settings 62562 62563 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 62564 if test "x$FREETYPE_CFLAGS" = x; then 62565 62566 # Only process if variable expands to non-empty 62567 62568 if test "x$FREETYPE_INCLUDE_PATH" != x; then 62569 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62570 62571 # Input might be given as Windows format, start by converting to 62572 # unix format. 62573 path="$FREETYPE_INCLUDE_PATH" 62574 new_path=`$CYGPATH -u "$path"` 62575 62576 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62577 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62578 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62579 # "foo.exe" is OK but "foo" is an error. 62580 # 62581 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62582 # It is also a way to make sure we got the proper file name for the real test later on. 62583 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62584 if test "x$test_shortpath" = x; then 62585 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62586 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62587 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 62588 fi 62589 62590 # Call helper function which possibly converts this using DOS-style short mode. 62591 # If so, the updated path is stored in $new_path. 62592 62593 input_path="$new_path" 62594 # Check if we need to convert this using DOS-style short mode. If the path 62595 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62596 # take no chances and rewrite it. 62597 # Note: m4 eats our [], so we need to use [ and ] instead. 62598 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62599 if test "x$has_forbidden_chars" != x; then 62600 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62601 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62602 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62603 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62604 # Going to short mode and back again did indeed matter. Since short mode is 62605 # case insensitive, let's make it lowercase to improve readability. 62606 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62607 # Now convert it back to Unix-style (cygpath) 62608 input_path=`$CYGPATH -u "$shortmode_path"` 62609 new_path="$input_path" 62610 fi 62611 fi 62612 62613 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62614 if test "x$test_cygdrive_prefix" = x; then 62615 # As a simple fix, exclude /usr/bin since it's not a real path. 62616 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62617 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62618 # a path prefixed by /cygdrive for fixpath to work. 62619 new_path="$CYGWIN_ROOT_PATH$input_path" 62620 fi 62621 fi 62622 62623 62624 if test "x$path" != "x$new_path"; then 62625 FREETYPE_INCLUDE_PATH="$new_path" 62626 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62627 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62628 fi 62629 62630 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62631 62632 path="$FREETYPE_INCLUDE_PATH" 62633 has_colon=`$ECHO $path | $GREP ^.:` 62634 new_path="$path" 62635 if test "x$has_colon" = x; then 62636 # Not in mixed or Windows style, start by that. 62637 new_path=`cmd //c echo $path` 62638 fi 62639 62640 62641 input_path="$new_path" 62642 # Check if we need to convert this using DOS-style short mode. If the path 62643 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62644 # take no chances and rewrite it. 62645 # Note: m4 eats our [], so we need to use [ and ] instead. 62646 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62647 if test "x$has_forbidden_chars" != x; then 62648 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62649 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62650 fi 62651 62652 62653 windows_path="$new_path" 62654 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62655 unix_path=`$CYGPATH -u "$windows_path"` 62656 new_path="$unix_path" 62657 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62658 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62659 new_path="$unix_path" 62660 fi 62661 62662 if test "x$path" != "x$new_path"; then 62663 FREETYPE_INCLUDE_PATH="$new_path" 62664 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62665 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62666 fi 62667 62668 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62669 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62670 62671 else 62672 # We're on a unix platform. Hooray! :) 62673 path="$FREETYPE_INCLUDE_PATH" 62674 has_space=`$ECHO "$path" | $GREP " "` 62675 if test "x$has_space" != x; then 62676 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62677 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62678 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62679 fi 62680 62681 # Use eval to expand a potential ~ 62682 eval path="$path" 62683 if test ! -f "$path" && test ! -d "$path"; then 62684 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62685 fi 62686 62687 if test -d "$path"; then 62688 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62689 else 62690 dir="`$DIRNAME "$path"`" 62691 base="`$BASENAME "$path"`" 62692 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62693 fi 62694 fi 62695 fi 62696 62697 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 62698 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 62699 else 62700 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 62701 fi 62702 fi 62703 62704 if test "x$FREETYPE_LIBS" = x; then 62705 62706 # Only process if variable expands to non-empty 62707 62708 if test "x$FREETYPE_LIB_PATH" != x; then 62709 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62710 62711 # Input might be given as Windows format, start by converting to 62712 # unix format. 62713 path="$FREETYPE_LIB_PATH" 62714 new_path=`$CYGPATH -u "$path"` 62715 62716 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62717 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62718 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62719 # "foo.exe" is OK but "foo" is an error. 62720 # 62721 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62722 # It is also a way to make sure we got the proper file name for the real test later on. 62723 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62724 if test "x$test_shortpath" = x; then 62725 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62726 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62727 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 62728 fi 62729 62730 # Call helper function which possibly converts this using DOS-style short mode. 62731 # If so, the updated path is stored in $new_path. 62732 62733 input_path="$new_path" 62734 # Check if we need to convert this using DOS-style short mode. If the path 62735 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62736 # take no chances and rewrite it. 62737 # Note: m4 eats our [], so we need to use [ and ] instead. 62738 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62739 if test "x$has_forbidden_chars" != x; then 62740 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62741 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62742 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62743 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62744 # Going to short mode and back again did indeed matter. Since short mode is 62745 # case insensitive, let's make it lowercase to improve readability. 62746 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62747 # Now convert it back to Unix-style (cygpath) 62748 input_path=`$CYGPATH -u "$shortmode_path"` 62749 new_path="$input_path" 62750 fi 62751 fi 62752 62753 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62754 if test "x$test_cygdrive_prefix" = x; then 62755 # As a simple fix, exclude /usr/bin since it's not a real path. 62756 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62757 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62758 # a path prefixed by /cygdrive for fixpath to work. 62759 new_path="$CYGWIN_ROOT_PATH$input_path" 62760 fi 62761 fi 62762 62763 62764 if test "x$path" != "x$new_path"; then 62765 FREETYPE_LIB_PATH="$new_path" 62766 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62767 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62768 fi 62769 62770 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62771 62772 path="$FREETYPE_LIB_PATH" 62773 has_colon=`$ECHO $path | $GREP ^.:` 62774 new_path="$path" 62775 if test "x$has_colon" = x; then 62776 # Not in mixed or Windows style, start by that. 62777 new_path=`cmd //c echo $path` 62778 fi 62779 62780 62781 input_path="$new_path" 62782 # Check if we need to convert this using DOS-style short mode. If the path 62783 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62784 # take no chances and rewrite it. 62785 # Note: m4 eats our [], so we need to use [ and ] instead. 62786 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62787 if test "x$has_forbidden_chars" != x; then 62788 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62789 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62790 fi 62791 62792 62793 windows_path="$new_path" 62794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62795 unix_path=`$CYGPATH -u "$windows_path"` 62796 new_path="$unix_path" 62797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62798 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62799 new_path="$unix_path" 62800 fi 62801 62802 if test "x$path" != "x$new_path"; then 62803 FREETYPE_LIB_PATH="$new_path" 62804 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62805 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62806 fi 62807 62808 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62809 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62810 62811 else 62812 # We're on a unix platform. Hooray! :) 62813 path="$FREETYPE_LIB_PATH" 62814 has_space=`$ECHO "$path" | $GREP " "` 62815 if test "x$has_space" != x; then 62816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62817 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62818 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62819 fi 62820 62821 # Use eval to expand a potential ~ 62822 eval path="$path" 62823 if test ! -f "$path" && test ! -d "$path"; then 62824 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62825 fi 62826 62827 if test -d "$path"; then 62828 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62829 else 62830 dir="`$DIRNAME "$path"`" 62831 base="`$BASENAME "$path"`" 62832 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62833 fi 62834 fi 62835 fi 62836 62837 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62838 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 62839 else 62840 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 62841 fi 62842 fi 62843 62844 # Try to compile it 62845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 62846 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 62847 ac_ext=cpp 62848 ac_cpp='$CXXCPP $CPPFLAGS' 62849 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62850 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62851 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62852 62853 PREV_CXXCFLAGS="$CXXFLAGS" 62854 PREV_LIBS="$LIBS" 62855 PREV_CXX="$CXX" 62856 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 62857 LIBS="$LIBS $FREETYPE_LIBS" 62858 CXX="$FIXPATH $CXX" 62859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62860 /* end confdefs.h. */ 62861 62862 #include<ft2build.h> 62863 #include FT_FREETYPE_H 62864 int main () { 62865 FT_Init_FreeType(NULL); 62866 return 0; 62867 } 62868 62869 _ACEOF 62870 if ac_fn_cxx_try_link "$LINENO"; then : 62871 62872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62873 $as_echo "yes" >&6; } 62874 62875 else 62876 62877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62878 $as_echo "no" >&6; } 62879 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 62880 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 62881 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 62882 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 62883 62884 62885 # Print a helpful message on how to acquire the necessary build dependency. 62886 # freetype is the help tag: freetype, cups, alsa etc 62887 MISSING_DEPENDENCY=freetype 62888 62889 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62890 cygwin_help $MISSING_DEPENDENCY 62891 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62892 msys_help $MISSING_DEPENDENCY 62893 else 62894 PKGHANDLER_COMMAND= 62895 62896 case $PKGHANDLER in 62897 apt-get) 62898 apt_help $MISSING_DEPENDENCY ;; 62899 yum) 62900 yum_help $MISSING_DEPENDENCY ;; 62901 port) 62902 port_help $MISSING_DEPENDENCY ;; 62903 pkgutil) 62904 pkgutil_help $MISSING_DEPENDENCY ;; 62905 pkgadd) 62906 pkgadd_help $MISSING_DEPENDENCY ;; 62907 esac 62908 62909 if test "x$PKGHANDLER_COMMAND" != x; then 62910 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62911 fi 62912 fi 62913 62914 62915 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 62916 62917 62918 fi 62919 rm -f core conftest.err conftest.$ac_objext \ 62920 conftest$ac_exeext conftest.$ac_ext 62921 CXXCFLAGS="$PREV_CXXFLAGS" 62922 LIBS="$PREV_LIBS" 62923 CXX="$PREV_CXX" 62924 ac_ext=cpp 62925 ac_cpp='$CXXCPP $CPPFLAGS' 62926 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62927 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62928 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62929 62930 62931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 62932 $as_echo_n "checking if we should bundle freetype... " >&6; } 62933 if test "x$BUNDLE_FREETYPE" = xyes; then 62934 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 62935 fi 62936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 62937 $as_echo "$BUNDLE_FREETYPE" >&6; } 62938 62939 fi # end freetype needed 62940 62941 62942 62943 62944 62945 62946 62947 # Check whether --with-alsa was given. 62948 if test "${with_alsa+set}" = set; then : 62949 withval=$with_alsa; 62950 fi 62951 62952 62953 # Check whether --with-alsa-include was given. 62954 if test "${with_alsa_include+set}" = set; then : 62955 withval=$with_alsa_include; 62956 fi 62957 62958 62959 # Check whether --with-alsa-lib was given. 62960 if test "${with_alsa_lib+set}" = set; then : 62961 withval=$with_alsa_lib; 62962 fi 62963 62964 62965 if test "x$NEEDS_LIB_ALSA" = xfalse; then 62966 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 62967 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 62968 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 62969 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 62970 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 62971 fi 62972 ALSA_CFLAGS= 62973 ALSA_LIBS= 62974 else 62975 ALSA_FOUND=no 62976 62977 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 62978 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 62979 fi 62980 62981 if test "x${with_alsa}" != x; then 62982 ALSA_LIBS="-L${with_alsa}/lib -lasound" 62983 ALSA_CFLAGS="-I${with_alsa}/include" 62984 ALSA_FOUND=yes 62985 fi 62986 if test "x${with_alsa_include}" != x; then 62987 ALSA_CFLAGS="-I${with_alsa_include}" 62988 ALSA_FOUND=yes 62989 fi 62990 if test "x${with_alsa_lib}" != x; then 62991 ALSA_LIBS="-L${with_alsa_lib} -lasound" 62992 ALSA_FOUND=yes 62993 fi 62994 # Do not try pkg-config if we have a sysroot set. 62995 if test "x$SYSROOT" = x; then 62996 if test "x$ALSA_FOUND" = xno; then 62997 62998 pkg_failed=no 62999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 63000 $as_echo_n "checking for ALSA... " >&6; } 63001 63002 if test -n "$ALSA_CFLAGS"; then 63003 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 63004 elif test -n "$PKG_CONFIG"; then 63005 if test -n "$PKG_CONFIG" && \ 63006 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 63007 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 63008 ac_status=$? 63009 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63010 test $ac_status = 0; }; then 63011 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 63012 else 63013 pkg_failed=yes 63014 fi 63015 else 63016 pkg_failed=untried 63017 fi 63018 if test -n "$ALSA_LIBS"; then 63019 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 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_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 63028 else 63029 pkg_failed=yes 63030 fi 63031 else 63032 pkg_failed=untried 63033 fi 63034 63035 63036 63037 if test $pkg_failed = yes; then 63038 63039 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63040 _pkg_short_errors_supported=yes 63041 else 63042 _pkg_short_errors_supported=no 63043 fi 63044 if test $_pkg_short_errors_supported = yes; then 63045 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 63046 else 63047 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 63048 fi 63049 # Put the nasty error message in config.log where it belongs 63050 echo "$ALSA_PKG_ERRORS" >&5 63051 63052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63053 $as_echo "no" >&6; } 63054 ALSA_FOUND=no 63055 elif test $pkg_failed = untried; then 63056 ALSA_FOUND=no 63057 else 63058 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 63059 ALSA_LIBS=$pkg_cv_ALSA_LIBS 63060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63061 $as_echo "yes" >&6; } 63062 ALSA_FOUND=yes 63063 fi 63064 fi 63065 fi 63066 if test "x$ALSA_FOUND" = xno; then 63067 for ac_header in alsa/asoundlib.h 63068 do : 63069 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 63070 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 63071 cat >>confdefs.h <<_ACEOF 63072 #define HAVE_ALSA_ASOUNDLIB_H 1 63073 _ACEOF 63074 63075 ALSA_FOUND=yes 63076 ALSA_CFLAGS=-Iignoreme 63077 ALSA_LIBS=-lasound 63078 DEFAULT_ALSA=yes 63079 63080 else 63081 ALSA_FOUND=no 63082 63083 fi 63084 63085 done 63086 63087 fi 63088 if test "x$ALSA_FOUND" = xno; then 63089 63090 # Print a helpful message on how to acquire the necessary build dependency. 63091 # alsa is the help tag: freetype, cups, alsa etc 63092 MISSING_DEPENDENCY=alsa 63093 63094 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63095 cygwin_help $MISSING_DEPENDENCY 63096 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63097 msys_help $MISSING_DEPENDENCY 63098 else 63099 PKGHANDLER_COMMAND= 63100 63101 case $PKGHANDLER in 63102 apt-get) 63103 apt_help $MISSING_DEPENDENCY ;; 63104 yum) 63105 yum_help $MISSING_DEPENDENCY ;; 63106 port) 63107 port_help $MISSING_DEPENDENCY ;; 63108 pkgutil) 63109 pkgutil_help $MISSING_DEPENDENCY ;; 63110 pkgadd) 63111 pkgadd_help $MISSING_DEPENDENCY ;; 63112 esac 63113 63114 if test "x$PKGHANDLER_COMMAND" != x; then 63115 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63116 fi 63117 fi 63118 63119 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 63120 fi 63121 fi 63122 63123 63124 63125 63126 63127 63128 # Check whether --with-libffi was given. 63129 if test "${with_libffi+set}" = set; then : 63130 withval=$with_libffi; 63131 fi 63132 63133 63134 # Check whether --with-libffi-include was given. 63135 if test "${with_libffi_include+set}" = set; then : 63136 withval=$with_libffi_include; 63137 fi 63138 63139 63140 # Check whether --with-libffi-lib was given. 63141 if test "${with_libffi_lib+set}" = set; then : 63142 withval=$with_libffi_lib; 63143 fi 63144 63145 63146 if test "x$NEEDS_LIB_FFI" = xfalse; then 63147 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 63148 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 63149 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 63150 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 63151 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 63152 fi 63153 LIBFFI_CFLAGS= 63154 LIBFFI_LIBS= 63155 else 63156 LIBFFI_FOUND=no 63157 63158 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 63159 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 63160 fi 63161 63162 if test "x${with_libffi}" != x; then 63163 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 63164 LIBFFI_CFLAGS="-I${with_libffi}/include" 63165 LIBFFI_FOUND=yes 63166 fi 63167 if test "x${with_libffi_include}" != x; then 63168 LIBFFI_CFLAGS="-I${with_libffi_include}" 63169 LIBFFI_FOUND=yes 63170 fi 63171 if test "x${with_libffi_lib}" != x; then 63172 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 63173 LIBFFI_FOUND=yes 63174 fi 63175 # Do not try pkg-config if we have a sysroot set. 63176 if test "x$SYSROOT" = x; then 63177 if test "x$LIBFFI_FOUND" = xno; then 63178 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 63179 63180 pkg_failed=no 63181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 63182 $as_echo_n "checking for LIBFFI... " >&6; } 63183 63184 if test -n "$LIBFFI_CFLAGS"; then 63185 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 63186 elif test -n "$PKG_CONFIG"; then 63187 if test -n "$PKG_CONFIG" && \ 63188 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 63189 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 63190 ac_status=$? 63191 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63192 test $ac_status = 0; }; then 63193 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 63194 else 63195 pkg_failed=yes 63196 fi 63197 else 63198 pkg_failed=untried 63199 fi 63200 if test -n "$LIBFFI_LIBS"; then 63201 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 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_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 63210 else 63211 pkg_failed=yes 63212 fi 63213 else 63214 pkg_failed=untried 63215 fi 63216 63217 63218 63219 if test $pkg_failed = yes; then 63220 63221 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63222 _pkg_short_errors_supported=yes 63223 else 63224 _pkg_short_errors_supported=no 63225 fi 63226 if test $_pkg_short_errors_supported = yes; then 63227 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 63228 else 63229 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 63230 fi 63231 # Put the nasty error message in config.log where it belongs 63232 echo "$LIBFFI_PKG_ERRORS" >&5 63233 63234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63235 $as_echo "no" >&6; } 63236 LIBFFI_FOUND=no 63237 elif test $pkg_failed = untried; then 63238 LIBFFI_FOUND=no 63239 else 63240 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 63241 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 63242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63243 $as_echo "yes" >&6; } 63244 LIBFFI_FOUND=yes 63245 fi 63246 fi 63247 fi 63248 if test "x$LIBFFI_FOUND" = xno; then 63249 for ac_header in ffi.h 63250 do : 63251 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 63252 if test "x$ac_cv_header_ffi_h" = xyes; then : 63253 cat >>confdefs.h <<_ACEOF 63254 #define HAVE_FFI_H 1 63255 _ACEOF 63256 63257 LIBFFI_FOUND=yes 63258 LIBFFI_CFLAGS= 63259 LIBFFI_LIBS=-lffi 63260 63261 else 63262 LIBFFI_FOUND=no 63263 63264 fi 63265 63266 done 63267 63268 fi 63269 if test "x$LIBFFI_FOUND" = xno; then 63270 63271 # Print a helpful message on how to acquire the necessary build dependency. 63272 # ffi is the help tag: freetype, cups, alsa etc 63273 MISSING_DEPENDENCY=ffi 63274 63275 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63276 cygwin_help $MISSING_DEPENDENCY 63277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63278 msys_help $MISSING_DEPENDENCY 63279 else 63280 PKGHANDLER_COMMAND= 63281 63282 case $PKGHANDLER in 63283 apt-get) 63284 apt_help $MISSING_DEPENDENCY ;; 63285 yum) 63286 yum_help $MISSING_DEPENDENCY ;; 63287 port) 63288 port_help $MISSING_DEPENDENCY ;; 63289 pkgutil) 63290 pkgutil_help $MISSING_DEPENDENCY ;; 63291 pkgadd) 63292 pkgadd_help $MISSING_DEPENDENCY ;; 63293 esac 63294 63295 if test "x$PKGHANDLER_COMMAND" != x; then 63296 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63297 fi 63298 fi 63299 63300 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 63301 fi 63302 63303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 63304 $as_echo_n "checking if libffi works... " >&6; } 63305 ac_ext=c 63306 ac_cpp='$CPP $CPPFLAGS' 63307 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63308 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63309 ac_compiler_gnu=$ac_cv_c_compiler_gnu 63310 63311 OLD_CFLAGS="$CFLAGS" 63312 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 63313 OLD_LIBS="$LIBS" 63314 LIBS="$LIBS $LIBFFI_LIBS" 63315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63316 /* end confdefs.h. */ 63317 #include <ffi.h> 63318 int 63319 main () 63320 { 63321 63322 ffi_call(NULL, NULL, NULL, NULL); 63323 return 0; 63324 63325 ; 63326 return 0; 63327 } 63328 _ACEOF 63329 if ac_fn_c_try_link "$LINENO"; then : 63330 LIBFFI_WORKS=yes 63331 else 63332 LIBFFI_WORKS=no 63333 63334 fi 63335 rm -f core conftest.err conftest.$ac_objext \ 63336 conftest$ac_exeext conftest.$ac_ext 63337 CFLAGS="$OLD_CFLAGS" 63338 LIBS="$OLD_LIBS" 63339 ac_ext=cpp 63340 ac_cpp='$CXXCPP $CPPFLAGS' 63341 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63342 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63343 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 63344 63345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 63346 $as_echo "$LIBFFI_WORKS" >&6; } 63347 63348 if test "x$LIBFFI_WORKS" = xno; then 63349 63350 # Print a helpful message on how to acquire the necessary build dependency. 63351 # ffi is the help tag: freetype, cups, alsa etc 63352 MISSING_DEPENDENCY=ffi 63353 63354 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63355 cygwin_help $MISSING_DEPENDENCY 63356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63357 msys_help $MISSING_DEPENDENCY 63358 else 63359 PKGHANDLER_COMMAND= 63360 63361 case $PKGHANDLER in 63362 apt-get) 63363 apt_help $MISSING_DEPENDENCY ;; 63364 yum) 63365 yum_help $MISSING_DEPENDENCY ;; 63366 port) 63367 port_help $MISSING_DEPENDENCY ;; 63368 pkgutil) 63369 pkgutil_help $MISSING_DEPENDENCY ;; 63370 pkgadd) 63371 pkgadd_help $MISSING_DEPENDENCY ;; 63372 esac 63373 63374 if test "x$PKGHANDLER_COMMAND" != x; then 63375 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63376 fi 63377 fi 63378 63379 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 63380 fi 63381 fi 63382 63383 63384 63385 63386 63387 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 63388 # Extract the first word of "llvm-config", so it can be a program name with args. 63389 set dummy llvm-config; ac_word=$2 63390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 63391 $as_echo_n "checking for $ac_word... " >&6; } 63392 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 63393 $as_echo_n "(cached) " >&6 63394 else 63395 if test -n "$LLVM_CONFIG"; then 63396 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 63397 else 63398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 63399 for as_dir in $PATH 63400 do 63401 IFS=$as_save_IFS 63402 test -z "$as_dir" && as_dir=. 63403 for ac_exec_ext in '' $ac_executable_extensions; do 63404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 63405 ac_cv_prog_LLVM_CONFIG="llvm-config" 63406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 63407 break 2 63408 fi 63409 done 63410 done 63411 IFS=$as_save_IFS 63412 63413 fi 63414 fi 63415 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 63416 if test -n "$LLVM_CONFIG"; then 63417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 63418 $as_echo "$LLVM_CONFIG" >&6; } 63419 else 63420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63421 $as_echo "no" >&6; } 63422 fi 63423 63424 63425 63426 if test "x$LLVM_CONFIG" != xllvm-config; then 63427 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 63428 fi 63429 63430 llvm_components="jit mcjit engine nativecodegen native" 63431 unset LLVM_CFLAGS 63432 for flag in $("$LLVM_CONFIG" --cxxflags); do 63433 if echo "${flag}" | grep -q '^-[ID]'; then 63434 if test "${flag}" != "-D_DEBUG" ; then 63435 if test "${LLVM_CFLAGS}" != "" ; then 63436 LLVM_CFLAGS="${LLVM_CFLAGS} " 63437 fi 63438 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 63439 fi 63440 fi 63441 done 63442 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 63443 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 63444 63445 unset LLVM_LDFLAGS 63446 for flag in $("${LLVM_CONFIG}" --ldflags); do 63447 if echo "${flag}" | grep -q '^-L'; then 63448 if test "${LLVM_LDFLAGS}" != ""; then 63449 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 63450 fi 63451 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 63452 fi 63453 done 63454 63455 unset LLVM_LIBS 63456 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 63457 if echo "${flag}" | grep -q '^-l'; then 63458 if test "${LLVM_LIBS}" != ""; then 63459 LLVM_LIBS="${LLVM_LIBS} " 63460 fi 63461 LLVM_LIBS="${LLVM_LIBS}${flag}" 63462 fi 63463 done 63464 63465 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 63466 # always properly detect -ltinfo 63467 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 63468 63469 63470 63471 63472 fi 63473 63474 63475 63476 # Check whether --with-libjpeg was given. 63477 if test "${with_libjpeg+set}" = set; then : 63478 withval=$with_libjpeg; 63479 fi 63480 63481 63482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 63483 $as_echo_n "checking for which libjpeg to use... " >&6; } 63484 # default is bundled 63485 DEFAULT_LIBJPEG=bundled 63486 # if user didn't specify, use DEFAULT_LIBJPEG 63487 if test "x${with_libjpeg}" = "x"; then 63488 with_libjpeg=${DEFAULT_LIBJPEG} 63489 fi 63490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 63491 $as_echo "${with_libjpeg}" >&6; } 63492 63493 if test "x${with_libjpeg}" = "xbundled"; then 63494 USE_EXTERNAL_LIBJPEG=false 63495 elif test "x${with_libjpeg}" = "xsystem"; then 63496 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 63497 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 63498 63499 else 63500 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 63501 fi 63502 63503 63504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 63505 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 63506 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 63507 $as_echo_n "(cached) " >&6 63508 else 63509 ac_check_lib_save_LIBS=$LIBS 63510 LIBS="-ljpeg $LIBS" 63511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63512 /* end confdefs.h. */ 63513 63514 /* Override any GCC internal prototype to avoid an error. 63515 Use char because int might match the return type of a GCC 63516 builtin and then its argument prototype would still apply. */ 63517 #ifdef __cplusplus 63518 extern "C" 63519 #endif 63520 char jpeg_CreateDecompress (); 63521 int 63522 main () 63523 { 63524 return jpeg_CreateDecompress (); 63525 ; 63526 return 0; 63527 } 63528 _ACEOF 63529 if ac_fn_cxx_try_link "$LINENO"; then : 63530 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 63531 else 63532 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 63533 fi 63534 rm -f core conftest.err conftest.$ac_objext \ 63535 conftest$ac_exeext conftest.$ac_ext 63536 LIBS=$ac_check_lib_save_LIBS 63537 fi 63538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 63539 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 63540 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 63541 cat >>confdefs.h <<_ACEOF 63542 #define HAVE_LIBJPEG 1 63543 _ACEOF 63544 63545 LIBS="-ljpeg $LIBS" 63546 63547 else 63548 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 63549 fi 63550 63551 63552 USE_EXTERNAL_LIBJPEG=true 63553 else 63554 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 63555 fi 63556 63557 63558 63559 63560 63561 # Check whether --with-giflib was given. 63562 if test "${with_giflib+set}" = set; then : 63563 withval=$with_giflib; 63564 fi 63565 63566 63567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 63568 $as_echo_n "checking for which giflib to use... " >&6; } 63569 # default is bundled 63570 DEFAULT_GIFLIB=bundled 63571 # if user didn't specify, use DEFAULT_GIFLIB 63572 if test "x${with_giflib}" = "x"; then 63573 with_giflib=${DEFAULT_GIFLIB} 63574 fi 63575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 63576 $as_echo "${with_giflib}" >&6; } 63577 63578 if test "x${with_giflib}" = "xbundled"; then 63579 USE_EXTERNAL_LIBGIF=false 63580 elif test "x${with_giflib}" = "xsystem"; then 63581 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 63582 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 63583 63584 else 63585 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 63586 fi 63587 63588 63589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 63590 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 63591 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 63592 $as_echo_n "(cached) " >&6 63593 else 63594 ac_check_lib_save_LIBS=$LIBS 63595 LIBS="-lgif $LIBS" 63596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63597 /* end confdefs.h. */ 63598 63599 /* Override any GCC internal prototype to avoid an error. 63600 Use char because int might match the return type of a GCC 63601 builtin and then its argument prototype would still apply. */ 63602 #ifdef __cplusplus 63603 extern "C" 63604 #endif 63605 char DGifGetCode (); 63606 int 63607 main () 63608 { 63609 return DGifGetCode (); 63610 ; 63611 return 0; 63612 } 63613 _ACEOF 63614 if ac_fn_cxx_try_link "$LINENO"; then : 63615 ac_cv_lib_gif_DGifGetCode=yes 63616 else 63617 ac_cv_lib_gif_DGifGetCode=no 63618 fi 63619 rm -f core conftest.err conftest.$ac_objext \ 63620 conftest$ac_exeext conftest.$ac_ext 63621 LIBS=$ac_check_lib_save_LIBS 63622 fi 63623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 63624 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 63625 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 63626 cat >>confdefs.h <<_ACEOF 63627 #define HAVE_LIBGIF 1 63628 _ACEOF 63629 63630 LIBS="-lgif $LIBS" 63631 63632 else 63633 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 63634 fi 63635 63636 63637 USE_EXTERNAL_LIBGIF=true 63638 else 63639 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 63640 fi 63641 63642 63643 63644 63645 63646 # Check whether --with-libpng was given. 63647 if test "${with_libpng+set}" = set; then : 63648 withval=$with_libpng; 63649 fi 63650 63651 63652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 63653 $as_echo_n "checking for which libpng to use... " >&6; } 63654 63655 # default is bundled 63656 DEFAULT_LIBPNG=bundled 63657 # if user didn't specify, use DEFAULT_LIBPNG 63658 if test "x${with_libpng}" = "x"; then 63659 with_libpng=${DEFAULT_LIBPNG} 63660 fi 63661 63662 if test "x${with_libpng}" = "xbundled"; then 63663 USE_EXTERNAL_LIBPNG=false 63664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63665 $as_echo "bundled" >&6; } 63666 elif test "x${with_libpng}" = "xsystem"; then 63667 63668 pkg_failed=no 63669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 63670 $as_echo_n "checking for PNG... " >&6; } 63671 63672 if test -n "$PNG_CFLAGS"; then 63673 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 63674 elif test -n "$PKG_CONFIG"; then 63675 if test -n "$PKG_CONFIG" && \ 63676 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63677 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63678 ac_status=$? 63679 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63680 test $ac_status = 0; }; then 63681 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 63682 else 63683 pkg_failed=yes 63684 fi 63685 else 63686 pkg_failed=untried 63687 fi 63688 if test -n "$PNG_LIBS"; then 63689 pkg_cv_PNG_LIBS="$PNG_LIBS" 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_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 63698 else 63699 pkg_failed=yes 63700 fi 63701 else 63702 pkg_failed=untried 63703 fi 63704 63705 63706 63707 if test $pkg_failed = yes; then 63708 63709 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63710 _pkg_short_errors_supported=yes 63711 else 63712 _pkg_short_errors_supported=no 63713 fi 63714 if test $_pkg_short_errors_supported = yes; then 63715 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 63716 else 63717 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 63718 fi 63719 # Put the nasty error message in config.log where it belongs 63720 echo "$PNG_PKG_ERRORS" >&5 63721 63722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63723 $as_echo "no" >&6; } 63724 LIBPNG_FOUND=no 63725 elif test $pkg_failed = untried; then 63726 LIBPNG_FOUND=no 63727 else 63728 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 63729 PNG_LIBS=$pkg_cv_PNG_LIBS 63730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63731 $as_echo "yes" >&6; } 63732 LIBPNG_FOUND=yes 63733 fi 63734 if test "x${LIBPNG_FOUND}" = "xyes"; then 63735 USE_EXTERNAL_LIBPNG=true 63736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63737 $as_echo "system" >&6; } 63738 else 63739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63740 $as_echo "system not found" >&6; } 63741 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 63742 fi 63743 else 63744 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 63745 fi 63746 63747 63748 63749 63750 63751 # Check whether --with-zlib was given. 63752 if test "${with_zlib+set}" = set; then : 63753 withval=$with_zlib; 63754 fi 63755 63756 63757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 63758 $as_echo_n "checking for compress in -lz... " >&6; } 63759 if ${ac_cv_lib_z_compress+:} false; then : 63760 $as_echo_n "(cached) " >&6 63761 else 63762 ac_check_lib_save_LIBS=$LIBS 63763 LIBS="-lz $LIBS" 63764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63765 /* end confdefs.h. */ 63766 63767 /* Override any GCC internal prototype to avoid an error. 63768 Use char because int might match the return type of a GCC 63769 builtin and then its argument prototype would still apply. */ 63770 #ifdef __cplusplus 63771 extern "C" 63772 #endif 63773 char compress (); 63774 int 63775 main () 63776 { 63777 return compress (); 63778 ; 63779 return 0; 63780 } 63781 _ACEOF 63782 if ac_fn_cxx_try_link "$LINENO"; then : 63783 ac_cv_lib_z_compress=yes 63784 else 63785 ac_cv_lib_z_compress=no 63786 fi 63787 rm -f core conftest.err conftest.$ac_objext \ 63788 conftest$ac_exeext conftest.$ac_ext 63789 LIBS=$ac_check_lib_save_LIBS 63790 fi 63791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 63792 $as_echo "$ac_cv_lib_z_compress" >&6; } 63793 if test "x$ac_cv_lib_z_compress" = xyes; then : 63794 ZLIB_FOUND=yes 63795 else 63796 ZLIB_FOUND=no 63797 fi 63798 63799 63800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 63801 $as_echo_n "checking for which zlib to use... " >&6; } 63802 63803 DEFAULT_ZLIB=system 63804 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63805 # On windows default is bundled...on others default is system 63806 DEFAULT_ZLIB=bundled 63807 fi 63808 63809 if test "x${ZLIB_FOUND}" != "xyes"; then 63810 # If we don't find any system...set default to bundled 63811 DEFAULT_ZLIB=bundled 63812 fi 63813 63814 # If user didn't specify, use DEFAULT_ZLIB 63815 if test "x${with_zlib}" = "x"; then 63816 with_zlib=${DEFAULT_ZLIB} 63817 fi 63818 63819 if test "x${with_zlib}" = "xbundled"; then 63820 USE_EXTERNAL_LIBZ=false 63821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63822 $as_echo "bundled" >&6; } 63823 elif test "x${with_zlib}" = "xsystem"; then 63824 if test "x${ZLIB_FOUND}" = "xyes"; then 63825 USE_EXTERNAL_LIBZ=true 63826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63827 $as_echo "system" >&6; } 63828 else 63829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63830 $as_echo "system not found" >&6; } 63831 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 63832 fi 63833 else 63834 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 63835 fi 63836 63837 63838 63839 63840 63841 # Check whether --with-lcms was given. 63842 if test "${with_lcms+set}" = set; then : 63843 withval=$with_lcms; 63844 fi 63845 63846 63847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 63848 $as_echo_n "checking for which lcms to use... " >&6; } 63849 63850 DEFAULT_LCMS=bundled 63851 # If user didn't specify, use DEFAULT_LCMS 63852 if test "x${with_lcms}" = "x"; then 63853 with_lcms=${DEFAULT_LCMS} 63854 fi 63855 63856 if test "x${with_lcms}" = "xbundled"; then 63857 USE_EXTERNAL_LCMS=false 63858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63859 $as_echo "bundled" >&6; } 63860 elif test "x${with_lcms}" = "xsystem"; then 63861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63862 $as_echo "system" >&6; } 63863 63864 pkg_failed=no 63865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 63866 $as_echo_n "checking for LCMS... " >&6; } 63867 63868 if test -n "$LCMS_CFLAGS"; then 63869 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 63870 elif test -n "$PKG_CONFIG"; then 63871 if test -n "$PKG_CONFIG" && \ 63872 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63873 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63874 ac_status=$? 63875 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63876 test $ac_status = 0; }; then 63877 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 63878 else 63879 pkg_failed=yes 63880 fi 63881 else 63882 pkg_failed=untried 63883 fi 63884 if test -n "$LCMS_LIBS"; then 63885 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 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_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 63894 else 63895 pkg_failed=yes 63896 fi 63897 else 63898 pkg_failed=untried 63899 fi 63900 63901 63902 63903 if test $pkg_failed = yes; then 63904 63905 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63906 _pkg_short_errors_supported=yes 63907 else 63908 _pkg_short_errors_supported=no 63909 fi 63910 if test $_pkg_short_errors_supported = yes; then 63911 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 63912 else 63913 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 63914 fi 63915 # Put the nasty error message in config.log where it belongs 63916 echo "$LCMS_PKG_ERRORS" >&5 63917 63918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63919 $as_echo "no" >&6; } 63920 LCMS_FOUND=no 63921 elif test $pkg_failed = untried; then 63922 LCMS_FOUND=no 63923 else 63924 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 63925 LCMS_LIBS=$pkg_cv_LCMS_LIBS 63926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63927 $as_echo "yes" >&6; } 63928 LCMS_FOUND=yes 63929 fi 63930 if test "x${LCMS_FOUND}" = "xyes"; then 63931 USE_EXTERNAL_LCMS=true 63932 else 63933 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 63934 fi 63935 else 63936 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 63937 fi 63938 63939 63940 63941 63942 63943 63944 63945 63946 63947 63948 63949 # Setup libm (the maths library) 63950 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 63951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 63952 $as_echo_n "checking for cos in -lm... " >&6; } 63953 if ${ac_cv_lib_m_cos+:} false; then : 63954 $as_echo_n "(cached) " >&6 63955 else 63956 ac_check_lib_save_LIBS=$LIBS 63957 LIBS="-lm $LIBS" 63958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63959 /* end confdefs.h. */ 63960 63961 /* Override any GCC internal prototype to avoid an error. 63962 Use char because int might match the return type of a GCC 63963 builtin and then its argument prototype would still apply. */ 63964 #ifdef __cplusplus 63965 extern "C" 63966 #endif 63967 char cos (); 63968 int 63969 main () 63970 { 63971 return cos (); 63972 ; 63973 return 0; 63974 } 63975 _ACEOF 63976 if ac_fn_cxx_try_link "$LINENO"; then : 63977 ac_cv_lib_m_cos=yes 63978 else 63979 ac_cv_lib_m_cos=no 63980 fi 63981 rm -f core conftest.err conftest.$ac_objext \ 63982 conftest$ac_exeext conftest.$ac_ext 63983 LIBS=$ac_check_lib_save_LIBS 63984 fi 63985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 63986 $as_echo "$ac_cv_lib_m_cos" >&6; } 63987 if test "x$ac_cv_lib_m_cos" = xyes; then : 63988 cat >>confdefs.h <<_ACEOF 63989 #define HAVE_LIBM 1 63990 _ACEOF 63991 63992 LIBS="-lm $LIBS" 63993 63994 else 63995 63996 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 63997 $as_echo "$as_me: Maths library was not found" >&6;} 63998 63999 fi 64000 64001 LIBM="-lm" 64002 else 64003 LIBM="" 64004 fi 64005 64006 64007 # Setup libdl (for dynamic library loading) 64008 save_LIBS="$LIBS" 64009 LIBS="" 64010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 64011 $as_echo_n "checking for dlopen in -ldl... " >&6; } 64012 if ${ac_cv_lib_dl_dlopen+:} false; then : 64013 $as_echo_n "(cached) " >&6 64014 else 64015 ac_check_lib_save_LIBS=$LIBS 64016 LIBS="-ldl $LIBS" 64017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64018 /* end confdefs.h. */ 64019 64020 /* Override any GCC internal prototype to avoid an error. 64021 Use char because int might match the return type of a GCC 64022 builtin and then its argument prototype would still apply. */ 64023 #ifdef __cplusplus 64024 extern "C" 64025 #endif 64026 char dlopen (); 64027 int 64028 main () 64029 { 64030 return dlopen (); 64031 ; 64032 return 0; 64033 } 64034 _ACEOF 64035 if ac_fn_cxx_try_link "$LINENO"; then : 64036 ac_cv_lib_dl_dlopen=yes 64037 else 64038 ac_cv_lib_dl_dlopen=no 64039 fi 64040 rm -f core conftest.err conftest.$ac_objext \ 64041 conftest$ac_exeext conftest.$ac_ext 64042 LIBS=$ac_check_lib_save_LIBS 64043 fi 64044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 64045 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 64046 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 64047 cat >>confdefs.h <<_ACEOF 64048 #define HAVE_LIBDL 1 64049 _ACEOF 64050 64051 LIBS="-ldl $LIBS" 64052 64053 fi 64054 64055 LIBDL="$LIBS" 64056 64057 LIBS="$save_LIBS" 64058 64059 # Deprecated libraries, keep the flags for backwards compatibility 64060 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 64061 64062 64063 # Check whether --with-dxsdk was given. 64064 if test "${with_dxsdk+set}" = set; then : 64065 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 64066 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 64067 fi 64068 64069 64070 64071 64072 # Check whether --with-dxsdk-lib was given. 64073 if test "${with_dxsdk_lib+set}" = set; then : 64074 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 64075 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 64076 fi 64077 64078 64079 64080 64081 # Check whether --with-dxsdk-include was given. 64082 if test "${with_dxsdk_include+set}" = set; then : 64083 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 64084 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 64085 fi 64086 64087 64088 fi 64089 64090 # Control if libzip can use mmap. Available for purposes of overriding. 64091 LIBZIP_CAN_USE_MMAP=true 64092 64093 64094 64095 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 64096 # Find the root of the Solaris Studio installation from the compiler path 64097 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 64098 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 64099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 64100 $as_echo_n "checking for libstlport.so.1... " >&6; } 64101 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 64102 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 64103 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 64104 fi 64105 if test -f "$STLPORT_LIB"; then 64106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 64107 $as_echo "yes, $STLPORT_LIB" >&6; } 64108 64109 # Only process if variable expands to non-empty 64110 64111 if test "x$STLPORT_LIB" != x; then 64112 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64113 64114 # Input might be given as Windows format, start by converting to 64115 # unix format. 64116 path="$STLPORT_LIB" 64117 new_path=`$CYGPATH -u "$path"` 64118 64119 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64120 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64121 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64122 # "foo.exe" is OK but "foo" is an error. 64123 # 64124 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64125 # It is also a way to make sure we got the proper file name for the real test later on. 64126 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64127 if test "x$test_shortpath" = x; then 64128 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 64129 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 64130 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 64131 fi 64132 64133 # Call helper function which possibly converts this using DOS-style short mode. 64134 # If so, the updated path is stored in $new_path. 64135 64136 input_path="$new_path" 64137 # Check if we need to convert this using DOS-style short mode. If the path 64138 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64139 # take no chances and rewrite it. 64140 # Note: m4 eats our [], so we need to use [ and ] instead. 64141 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64142 if test "x$has_forbidden_chars" != x; then 64143 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64144 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64145 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64146 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64147 # Going to short mode and back again did indeed matter. Since short mode is 64148 # case insensitive, let's make it lowercase to improve readability. 64149 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64150 # Now convert it back to Unix-style (cygpath) 64151 input_path=`$CYGPATH -u "$shortmode_path"` 64152 new_path="$input_path" 64153 fi 64154 fi 64155 64156 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64157 if test "x$test_cygdrive_prefix" = x; then 64158 # As a simple fix, exclude /usr/bin since it's not a real path. 64159 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64160 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64161 # a path prefixed by /cygdrive for fixpath to work. 64162 new_path="$CYGWIN_ROOT_PATH$input_path" 64163 fi 64164 fi 64165 64166 64167 if test "x$path" != "x$new_path"; then 64168 STLPORT_LIB="$new_path" 64169 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 64170 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 64171 fi 64172 64173 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64174 64175 path="$STLPORT_LIB" 64176 has_colon=`$ECHO $path | $GREP ^.:` 64177 new_path="$path" 64178 if test "x$has_colon" = x; then 64179 # Not in mixed or Windows style, start by that. 64180 new_path=`cmd //c echo $path` 64181 fi 64182 64183 64184 input_path="$new_path" 64185 # Check if we need to convert this using DOS-style short mode. If the path 64186 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64187 # take no chances and rewrite it. 64188 # Note: m4 eats our [], so we need to use [ and ] instead. 64189 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64190 if test "x$has_forbidden_chars" != x; then 64191 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64192 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64193 fi 64194 64195 64196 windows_path="$new_path" 64197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64198 unix_path=`$CYGPATH -u "$windows_path"` 64199 new_path="$unix_path" 64200 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64201 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64202 new_path="$unix_path" 64203 fi 64204 64205 if test "x$path" != "x$new_path"; then 64206 STLPORT_LIB="$new_path" 64207 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 64208 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 64209 fi 64210 64211 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64212 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64213 64214 else 64215 # We're on a unix platform. Hooray! :) 64216 path="$STLPORT_LIB" 64217 has_space=`$ECHO "$path" | $GREP " "` 64218 if test "x$has_space" != x; then 64219 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 64220 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 64221 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64222 fi 64223 64224 # Use eval to expand a potential ~ 64225 eval path="$path" 64226 if test ! -f "$path" && test ! -d "$path"; then 64227 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 64228 fi 64229 64230 if test -d "$path"; then 64231 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 64232 else 64233 dir="`$DIRNAME "$path"`" 64234 base="`$BASENAME "$path"`" 64235 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 64236 fi 64237 fi 64238 fi 64239 64240 else 64241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 64242 $as_echo "no, not found at $STLPORT_LIB" >&6; } 64243 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 64244 fi 64245 64246 fi 64247 64248 64249 64250 64251 64252 64253 64254 64255 64256 64257 64258 64259 64260 64261 ############################################################################### 64262 # 64263 # We need to do some final tweaking, when everything else is done. 64264 # 64265 ############################################################################### 64266 64267 64268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 64269 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 64270 64271 if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then 64272 ENABLE_INTREE_EC=yes 64273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64274 $as_echo "yes" >&6; } 64275 else 64276 ENABLE_INTREE_EC=no 64277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64278 $as_echo "no" >&6; } 64279 fi 64280 64281 64282 64283 64284 # Check whether --enable-jtreg-failure-handler was given. 64285 if test "${enable_jtreg_failure_handler+set}" = set; then : 64286 enableval=$enable_jtreg_failure_handler; 64287 fi 64288 64289 64290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 64291 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 64292 64293 if test "x$enable_jtreg_failure_handler" = "xyes"; then 64294 if test "x$JT_HOME" = "x"; then 64295 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 64296 else 64297 BUILD_FAILURE_HANDLER=true 64298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64299 $as_echo "yes, forced" >&6; } 64300 fi 64301 elif test "x$enable_jtreg_failure_handler" = "xno"; then 64302 BUILD_FAILURE_HANDLER=false 64303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64304 $as_echo "no, forced" >&6; } 64305 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 64306 || test "x$enable_jtreg_failure_handler" = "x"; then 64307 if test "x$JT_HOME" = "x"; then 64308 BUILD_FAILURE_HANDLER=false 64309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 64310 $as_echo "no, missing jtreg" >&6; } 64311 else 64312 BUILD_FAILURE_HANDLER=true 64313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 64314 $as_echo "yes, jtreg present" >&6; } 64315 fi 64316 else 64317 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 64318 fi 64319 64320 64321 64322 64323 # Check whether --enable-generate-classlist was given. 64324 if test "${enable_generate_classlist+set}" = set; then : 64325 enableval=$enable_generate_classlist; 64326 fi 64327 64328 64329 # Check if it's likely that it's possible to generate the classlist. Depending 64330 # on exact jvm configuration it could be possible anyway. 64331 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ; then 64332 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 64333 else 64334 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 64335 fi 64336 64337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 64338 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 64339 if test "x$enable_generate_classlist" = "xyes"; then 64340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64341 $as_echo "yes, forced" >&6; } 64342 ENABLE_GENERATE_CLASSLIST="true" 64343 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 64344 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&5 64345 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&2;} 64346 fi 64347 elif test "x$enable_generate_classlist" = "xno"; then 64348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64349 $as_echo "no, forced" >&6; } 64350 ENABLE_GENERATE_CLASSLIST="false" 64351 elif test "x$enable_generate_classlist" = "x"; then 64352 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 64353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64354 $as_echo "yes" >&6; } 64355 ENABLE_GENERATE_CLASSLIST="true" 64356 else 64357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64358 $as_echo "no" >&6; } 64359 ENABLE_GENERATE_CLASSLIST="false" 64360 fi 64361 else 64362 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 64363 fi 64364 64365 64366 64367 64368 ############################################################################### 64369 # 64370 # Configure parts of the build that only affect the build performance, 64371 # not the result. 64372 # 64373 ############################################################################### 64374 64375 64376 # How many cores do we have on this build system? 64377 64378 # Check whether --with-num-cores was given. 64379 if test "${with_num_cores+set}" = set; then : 64380 withval=$with_num_cores; 64381 fi 64382 64383 if test "x$with_num_cores" = x; then 64384 # The number of cores were not specified, try to probe them. 64385 64386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 64387 $as_echo_n "checking for number of cores... " >&6; } 64388 NUM_CORES=1 64389 FOUND_CORES=no 64390 64391 if test -f /proc/cpuinfo; then 64392 # Looks like a Linux (or cygwin) system 64393 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 64394 FOUND_CORES=yes 64395 elif test -x /usr/sbin/psrinfo; then 64396 # Looks like a Solaris system 64397 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 64398 FOUND_CORES=yes 64399 elif test -x /usr/sbin/sysctl; then 64400 # Looks like a MacOSX system 64401 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 64402 FOUND_CORES=yes 64403 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 64404 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 64405 FOUND_CORES=yes 64406 elif test -n "$NUMBER_OF_PROCESSORS"; then 64407 # On windows, look in the env 64408 NUM_CORES=$NUMBER_OF_PROCESSORS 64409 FOUND_CORES=yes 64410 fi 64411 64412 if test "x$FOUND_CORES" = xyes; then 64413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 64414 $as_echo "$NUM_CORES" >&6; } 64415 else 64416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 64417 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 64418 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 64419 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 64420 fi 64421 64422 else 64423 NUM_CORES=$with_num_cores 64424 fi 64425 64426 64427 64428 # How much memory do we have on this build system? 64429 64430 # Check whether --with-memory-size was given. 64431 if test "${with_memory_size+set}" = set; then : 64432 withval=$with_memory_size; 64433 fi 64434 64435 if test "x$with_memory_size" = x; then 64436 # The memory size was not specified, try to probe it. 64437 64438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 64439 $as_echo_n "checking for memory size... " >&6; } 64440 # Default to 1024 MB 64441 MEMORY_SIZE=1024 64442 FOUND_MEM=no 64443 64444 if test -f /proc/meminfo; then 64445 # Looks like a Linux (or cygwin) system 64446 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 64447 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 64448 FOUND_MEM=yes 64449 elif test -x /usr/sbin/prtconf; then 64450 # Looks like a Solaris or AIX system 64451 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 64452 FOUND_MEM=yes 64453 elif test -x /usr/sbin/sysctl; then 64454 # Looks like a MacOSX system 64455 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 64456 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64457 FOUND_MEM=yes 64458 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 64459 # Windows, but without cygwin 64460 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 64461 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64462 FOUND_MEM=yes 64463 fi 64464 64465 if test "x$FOUND_MEM" = xyes; then 64466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 64467 $as_echo "$MEMORY_SIZE MB" >&6; } 64468 else 64469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 64470 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 64471 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 64472 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 64473 fi 64474 64475 else 64476 MEMORY_SIZE=$with_memory_size 64477 fi 64478 64479 64480 64481 # Provide a decent default number of parallel jobs for make depending on 64482 # number of cores, amount of memory and machine architecture. 64483 64484 # Check whether --with-jobs was given. 64485 if test "${with_jobs+set}" = set; then : 64486 withval=$with_jobs; 64487 fi 64488 64489 if test "x$with_jobs" = x; then 64490 # Number of jobs was not specified, calculate. 64491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 64492 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 64493 # Approximate memory in GB. 64494 memory_gb=`expr $MEMORY_SIZE / 1024` 64495 # Pick the lowest of memory in gb and number of cores. 64496 if test "$memory_gb" -lt "$NUM_CORES"; then 64497 JOBS="$memory_gb" 64498 else 64499 JOBS="$NUM_CORES" 64500 fi 64501 if test "$JOBS" -eq "0"; then 64502 JOBS=1 64503 fi 64504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 64505 $as_echo "$JOBS" >&6; } 64506 else 64507 JOBS=$with_jobs 64508 fi 64509 64510 64511 64512 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 64513 64514 # Check whether --with-test-jobs was given. 64515 if test "${with_test_jobs+set}" = set; then : 64516 withval=$with_test_jobs; 64517 fi 64518 64519 if test "x$with_test_jobs" = x; then 64520 TEST_JOBS=0 64521 else 64522 TEST_JOBS=$with_test_jobs 64523 fi 64524 64525 64526 64527 # Setup arguments for the boot jdk (after cores and memory have been setup) 64528 64529 ############################################################################## 64530 # 64531 # Specify jvm options for anything that is run with the Boot JDK. 64532 # Not all JVM:s accept the same arguments on the command line. 64533 # 64534 64535 # Check whether --with-boot-jdk-jvmargs was given. 64536 if test "${with_boot_jdk_jvmargs+set}" = set; then : 64537 withval=$with_boot_jdk_jvmargs; 64538 fi 64539 64540 64541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 64542 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 64543 64544 # Disable special log output when a debug build is used as Boot JDK... 64545 64546 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 64547 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 64548 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 64549 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64550 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64551 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64552 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 64553 JVM_ARG_OK=true 64554 else 64555 $ECHO "Arg failed:" >&5 64556 $ECHO "$OUTPUT" >&5 64557 JVM_ARG_OK=false 64558 fi 64559 64560 64561 # Force en-US environment 64562 64563 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 64564 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 64565 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 64566 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64567 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64568 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64569 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 64570 JVM_ARG_OK=true 64571 else 64572 $ECHO "Arg failed:" >&5 64573 $ECHO "$OUTPUT" >&5 64574 JVM_ARG_OK=false 64575 fi 64576 64577 64578 # Apply user provided options. 64579 64580 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 64581 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 64582 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 64583 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64584 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64585 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64586 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 64587 JVM_ARG_OK=true 64588 else 64589 $ECHO "Arg failed:" >&5 64590 $ECHO "$OUTPUT" >&5 64591 JVM_ARG_OK=false 64592 fi 64593 64594 64595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 64596 $as_echo "$boot_jdk_jvmargs" >&6; } 64597 64598 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 64599 JAVA_FLAGS=$boot_jdk_jvmargs 64600 64601 64602 64603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 64604 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 64605 64606 # Starting amount of heap memory. 64607 64608 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 64609 $ECHO "Command: $JAVA -Xms64M -version" >&5 64610 OUTPUT=`$JAVA -Xms64M -version 2>&1` 64611 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64612 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64613 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64614 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 64615 JVM_ARG_OK=true 64616 else 64617 $ECHO "Arg failed:" >&5 64618 $ECHO "$OUTPUT" >&5 64619 JVM_ARG_OK=false 64620 fi 64621 64622 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 64623 64624 # Maximum amount of heap memory and stack size. 64625 JVM_HEAP_LIMIT_32="1024" 64626 # Running a 64 bit JVM allows for and requires a bigger heap 64627 JVM_HEAP_LIMIT_64="1600" 64628 STACK_SIZE_32=768 64629 STACK_SIZE_64=1536 64630 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 64631 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 64632 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 64633 fi 64634 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 64635 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 64636 fi 64637 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 64638 JVM_HEAP_LIMIT_32=512 64639 JVM_HEAP_LIMIT_64=512 64640 fi 64641 64642 if test "x$BOOT_JDK_BITS" = "x32"; then 64643 STACK_SIZE=$STACK_SIZE_32 64644 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 64645 else 64646 STACK_SIZE=$STACK_SIZE_64 64647 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 64648 fi 64649 64650 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 64651 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 64652 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 64653 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64654 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64655 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64656 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 64657 JVM_ARG_OK=true 64658 else 64659 $ECHO "Arg failed:" >&5 64660 $ECHO "$OUTPUT" >&5 64661 JVM_ARG_OK=false 64662 fi 64663 64664 64665 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 64666 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 64667 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 64668 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64669 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64670 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64671 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 64672 JVM_ARG_OK=true 64673 else 64674 $ECHO "Arg failed:" >&5 64675 $ECHO "$OUTPUT" >&5 64676 JVM_ARG_OK=false 64677 fi 64678 64679 64680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 64681 $as_echo "$boot_jdk_jvmargs_big" >&6; } 64682 64683 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 64684 64685 64686 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 64687 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 64688 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 64689 else 64690 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 64691 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 64692 fi 64693 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 64694 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 64695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 64696 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 64697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 64698 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 64699 64700 64701 # By default, the main javac compilations use big 64702 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 64703 64704 64705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 64706 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 64707 64708 # Use serial gc for small short lived tools if possible 64709 64710 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 64711 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 64712 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 64713 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64714 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64715 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64716 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 64717 JVM_ARG_OK=true 64718 else 64719 $ECHO "Arg failed:" >&5 64720 $ECHO "$OUTPUT" >&5 64721 JVM_ARG_OK=false 64722 fi 64723 64724 64725 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 64726 $ECHO "Command: $JAVA -Xms32M -version" >&5 64727 OUTPUT=`$JAVA -Xms32M -version 2>&1` 64728 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64729 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64730 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64731 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 64732 JVM_ARG_OK=true 64733 else 64734 $ECHO "Arg failed:" >&5 64735 $ECHO "$OUTPUT" >&5 64736 JVM_ARG_OK=false 64737 fi 64738 64739 64740 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 64741 $ECHO "Command: $JAVA -Xmx512M -version" >&5 64742 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 64743 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64744 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64745 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64746 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 64747 JVM_ARG_OK=true 64748 else 64749 $ECHO "Arg failed:" >&5 64750 $ECHO "$OUTPUT" >&5 64751 JVM_ARG_OK=false 64752 fi 64753 64754 64755 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 64756 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 64757 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 64758 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64759 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64760 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64761 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 64762 JVM_ARG_OK=true 64763 else 64764 $ECHO "Arg failed:" >&5 64765 $ECHO "$OUTPUT" >&5 64766 JVM_ARG_OK=false 64767 fi 64768 64769 64770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 64771 $as_echo "$boot_jdk_jvmargs_small" >&6; } 64772 64773 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 64774 64775 64776 JAVA_TOOL_FLAGS_SMALL="" 64777 for f in $JAVA_FLAGS_SMALL; do 64778 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 64779 done 64780 64781 64782 64783 # Setup smart javac (after cores and memory have been setup) 64784 64785 64786 # Check whether --with-sjavac-server-java was given. 64787 if test "${with_sjavac_server_java+set}" = set; then : 64788 withval=$with_sjavac_server_java; 64789 fi 64790 64791 64792 if test "x$with_sjavac_server_java" != x; then 64793 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 64794 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 64795 if test "x$FOUND_VERSION" = x; then 64796 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 64797 fi 64798 else 64799 SJAVAC_SERVER_JAVA="$JAVA" 64800 fi 64801 64802 64803 if test "$MEMORY_SIZE" -gt "3000"; then 64804 64805 $ECHO "Check if jvm arg is ok: -d64" >&5 64806 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 64807 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 64808 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64809 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64810 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64811 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" 64812 JVM_ARG_OK=true 64813 else 64814 $ECHO "Arg failed:" >&5 64815 $ECHO "$OUTPUT" >&5 64816 JVM_ARG_OK=false 64817 fi 64818 64819 if test "$JVM_ARG_OK" = true; then 64820 JVM_64BIT=true 64821 JVM_ARG_OK=false 64822 fi 64823 fi 64824 64825 MX_VALUE=`expr $MEMORY_SIZE / 2` 64826 if test "$JVM_64BIT" = true; then 64827 # Set ms lower than mx since more than one instance of the server might 64828 # get launched at the same time before they figure out which instance won. 64829 MS_VALUE=512 64830 if test "$MX_VALUE" -gt "2048"; then 64831 MX_VALUE=2048 64832 fi 64833 else 64834 MS_VALUE=256 64835 if test "$MX_VALUE" -gt "1500"; then 64836 MX_VALUE=1500 64837 fi 64838 fi 64839 if test "$MX_VALUE" -lt "512"; then 64840 MX_VALUE=512 64841 fi 64842 64843 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 64844 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 64845 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 64846 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64847 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64848 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64849 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 64850 JVM_ARG_OK=true 64851 else 64852 $ECHO "Arg failed:" >&5 64853 $ECHO "$OUTPUT" >&5 64854 JVM_ARG_OK=false 64855 fi 64856 64857 64858 64859 # Check whether --enable-sjavac was given. 64860 if test "${enable_sjavac+set}" = set; then : 64861 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 64862 else 64863 ENABLE_SJAVAC="no" 64864 fi 64865 64866 if test "x$JVM_ARG_OK" = "xfalse"; then 64867 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 64868 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 64869 ENABLE_SJAVAC="no" 64870 fi 64871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 64872 $as_echo_n "checking whether to use sjavac... " >&6; } 64873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 64874 $as_echo "$ENABLE_SJAVAC" >&6; } 64875 64876 64877 # Check whether --enable-javac-server was given. 64878 if test "${enable_javac_server+set}" = set; then : 64879 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 64880 else 64881 ENABLE_JAVAC_SERVER="yes" 64882 fi 64883 64884 if test "x$JVM_ARG_OK" = "xfalse"; then 64885 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 64886 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 64887 ENABLE_JAVAC_SERVER="no" 64888 fi 64889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 64890 $as_echo_n "checking whether to use javac server... " >&6; } 64891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 64892 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 64893 64894 64895 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 64896 # When using a server javac, the small client instances do not need much 64897 # resources. 64898 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 64899 fi 64900 64901 64902 # Setup use of icecc if requested 64903 64904 # Check whether --enable-icecc was given. 64905 if test "${enable_icecc+set}" = set; then : 64906 enableval=$enable_icecc; 64907 fi 64908 64909 64910 if test "x${enable_icecc}" = "xyes"; then 64911 64912 64913 64914 # Publish this variable in the help. 64915 64916 64917 if [ -z "${ICECC_CMD+x}" ]; then 64918 # The variable is not set by user, try to locate tool using the code snippet 64919 for ac_prog in icecc 64920 do 64921 # Extract the first word of "$ac_prog", so it can be a program name with args. 64922 set dummy $ac_prog; ac_word=$2 64923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64924 $as_echo_n "checking for $ac_word... " >&6; } 64925 if ${ac_cv_path_ICECC_CMD+:} false; then : 64926 $as_echo_n "(cached) " >&6 64927 else 64928 case $ICECC_CMD in 64929 [\\/]* | ?:[\\/]*) 64930 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64931 ;; 64932 *) 64933 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64934 for as_dir in $PATH 64935 do 64936 IFS=$as_save_IFS 64937 test -z "$as_dir" && as_dir=. 64938 for ac_exec_ext in '' $ac_executable_extensions; do 64939 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64940 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64941 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64942 break 2 64943 fi 64944 done 64945 done 64946 IFS=$as_save_IFS 64947 64948 ;; 64949 esac 64950 fi 64951 ICECC_CMD=$ac_cv_path_ICECC_CMD 64952 if test -n "$ICECC_CMD"; then 64953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64954 $as_echo "$ICECC_CMD" >&6; } 64955 else 64956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64957 $as_echo "no" >&6; } 64958 fi 64959 64960 64961 test -n "$ICECC_CMD" && break 64962 done 64963 64964 else 64965 # The variable is set, but is it from the command line or the environment? 64966 64967 # Try to remove the string !ICECC_CMD! from our list. 64968 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 64969 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64970 # If it failed, the variable was not from the command line. Ignore it, 64971 # but warn the user (except for BASH, which is always set by the calling BASH). 64972 if test "xICECC_CMD" != xBASH; then 64973 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 64974 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 64975 fi 64976 # Try to locate tool using the code snippet 64977 for ac_prog in icecc 64978 do 64979 # Extract the first word of "$ac_prog", so it can be a program name with args. 64980 set dummy $ac_prog; ac_word=$2 64981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64982 $as_echo_n "checking for $ac_word... " >&6; } 64983 if ${ac_cv_path_ICECC_CMD+:} false; then : 64984 $as_echo_n "(cached) " >&6 64985 else 64986 case $ICECC_CMD in 64987 [\\/]* | ?:[\\/]*) 64988 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64989 ;; 64990 *) 64991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64992 for as_dir in $PATH 64993 do 64994 IFS=$as_save_IFS 64995 test -z "$as_dir" && as_dir=. 64996 for ac_exec_ext in '' $ac_executable_extensions; do 64997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64998 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65000 break 2 65001 fi 65002 done 65003 done 65004 IFS=$as_save_IFS 65005 65006 ;; 65007 esac 65008 fi 65009 ICECC_CMD=$ac_cv_path_ICECC_CMD 65010 if test -n "$ICECC_CMD"; then 65011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65012 $as_echo "$ICECC_CMD" >&6; } 65013 else 65014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65015 $as_echo "no" >&6; } 65016 fi 65017 65018 65019 test -n "$ICECC_CMD" && break 65020 done 65021 65022 else 65023 # If it succeeded, then it was overridden by the user. We will use it 65024 # for the tool. 65025 65026 # First remove it from the list of overridden variables, so we can test 65027 # for unknown variables in the end. 65028 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65029 65030 # Check if we try to supply an empty value 65031 if test "x$ICECC_CMD" = x; then 65032 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 65033 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 65034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 65035 $as_echo_n "checking for ICECC_CMD... " >&6; } 65036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65037 $as_echo "disabled" >&6; } 65038 else 65039 # Check if the provided tool contains a complete path. 65040 tool_specified="$ICECC_CMD" 65041 tool_basename="${tool_specified##*/}" 65042 if test "x$tool_basename" = "x$tool_specified"; then 65043 # A command without a complete path is provided, search $PATH. 65044 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 65045 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 65046 # Extract the first word of "$tool_basename", so it can be a program name with args. 65047 set dummy $tool_basename; ac_word=$2 65048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65049 $as_echo_n "checking for $ac_word... " >&6; } 65050 if ${ac_cv_path_ICECC_CMD+:} false; then : 65051 $as_echo_n "(cached) " >&6 65052 else 65053 case $ICECC_CMD in 65054 [\\/]* | ?:[\\/]*) 65055 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 65056 ;; 65057 *) 65058 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65059 for as_dir in $PATH 65060 do 65061 IFS=$as_save_IFS 65062 test -z "$as_dir" && as_dir=. 65063 for ac_exec_ext in '' $ac_executable_extensions; do 65064 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65065 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 65066 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65067 break 2 65068 fi 65069 done 65070 done 65071 IFS=$as_save_IFS 65072 65073 ;; 65074 esac 65075 fi 65076 ICECC_CMD=$ac_cv_path_ICECC_CMD 65077 if test -n "$ICECC_CMD"; then 65078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65079 $as_echo "$ICECC_CMD" >&6; } 65080 else 65081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65082 $as_echo "no" >&6; } 65083 fi 65084 65085 65086 if test "x$ICECC_CMD" = x; then 65087 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65088 fi 65089 else 65090 # Otherwise we believe it is a complete path. Use it as it is. 65091 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 65092 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 65093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 65094 $as_echo_n "checking for ICECC_CMD... " >&6; } 65095 if test ! -x "$tool_specified"; then 65096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65097 $as_echo "not found" >&6; } 65098 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 65099 fi 65100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65101 $as_echo "$tool_specified" >&6; } 65102 fi 65103 fi 65104 fi 65105 65106 fi 65107 65108 65109 65110 if test "x$ICECC_CMD" = x; then 65111 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 65112 fi 65113 65114 65115 old_path="$PATH" 65116 65117 # Look for icecc-create-env in some known places 65118 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 65119 65120 65121 65122 # Publish this variable in the help. 65123 65124 65125 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 65126 # The variable is not set by user, try to locate tool using the code snippet 65127 for ac_prog in icecc-create-env 65128 do 65129 # Extract the first word of "$ac_prog", so it can be a program name with args. 65130 set dummy $ac_prog; ac_word=$2 65131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65132 $as_echo_n "checking for $ac_word... " >&6; } 65133 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65134 $as_echo_n "(cached) " >&6 65135 else 65136 case $ICECC_CREATE_ENV in 65137 [\\/]* | ?:[\\/]*) 65138 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65139 ;; 65140 *) 65141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65142 for as_dir in $PATH 65143 do 65144 IFS=$as_save_IFS 65145 test -z "$as_dir" && as_dir=. 65146 for ac_exec_ext in '' $ac_executable_extensions; do 65147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65148 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65150 break 2 65151 fi 65152 done 65153 done 65154 IFS=$as_save_IFS 65155 65156 ;; 65157 esac 65158 fi 65159 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65160 if test -n "$ICECC_CREATE_ENV"; then 65161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65162 $as_echo "$ICECC_CREATE_ENV" >&6; } 65163 else 65164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65165 $as_echo "no" >&6; } 65166 fi 65167 65168 65169 test -n "$ICECC_CREATE_ENV" && break 65170 done 65171 65172 else 65173 # The variable is set, but is it from the command line or the environment? 65174 65175 # Try to remove the string !ICECC_CREATE_ENV! from our list. 65176 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 65177 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65178 # If it failed, the variable was not from the command line. Ignore it, 65179 # but warn the user (except for BASH, which is always set by the calling BASH). 65180 if test "xICECC_CREATE_ENV" != xBASH; then 65181 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 65182 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 65183 fi 65184 # Try to locate tool using the code snippet 65185 for ac_prog in icecc-create-env 65186 do 65187 # Extract the first word of "$ac_prog", so it can be a program name with args. 65188 set dummy $ac_prog; ac_word=$2 65189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65190 $as_echo_n "checking for $ac_word... " >&6; } 65191 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65192 $as_echo_n "(cached) " >&6 65193 else 65194 case $ICECC_CREATE_ENV in 65195 [\\/]* | ?:[\\/]*) 65196 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65197 ;; 65198 *) 65199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65200 for as_dir in $PATH 65201 do 65202 IFS=$as_save_IFS 65203 test -z "$as_dir" && as_dir=. 65204 for ac_exec_ext in '' $ac_executable_extensions; do 65205 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65206 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65208 break 2 65209 fi 65210 done 65211 done 65212 IFS=$as_save_IFS 65213 65214 ;; 65215 esac 65216 fi 65217 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65218 if test -n "$ICECC_CREATE_ENV"; then 65219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65220 $as_echo "$ICECC_CREATE_ENV" >&6; } 65221 else 65222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65223 $as_echo "no" >&6; } 65224 fi 65225 65226 65227 test -n "$ICECC_CREATE_ENV" && break 65228 done 65229 65230 else 65231 # If it succeeded, then it was overridden by the user. We will use it 65232 # for the tool. 65233 65234 # First remove it from the list of overridden variables, so we can test 65235 # for unknown variables in the end. 65236 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65237 65238 # Check if we try to supply an empty value 65239 if test "x$ICECC_CREATE_ENV" = x; then 65240 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 65241 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 65242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 65243 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 65244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65245 $as_echo "disabled" >&6; } 65246 else 65247 # Check if the provided tool contains a complete path. 65248 tool_specified="$ICECC_CREATE_ENV" 65249 tool_basename="${tool_specified##*/}" 65250 if test "x$tool_basename" = "x$tool_specified"; then 65251 # A command without a complete path is provided, search $PATH. 65252 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 65253 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 65254 # Extract the first word of "$tool_basename", so it can be a program name with args. 65255 set dummy $tool_basename; ac_word=$2 65256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65257 $as_echo_n "checking for $ac_word... " >&6; } 65258 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65259 $as_echo_n "(cached) " >&6 65260 else 65261 case $ICECC_CREATE_ENV in 65262 [\\/]* | ?:[\\/]*) 65263 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65264 ;; 65265 *) 65266 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65267 for as_dir in $PATH 65268 do 65269 IFS=$as_save_IFS 65270 test -z "$as_dir" && as_dir=. 65271 for ac_exec_ext in '' $ac_executable_extensions; do 65272 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65273 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65274 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65275 break 2 65276 fi 65277 done 65278 done 65279 IFS=$as_save_IFS 65280 65281 ;; 65282 esac 65283 fi 65284 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65285 if test -n "$ICECC_CREATE_ENV"; then 65286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65287 $as_echo "$ICECC_CREATE_ENV" >&6; } 65288 else 65289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65290 $as_echo "no" >&6; } 65291 fi 65292 65293 65294 if test "x$ICECC_CREATE_ENV" = x; then 65295 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65296 fi 65297 else 65298 # Otherwise we believe it is a complete path. Use it as it is. 65299 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 65300 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 65301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 65302 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 65303 if test ! -x "$tool_specified"; then 65304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65305 $as_echo "not found" >&6; } 65306 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 65307 fi 65308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65309 $as_echo "$tool_specified" >&6; } 65310 fi 65311 fi 65312 fi 65313 65314 fi 65315 65316 65317 65318 if test "x$ICECC_CREATE_ENV" = x; then 65319 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 65320 fi 65321 65322 65323 # Use icecc-create-env to create a minimal compilation environment that can 65324 # be sent to the other hosts in the icecream cluster. 65325 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 65326 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 65327 # Older versions of icecc does not have the --gcc parameter 65328 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 65329 icecc_gcc_arg="--gcc" 65330 fi 65331 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 65332 65333 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65334 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 65335 ${icecc_create_env_log} 2>&1 ) 65336 if test "$?" != "0"; then 65337 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65338 $as_echo "$as_me: icecc-create-env output:" >&6;} 65339 cat \ 65340 ${icecc_create_env_log} 65341 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65342 fi 65343 65344 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 65345 # For clang, the icecc compilerwrapper is needed. It usually resides next 65346 # to icecc-create-env. 65347 65348 65349 65350 # Publish this variable in the help. 65351 65352 65353 if [ -z "${ICECC_WRAPPER+x}" ]; then 65354 # The variable is not set by user, try to locate tool using the code snippet 65355 for ac_prog in compilerwrapper 65356 do 65357 # Extract the first word of "$ac_prog", so it can be a program name with args. 65358 set dummy $ac_prog; ac_word=$2 65359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65360 $as_echo_n "checking for $ac_word... " >&6; } 65361 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65362 $as_echo_n "(cached) " >&6 65363 else 65364 case $ICECC_WRAPPER in 65365 [\\/]* | ?:[\\/]*) 65366 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65367 ;; 65368 *) 65369 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65370 for as_dir in $PATH 65371 do 65372 IFS=$as_save_IFS 65373 test -z "$as_dir" && as_dir=. 65374 for ac_exec_ext in '' $ac_executable_extensions; do 65375 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65376 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65377 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65378 break 2 65379 fi 65380 done 65381 done 65382 IFS=$as_save_IFS 65383 65384 ;; 65385 esac 65386 fi 65387 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65388 if test -n "$ICECC_WRAPPER"; then 65389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65390 $as_echo "$ICECC_WRAPPER" >&6; } 65391 else 65392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65393 $as_echo "no" >&6; } 65394 fi 65395 65396 65397 test -n "$ICECC_WRAPPER" && break 65398 done 65399 65400 else 65401 # The variable is set, but is it from the command line or the environment? 65402 65403 # Try to remove the string !ICECC_WRAPPER! from our list. 65404 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 65405 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65406 # If it failed, the variable was not from the command line. Ignore it, 65407 # but warn the user (except for BASH, which is always set by the calling BASH). 65408 if test "xICECC_WRAPPER" != xBASH; then 65409 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 65410 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 65411 fi 65412 # Try to locate tool using the code snippet 65413 for ac_prog in compilerwrapper 65414 do 65415 # Extract the first word of "$ac_prog", so it can be a program name with args. 65416 set dummy $ac_prog; ac_word=$2 65417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65418 $as_echo_n "checking for $ac_word... " >&6; } 65419 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65420 $as_echo_n "(cached) " >&6 65421 else 65422 case $ICECC_WRAPPER in 65423 [\\/]* | ?:[\\/]*) 65424 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65425 ;; 65426 *) 65427 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65428 for as_dir in $PATH 65429 do 65430 IFS=$as_save_IFS 65431 test -z "$as_dir" && as_dir=. 65432 for ac_exec_ext in '' $ac_executable_extensions; do 65433 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65434 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65435 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65436 break 2 65437 fi 65438 done 65439 done 65440 IFS=$as_save_IFS 65441 65442 ;; 65443 esac 65444 fi 65445 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65446 if test -n "$ICECC_WRAPPER"; then 65447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65448 $as_echo "$ICECC_WRAPPER" >&6; } 65449 else 65450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65451 $as_echo "no" >&6; } 65452 fi 65453 65454 65455 test -n "$ICECC_WRAPPER" && break 65456 done 65457 65458 else 65459 # If it succeeded, then it was overridden by the user. We will use it 65460 # for the tool. 65461 65462 # First remove it from the list of overridden variables, so we can test 65463 # for unknown variables in the end. 65464 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65465 65466 # Check if we try to supply an empty value 65467 if test "x$ICECC_WRAPPER" = x; then 65468 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 65469 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 65470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65471 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65473 $as_echo "disabled" >&6; } 65474 else 65475 # Check if the provided tool contains a complete path. 65476 tool_specified="$ICECC_WRAPPER" 65477 tool_basename="${tool_specified##*/}" 65478 if test "x$tool_basename" = "x$tool_specified"; then 65479 # A command without a complete path is provided, search $PATH. 65480 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 65481 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 65482 # Extract the first word of "$tool_basename", so it can be a program name with args. 65483 set dummy $tool_basename; ac_word=$2 65484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65485 $as_echo_n "checking for $ac_word... " >&6; } 65486 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65487 $as_echo_n "(cached) " >&6 65488 else 65489 case $ICECC_WRAPPER in 65490 [\\/]* | ?:[\\/]*) 65491 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65492 ;; 65493 *) 65494 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65495 for as_dir in $PATH 65496 do 65497 IFS=$as_save_IFS 65498 test -z "$as_dir" && as_dir=. 65499 for ac_exec_ext in '' $ac_executable_extensions; do 65500 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65501 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65502 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65503 break 2 65504 fi 65505 done 65506 done 65507 IFS=$as_save_IFS 65508 65509 ;; 65510 esac 65511 fi 65512 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65513 if test -n "$ICECC_WRAPPER"; then 65514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65515 $as_echo "$ICECC_WRAPPER" >&6; } 65516 else 65517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65518 $as_echo "no" >&6; } 65519 fi 65520 65521 65522 if test "x$ICECC_WRAPPER" = x; then 65523 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65524 fi 65525 else 65526 # Otherwise we believe it is a complete path. Use it as it is. 65527 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 65528 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 65529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65530 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65531 if test ! -x "$tool_specified"; then 65532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65533 $as_echo "not found" >&6; } 65534 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 65535 fi 65536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65537 $as_echo "$tool_specified" >&6; } 65538 fi 65539 fi 65540 fi 65541 65542 fi 65543 65544 65545 65546 if test "x$ICECC_WRAPPER" = x; then 65547 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 65548 fi 65549 65550 65551 65552 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65553 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 65554 if test "$?" != "0"; then 65555 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65556 $as_echo "$as_me: icecc-create-env output:" >&6;} 65557 cat ${icecc_create_env_log} 65558 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65559 fi 65560 65561 else 65562 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 65563 fi 65564 PATH="$old_path" 65565 # The bundle with the compiler gets a name based on checksums. Parse log file 65566 # to find it. 65567 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 65568 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65569 if test ! -f ${ICECC_ENV_BUNDLE}; then 65570 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65571 fi 65572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 65573 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 65574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65575 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65576 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 65577 65578 if test "x${COMPILE_TYPE}" = "xcross"; then 65579 # If cross compiling, create a separate env package for the build compiler 65580 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 65581 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 65582 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 65583 65584 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65585 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 65586 ${icecc_create_env_log_build} 2>&1 ) 65587 if test "$?" != "0"; then 65588 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65589 $as_echo "$as_me: icecc-create-env output:" >&6;} 65590 cat \ 65591 ${icecc_create_env_log_build} 65592 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65593 fi 65594 65595 elif test "x${BUILD_CC##*/}" = "xclang"; then 65596 65597 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65598 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 65599 if test "$?" != "0"; then 65600 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65601 $as_echo "$as_me: icecc-create-env output:" >&6;} 65602 cat ${icecc_create_env_log_build} 65603 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65604 fi 65605 65606 else 65607 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 65608 fi 65609 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 65610 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65611 if test ! -f ${ICECC_ENV_BUNDLE}; then 65612 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65613 fi 65614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 65615 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 65616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65617 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65618 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 65619 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 65620 else 65621 BUILD_ICECC="${ICECC}" 65622 fi 65623 65624 65625 fi 65626 65627 65628 # Can the C/C++ compiler use precompiled headers? 65629 65630 65631 ############################################################################### 65632 # 65633 # Can the C/C++ compiler use precompiled headers? 65634 # 65635 # Check whether --enable-precompiled-headers was given. 65636 if test "${enable_precompiled_headers+set}" = set; then : 65637 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 65638 else 65639 ENABLE_PRECOMPH=yes 65640 fi 65641 65642 65643 USE_PRECOMPILED_HEADER=1 65644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 65645 $as_echo_n "checking If precompiled header is enabled... " >&6; } 65646 if test "x$ENABLE_PRECOMPH" = xno; then 65647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65648 $as_echo "no, forced" >&6; } 65649 USE_PRECOMPILED_HEADER=0 65650 elif test "x$ICECC" != "x"; then 65651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 65652 $as_echo "no, does not work effectively with icecc" >&6; } 65653 USE_PRECOMPILED_HEADER=0 65654 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 65655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 65656 $as_echo "no, does not work with Solaris Studio" >&6; } 65657 USE_PRECOMPILED_HEADER=0 65658 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 65659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 65660 $as_echo "no, does not work with xlc" >&6; } 65661 USE_PRECOMPILED_HEADER=0 65662 else 65663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65664 $as_echo "yes" >&6; } 65665 fi 65666 65667 if test "x$ENABLE_PRECOMPH" = xyes; then 65668 # Check that the compiler actually supports precomp headers. 65669 if test "x$TOOLCHAIN_TYPE" = xgcc; then 65670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 65671 $as_echo_n "checking that precompiled headers work... " >&6; } 65672 echo "int alfa();" > conftest.h 65673 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 65674 if test ! -f conftest.hpp.gch; then 65675 USE_PRECOMPILED_HEADER=0 65676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65677 $as_echo "no" >&6; } 65678 else 65679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65680 $as_echo "yes" >&6; } 65681 fi 65682 $RM conftest.h conftest.hpp.gch 65683 fi 65684 fi 65685 65686 65687 65688 65689 # Setup use of ccache, if available 65690 65691 # Check whether --enable-ccache was given. 65692 if test "${enable_ccache+set}" = set; then : 65693 enableval=$enable_ccache; 65694 fi 65695 65696 65697 CCACHE= 65698 CCACHE_STATUS= 65699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 65700 $as_echo_n "checking is ccache enabled... " >&6; } 65701 if test "x$enable_ccache" = xyes; then 65702 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 65703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65704 $as_echo "yes" >&6; } 65705 OLD_PATH="$PATH" 65706 if test "x$TOOLCHAIN_PATH" != x; then 65707 PATH=$TOOLCHAIN_PATH:$PATH 65708 fi 65709 65710 65711 65712 # Publish this variable in the help. 65713 65714 65715 if [ -z "${CCACHE+x}" ]; then 65716 # The variable is not set by user, try to locate tool using the code snippet 65717 for ac_prog in ccache 65718 do 65719 # Extract the first word of "$ac_prog", so it can be a program name with args. 65720 set dummy $ac_prog; ac_word=$2 65721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65722 $as_echo_n "checking for $ac_word... " >&6; } 65723 if ${ac_cv_path_CCACHE+:} false; then : 65724 $as_echo_n "(cached) " >&6 65725 else 65726 case $CCACHE in 65727 [\\/]* | ?:[\\/]*) 65728 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65729 ;; 65730 *) 65731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65732 for as_dir in $PATH 65733 do 65734 IFS=$as_save_IFS 65735 test -z "$as_dir" && as_dir=. 65736 for ac_exec_ext in '' $ac_executable_extensions; do 65737 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65738 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65740 break 2 65741 fi 65742 done 65743 done 65744 IFS=$as_save_IFS 65745 65746 ;; 65747 esac 65748 fi 65749 CCACHE=$ac_cv_path_CCACHE 65750 if test -n "$CCACHE"; then 65751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65752 $as_echo "$CCACHE" >&6; } 65753 else 65754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65755 $as_echo "no" >&6; } 65756 fi 65757 65758 65759 test -n "$CCACHE" && break 65760 done 65761 65762 else 65763 # The variable is set, but is it from the command line or the environment? 65764 65765 # Try to remove the string !CCACHE! from our list. 65766 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 65767 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65768 # If it failed, the variable was not from the command line. Ignore it, 65769 # but warn the user (except for BASH, which is always set by the calling BASH). 65770 if test "xCCACHE" != xBASH; then 65771 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 65772 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 65773 fi 65774 # Try to locate tool using the code snippet 65775 for ac_prog in ccache 65776 do 65777 # Extract the first word of "$ac_prog", so it can be a program name with args. 65778 set dummy $ac_prog; ac_word=$2 65779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65780 $as_echo_n "checking for $ac_word... " >&6; } 65781 if ${ac_cv_path_CCACHE+:} false; then : 65782 $as_echo_n "(cached) " >&6 65783 else 65784 case $CCACHE in 65785 [\\/]* | ?:[\\/]*) 65786 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65787 ;; 65788 *) 65789 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65790 for as_dir in $PATH 65791 do 65792 IFS=$as_save_IFS 65793 test -z "$as_dir" && as_dir=. 65794 for ac_exec_ext in '' $ac_executable_extensions; do 65795 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65796 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65797 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65798 break 2 65799 fi 65800 done 65801 done 65802 IFS=$as_save_IFS 65803 65804 ;; 65805 esac 65806 fi 65807 CCACHE=$ac_cv_path_CCACHE 65808 if test -n "$CCACHE"; then 65809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65810 $as_echo "$CCACHE" >&6; } 65811 else 65812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65813 $as_echo "no" >&6; } 65814 fi 65815 65816 65817 test -n "$CCACHE" && break 65818 done 65819 65820 else 65821 # If it succeeded, then it was overridden by the user. We will use it 65822 # for the tool. 65823 65824 # First remove it from the list of overridden variables, so we can test 65825 # for unknown variables in the end. 65826 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65827 65828 # Check if we try to supply an empty value 65829 if test "x$CCACHE" = x; then 65830 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 65831 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 65832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65833 $as_echo_n "checking for CCACHE... " >&6; } 65834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65835 $as_echo "disabled" >&6; } 65836 else 65837 # Check if the provided tool contains a complete path. 65838 tool_specified="$CCACHE" 65839 tool_basename="${tool_specified##*/}" 65840 if test "x$tool_basename" = "x$tool_specified"; then 65841 # A command without a complete path is provided, search $PATH. 65842 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 65843 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 65844 # Extract the first word of "$tool_basename", so it can be a program name with args. 65845 set dummy $tool_basename; ac_word=$2 65846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65847 $as_echo_n "checking for $ac_word... " >&6; } 65848 if ${ac_cv_path_CCACHE+:} false; then : 65849 $as_echo_n "(cached) " >&6 65850 else 65851 case $CCACHE in 65852 [\\/]* | ?:[\\/]*) 65853 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65854 ;; 65855 *) 65856 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65857 for as_dir in $PATH 65858 do 65859 IFS=$as_save_IFS 65860 test -z "$as_dir" && as_dir=. 65861 for ac_exec_ext in '' $ac_executable_extensions; do 65862 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65863 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65864 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65865 break 2 65866 fi 65867 done 65868 done 65869 IFS=$as_save_IFS 65870 65871 ;; 65872 esac 65873 fi 65874 CCACHE=$ac_cv_path_CCACHE 65875 if test -n "$CCACHE"; then 65876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65877 $as_echo "$CCACHE" >&6; } 65878 else 65879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65880 $as_echo "no" >&6; } 65881 fi 65882 65883 65884 if test "x$CCACHE" = x; then 65885 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65886 fi 65887 else 65888 # Otherwise we believe it is a complete path. Use it as it is. 65889 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 65890 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 65891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65892 $as_echo_n "checking for CCACHE... " >&6; } 65893 if test ! -x "$tool_specified"; then 65894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65895 $as_echo "not found" >&6; } 65896 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 65897 fi 65898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65899 $as_echo "$tool_specified" >&6; } 65900 fi 65901 fi 65902 fi 65903 65904 fi 65905 65906 65907 65908 if test "x$CCACHE" = x; then 65909 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 65910 fi 65911 65912 65913 PATH="$OLD_PATH" 65914 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 65915 CCACHE_STATUS="Active ($CCACHE_VERSION)" 65916 else 65917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65918 $as_echo "no" >&6; } 65919 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 65920 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 65921 fi 65922 elif test "x$enable_ccache" = xno; then 65923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 65924 $as_echo "no, explicitly disabled" >&6; } 65925 CCACHE_STATUS="Disabled" 65926 elif test "x$enable_ccache" = x; then 65927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65928 $as_echo "no" >&6; } 65929 else 65930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 65931 $as_echo "unknown" >&6; } 65932 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 65933 fi 65934 65935 65936 65937 # Check whether --with-ccache-dir was given. 65938 if test "${with_ccache_dir+set}" = set; then : 65939 withval=$with_ccache_dir; 65940 fi 65941 65942 65943 if test "x$with_ccache_dir" != x; then 65944 # When using a non home ccache directory, assume the use is to share ccache files 65945 # with other users. Thus change the umask. 65946 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 65947 if test "x$CCACHE" = x; then 65948 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 65949 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 65950 fi 65951 fi 65952 65953 if test "x$CCACHE" != x; then 65954 65955 if test "x$CCACHE" != x; then 65956 if test "x$USE_PRECOMPILED_HEADER" = "x1"; then 65957 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 65958 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 65959 if test "x$HAS_BAD_CCACHE" != "x"; then 65960 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 65961 fi 65962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 65963 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 65964 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 65965 PUSHED_FLAGS="$CXXFLAGS" 65966 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 65967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65968 /* end confdefs.h. */ 65969 65970 int 65971 main () 65972 { 65973 65974 ; 65975 return 0; 65976 } 65977 _ACEOF 65978 if ac_fn_cxx_try_compile "$LINENO"; then : 65979 CC_KNOWS_CCACHE_TRICK=yes 65980 else 65981 CC_KNOWS_CCACHE_TRICK=no 65982 fi 65983 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 65984 CXXFLAGS="$PUSHED_FLAGS" 65985 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 65986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65987 $as_echo "yes" >&6; } 65988 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 65989 65990 CCACHE_SLOPPINESS=pch_defines,time_macros 65991 else 65992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65993 $as_echo "no" >&6; } 65994 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 65995 fi 65996 fi 65997 65998 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 65999 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 66000 66001 if test "x$SET_CCACHE_DIR" != x; then 66002 mkdir -p $CCACHE_DIR > /dev/null 2>&1 66003 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 66004 fi 66005 fi 66006 66007 fi 66008 66009 66010 ############################################################################### 66011 # 66012 # And now the finish... 66013 # 66014 ############################################################################### 66015 66016 # Check for some common pitfalls 66017 66018 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66019 file_to_test="$SRC_ROOT/LICENSE" 66020 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 66021 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 66022 fi 66023 fi 66024 66025 66026 # Did user specify any unknown variables? 66027 66028 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 66029 # Replace the separating ! with spaces before presenting for end user. 66030 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 66031 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 66032 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 66033 fi 66034 66035 66036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 66037 $as_echo_n "checking if build directory is on local disk... " >&6; } 66038 66039 # df -l lists only local disks; if the given directory is not found then 66040 # a non-zero exit code is given 66041 if test "x$DF" = x; then 66042 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66043 # msys does not have df; use Windows "net use" instead. 66044 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 66045 if test "x$IS_NETWORK_DISK" = x; then 66046 OUTPUT_DIR_IS_LOCAL="yes" 66047 else 66048 OUTPUT_DIR_IS_LOCAL="no" 66049 fi 66050 else 66051 # No df here, say it's local 66052 OUTPUT_DIR_IS_LOCAL="yes" 66053 fi 66054 else 66055 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 66056 OUTPUT_DIR_IS_LOCAL="yes" 66057 else 66058 OUTPUT_DIR_IS_LOCAL="no" 66059 fi 66060 fi 66061 66062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 66063 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 66064 66065 66066 66067 # Check if the user has any old-style ALT_ variables set. 66068 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 66069 66070 # Before generating output files, test if they exist. If they do, this is a reconfigure. 66071 # Since we can't properly handle the dependencies for this, warn the user about the situation 66072 if test -e $OUTPUT_ROOT/spec.gmk; then 66073 IS_RECONFIGURE=yes 66074 else 66075 IS_RECONFIGURE=no 66076 fi 66077 66078 66079 # At the end, call the custom hook. (Dummy macro if no custom sources available) 66080 66081 66082 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 66083 66084 # Keep feature lists sorted and free of duplicates 66085 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 66086 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 66087 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 66088 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 66089 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 66090 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 66091 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 66092 66093 # Validate features 66094 for variant in $JVM_VARIANTS; do 66095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 66096 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 66097 features_var_name=JVM_FEATURES_$variant 66098 JVM_FEATURES_TO_TEST=${!features_var_name} 66099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 66100 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 66101 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 66102 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 66103 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 66104 if test "x$INVALID_FEATURES" != x; then 66105 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 66106 fi 66107 done 66108 66109 66110 # We're messing a bit with internal autoconf variables to put the config.status 66111 # in the output directory instead of the current directory. 66112 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 66113 66114 # Create the actual output files. Now the main work of configure is done. 66115 cat >confcache <<\_ACEOF 66116 # This file is a shell script that caches the results of configure 66117 # tests run on this system so they can be shared between configure 66118 # scripts and configure runs, see configure's option --config-cache. 66119 # It is not useful on other systems. If it contains results you don't 66120 # want to keep, you may remove or edit it. 66121 # 66122 # config.status only pays attention to the cache file if you give it 66123 # the --recheck option to rerun configure. 66124 # 66125 # `ac_cv_env_foo' variables (set or unset) will be overridden when 66126 # loading this file, other *unset* `ac_cv_foo' will be assigned the 66127 # following values. 66128 66129 _ACEOF 66130 66131 # The following way of writing the cache mishandles newlines in values, 66132 # but we know of no workaround that is simple, portable, and efficient. 66133 # So, we kill variables containing newlines. 66134 # Ultrix sh set writes to stderr and can't be redirected directly, 66135 # and sets the high bit in the cache file unless we assign to the vars. 66136 ( 66137 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 66138 eval ac_val=\$$ac_var 66139 case $ac_val in #( 66140 *${as_nl}*) 66141 case $ac_var in #( 66142 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 66143 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 66144 esac 66145 case $ac_var in #( 66146 _ | IFS | as_nl) ;; #( 66147 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 66148 *) { eval $ac_var=; unset $ac_var;} ;; 66149 esac ;; 66150 esac 66151 done 66152 66153 (set) 2>&1 | 66154 case $as_nl`(ac_space=' '; set) 2>&1` in #( 66155 *${as_nl}ac_space=\ *) 66156 # `set' does not quote correctly, so add quotes: double-quote 66157 # substitution turns \\\\ into \\, and sed turns \\ into \. 66158 sed -n \ 66159 "s/'/'\\\\''/g; 66160 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 66161 ;; #( 66162 *) 66163 # `set' quotes correctly as required by POSIX, so do not add quotes. 66164 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 66165 ;; 66166 esac | 66167 sort 66168 ) | 66169 sed ' 66170 /^ac_cv_env_/b end 66171 t clear 66172 :clear 66173 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 66174 t end 66175 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 66176 :end' >>confcache 66177 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 66178 if test -w "$cache_file"; then 66179 if test "x$cache_file" != "x/dev/null"; then 66180 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 66181 $as_echo "$as_me: updating cache $cache_file" >&6;} 66182 if test ! -f "$cache_file" || test -h "$cache_file"; then 66183 cat confcache >"$cache_file" 66184 else 66185 case $cache_file in #( 66186 */* | ?:*) 66187 mv -f confcache "$cache_file"$$ && 66188 mv -f "$cache_file"$$ "$cache_file" ;; #( 66189 *) 66190 mv -f confcache "$cache_file" ;; 66191 esac 66192 fi 66193 fi 66194 else 66195 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 66196 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 66197 fi 66198 fi 66199 rm -f confcache 66200 66201 test "x$prefix" = xNONE && prefix=$ac_default_prefix 66202 # Let make expand exec_prefix. 66203 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 66204 66205 # Transform confdefs.h into DEFS. 66206 # Protect against shell expansion while executing Makefile rules. 66207 # Protect against Makefile macro expansion. 66208 # 66209 # If the first sed substitution is executed (which looks for macros that 66210 # take arguments), then branch to the quote section. Otherwise, 66211 # look for a macro that doesn't take arguments. 66212 ac_script=' 66213 :mline 66214 /\\$/{ 66215 N 66216 s,\\\n,, 66217 b mline 66218 } 66219 t clear 66220 :clear 66221 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 66222 t quote 66223 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 66224 t quote 66225 b any 66226 :quote 66227 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 66228 s/\[/\\&/g 66229 s/\]/\\&/g 66230 s/\$/$$/g 66231 H 66232 :any 66233 ${ 66234 g 66235 s/^\n// 66236 s/\n/ /g 66237 p 66238 } 66239 ' 66240 DEFS=`sed -n "$ac_script" confdefs.h` 66241 66242 66243 ac_libobjs= 66244 ac_ltlibobjs= 66245 U= 66246 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 66247 # 1. Remove the extension, and $U if already installed. 66248 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 66249 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 66250 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 66251 # will be set to the directory where LIBOBJS objects are built. 66252 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 66253 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 66254 done 66255 LIBOBJS=$ac_libobjs 66256 66257 LTLIBOBJS=$ac_ltlibobjs 66258 66259 66260 66261 : "${CONFIG_STATUS=./config.status}" 66262 ac_write_fail=0 66263 ac_clean_files_save=$ac_clean_files 66264 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 66265 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 66266 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 66267 as_write_fail=0 66268 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 66269 #! $SHELL 66270 # Generated by $as_me. 66271 # Run this file to recreate the current configuration. 66272 # Compiler output produced by configure, useful for debugging 66273 # configure, is in config.log if it exists. 66274 66275 debug=false 66276 ac_cs_recheck=false 66277 ac_cs_silent=false 66278 66279 SHELL=\${CONFIG_SHELL-$SHELL} 66280 export SHELL 66281 _ASEOF 66282 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 66283 ## -------------------- ## 66284 ## M4sh Initialization. ## 66285 ## -------------------- ## 66286 66287 # Be more Bourne compatible 66288 DUALCASE=1; export DUALCASE # for MKS sh 66289 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 66290 emulate sh 66291 NULLCMD=: 66292 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 66293 # is contrary to our usage. Disable this feature. 66294 alias -g '${1+"$@"}'='"$@"' 66295 setopt NO_GLOB_SUBST 66296 else 66297 case `(set -o) 2>/dev/null` in #( 66298 *posix*) : 66299 set -o posix ;; #( 66300 *) : 66301 ;; 66302 esac 66303 fi 66304 66305 66306 as_nl=' 66307 ' 66308 export as_nl 66309 # Printing a long string crashes Solaris 7 /usr/bin/printf. 66310 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 66311 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 66312 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 66313 # Prefer a ksh shell builtin over an external printf program on Solaris, 66314 # but without wasting forks for bash or zsh. 66315 if test -z "$BASH_VERSION$ZSH_VERSION" \ 66316 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 66317 as_echo='print -r --' 66318 as_echo_n='print -rn --' 66319 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 66320 as_echo='printf %s\n' 66321 as_echo_n='printf %s' 66322 else 66323 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 66324 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 66325 as_echo_n='/usr/ucb/echo -n' 66326 else 66327 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 66328 as_echo_n_body='eval 66329 arg=$1; 66330 case $arg in #( 66331 *"$as_nl"*) 66332 expr "X$arg" : "X\\(.*\\)$as_nl"; 66333 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 66334 esac; 66335 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 66336 ' 66337 export as_echo_n_body 66338 as_echo_n='sh -c $as_echo_n_body as_echo' 66339 fi 66340 export as_echo_body 66341 as_echo='sh -c $as_echo_body as_echo' 66342 fi 66343 66344 # The user is always right. 66345 if test "${PATH_SEPARATOR+set}" != set; then 66346 PATH_SEPARATOR=: 66347 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 66348 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 66349 PATH_SEPARATOR=';' 66350 } 66351 fi 66352 66353 66354 # IFS 66355 # We need space, tab and new line, in precisely that order. Quoting is 66356 # there to prevent editors from complaining about space-tab. 66357 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 66358 # splitting by setting IFS to empty value.) 66359 IFS=" "" $as_nl" 66360 66361 # Find who we are. Look in the path if we contain no directory separator. 66362 as_myself= 66363 case $0 in #(( 66364 *[\\/]* ) as_myself=$0 ;; 66365 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66366 for as_dir in $PATH 66367 do 66368 IFS=$as_save_IFS 66369 test -z "$as_dir" && as_dir=. 66370 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 66371 done 66372 IFS=$as_save_IFS 66373 66374 ;; 66375 esac 66376 # We did not find ourselves, most probably we were run as `sh COMMAND' 66377 # in which case we are not to be found in the path. 66378 if test "x$as_myself" = x; then 66379 as_myself=$0 66380 fi 66381 if test ! -f "$as_myself"; then 66382 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 66383 exit 1 66384 fi 66385 66386 # Unset variables that we do not need and which cause bugs (e.g. in 66387 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 66388 # suppresses any "Segmentation fault" message there. '((' could 66389 # trigger a bug in pdksh 5.2.14. 66390 for as_var in BASH_ENV ENV MAIL MAILPATH 66391 do eval test x\${$as_var+set} = xset \ 66392 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 66393 done 66394 PS1='$ ' 66395 PS2='> ' 66396 PS4='+ ' 66397 66398 # NLS nuisances. 66399 LC_ALL=C 66400 export LC_ALL 66401 LANGUAGE=C 66402 export LANGUAGE 66403 66404 # CDPATH. 66405 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 66406 66407 66408 # as_fn_error STATUS ERROR [LINENO LOG_FD] 66409 # ---------------------------------------- 66410 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 66411 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 66412 # script with STATUS, using 1 if that was 0. 66413 as_fn_error () 66414 { 66415 as_status=$1; test $as_status -eq 0 && as_status=1 66416 if test "$4"; then 66417 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 66418 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 66419 fi 66420 $as_echo "$as_me: error: $2" >&2 66421 as_fn_exit $as_status 66422 } # as_fn_error 66423 66424 66425 # as_fn_set_status STATUS 66426 # ----------------------- 66427 # Set $? to STATUS, without forking. 66428 as_fn_set_status () 66429 { 66430 return $1 66431 } # as_fn_set_status 66432 66433 # as_fn_exit STATUS 66434 # ----------------- 66435 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 66436 as_fn_exit () 66437 { 66438 set +e 66439 as_fn_set_status $1 66440 exit $1 66441 } # as_fn_exit 66442 66443 # as_fn_unset VAR 66444 # --------------- 66445 # Portably unset VAR. 66446 as_fn_unset () 66447 { 66448 { eval $1=; unset $1;} 66449 } 66450 as_unset=as_fn_unset 66451 # as_fn_append VAR VALUE 66452 # ---------------------- 66453 # Append the text in VALUE to the end of the definition contained in VAR. Take 66454 # advantage of any shell optimizations that allow amortized linear growth over 66455 # repeated appends, instead of the typical quadratic growth present in naive 66456 # implementations. 66457 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 66458 eval 'as_fn_append () 66459 { 66460 eval $1+=\$2 66461 }' 66462 else 66463 as_fn_append () 66464 { 66465 eval $1=\$$1\$2 66466 } 66467 fi # as_fn_append 66468 66469 # as_fn_arith ARG... 66470 # ------------------ 66471 # Perform arithmetic evaluation on the ARGs, and store the result in the 66472 # global $as_val. Take advantage of shells that can avoid forks. The arguments 66473 # must be portable across $(()) and expr. 66474 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 66475 eval 'as_fn_arith () 66476 { 66477 as_val=$(( $* )) 66478 }' 66479 else 66480 as_fn_arith () 66481 { 66482 as_val=`expr "$@" || test $? -eq 1` 66483 } 66484 fi # as_fn_arith 66485 66486 66487 if expr a : '\(a\)' >/dev/null 2>&1 && 66488 test "X`expr 00001 : '.*\(...\)'`" = X001; then 66489 as_expr=expr 66490 else 66491 as_expr=false 66492 fi 66493 66494 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 66495 as_basename=basename 66496 else 66497 as_basename=false 66498 fi 66499 66500 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 66501 as_dirname=dirname 66502 else 66503 as_dirname=false 66504 fi 66505 66506 as_me=`$as_basename -- "$0" || 66507 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 66508 X"$0" : 'X\(//\)$' \| \ 66509 X"$0" : 'X\(/\)' \| . 2>/dev/null || 66510 $as_echo X/"$0" | 66511 sed '/^.*\/\([^/][^/]*\)\/*$/{ 66512 s//\1/ 66513 q 66514 } 66515 /^X\/\(\/\/\)$/{ 66516 s//\1/ 66517 q 66518 } 66519 /^X\/\(\/\).*/{ 66520 s//\1/ 66521 q 66522 } 66523 s/.*/./; q'` 66524 66525 # Avoid depending upon Character Ranges. 66526 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 66527 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 66528 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 66529 as_cr_digits='0123456789' 66530 as_cr_alnum=$as_cr_Letters$as_cr_digits 66531 66532 ECHO_C= ECHO_N= ECHO_T= 66533 case `echo -n x` in #((((( 66534 -n*) 66535 case `echo 'xy\c'` in 66536 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 66537 xy) ECHO_C='\c';; 66538 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 66539 ECHO_T=' ';; 66540 esac;; 66541 *) 66542 ECHO_N='-n';; 66543 esac 66544 66545 rm -f conf$$ conf$$.exe conf$$.file 66546 if test -d conf$$.dir; then 66547 rm -f conf$$.dir/conf$$.file 66548 else 66549 rm -f conf$$.dir 66550 mkdir conf$$.dir 2>/dev/null 66551 fi 66552 if (echo >conf$$.file) 2>/dev/null; then 66553 if ln -s conf$$.file conf$$ 2>/dev/null; then 66554 as_ln_s='ln -s' 66555 # ... but there are two gotchas: 66556 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 66557 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 66558 # In both cases, we have to default to `cp -pR'. 66559 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 66560 as_ln_s='cp -pR' 66561 elif ln conf$$.file conf$$ 2>/dev/null; then 66562 as_ln_s=ln 66563 else 66564 as_ln_s='cp -pR' 66565 fi 66566 else 66567 as_ln_s='cp -pR' 66568 fi 66569 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 66570 rmdir conf$$.dir 2>/dev/null 66571 66572 66573 # as_fn_mkdir_p 66574 # ------------- 66575 # Create "$as_dir" as a directory, including parents if necessary. 66576 as_fn_mkdir_p () 66577 { 66578 66579 case $as_dir in #( 66580 -*) as_dir=./$as_dir;; 66581 esac 66582 test -d "$as_dir" || eval $as_mkdir_p || { 66583 as_dirs= 66584 while :; do 66585 case $as_dir in #( 66586 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 66587 *) as_qdir=$as_dir;; 66588 esac 66589 as_dirs="'$as_qdir' $as_dirs" 66590 as_dir=`$as_dirname -- "$as_dir" || 66591 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 66592 X"$as_dir" : 'X\(//\)[^/]' \| \ 66593 X"$as_dir" : 'X\(//\)$' \| \ 66594 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 66595 $as_echo X"$as_dir" | 66596 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 66597 s//\1/ 66598 q 66599 } 66600 /^X\(\/\/\)[^/].*/{ 66601 s//\1/ 66602 q 66603 } 66604 /^X\(\/\/\)$/{ 66605 s//\1/ 66606 q 66607 } 66608 /^X\(\/\).*/{ 66609 s//\1/ 66610 q 66611 } 66612 s/.*/./; q'` 66613 test -d "$as_dir" && break 66614 done 66615 test -z "$as_dirs" || eval "mkdir $as_dirs" 66616 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 66617 66618 66619 } # as_fn_mkdir_p 66620 if mkdir -p . 2>/dev/null; then 66621 as_mkdir_p='mkdir -p "$as_dir"' 66622 else 66623 test -d ./-p && rmdir ./-p 66624 as_mkdir_p=false 66625 fi 66626 66627 66628 # as_fn_executable_p FILE 66629 # ----------------------- 66630 # Test if FILE is an executable regular file. 66631 as_fn_executable_p () 66632 { 66633 test -f "$1" && test -x "$1" 66634 } # as_fn_executable_p 66635 as_test_x='test -x' 66636 as_executable_p=as_fn_executable_p 66637 66638 # Sed expression to map a string onto a valid CPP name. 66639 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 66640 66641 # Sed expression to map a string onto a valid variable name. 66642 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 66643 66644 66645 exec 6>&1 66646 ## ----------------------------------- ## 66647 ## Main body of $CONFIG_STATUS script. ## 66648 ## ----------------------------------- ## 66649 _ASEOF 66650 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 66651 66652 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66653 # Save the log message, to keep $0 and so on meaningful, and to 66654 # report actual input values of CONFIG_FILES etc. instead of their 66655 # values after options handling. 66656 ac_log=" 66657 This file was extended by OpenJDK $as_me jdk9, which was 66658 generated by GNU Autoconf 2.69. Invocation command line was 66659 66660 CONFIG_FILES = $CONFIG_FILES 66661 CONFIG_HEADERS = $CONFIG_HEADERS 66662 CONFIG_LINKS = $CONFIG_LINKS 66663 CONFIG_COMMANDS = $CONFIG_COMMANDS 66664 $ $0 $@ 66665 66666 on `(hostname || uname -n) 2>/dev/null | sed 1q` 66667 " 66668 66669 _ACEOF 66670 66671 case $ac_config_files in *" 66672 "*) set x $ac_config_files; shift; ac_config_files=$*;; 66673 esac 66674 66675 66676 66677 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66678 # Files that config.status was made for. 66679 config_files="$ac_config_files" 66680 66681 _ACEOF 66682 66683 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66684 ac_cs_usage="\ 66685 \`$as_me' instantiates files and other configuration actions 66686 from templates according to the current configuration. Unless the files 66687 and actions are specified as TAGs, all are instantiated by default. 66688 66689 Usage: $0 [OPTION]... [TAG]... 66690 66691 -h, --help print this help, then exit 66692 -V, --version print version number and configuration settings, then exit 66693 --config print configuration, then exit 66694 -q, --quiet, --silent 66695 do not print progress messages 66696 -d, --debug don't remove temporary files 66697 --recheck update $as_me by reconfiguring in the same conditions 66698 --file=FILE[:TEMPLATE] 66699 instantiate the configuration file FILE 66700 66701 Configuration files: 66702 $config_files 66703 66704 Report bugs to <build-dev@openjdk.java.net>. 66705 OpenJDK home page: <http://openjdk.java.net>." 66706 66707 _ACEOF 66708 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66709 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 66710 ac_cs_version="\\ 66711 OpenJDK config.status jdk9 66712 configured by $0, generated by GNU Autoconf 2.69, 66713 with options \\"\$ac_cs_config\\" 66714 66715 Copyright (C) 2012 Free Software Foundation, Inc. 66716 This config.status script is free software; the Free Software Foundation 66717 gives unlimited permission to copy, distribute and modify it." 66718 66719 ac_pwd='$ac_pwd' 66720 srcdir='$srcdir' 66721 AWK='$AWK' 66722 test -n "\$AWK" || AWK=awk 66723 _ACEOF 66724 66725 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66726 # The default lists apply if the user does not specify any file. 66727 ac_need_defaults=: 66728 while test $# != 0 66729 do 66730 case $1 in 66731 --*=?*) 66732 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66733 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 66734 ac_shift=: 66735 ;; 66736 --*=) 66737 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66738 ac_optarg= 66739 ac_shift=: 66740 ;; 66741 *) 66742 ac_option=$1 66743 ac_optarg=$2 66744 ac_shift=shift 66745 ;; 66746 esac 66747 66748 case $ac_option in 66749 # Handling of the options. 66750 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 66751 ac_cs_recheck=: ;; 66752 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 66753 $as_echo "$ac_cs_version"; exit ;; 66754 --config | --confi | --conf | --con | --co | --c ) 66755 $as_echo "$ac_cs_config"; exit ;; 66756 --debug | --debu | --deb | --de | --d | -d ) 66757 debug=: ;; 66758 --file | --fil | --fi | --f ) 66759 $ac_shift 66760 case $ac_optarg in 66761 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 66762 '') as_fn_error $? "missing file argument" ;; 66763 esac 66764 as_fn_append CONFIG_FILES " '$ac_optarg'" 66765 ac_need_defaults=false;; 66766 --he | --h | --help | --hel | -h ) 66767 $as_echo "$ac_cs_usage"; exit ;; 66768 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 66769 | -silent | --silent | --silen | --sile | --sil | --si | --s) 66770 ac_cs_silent=: ;; 66771 66772 # This is an error. 66773 -*) as_fn_error $? "unrecognized option: \`$1' 66774 Try \`$0 --help' for more information." ;; 66775 66776 *) as_fn_append ac_config_targets " $1" 66777 ac_need_defaults=false ;; 66778 66779 esac 66780 shift 66781 done 66782 66783 ac_configure_extra_args= 66784 66785 if $ac_cs_silent; then 66786 exec 6>/dev/null 66787 ac_configure_extra_args="$ac_configure_extra_args --silent" 66788 fi 66789 66790 _ACEOF 66791 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66792 if \$ac_cs_recheck; then 66793 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 66794 shift 66795 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 66796 CONFIG_SHELL='$SHELL' 66797 export CONFIG_SHELL 66798 exec "\$@" 66799 fi 66800 66801 _ACEOF 66802 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66803 exec 5>>config.log 66804 { 66805 echo 66806 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 66807 ## Running $as_me. ## 66808 _ASBOX 66809 $as_echo "$ac_log" 66810 } >&5 66811 66812 _ACEOF 66813 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66814 _ACEOF 66815 66816 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66817 66818 # Handling of arguments. 66819 for ac_config_target in $ac_config_targets 66820 do 66821 case $ac_config_target in 66822 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 66823 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 66824 "$OUTPUT_ROOT/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 66825 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 66826 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 66827 66828 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 66829 esac 66830 done 66831 66832 66833 # If the user did not use the arguments to specify the items to instantiate, 66834 # then the envvar interface is used. Set only those that are not. 66835 # We use the long form for the default assignment because of an extremely 66836 # bizarre bug on SunOS 4.1.3. 66837 if $ac_need_defaults; then 66838 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 66839 fi 66840 66841 # Have a temporary directory for convenience. Make it in the build tree 66842 # simply because there is no reason against having it here, and in addition, 66843 # creating and moving files from /tmp can sometimes cause problems. 66844 # Hook for its removal unless debugging. 66845 # Note that there is a small window in which the directory will not be cleaned: 66846 # after its creation but before its name has been assigned to `$tmp'. 66847 $debug || 66848 { 66849 tmp= ac_tmp= 66850 trap 'exit_status=$? 66851 : "${ac_tmp:=$tmp}" 66852 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 66853 ' 0 66854 trap 'as_fn_exit 1' 1 2 13 15 66855 } 66856 # Create a (secure) tmp directory for tmp files. 66857 66858 { 66859 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 66860 test -d "$tmp" 66861 } || 66862 { 66863 tmp=./conf$$-$RANDOM 66864 (umask 077 && mkdir "$tmp") 66865 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 66866 ac_tmp=$tmp 66867 66868 # Set up the scripts for CONFIG_FILES section. 66869 # No need to generate them if there are no CONFIG_FILES. 66870 # This happens for instance with `./config.status config.h'. 66871 if test -n "$CONFIG_FILES"; then 66872 66873 66874 ac_cr=`echo X | tr X '\015'` 66875 # On cygwin, bash can eat \r inside `` if the user requested igncr. 66876 # But we know of no other shell where ac_cr would be empty at this 66877 # point, so we can use a bashism as a fallback. 66878 if test "x$ac_cr" = x; then 66879 eval ac_cr=\$\'\\r\' 66880 fi 66881 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 66882 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 66883 ac_cs_awk_cr='\\r' 66884 else 66885 ac_cs_awk_cr=$ac_cr 66886 fi 66887 66888 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 66889 _ACEOF 66890 66891 66892 { 66893 echo "cat >conf$$subs.awk <<_ACEOF" && 66894 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 66895 echo "_ACEOF" 66896 } >conf$$subs.sh || 66897 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66898 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 66899 ac_delim='%!_!# ' 66900 for ac_last_try in false false false false false :; do 66901 . ./conf$$subs.sh || 66902 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66903 66904 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 66905 if test $ac_delim_n = $ac_delim_num; then 66906 break 66907 elif $ac_last_try; then 66908 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66909 else 66910 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 66911 fi 66912 done 66913 rm -f conf$$subs.sh 66914 66915 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66916 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 66917 _ACEOF 66918 sed -n ' 66919 h 66920 s/^/S["/; s/!.*/"]=/ 66921 p 66922 g 66923 s/^[^!]*!// 66924 :repl 66925 t repl 66926 s/'"$ac_delim"'$// 66927 t delim 66928 :nl 66929 h 66930 s/\(.\{148\}\)..*/\1/ 66931 t more1 66932 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 66933 p 66934 n 66935 b repl 66936 :more1 66937 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66938 p 66939 g 66940 s/.\{148\}// 66941 t nl 66942 :delim 66943 h 66944 s/\(.\{148\}\)..*/\1/ 66945 t more2 66946 s/["\\]/\\&/g; s/^/"/; s/$/"/ 66947 p 66948 b 66949 :more2 66950 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66951 p 66952 g 66953 s/.\{148\}// 66954 t delim 66955 ' <conf$$subs.awk | sed ' 66956 /^[^""]/{ 66957 N 66958 s/\n// 66959 } 66960 ' >>$CONFIG_STATUS || ac_write_fail=1 66961 rm -f conf$$subs.awk 66962 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66963 _ACAWK 66964 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 66965 for (key in S) S_is_set[key] = 1 66966 FS = "" 66967 66968 } 66969 { 66970 line = $ 0 66971 nfields = split(line, field, "@") 66972 substed = 0 66973 len = length(field[1]) 66974 for (i = 2; i < nfields; i++) { 66975 key = field[i] 66976 keylen = length(key) 66977 if (S_is_set[key]) { 66978 value = S[key] 66979 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 66980 len += length(value) + length(field[++i]) 66981 substed = 1 66982 } else 66983 len += 1 + keylen 66984 } 66985 66986 print line 66987 } 66988 66989 _ACAWK 66990 _ACEOF 66991 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66992 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 66993 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 66994 else 66995 cat 66996 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 66997 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 66998 _ACEOF 66999 67000 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 67001 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 67002 # trailing colons and then remove the whole line if VPATH becomes empty 67003 # (actually we leave an empty line to preserve line numbers). 67004 if test "x$srcdir" = x.; then 67005 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 67006 h 67007 s/// 67008 s/^/:/ 67009 s/[ ]*$/:/ 67010 s/:\$(srcdir):/:/g 67011 s/:\${srcdir}:/:/g 67012 s/:@srcdir@:/:/g 67013 s/^:*// 67014 s/:*$// 67015 x 67016 s/\(=[ ]*\).*/\1/ 67017 G 67018 s/\n// 67019 s/^[^=]*=[ ]*$// 67020 }' 67021 fi 67022 67023 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67024 fi # test -n "$CONFIG_FILES" 67025 67026 67027 eval set X " :F $CONFIG_FILES " 67028 shift 67029 for ac_tag 67030 do 67031 case $ac_tag in 67032 :[FHLC]) ac_mode=$ac_tag; continue;; 67033 esac 67034 case $ac_mode$ac_tag in 67035 :[FHL]*:*);; 67036 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 67037 :[FH]-) ac_tag=-:-;; 67038 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 67039 esac 67040 ac_save_IFS=$IFS 67041 IFS=: 67042 set x $ac_tag 67043 IFS=$ac_save_IFS 67044 shift 67045 ac_file=$1 67046 shift 67047 67048 case $ac_mode in 67049 :L) ac_source=$1;; 67050 :[FH]) 67051 ac_file_inputs= 67052 for ac_f 67053 do 67054 case $ac_f in 67055 -) ac_f="$ac_tmp/stdin";; 67056 *) # Look for the file first in the build tree, then in the source tree 67057 # (if the path is not absolute). The absolute path cannot be DOS-style, 67058 # because $ac_f cannot contain `:'. 67059 test -f "$ac_f" || 67060 case $ac_f in 67061 [\\/$]*) false;; 67062 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 67063 esac || 67064 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 67065 esac 67066 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 67067 as_fn_append ac_file_inputs " '$ac_f'" 67068 done 67069 67070 # Let's still pretend it is `configure' which instantiates (i.e., don't 67071 # use $as_me), people would be surprised to read: 67072 # /* config.h. Generated by config.status. */ 67073 configure_input='Generated from '` 67074 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 67075 `' by configure.' 67076 if test x"$ac_file" != x-; then 67077 configure_input="$ac_file. $configure_input" 67078 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 67079 $as_echo "$as_me: creating $ac_file" >&6;} 67080 fi 67081 # Neutralize special characters interpreted by sed in replacement strings. 67082 case $configure_input in #( 67083 *\&* | *\|* | *\\* ) 67084 ac_sed_conf_input=`$as_echo "$configure_input" | 67085 sed 's/[\\\\&|]/\\\\&/g'`;; #( 67086 *) ac_sed_conf_input=$configure_input;; 67087 esac 67088 67089 case $ac_tag in 67090 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 67091 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 67092 esac 67093 ;; 67094 esac 67095 67096 ac_dir=`$as_dirname -- "$ac_file" || 67097 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 67098 X"$ac_file" : 'X\(//\)[^/]' \| \ 67099 X"$ac_file" : 'X\(//\)$' \| \ 67100 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 67101 $as_echo X"$ac_file" | 67102 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 67103 s//\1/ 67104 q 67105 } 67106 /^X\(\/\/\)[^/].*/{ 67107 s//\1/ 67108 q 67109 } 67110 /^X\(\/\/\)$/{ 67111 s//\1/ 67112 q 67113 } 67114 /^X\(\/\).*/{ 67115 s//\1/ 67116 q 67117 } 67118 s/.*/./; q'` 67119 as_dir="$ac_dir"; as_fn_mkdir_p 67120 ac_builddir=. 67121 67122 case "$ac_dir" in 67123 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 67124 *) 67125 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 67126 # A ".." for each directory in $ac_dir_suffix. 67127 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 67128 case $ac_top_builddir_sub in 67129 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 67130 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 67131 esac ;; 67132 esac 67133 ac_abs_top_builddir=$ac_pwd 67134 ac_abs_builddir=$ac_pwd$ac_dir_suffix 67135 # for backward compatibility: 67136 ac_top_builddir=$ac_top_build_prefix 67137 67138 case $srcdir in 67139 .) # We are building in place. 67140 ac_srcdir=. 67141 ac_top_srcdir=$ac_top_builddir_sub 67142 ac_abs_top_srcdir=$ac_pwd ;; 67143 [\\/]* | ?:[\\/]* ) # Absolute name. 67144 ac_srcdir=$srcdir$ac_dir_suffix; 67145 ac_top_srcdir=$srcdir 67146 ac_abs_top_srcdir=$srcdir ;; 67147 *) # Relative name. 67148 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 67149 ac_top_srcdir=$ac_top_build_prefix$srcdir 67150 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 67151 esac 67152 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 67153 67154 67155 case $ac_mode in 67156 :F) 67157 # 67158 # CONFIG_FILE 67159 # 67160 67161 _ACEOF 67162 67163 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67164 # If the template does not know about datarootdir, expand it. 67165 # FIXME: This hack should be removed a few years after 2.60. 67166 ac_datarootdir_hack=; ac_datarootdir_seen= 67167 ac_sed_dataroot=' 67168 /datarootdir/ { 67169 p 67170 q 67171 } 67172 /@datadir@/p 67173 /@docdir@/p 67174 /@infodir@/p 67175 /@localedir@/p 67176 /@mandir@/p' 67177 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 67178 *datarootdir*) ac_datarootdir_seen=yes;; 67179 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 67180 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 67181 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 67182 _ACEOF 67183 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67184 ac_datarootdir_hack=' 67185 s&@datadir@&$datadir&g 67186 s&@docdir@&$docdir&g 67187 s&@infodir@&$infodir&g 67188 s&@localedir@&$localedir&g 67189 s&@mandir@&$mandir&g 67190 s&\\\${datarootdir}&$datarootdir&g' ;; 67191 esac 67192 _ACEOF 67193 67194 # Neutralize VPATH when `$srcdir' = `.'. 67195 # Shell code in configure.ac might set extrasub. 67196 # FIXME: do we really want to maintain this feature? 67197 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67198 ac_sed_extra="$ac_vpsub 67199 $extrasub 67200 _ACEOF 67201 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67202 :t 67203 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 67204 s|@configure_input@|$ac_sed_conf_input|;t t 67205 s&@top_builddir@&$ac_top_builddir_sub&;t t 67206 s&@top_build_prefix@&$ac_top_build_prefix&;t t 67207 s&@srcdir@&$ac_srcdir&;t t 67208 s&@abs_srcdir@&$ac_abs_srcdir&;t t 67209 s&@top_srcdir@&$ac_top_srcdir&;t t 67210 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 67211 s&@builddir@&$ac_builddir&;t t 67212 s&@abs_builddir@&$ac_abs_builddir&;t t 67213 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 67214 $ac_datarootdir_hack 67215 " 67216 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 67217 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 67218 67219 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 67220 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 67221 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 67222 "$ac_tmp/out"`; test -z "$ac_out"; } && 67223 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 67224 which seems to be undefined. Please make sure it is defined" >&5 67225 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 67226 which seems to be undefined. Please make sure it is defined" >&2;} 67227 67228 rm -f "$ac_tmp/stdin" 67229 case $ac_file in 67230 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 67231 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 67232 esac \ 67233 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 67234 ;; 67235 67236 67237 67238 esac 67239 67240 done # for ac_tag 67241 67242 67243 as_fn_exit 0 67244 _ACEOF 67245 ac_clean_files=$ac_clean_files_save 67246 67247 test $ac_write_fail = 0 || 67248 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 67249 67250 67251 # configure is writing to config.log, and then calls config.status. 67252 # config.status does its own redirection, appending to config.log. 67253 # Unfortunately, on DOS this fails, as config.log is still kept open 67254 # by configure, so config.status won't be able to write to it; its 67255 # output is simply discarded. So we exec the FD to /dev/null, 67256 # effectively closing config.log, so it can be properly (re)opened and 67257 # appended to by config.status. When coming back to configure, we 67258 # need to make the FD available again. 67259 if test "$no_create" != yes; then 67260 ac_cs_success=: 67261 ac_config_status_args= 67262 test "$silent" = yes && 67263 ac_config_status_args="$ac_config_status_args --quiet" 67264 exec 5>/dev/null 67265 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 67266 exec 5>>config.log 67267 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 67268 # would make configure fail if this is the last instruction. 67269 $ac_cs_success || as_fn_exit 1 67270 fi 67271 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 67272 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 67273 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 67274 fi 67275 67276 67277 # After AC_OUTPUT, we need to do final work 67278 67279 67280 # Try to move config.log (generated by autoconf) to the configure-support directory. 67281 if test -e ./config.log; then 67282 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 67283 fi 67284 67285 # Rotate our log file (configure.log) 67286 if test -e "$OUTPUT_ROOT/configure.log.old"; then 67287 $RM -f "$OUTPUT_ROOT/configure.log.old" 67288 fi 67289 if test -e "$OUTPUT_ROOT/configure.log"; then 67290 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 67291 fi 67292 67293 # Move configure.log from current directory to the build output root 67294 if test -e ./configure.log; then 67295 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 67296 fi 67297 67298 # Make the compare script executable 67299 $CHMOD +x $OUTPUT_ROOT/compare.sh 67300 67301 67302 # Finally output some useful information to the user 67303 67304 # Finally output some useful information to the user 67305 67306 printf "\n" 67307 printf "====================================================\n" 67308 if test "x$no_create" != "xyes"; then 67309 if test "x$IS_RECONFIGURE" != "xyes"; then 67310 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 67311 else 67312 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 67313 fi 67314 else 67315 if test "x$IS_RECONFIGURE" != "xyes"; then 67316 printf "A configuration has been successfully checked but not created\n" 67317 else 67318 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 67319 fi 67320 fi 67321 if test "x$CONFIGURE_COMMAND_LINE" != x; then 67322 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 67323 else 67324 printf "using default settings.\n" 67325 fi 67326 67327 printf "\n" 67328 printf "Configuration summary:\n" 67329 printf "* Debug level: $DEBUG_LEVEL\n" 67330 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 67331 printf "* JDK variant: $JDK_VARIANT\n" 67332 printf "* JVM variants: $JVM_VARIANTS\n" 67333 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 67334 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 67335 67336 printf "\n" 67337 printf "Tools summary:\n" 67338 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 67339 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 67340 fi 67341 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 67342 if test "x$TOOLCHAIN_VERSION" != "x"; then 67343 print_version=" $TOOLCHAIN_VERSION" 67344 fi 67345 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 67346 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 67347 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 67348 67349 printf "\n" 67350 printf "Build performance summary:\n" 67351 printf "* Cores to use: $JOBS\n" 67352 printf "* Memory limit: $MEMORY_SIZE MB\n" 67353 if test "x$CCACHE_STATUS" != "x"; then 67354 printf "* ccache status: $CCACHE_STATUS\n" 67355 fi 67356 printf "\n" 67357 67358 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 67359 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 67360 printf "will result in longer build times.\n" 67361 printf "\n" 67362 fi 67363 67364 if test "x$FOUND_ALT_VARIABLES" != "x"; then 67365 printf "WARNING: You have old-style ALT_ environment variables set.\n" 67366 printf "These are not respected, and will be ignored. It is recommended\n" 67367 printf "that you clean your environment. The following variables are set:\n" 67368 printf "$FOUND_ALT_VARIABLES\n" 67369 printf "\n" 67370 fi 67371 67372 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 67373 printf "WARNING: Your build output directory is not on a local disk.\n" 67374 printf "This will severely degrade build performance!\n" 67375 printf "It is recommended that you create an output directory on a local disk,\n" 67376 printf "and run the configure script again from that directory.\n" 67377 printf "\n" 67378 fi 67379 67380 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 67381 printf "WARNING: The result of this configuration has overridden an older\n" 67382 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 67383 printf "proper build. Failure to do so might result in strange build problems.\n" 67384 printf "\n" 67385 fi 67386 67387 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 67388 printf "WARNING: The result of this configuration was not saved.\n" 67389 printf "You should run without '--no-create | -n' to create the configuration.\n" 67390 printf "\n" 67391 fi 67392 67393 67394 67395 # Locate config.log. 67396 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 67397 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 67398 elif test -e "./config.log"; then 67399 CONFIG_LOG_PATH="." 67400 fi 67401 67402 if test -e "$CONFIG_LOG_PATH/config.log"; then 67403 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 67404 if test $? -eq 0; then 67405 printf "The following warnings were produced. Repeated here for convenience:\n" 67406 # We must quote sed expression (using []) to stop m4 from eating the []. 67407 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 67408 printf "\n" 67409 fi 67410 fi 67411